feat: add enableCopilot prop to Editor and update ScheduledMessageModal to disable copilot
This commit is contained in:
parent
85ec13a273
commit
360ad59732
@ -92,6 +92,7 @@ const props = defineProps({
|
|||||||
medium: { type: String, default: '' },
|
medium: { type: String, default: '' },
|
||||||
showImageResizeToolbar: { type: Boolean, default: false }, // A kill switch to show or hide the image toolbar
|
showImageResizeToolbar: { type: Boolean, default: false }, // A kill switch to show or hide the image toolbar
|
||||||
focusOnMount: { type: Boolean, default: true },
|
focusOnMount: { type: Boolean, default: true },
|
||||||
|
enableCopilot: { type: Boolean, default: true },
|
||||||
});
|
});
|
||||||
|
|
||||||
const emit = defineEmits([
|
const emit = defineEmits([
|
||||||
@ -110,7 +111,10 @@ const emit = defineEmits([
|
|||||||
]);
|
]);
|
||||||
|
|
||||||
const { t } = useI18n();
|
const { t } = useI18n();
|
||||||
const { captainTasksEnabled } = useCaptain();
|
const { captainTasksEnabled: rawCaptainTasksEnabled } = useCaptain();
|
||||||
|
const captainTasksEnabled = computed(
|
||||||
|
() => props.enableCopilot && rawCaptainTasksEnabled.value
|
||||||
|
);
|
||||||
|
|
||||||
const TYPING_INDICATOR_IDLE_TIME = 4000;
|
const TYPING_INDICATOR_IDLE_TIME = 4000;
|
||||||
const MAXIMUM_FILE_UPLOAD_SIZE = 4; // in MB
|
const MAXIMUM_FILE_UPLOAD_SIZE = 4; // in MB
|
||||||
|
|||||||
@ -504,6 +504,7 @@ watch(
|
|||||||
:channel-type="currentInbox?.channel_type"
|
:channel-type="currentInbox?.channel_type"
|
||||||
:medium="currentInbox?.medium"
|
:medium="currentInbox?.medium"
|
||||||
:disabled="hasTemplate"
|
:disabled="hasTemplate"
|
||||||
|
:enable-copilot="false"
|
||||||
override-line-breaks
|
override-line-breaks
|
||||||
@update:model-value="
|
@update:model-value="
|
||||||
() => {
|
() => {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user