2323 <div >
2424 <NcFormGroup :label =" t (' assistant' , ' Select which features you want to enable' )"
2525 class="switch-group">
26- <NcFormBoxSwitch :model-value =" state .assistant_enabled "
27- @update :model-value =" onCheckboxChanged ($event , ' assistant_enabled' )" >
28- {{ t('assistant', 'Enable Nextcloud Assistant in header') }}
29- </NcFormBoxSwitch >
30- <NcNoteCard v-if =" ! state .text_processing_available " type="warning">
31- {{ t('assistant', 'To be able to use this feature, please install at least one AI task processing provider.') }}
32- </NcNoteCard >
33- <NcFormBoxSwitch :model-value =" state .free_prompt_picker_enabled "
34- :disabled =" ! state .free_prompt_task_type_available "
35- @update :model-value =" onCheckboxChanged ($event , ' free_prompt_picker_enabled' )" >
36- {{ t('assistant', 'Enable AI text generation in smart picker') }}
37- </NcFormBoxSwitch >
38- <NcNoteCard v-if =" ! state .free_prompt_task_type_available " type="info">
39- <div class =" checkbox-text" >
40- <span >
41- {{ t('assistant', 'To enable text generation in the smart picker, please install an AI task processing provider for the "Free text to text prompt" task type:') }}
42- </span >
43- <ul >
44- <li ><a href =" https://github.com/nextcloud/llm2#readme" >Local Large language model app</a ></li >
45- <li ><a href =" https://apps.nextcloud.com/apps/integration_openai" >OpenAI/LocalAI Integration</a ></li >
46- </ul >
47- </div >
48- </NcNoteCard >
49- <NcFormBoxSwitch :model-value =" state .text_to_image_picker_enabled "
50- :disabled =" ! state .text_to_image_picker_available "
51- @update :model-value =" onCheckboxChanged ($event , ' text_to_image_picker_enabled' )" >
52- {{ t('assistant', 'Enable text-to-image in smart picker') }}
53- </NcFormBoxSwitch >
54- <NcFormBoxSwitch :model-value =" state .text_to_sticker_picker_enabled "
55- :disabled =" ! state .text_to_image_picker_available "
56- @update :model-value =" onCheckboxChanged ($event , ' text_to_sticker_picker_enabled' )" >
57- {{ t('assistant', 'Enable text-to-sticker in smart picker') }}
58- </NcFormBoxSwitch >
59- <NcNoteCard v-if =" ! state .text_to_image_picker_available " type="warning">
60- <div class =" checkbox-text" >
61- <span >
62- {{ t('assistant', 'To enable the sticker generation picker or the image generation picker, please install and enable a "Generate image" provider:') }}
63- </span >
64- <ul >
65- <li ><a href =" https://github.com/nextcloud/text2image_stablediffusion#readme" >Local Text-To-Image StableDiffusion</a ></li >
66- <li ><a href =" https://apps.nextcloud.com/apps/integration_openai" >OpenAI/LocalAI Integration</a ></li >
67- </ul >
68- </div >
69- </NcNoteCard >
70- <NcFormBoxSwitch :model-value =" state .speech_to_text_picker_enabled "
71- :disabled =" ! state .speech_to_text_picker_available "
72- @update :model-value =" onCheckboxChanged ($event , ' speech_to_text_picker_enabled' )" >
73- {{ t('assistant', 'Enable speech-to-text in smart picker') }}
74- </NcFormBoxSwitch >
75- <NcNoteCard v-if =" ! state .speech_to_text_picker_available " type="warning">
76- <div class =" checkbox-text" >
77- <span >
78- {{ t('assistant', 'To enable speech-to-text in the smart picker, please install and enable a "Transcribe audio" provider:') }}
79- </span >
80- <ul >
81- <li ><a href =" https://github.com/nextcloud/stt_whisper2#readme" >Local Speech-To-Text Whisper</a ></li >
82- <li ><a href =" https://apps.nextcloud.com/apps/integration_openai" >OpenAI/LocalAI Integration</a ></li >
83- </ul >
84- </div >
85- </NcNoteCard >
26+ <NcFormBox >
27+ <NcFormBoxSwitch :model-value =" state .assistant_enabled "
28+ @update :model-value =" onCheckboxChanged ($event , ' assistant_enabled' )" >
29+ {{ t('assistant', 'Enable Nextcloud Assistant in header') }}
30+ </NcFormBoxSwitch >
31+ <NcNoteCard v-if =" ! state .text_processing_available " type="warning">
32+ {{ t('assistant', 'To be able to use this feature, please install at least one AI task processing provider.') }}
33+ </NcNoteCard >
34+ <NcFormBoxSwitch :model-value =" state .free_prompt_picker_enabled "
35+ :disabled =" ! state .free_prompt_task_type_available "
36+ @update :model-value =" onCheckboxChanged ($event , ' free_prompt_picker_enabled' )" >
37+ {{ t('assistant', 'Enable AI text generation in smart picker') }}
38+ </NcFormBoxSwitch >
39+ <NcNoteCard v-if =" ! state .free_prompt_task_type_available " type="info">
40+ <div class =" checkbox-text" >
41+ <span >
42+ {{ t('assistant', 'To enable text generation in the smart picker, please install an AI task processing provider for the "Free text to text prompt" task type:') }}
43+ </span >
44+ <ul >
45+ <li ><a href =" https://github.com/nextcloud/llm2#readme" >Local Large language model app</a ></li >
46+ <li ><a href =" https://apps.nextcloud.com/apps/integration_openai" >OpenAI/LocalAI Integration</a ></li >
47+ </ul >
48+ </div >
49+ </NcNoteCard >
50+ <NcFormBoxSwitch :model-value =" state .text_to_image_picker_enabled "
51+ :disabled =" ! state .text_to_image_picker_available "
52+ @update :model-value =" onCheckboxChanged ($event , ' text_to_image_picker_enabled' )" >
53+ {{ t('assistant', 'Enable text-to-image in smart picker') }}
54+ </NcFormBoxSwitch >
55+ <NcFormBoxSwitch :model-value =" state .text_to_sticker_picker_enabled "
56+ :disabled =" ! state .text_to_image_picker_available "
57+ @update :model-value =" onCheckboxChanged ($event , ' text_to_sticker_picker_enabled' )" >
58+ {{ t('assistant', 'Enable text-to-sticker in smart picker') }}
59+ </NcFormBoxSwitch >
60+ <NcNoteCard v-if =" ! state .text_to_image_picker_available " type="warning">
61+ <div class =" checkbox-text" >
62+ <span >
63+ {{ t('assistant', 'To enable the sticker generation picker or the image generation picker, please install and enable a "Generate image" provider:') }}
64+ </span >
65+ <ul >
66+ <li ><a href =" https://github.com/nextcloud/text2image_stablediffusion#readme" >Local Text-To-Image StableDiffusion</a ></li >
67+ <li ><a href =" https://apps.nextcloud.com/apps/integration_openai" >OpenAI/LocalAI Integration</a ></li >
68+ </ul >
69+ </div >
70+ </NcNoteCard >
71+ <NcFormBoxSwitch :model-value =" state .speech_to_text_picker_enabled "
72+ :disabled =" ! state .speech_to_text_picker_available "
73+ @update :model-value =" onCheckboxChanged ($event , ' speech_to_text_picker_enabled' )" >
74+ {{ t('assistant', 'Enable speech-to-text in smart picker') }}
75+ </NcFormBoxSwitch >
76+ <NcNoteCard v-if =" ! state .speech_to_text_picker_available " type="warning">
77+ <div class =" checkbox-text" >
78+ <span >
79+ {{ t('assistant', 'To enable speech-to-text in the smart picker, please install and enable a "Transcribe audio" provider:') }}
80+ </span >
81+ <ul >
82+ <li ><a href =" https://github.com/nextcloud/stt_whisper2#readme" >Local Speech-To-Text Whisper</a ></li >
83+ <li ><a href =" https://apps.nextcloud.com/apps/integration_openai" >OpenAI/LocalAI Integration</a ></li >
84+ </ul >
85+ </div >
86+ </NcNoteCard >
87+ </NcFormBox >
8688 </NcFormGroup >
8789 </div >
8890 <div class =" chat-with-ai" >
@@ -158,6 +160,7 @@ import NcNoteCard from '@nextcloud/vue/components/NcNoteCard'
158160import NcRichContenteditable from ' @nextcloud/vue/components/NcRichContenteditable'
159161import NcTextField from ' @nextcloud/vue/components/NcTextField'
160162import NcFormGroup from ' @nextcloud/vue/components/NcFormGroup'
163+ import NcFormBox from ' @nextcloud/vue/components/NcFormBox'
161164import NcFormBoxSwitch from ' @nextcloud/vue/components/NcFormBoxSwitch'
162165
163166import axios from ' @nextcloud/axios'
@@ -176,6 +179,7 @@ export default {
176179 NcRichContenteditable,
177180 NcTextField,
178181 NcFormGroup,
182+ NcFormBox,
179183 NcFormBoxSwitch,
180184 OpenInNewIcon,
181185 },
0 commit comments