@voicenter-team/voicenter-ui-plus 3.4.8 → 4.0.0-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (564) hide show
  1. package/README.md +1023 -558
  2. package/library/assets/assets/sass/main.css +1 -1
  3. package/library/assets/components/VcAgentRun/UiComponents/VcAgentRunMetrics.css +1 -0
  4. package/library/assets/components/VcAgentRun/UiComponents/VcAgentRunRow.css +1 -0
  5. package/library/assets/components/VcAgentRun/VcAgentRunCard.css +1 -0
  6. package/library/assets/components/VcAgentRun/VcAgentRunGroup.css +1 -0
  7. package/library/assets/components/VcAiReasoning/VcAiReasoning.css +1 -0
  8. package/library/assets/components/VcApprovalCard/VcApprovalCard.css +1 -0
  9. package/library/assets/components/VcAskUserCard/VcAskUserCard.css +1 -0
  10. package/library/assets/components/VcAutocomplete/VcAutocomplete.css +1 -1
  11. package/library/assets/components/VcAvatar/VcAvatar.css +1 -1
  12. package/library/assets/components/VcBadgeTag/VcBadgeTag.css +1 -1
  13. package/library/assets/components/VcButton/VcButton.css +1 -1
  14. package/library/assets/components/VcButton/VcButtonIcon.css +1 -1
  15. package/library/assets/components/VcButton/VcToggleButton.css +1 -1
  16. package/library/assets/components/VcCard/VcCard.css +1 -1
  17. package/library/assets/components/VcChatComposer/VcChatComposer.css +1 -1
  18. package/library/assets/components/VcCheckbox/VcCheckbox.css +1 -1
  19. package/library/assets/components/VcCheckbox/VcCheckboxButton.css +1 -1
  20. package/library/assets/components/VcCodeBlock/VcCodeBlock.css +1 -1
  21. package/library/assets/components/VcCollapse/VcCollapseItem.css +1 -1
  22. package/library/assets/components/VcColorPicker/VcColorPicker.css +1 -1
  23. package/library/assets/components/VcDatePicker/VcDatePicker.css +1 -1
  24. package/library/assets/components/VcDatePickerPanel/VcDatePickerPanel.css +1 -1
  25. package/library/assets/components/VcDatetimeRangePicker/VcDatetimeRangePicker.css +1 -1
  26. package/library/assets/components/VcDropdown/VcDropdown.css +1 -1
  27. package/library/assets/components/VcDropdown/VcDropdownItem.css +1 -1
  28. package/library/assets/components/VcEmojiPicker/VcEmojiPicker.css +1 -1
  29. package/library/assets/components/VcExtendedDatetimeRangePicker/VcExtendedDatetimeRangePicker.css +1 -1
  30. package/library/assets/components/VcExtendedDatetimeRangePicker/VcExtendedDatetimeRangePickerQuickOptionsSelection.css +1 -1
  31. package/library/assets/components/VcFileUploader/VcFileItem.css +1 -1
  32. package/library/assets/components/VcFileUploader/VcFileUploaderArea.css +1 -1
  33. package/library/assets/components/VcFileUploader/VcFileUploaderSimple.css +1 -1
  34. package/library/assets/components/VcForm/UiComponents/VcInputError.css +1 -1
  35. package/library/assets/components/VcForm/UiComponents/VcInputLabel.css +1 -1
  36. package/library/assets/components/VcForm/VcFormItem.css +1 -1
  37. package/library/assets/components/VcHtmlEditor/VcHtmlEditor.css +1 -1
  38. package/library/assets/components/VcHyperLink/VcHyperLink.css +1 -1
  39. package/library/assets/components/VcIconPicker/VcIconPicker.css +1 -1
  40. package/library/assets/components/VcImageUploader/VcImageUploader.css +1 -1
  41. package/library/assets/components/VcInput/VcInput.css +1 -1
  42. package/library/assets/components/VcInputNumber/VcInputNumber.css +1 -1
  43. package/library/assets/components/VcJsonSchema/Components/JsonCodeMirror.css +1 -1
  44. package/library/assets/components/VcJsonSchema/Components/JsonSchemaEditor.css +1 -1
  45. package/library/assets/components/VcJsonSchema/VcJsonSchema.css +1 -1
  46. package/library/assets/components/VcJsonViewer/UiComponents/VcJsonViewerAuto.css +1 -0
  47. package/library/assets/components/VcJsonViewer/UiComponents/VcJsonViewerCards.css +1 -0
  48. package/library/assets/components/VcJsonViewer/UiComponents/VcJsonViewerFields.css +1 -0
  49. package/library/assets/components/VcJsonViewer/UiComponents/VcJsonViewerKey.css +1 -0
  50. package/library/assets/components/VcJsonViewer/UiComponents/VcJsonViewerMore.css +1 -0
  51. package/library/assets/components/VcJsonViewer/UiComponents/VcJsonViewerObject.css +1 -0
  52. package/library/assets/components/VcJsonViewer/UiComponents/VcJsonViewerSections.css +1 -0
  53. package/library/assets/components/VcJsonViewer/UiComponents/VcJsonViewerState.css +1 -0
  54. package/library/assets/components/VcJsonViewer/UiComponents/VcJsonViewerTable.css +1 -0
  55. package/library/assets/components/VcJsonViewer/UiComponents/VcJsonViewerTree.css +1 -0
  56. package/library/assets/components/VcJsonViewer/UiComponents/VcJsonViewerValue.css +1 -0
  57. package/library/assets/components/VcJsonViewer/VcJsonViewer.css +1 -0
  58. package/library/assets/components/VcLightbox/VcLightbox.css +1 -0
  59. package/library/assets/components/VcLoading/Loaders/Circles.css +1 -1
  60. package/library/assets/components/VcLoading/Loaders/DotSpinner.css +1 -1
  61. package/library/assets/components/VcLoading/Loaders/LdsSpinner.css +1 -1
  62. package/library/assets/components/VcLoading/Loaders/LoadIcon.css +1 -1
  63. package/library/assets/components/VcLoading/Loaders/Stretch.css +1 -1
  64. package/library/assets/components/VcLoading/VcLoading.css +1 -1
  65. package/library/assets/components/VcMdEditor/ParameterNode.css +1 -1
  66. package/library/assets/components/VcMdEditor/VcMdEditorContent.css +1 -1
  67. package/library/assets/components/VcMessage/VcMessage.css +1 -1
  68. package/library/assets/components/VcMessage/content/VcMessageFileBlock.css +1 -1
  69. package/library/assets/components/VcMessage/content/VcMessageImageBlock.css +1 -1
  70. package/library/assets/components/VcMessage/content/VcMessageMarkdownBlock.css +1 -0
  71. package/library/assets/components/VcMessage/content/VcMessageTextBlock.css +1 -1
  72. package/library/assets/components/VcMessage/content/VcMessageVideoBlock.css +1 -1
  73. package/library/assets/components/VcMessage/reactions/VcMessageEmojiPicker.css +1 -1
  74. package/library/assets/components/VcMessage/reactions/VcMessageReactionBar.css +1 -1
  75. package/library/assets/components/VcMessagesWrapper/VcMessagesWrapper.css +1 -1
  76. package/library/assets/components/VcMeterGroup/VcMeterGroup.css +1 -1
  77. package/library/assets/components/VcModal/VcModal.css +1 -1
  78. package/library/assets/components/VcNotification/VcNotification.css +1 -1
  79. package/library/assets/components/VcOtpInput/VcOtpInput.css +1 -1
  80. package/library/assets/components/VcPdfViewer/UiComponents/VcPdfViewerToolbar.css +1 -0
  81. package/library/assets/components/VcPdfViewer/VcPdfDocument.css +1 -1
  82. package/library/assets/components/VcPdfViewer/VcPdfDocumentCard.css +1 -1
  83. package/library/assets/components/VcPdfViewer/VcPdfDocumentViewerFooter.css +1 -1
  84. package/library/assets/components/VcPdfViewer/VcPdfViewer.css +1 -0
  85. package/library/assets/components/VcPhoneInput/VcFlagLabel.css +1 -1
  86. package/library/assets/components/VcPhoneInput/VcPhoneInput.css +1 -1
  87. package/library/assets/components/VcPopover/VcConfirmPopover.css +1 -1
  88. package/library/assets/components/VcPopover/VcPopover.css +1 -1
  89. package/library/assets/components/VcPopover/VcSelectPopover.css +1 -1
  90. package/library/assets/components/VcProgress/VcProgress.css +1 -1
  91. package/library/assets/components/VcProgress/VcProgressCircular.css +1 -1
  92. package/library/assets/components/VcRadio/VcRadio.css +1 -1
  93. package/library/assets/components/VcRadioButtons/VcRadioButtonsGroup.css +1 -1
  94. package/library/assets/components/VcRadioGroup/VcRadioGroup.css +1 -1
  95. package/library/assets/components/VcRadioTabs/UiComponents/VcRadioTabsNav.css +1 -1
  96. package/library/assets/components/VcRadioTabs/VcRadioTabs.css +1 -1
  97. package/library/assets/components/VcSegmented/VcSegmented.css +1 -1
  98. package/library/assets/components/VcSelect/VcSelect.css +1 -1
  99. package/library/assets/components/VcSelect/VcSelectOption.css +1 -1
  100. package/library/assets/components/VcSipFlow/VcSipFlow.css +1 -1
  101. package/library/assets/components/VcSkeletonLoader/Loaders/Card.css +1 -1
  102. package/library/assets/components/VcSkeletonLoader/Loaders/Circle.css +1 -1
  103. package/library/assets/components/VcSkeletonLoader/Loaders/Row.css +1 -1
  104. package/library/assets/components/VcSkeletonLoader/Loaders/Square.css +1 -1
  105. package/library/assets/components/VcSkeletonLoader/Loaders/Text.css +1 -1
  106. package/library/assets/components/VcSlider/VcSlider.css +1 -1
  107. package/library/assets/components/VcSoundplayer/VcPlayerPlaybackRate.css +1 -1
  108. package/library/assets/components/VcSoundplayer/VcSoundPlayerMarker.css +1 -1
  109. package/library/assets/components/VcSplitButton/VcSplitButton.css +1 -1
  110. package/library/assets/components/VcSwitch/VcSwitch.css +1 -1
  111. package/library/assets/components/VcSystemUserPrompt/VcSystemUserPrompt.css +1 -1
  112. package/library/assets/components/VcTable/VcTable.css +1 -1
  113. package/library/assets/components/VcTable/VcTable2.css +1 -1
  114. package/library/assets/components/VcTabs/VcTabNav.css +1 -1
  115. package/library/assets/components/VcTabs/VcTabs.css +1 -1
  116. package/library/assets/components/VcTag/VcTag.css +1 -1
  117. package/library/assets/components/VcTagInput/VcTagInput.css +1 -1
  118. package/library/assets/components/VcTimeInput/VcTimeInput.css +1 -1
  119. package/library/assets/components/VcToolCall/UiComponents/VcToolCallValue.css +1 -0
  120. package/library/assets/components/VcToolCall/VcToolCall.css +1 -0
  121. package/library/assets/components/VcTour/VcTour.css +1 -1
  122. package/library/assets/components/VcTransfer/VcTransfer.css +1 -1
  123. package/library/assets/components/VcTree/VcTree.css +1 -1
  124. package/library/assets/components/VcTree/VcTreeSelect.css +1 -1
  125. package/library/assets/components/VcVerticalTabs/VcVerticalTabs.css +1 -1
  126. package/library/assets/components/VcVerticalTabs/VerticalTabNav.css +1 -1
  127. package/library/assets/components/VcViewSwitcher/VcViewSwitcher.css +1 -1
  128. package/library/assets/components/VcWizard/VcSummaryProgress.css +1 -1
  129. package/library/assets/components/VcWizard/VcWizard.css +1 -1
  130. package/library/assets/components/VcWizard/VcWizardNavigation.css +1 -1
  131. package/library/assets/components/VcWizard/VcWizardSummary.css +1 -1
  132. package/library/assets/entity/components/Form/VcBaseVerticalForm.css +1 -1
  133. package/library/assets/entity/components/Table/VcEntityListTable.css +1 -1
  134. package/library/assets/entity/components/Tabs/VcEntityEditableTabs.css +1 -1
  135. package/library/assets/node_modules/element-plus/theme-chalk/src/autocomplete.css +1 -1
  136. package/library/assets/node_modules/element-plus/theme-chalk/src/base.css +1 -1
  137. package/library/assets/node_modules/element-plus/theme-chalk/src/button.css +1 -1
  138. package/library/assets/node_modules/element-plus/theme-chalk/src/checkbox.css +1 -1
  139. package/library/assets/node_modules/element-plus/theme-chalk/src/date-picker-panel.css +1 -1
  140. package/library/assets/node_modules/element-plus/theme-chalk/src/image-viewer.css +1 -0
  141. package/library/assets/node_modules/element-plus/theme-chalk/src/input-number.css +1 -1
  142. package/library/assets/node_modules/element-plus/theme-chalk/src/input.css +1 -1
  143. package/library/assets/node_modules/element-plus/theme-chalk/src/option.css +1 -1
  144. package/library/assets/node_modules/element-plus/theme-chalk/src/popover.css +1 -1
  145. package/library/assets/node_modules/element-plus/theme-chalk/src/popper.css +1 -1
  146. package/library/assets/node_modules/element-plus/theme-chalk/src/radio-button.css +1 -1
  147. package/library/assets/node_modules/element-plus/theme-chalk/src/radio.css +1 -1
  148. package/library/assets/node_modules/element-plus/theme-chalk/src/select.css +1 -1
  149. package/library/assets/node_modules/element-plus/theme-chalk/src/tree.css +1 -1
  150. package/library/components/VcAgentRun/UiComponents/VcAgentRunMetrics.vue.mjs +110 -0
  151. package/library/components/VcAgentRun/UiComponents/VcAgentRunMetrics.vue3.mjs +5 -0
  152. package/library/components/VcAgentRun/UiComponents/VcAgentRunRow.vue.mjs +70 -0
  153. package/library/components/VcAgentRun/UiComponents/VcAgentRunRow.vue3.mjs +5 -0
  154. package/library/components/VcAgentRun/VcAgentRunCard.vue.mjs +423 -0
  155. package/library/components/VcAgentRun/VcAgentRunCard.vue3.mjs +5 -0
  156. package/library/components/VcAgentRun/VcAgentRunGroup.vue.mjs +210 -0
  157. package/library/components/VcAgentRun/VcAgentRunGroup.vue3.mjs +5 -0
  158. package/library/components/VcAgentRun/agentRunStatus.mjs +39 -0
  159. package/library/components/VcAiReasoning/VcAiReasoning.vue.mjs +227 -0
  160. package/library/components/VcAiReasoning/VcAiReasoning.vue3.mjs +5 -0
  161. package/library/components/VcApprovalCard/VcApprovalCard.vue.mjs +419 -0
  162. package/library/components/VcApprovalCard/VcApprovalCard.vue3.mjs +5 -0
  163. package/library/components/VcAskUserCard/UiComponents/VcAskUserConfirm.vue.mjs +69 -0
  164. package/library/components/VcAskUserCard/UiComponents/VcAskUserConfirm.vue2.mjs +4 -0
  165. package/library/components/VcAskUserCard/UiComponents/VcAskUserMultiSelect.vue.mjs +177 -0
  166. package/library/components/VcAskUserCard/UiComponents/VcAskUserMultiSelect.vue2.mjs +4 -0
  167. package/library/components/VcAskUserCard/UiComponents/VcAskUserQuestionList.vue.mjs +98 -0
  168. package/library/components/VcAskUserCard/UiComponents/VcAskUserQuestionList.vue2.mjs +4 -0
  169. package/library/components/VcAskUserCard/UiComponents/VcAskUserRankPriorities.vue.mjs +142 -0
  170. package/library/components/VcAskUserCard/UiComponents/VcAskUserRankPriorities.vue2.mjs +4 -0
  171. package/library/components/VcAskUserCard/UiComponents/VcAskUserSingleSelect.vue.mjs +156 -0
  172. package/library/components/VcAskUserCard/UiComponents/VcAskUserSingleSelect.vue2.mjs +4 -0
  173. package/library/components/VcAskUserCard/UiComponents/VcAskUserText.vue.mjs +76 -0
  174. package/library/components/VcAskUserCard/UiComponents/VcAskUserText.vue2.mjs +4 -0
  175. package/library/components/VcAskUserCard/VcAskUserCard.vue.mjs +382 -0
  176. package/library/components/VcAskUserCard/VcAskUserCard.vue3.mjs +5 -0
  177. package/library/components/VcAskUserCard/askUserAnswers.mjs +224 -0
  178. package/library/components/VcAutocomplete/VcAutocomplete.vue.mjs +4 -2
  179. package/library/components/VcAvatar/VcAvatar.vue.mjs +3 -3
  180. package/library/components/VcBadgeTag/VcBadgeTag.vue.mjs +8 -5
  181. package/library/components/VcButton/VcButton.vue.mjs +10 -4
  182. package/library/components/VcButton/VcButtonIcon.vue.mjs +3 -4
  183. package/library/components/VcButton/VcToggleButton.vue.mjs +5 -4
  184. package/library/components/VcChatComposer/VcChatComposer.vue.mjs +154 -51
  185. package/library/components/VcCodeBlock/VcCodeBlock.vue.mjs +27 -35
  186. package/library/components/VcCollapse/VcCollapseItem.vue.mjs +12 -7
  187. package/library/components/VcDatePicker/VcDatePicker.vue.mjs +40 -11
  188. package/library/components/VcDatePickerPanel/VcDatePickerPanel.vue.mjs +49 -32
  189. package/library/components/VcExcelUploader/VcExcelFileProcessLoader.vue.mjs +2 -2
  190. package/library/components/VcExcelUploader/VcExcelFileUploadBlock.vue.mjs +11 -7
  191. package/library/components/VcExcelUploader/VcExcelFileUploader.vue.mjs +7 -6
  192. package/library/components/VcExcelUploader/VcFileImportErrorsCard.vue.mjs +8 -4
  193. package/library/components/VcExcelUploader/VcFileImportParseResultBlock.vue.mjs +2 -1
  194. package/library/components/VcExcelUploader/VcFileImportResultBindDataTable.vue.mjs +13 -12
  195. package/library/components/VcExtendedDatetimeRangePicker/ExtendedDatetimeRangePickerPart.vue.mjs +6 -5
  196. package/library/components/VcExtendedDatetimeRangePicker/ExtendedDatetimeRangePickerRelative.vue.mjs +4 -3
  197. package/library/components/VcExtendedDatetimeRangePicker/VcExtendedDatetimeRangePicker.vue.mjs +7 -3
  198. package/library/components/VcExtendedDatetimeRangePicker/VcExtendedDatetimeRangePickerQuickOptionsSelection.vue.mjs +3 -2
  199. package/library/components/VcFileUploader/VcFileItem.vue.mjs +59 -31
  200. package/library/components/VcFileUploader/VcFileUploader.vue.mjs +2 -1
  201. package/library/components/VcFileUploader/VcFileUploaderArea.vue.mjs +2 -2
  202. package/library/components/VcFileUploader/VcFileUploaderSimple.vue.mjs +1 -1
  203. package/library/components/VcFileUploader/VcFileUploaderSimple.vue2.mjs +2 -1
  204. package/library/components/VcFileUploader/VcSimpleUploaderAction.vue.mjs +4 -3
  205. package/library/components/VcForm/UiComponents/VcInputLabel.vue.mjs +6 -2
  206. package/library/components/VcHtmlEditor/VcHtmlEditor.vue.mjs +4 -1
  207. package/library/components/VcHtmlEditor/VcHtmlEditorToolbar.vue.mjs +19 -31
  208. package/library/components/VcHtmlEditor/htmlEditor.config.mjs +13 -10
  209. package/library/components/VcHyperLink/VcHyperLink.vue.mjs +1 -1
  210. package/library/components/VcIconPicker/VcIconPicker.vue.mjs +1 -1
  211. package/library/components/VcImageUploader/VcImageUploader.vue.mjs +27 -14
  212. package/library/components/VcInput/VcInput.vue.mjs +4 -2
  213. package/library/components/VcInputNumber/VcInputNumber.vue.mjs +29 -4
  214. package/library/components/VcJsonSchema/Components/ImportJsonSchemaModal.vue.mjs +5 -4
  215. package/library/components/VcJsonSchema/Components/JsonSchemaEditor.vue.mjs +1 -2
  216. package/library/components/VcJsonSchema/Components/JsonSchemaManageModal.vue.mjs +6 -9
  217. package/library/components/VcJsonSchema/PropertySetup/JsonSchemaPropertyModal.vue.mjs +9 -10
  218. package/library/components/VcJsonSchema/VcJsonSchema.vue.mjs +0 -1
  219. package/library/components/VcJsonViewer/UiComponents/VcJsonViewerAuto.vue.mjs +98 -0
  220. package/library/components/VcJsonViewer/UiComponents/VcJsonViewerAuto.vue3.mjs +5 -0
  221. package/library/components/VcJsonViewer/UiComponents/VcJsonViewerCards.vue.mjs +164 -0
  222. package/library/components/VcJsonViewer/UiComponents/VcJsonViewerCards.vue3.mjs +5 -0
  223. package/library/components/VcJsonViewer/UiComponents/VcJsonViewerFields.vue.mjs +50 -0
  224. package/library/components/VcJsonViewer/UiComponents/VcJsonViewerFields.vue3.mjs +5 -0
  225. package/library/components/VcJsonViewer/UiComponents/VcJsonViewerKey.vue.mjs +25 -0
  226. package/library/components/VcJsonViewer/UiComponents/VcJsonViewerKey.vue3.mjs +5 -0
  227. package/library/components/VcJsonViewer/UiComponents/VcJsonViewerMore.vue.mjs +64 -0
  228. package/library/components/VcJsonViewer/UiComponents/VcJsonViewerMore.vue3.mjs +5 -0
  229. package/library/components/VcJsonViewer/UiComponents/VcJsonViewerObject.vue.mjs +53 -0
  230. package/library/components/VcJsonViewer/UiComponents/VcJsonViewerObject.vue3.mjs +5 -0
  231. package/library/components/VcJsonViewer/UiComponents/VcJsonViewerSections.vue.mjs +104 -0
  232. package/library/components/VcJsonViewer/UiComponents/VcJsonViewerSections.vue3.mjs +5 -0
  233. package/library/components/VcJsonViewer/UiComponents/VcJsonViewerState.vue.mjs +45 -0
  234. package/library/components/VcJsonViewer/UiComponents/VcJsonViewerState.vue3.mjs +5 -0
  235. package/library/components/VcJsonViewer/UiComponents/VcJsonViewerTable.vue.mjs +259 -0
  236. package/library/components/VcJsonViewer/UiComponents/VcJsonViewerTable.vue3.mjs +5 -0
  237. package/library/components/VcJsonViewer/UiComponents/VcJsonViewerTree.vue.mjs +179 -0
  238. package/library/components/VcJsonViewer/UiComponents/VcJsonViewerTree.vue3.mjs +5 -0
  239. package/library/components/VcJsonViewer/UiComponents/VcJsonViewerValue.vue.mjs +146 -0
  240. package/library/components/VcJsonViewer/UiComponents/VcJsonViewerValue.vue3.mjs +5 -0
  241. package/library/components/VcJsonViewer/VcJsonViewer.vue.mjs +454 -0
  242. package/library/components/VcJsonViewer/VcJsonViewer.vue3.mjs +5 -0
  243. package/library/components/VcJsonViewer/jsonViewerText.mjs +41 -0
  244. package/library/components/VcJsonViewer/jsonViewerUtils.mjs +568 -0
  245. package/library/components/VcJsonViewer/useJsonViewerContext.mjs +25 -0
  246. package/library/components/VcLightbox/VcLightbox.vue.mjs +417 -0
  247. package/library/components/VcLightbox/VcLightbox.vue3.mjs +5 -0
  248. package/library/components/VcLoading/Loaders/Circles.vue.mjs +1 -1
  249. package/library/components/VcLoading/Loaders/Circles.vue2.mjs +3 -2
  250. package/library/components/VcLoading/Loaders/DotSpinner.vue.mjs +1 -1
  251. package/library/components/VcLoading/Loaders/DotSpinner.vue2.mjs +5 -4
  252. package/library/components/VcLoading/Loaders/LdsSpinner.vue.mjs +1 -1
  253. package/library/components/VcLoading/Loaders/LdsSpinner.vue2.mjs +3 -2
  254. package/library/components/VcLoading/Loaders/LoadIcon.vue.mjs +1 -1
  255. package/library/components/VcLoading/Loaders/LoadIcon.vue2.mjs +5 -4
  256. package/library/components/VcLoading/Loaders/Stretch.vue.mjs +1 -1
  257. package/library/components/VcLoading/Loaders/Stretch.vue2.mjs +4 -3
  258. package/library/components/VcLoading/VcLoading.vue.mjs +1 -1
  259. package/library/components/VcMdEditor/ParameterNode.vue.mjs +1 -1
  260. package/library/components/VcMdEditor/ParameterNode.vue2.mjs +3 -3
  261. package/library/components/VcMdEditor/VcMdEditor.vue.mjs +37 -12
  262. package/library/components/VcMdEditor/VcMdEditorContent.vue.mjs +10 -0
  263. package/library/components/VcMdEditor/VcMdEditorToolbar.vue.mjs +6 -6
  264. package/library/components/VcMdEditor/ltrNumbersPlugin.mjs +55 -0
  265. package/library/components/VcMdEditor/readonlyMarkdown.mjs +81 -0
  266. package/library/components/VcMdEditor/streamingInterval.mjs +12 -0
  267. package/library/components/VcMessage/VcMessage.vue.mjs +75 -42
  268. package/library/components/VcMessage/content/VcMessageFileBlock.vue.mjs +99 -14
  269. package/library/components/VcMessage/content/VcMessageMarkdownBlock.vue.mjs +5 -0
  270. package/library/components/VcMessage/content/VcMessageMarkdownBlock.vue2.mjs +33 -0
  271. package/library/components/VcMessage/content/VcMessageTextBlock.vue.mjs +21 -3
  272. package/library/components/VcMessage/content/markdownPreview.mjs +32 -0
  273. package/library/components/VcMessage/content/messageContentComponents.mjs +3 -1
  274. package/library/components/VcMessagesWrapper/VcMessagesWrapper.vue.mjs +120 -52
  275. package/library/components/VcMessagesWrapper/VcMessagesWrapperRow.vue.mjs +49 -29
  276. package/library/components/VcMeterGroup/VcMeterGroup.vue.mjs +1 -1
  277. package/library/components/VcModal/VcConfirmModal.vue.mjs +10 -9
  278. package/library/components/VcModal/VcModal.vue.mjs +21 -22
  279. package/library/components/VcNotification/VcNotification.vue.mjs +2 -2
  280. package/library/components/VcNotification/VcNotificationMessage.vue.mjs +14 -11
  281. package/library/components/VcPagination/VcPagination.vue.mjs +5 -4
  282. package/library/components/VcPdfViewer/UiComponents/VcPdfViewerToolbar.vue.mjs +166 -0
  283. package/library/components/VcPdfViewer/UiComponents/VcPdfViewerToolbar.vue3.mjs +5 -0
  284. package/library/components/VcPdfViewer/VcPdfDocument.vue.mjs +12 -76
  285. package/library/components/VcPdfViewer/VcPdfDocumentCard.vue.mjs +18 -8
  286. package/library/components/VcPdfViewer/VcPdfDocumentViewerFooter.vue.mjs +23 -7
  287. package/library/components/VcPdfViewer/VcPdfDocumentViewerToolbar.vue.mjs +23 -10
  288. package/library/components/VcPdfViewer/VcPdfViewer.vue.mjs +581 -0
  289. package/library/components/VcPdfViewer/VcPdfViewer.vue3.mjs +5 -0
  290. package/library/components/VcPdfViewer/pdfDocumentActions.mjs +90 -0
  291. package/library/components/VcPdfViewer/pdfDocumentParams.mjs +11 -0
  292. package/library/components/VcPdfViewer/pdfStandardFonts.mjs +21 -0
  293. package/library/components/VcPdfViewer/standard_fonts/FoxitDingbats.pfb +0 -0
  294. package/library/components/VcPdfViewer/standard_fonts/FoxitSymbol.pfb +0 -0
  295. package/library/components/VcPdfViewer/standard_fonts/LICENSE_FOXIT +27 -0
  296. package/library/components/VcPhoneInput/VcPhoneInput.vue.mjs +12 -6
  297. package/library/components/VcPopover/VcConfirmPopover.vue.mjs +3 -3
  298. package/library/components/VcPopover/VcSelectPopover.vue.mjs +2 -1
  299. package/library/components/VcProgress/VcProgress.vue.mjs +11 -20
  300. package/library/components/VcProgress/VcProgressCircular.vue.mjs +14 -23
  301. package/library/components/VcProgress/progress.options.mjs +21 -21
  302. package/library/components/VcSelect/VcInfiniteScrollSelect.vue.mjs +13 -7
  303. package/library/components/VcSelect/VcSelect.vue.mjs +18 -19
  304. package/library/components/VcSelect/VcSelectGrouped.vue.mjs +8 -5
  305. package/library/components/VcSkeletonLoader/Loaders/Card.vue.mjs +1 -1
  306. package/library/components/VcSkeletonLoader/Loaders/Circle.vue.mjs +1 -1
  307. package/library/components/VcSkeletonLoader/Loaders/Row.vue.mjs +1 -1
  308. package/library/components/VcSkeletonLoader/Loaders/Square.vue.mjs +1 -1
  309. package/library/components/VcSkeletonLoader/Loaders/Text.vue.mjs +1 -1
  310. package/library/components/VcSkeletonLoader/Loaders/Text.vue2.mjs +1 -1
  311. package/library/components/VcSoundplayer/VcPlayerPlayStopButton.vue.mjs +7 -6
  312. package/library/components/VcSoundplayer/VcPlayerPlaybackRatePopup.vue.mjs +2 -2
  313. package/library/components/VcSoundplayer/VcPlayerSkipButtons.vue.mjs +5 -4
  314. package/library/components/VcSoundplayer/VcSoundPlayer.vue.mjs +26 -23
  315. package/library/components/VcSoundplayer/VcSoundPlayerError.vue.mjs +5 -4
  316. package/library/components/VcSoundplayer/VcSoundPlayerMarker.vue.mjs +1 -1
  317. package/library/components/VcSoundplayer/VcSoundPlayerProgress.vue.mjs +1 -1
  318. package/library/components/VcSoundplayer/VcSoundPlayerWrapper.vue.mjs +5 -3
  319. package/library/components/VcSoundplayer/VcSoundVolume.vue.mjs +5 -4
  320. package/library/components/VcSoundplayer/player.options.mjs +13 -5
  321. package/library/components/VcSparkline/VcBarLine.vue.mjs +2 -2
  322. package/library/components/VcSparkline/VcTrendLine.vue.mjs +2 -2
  323. package/library/components/VcSplitButton/VcSplitButton.vue.mjs +18 -19
  324. package/library/components/VcSwitch/VcSwitch.vue.mjs +1 -1
  325. package/library/components/VcTable/VcTable.vue.mjs +18 -11
  326. package/library/components/VcTabs/VcTabNav.vue.mjs +11 -9
  327. package/library/components/VcTag/VcTag.vue.mjs +6 -4
  328. package/library/components/VcTagInput/VcTagInput.vue.mjs +10 -7
  329. package/library/components/VcTimeInput/VcTimeInput.vue.mjs +18 -8
  330. package/library/components/VcToolCall/UiComponents/VcToolCallValue.vue.mjs +64 -0
  331. package/library/components/VcToolCall/UiComponents/VcToolCallValue.vue3.mjs +5 -0
  332. package/library/components/VcToolCall/VcToolCall.vue.mjs +328 -0
  333. package/library/components/VcToolCall/VcToolCall.vue3.mjs +5 -0
  334. package/library/components/VcTree/VcTree.vue.mjs +8 -4
  335. package/library/components/VcTree/VcTreeSelect.vue.mjs +11 -7
  336. package/library/components/VcWizard/VcSummaryProgress.vue.mjs +10 -7
  337. package/library/components/VcWizard/VcSummaryStep.vue.mjs +8 -4
  338. package/library/components/VcWizard/VcWizardNavigation.vue.mjs +12 -8
  339. package/library/composables/input/useInputColor.mjs +3 -3
  340. package/library/composables/useElapsed.mjs +47 -0
  341. package/library/composables/useThrottledText.mjs +22 -0
  342. package/library/entity/components/Button/VcEntityAddButton.vue.mjs +4 -3
  343. package/library/entity/components/Button/VcEntityCancelButton.vue.mjs +4 -3
  344. package/library/entity/components/Button/VcEntityEditIconButton.vue.mjs +3 -2
  345. package/library/entity/components/Form/VcBaseVerticalForm.vue.mjs +6 -5
  346. package/library/entity/components/Form/VcEntityEditPageForm.vue.mjs +4 -3
  347. package/library/entity/components/Form/VcEntityVerticalEditForm.vue.mjs +7 -6
  348. package/library/entity/components/Table/VcEntityListTable.vue.mjs +15 -15
  349. package/library/enum/constants.mjs +5 -11
  350. package/library/enum/fileTypes.mjs +24 -39
  351. package/library/enum/inputDefaults.mjs +2 -2
  352. package/library/index.mjs +263 -235
  353. package/library/index.mjs.br +0 -0
  354. package/library/index.mjs.gz +0 -0
  355. package/library/localization/index.mjs.gz +0 -0
  356. package/library/localization/locales/en.json.mjs +172 -1
  357. package/library/plugin-components.gen.mjs +95 -68
  358. package/library/plugin.mjs +261 -233
  359. package/library/plugin.mjs.br +0 -0
  360. package/library/plugin.mjs.gz +0 -0
  361. package/library/style.css +174 -122
  362. package/library/style.css.br +0 -0
  363. package/library/style.css.gz +0 -0
  364. package/library/theme/index.mjs.gz +0 -0
  365. package/library/theme/themeMerge.mjs +32 -16
  366. package/library/theme/themes.json.mjs +172 -222
  367. package/library/tokens/tokens.mjs +2 -0
  368. package/library/types/components/VcAgentRun/UiComponents/VcAgentRunMetrics.vue.d.ts +46 -0
  369. package/library/types/components/VcAgentRun/UiComponents/VcAgentRunRow.vue.d.ts +20 -0
  370. package/library/types/components/VcAgentRun/VcAgentRunCard.vue.d.ts +104 -0
  371. package/library/types/components/VcAgentRun/VcAgentRunGroup.vue.d.ts +53 -0
  372. package/library/types/components/VcAgentRun/agentRunStatus.d.ts +13 -0
  373. package/library/types/components/VcAiReasoning/VcAiReasoning.vue.d.ts +85 -0
  374. package/library/types/components/VcApprovalCard/VcApprovalCard.vue.d.ts +101 -0
  375. package/library/types/components/VcAskUserCard/UiComponents/VcAskUserConfirm.vue.d.ts +41 -0
  376. package/library/types/components/VcAskUserCard/UiComponents/VcAskUserMultiSelect.vue.d.ts +42 -0
  377. package/library/types/components/VcAskUserCard/UiComponents/VcAskUserQuestionList.vue.d.ts +53 -0
  378. package/library/types/components/VcAskUserCard/UiComponents/VcAskUserRankPriorities.vue.d.ts +42 -0
  379. package/library/types/components/VcAskUserCard/UiComponents/VcAskUserSingleSelect.vue.d.ts +42 -0
  380. package/library/types/components/VcAskUserCard/UiComponents/VcAskUserText.vue.d.ts +42 -0
  381. package/library/types/components/VcAskUserCard/UiComponents/askUserControl.d.ts +25 -0
  382. package/library/types/components/VcAskUserCard/VcAskUserCard.vue.d.ts +84 -0
  383. package/library/types/components/VcAskUserCard/askUserAnswers.d.ts +57 -0
  384. package/library/types/components/VcAutocomplete/VcAutocomplete.vue.d.ts +72 -72
  385. package/library/types/components/VcAvatar/VcAvatar.vue.d.ts +1 -1
  386. package/library/types/components/VcBadgeTag/VcBadgeTag.vue.d.ts +1 -1
  387. package/library/types/components/VcButton/VcButton.vue.d.ts +7 -7
  388. package/library/types/components/VcButton/VcButtonIcon.vue.d.ts +12 -13
  389. package/library/types/components/VcButton/VcToggleButton.vue.d.ts +4 -4
  390. package/library/types/components/VcChatComposer/VcChatComposer.vue.d.ts +43 -15
  391. package/library/types/components/VcCheckbox/VcCheckbox.vue.d.ts +24 -24
  392. package/library/types/components/VcCheckbox/VcCheckboxButton.vue.d.ts +18 -18
  393. package/library/types/components/VcCheckbox/VcCheckboxButtonGroup.vue.d.ts +15 -15
  394. package/library/types/components/VcCheckboxGroup/VcCheckboxGroup.vue.d.ts +12 -12
  395. package/library/types/components/VcCodeBlock/VcCodeBlock.vue.d.ts +1 -1
  396. package/library/types/components/VcCollapse/VcCollapseItem.vue.d.ts +3 -3
  397. package/library/types/components/VcColorPicker/VcColorPicker.vue.d.ts +1 -1
  398. package/library/types/components/VcDatePicker/VcDatePicker.vue.d.ts +21 -21
  399. package/library/types/components/VcDatePickerPanel/VcDatePickerPanel.vue.d.ts +18 -18
  400. package/library/types/components/VcDropdown/VcDropdown.vue.d.ts +4 -4
  401. package/library/types/components/VcEmojiPicker/VcEmojiPicker.vue.d.ts +1 -1
  402. package/library/types/components/VcExcelUploader/VcExcelFileProcessLoader.vue.d.ts +1 -1
  403. package/library/types/components/VcExcelUploader/VcExcelFileUploader.vue.d.ts +6 -5
  404. package/library/types/components/VcExtendedDatetimeRangePicker/ExtendedDatetimeRangePickerPart.vue.d.ts +1 -1
  405. package/library/types/components/VcExtendedDatetimeRangePicker/ExtendedDatetimeRangePickerRelative.vue.d.ts +4 -4
  406. package/library/types/components/VcExtendedDatetimeRangePicker/VcExtendedDatetimeRangePicker.vue.d.ts +11 -11
  407. package/library/types/components/VcFileUploader/VcFileItem.vue.d.ts +10 -45
  408. package/library/types/components/VcFileUploader/VcFileUploader.vue.d.ts +6 -6
  409. package/library/types/components/VcFileUploader/VcFileUploaderArea.vue.d.ts +6 -6
  410. package/library/types/components/VcFileUploader/VcFileUploaderSimple.vue.d.ts +6 -6
  411. package/library/types/components/VcFileUploader/VcSimpleUploaderAction.vue.d.ts +2 -2
  412. package/library/types/components/VcForm/VcForm.vue.d.ts +3 -3
  413. package/library/types/components/VcHtmlEditor/VcHtmlEditor.vue.d.ts +2 -2
  414. package/library/types/components/VcHtmlEditor/VcHtmlEditorToolbar.vue.d.ts +1 -1
  415. package/library/types/components/VcHtmlEditor/htmlEditor.config.d.ts +3 -3
  416. package/library/types/components/VcHyperLink/VcHyperLink.vue.d.ts +3 -3
  417. package/library/types/components/VcIconPicker/VcIconPicker.vue.d.ts +6 -6
  418. package/library/types/components/VcImageUploader/VcImageUploader.vue.d.ts +3 -3
  419. package/library/types/components/VcInput/VcInput.vue.d.ts +11 -11
  420. package/library/types/components/VcInputNumber/VcInputNumber.vue.d.ts +3 -3
  421. package/library/types/components/VcJsonViewer/UiComponents/VcJsonViewerAuto.vue.d.ts +42 -0
  422. package/library/types/components/VcJsonViewer/UiComponents/VcJsonViewerCards.vue.d.ts +18 -0
  423. package/library/types/components/VcJsonViewer/UiComponents/VcJsonViewerFields.vue.d.ts +32 -0
  424. package/library/types/components/VcJsonViewer/UiComponents/VcJsonViewerKey.vue.d.ts +31 -0
  425. package/library/types/components/VcJsonViewer/UiComponents/VcJsonViewerMore.vue.d.ts +25 -0
  426. package/library/types/components/VcJsonViewer/UiComponents/VcJsonViewerObject.vue.d.ts +34 -0
  427. package/library/types/components/VcJsonViewer/UiComponents/VcJsonViewerSections.vue.d.ts +39 -0
  428. package/library/types/components/VcJsonViewer/UiComponents/VcJsonViewerState.vue.d.ts +46 -0
  429. package/library/types/components/VcJsonViewer/UiComponents/VcJsonViewerTable.vue.d.ts +18 -0
  430. package/library/types/components/VcJsonViewer/UiComponents/VcJsonViewerTree.vue.d.ts +18 -0
  431. package/library/types/components/VcJsonViewer/UiComponents/VcJsonViewerValue.vue.d.ts +37 -0
  432. package/library/types/components/VcJsonViewer/VcJsonViewer.vue.d.ts +162 -0
  433. package/library/types/components/VcJsonViewer/jsonViewerText.d.ts +8 -0
  434. package/library/types/components/VcJsonViewer/jsonViewerUtils.d.ts +127 -0
  435. package/library/types/components/VcJsonViewer/useJsonViewerContext.d.ts +5 -0
  436. package/library/types/components/VcLightbox/VcLightbox.vue.d.ts +90 -0
  437. package/library/types/components/VcLoading/Loaders/LoadIcon.vue.d.ts +2 -2
  438. package/library/types/components/VcLoading/VcLoading.vue.d.ts +2 -2
  439. package/library/types/components/VcLoading/enum.d.ts +2 -2
  440. package/library/types/components/VcMdEditor/VcMdEditor.vue.d.ts +111 -55
  441. package/library/types/components/VcMdEditor/VcMdEditorContent.vue.d.ts +3 -3
  442. package/library/types/components/VcMdEditor/VcMdEditorToolbar.vue.d.ts +1 -1
  443. package/library/types/components/VcMdEditor/ltrNumbersPlugin.d.ts +16 -0
  444. package/library/types/components/VcMdEditor/readonlyMarkdown.d.ts +7 -0
  445. package/library/types/components/VcMdEditor/streamingInterval.d.ts +7 -0
  446. package/library/types/components/VcMessage/VcMessage.vue.d.ts +24 -3
  447. package/library/types/components/VcMessage/content/VcMessageFileBlock.vue.d.ts +6 -2
  448. package/library/types/components/VcMessage/content/VcMessageMarkdownBlock.vue.d.ts +24 -0
  449. package/library/types/components/VcMessage/content/markdownPreview.d.ts +1 -0
  450. package/library/types/components/VcMessage/reactions/VcMessageEmojiPicker.vue.d.ts +1 -1
  451. package/library/types/components/VcMessagesWrapper/VcMessagesWrapper.vue.d.ts +223 -84
  452. package/library/types/components/VcMessagesWrapper/VcMessagesWrapperRow.vue.d.ts +89 -42
  453. package/library/types/components/VcMeterGroup/VcMeterGroup.vue.d.ts +2 -2
  454. package/library/types/components/VcMeterGroup/VcMeterGroupLabel.vue.d.ts +1 -1
  455. package/library/types/components/VcModal/VcModal.vue.d.ts +3 -3
  456. package/library/types/components/VcNotification/VcNotification.vue.d.ts +1 -1
  457. package/library/types/components/VcOtpInput/VcOtpInput.vue.d.ts +8 -8
  458. package/library/types/components/VcPagination/VcPagination.vue.d.ts +1 -1
  459. package/library/types/components/VcPagination/VcPaginationButton.vue.d.ts +4 -4
  460. package/library/types/components/VcPdfViewer/UiComponents/VcPdfViewerToolbar.vue.d.ts +64 -0
  461. package/library/types/components/VcPdfViewer/VcPdfDocumentViewerToolbar.vue.d.ts +1 -1
  462. package/library/types/components/VcPdfViewer/VcPdfViewer.vue.d.ts +114 -0
  463. package/library/types/components/VcPdfViewer/pdfDocumentActions.d.ts +29 -0
  464. package/library/types/components/VcPdfViewer/pdfDocumentParams.d.ts +14 -0
  465. package/library/types/components/VcPdfViewer/pdfStandardFonts.d.ts +9 -0
  466. package/library/types/components/VcPhoneInput/VcPhoneInput.vue.d.ts +8 -8
  467. package/library/types/components/VcPopover/VcConfirmPopover.vue.d.ts +1 -1
  468. package/library/types/components/VcPopover/VcPopover.vue.d.ts +1 -1
  469. package/library/types/components/VcPopover/VcSelectPopover.vue.d.ts +3 -3
  470. package/library/types/components/VcProgress/VcProgress.vue.d.ts +1 -1
  471. package/library/types/components/VcProgress/VcProgressCircular.vue.d.ts +4 -4
  472. package/library/types/components/VcProgress/progress.options.d.ts +9 -7
  473. package/library/types/components/VcRadio/VcRadio.vue.d.ts +15 -15
  474. package/library/types/components/VcRadioButtons/VcRadioButtonsGroup.vue.d.ts +9 -9
  475. package/library/types/components/VcRadioGroup/VcRadioGroup.vue.d.ts +12 -12
  476. package/library/types/components/VcRadioTabs/VcRadioTabs.vue.d.ts +6 -6
  477. package/library/types/components/VcSegmented/VcSegmented.vue.d.ts +18 -18
  478. package/library/types/components/VcSelect/VcInfiniteScrollSelect.vue.d.ts +42 -42
  479. package/library/types/components/VcSelect/VcSelect.vue.d.ts +51 -51
  480. package/library/types/components/VcSelect/VcSelectGrouped.vue.d.ts +48 -48
  481. package/library/types/components/VcSelect/VcSelectOption.vue.d.ts +9 -9
  482. package/library/types/components/VcSkeletonLoader/VcSkeletonLoader.vue.d.ts +1 -1
  483. package/library/types/components/VcSoundplayer/VcPlayerPlayStopButton.vue.d.ts +6 -6
  484. package/library/types/components/VcSoundplayer/VcPlayerSkipButtons.vue.d.ts +4 -4
  485. package/library/types/components/VcSoundplayer/VcSoundPlayerMarker.vue.d.ts +2 -2
  486. package/library/types/components/VcSoundplayer/VcSoundVolume.vue.d.ts +4 -4
  487. package/library/types/components/VcSoundplayer/player.options.d.ts +1 -0
  488. package/library/types/components/VcSparkline/VcBarLine.vue.d.ts +4 -4
  489. package/library/types/components/VcSparkline/VcSparkline.vue.d.ts +4 -4
  490. package/library/types/components/VcSparkline/VcTrendLine.vue.d.ts +4 -4
  491. package/library/types/components/VcSplitButton/VcSplitButton.vue.d.ts +6 -6
  492. package/library/types/components/VcSwitch/VcSwitch.vue.d.ts +24 -24
  493. package/library/types/components/VcSystemUserPrompt/VcSystemUserPrompt.vue.d.ts +4 -4
  494. package/library/types/components/VcTable/VcTable.vue.d.ts +6 -3
  495. package/library/types/components/VcTabs/VcTabPane.vue.d.ts +1 -1
  496. package/library/types/components/VcTabs/VcTabs.vue.d.ts +1 -1
  497. package/library/types/components/VcTag/VcTag.vue.d.ts +3 -3
  498. package/library/types/components/VcTagInput/VcTagInput.vue.d.ts +14 -14
  499. package/library/types/components/VcTimeInput/VcTimeInput.vue.d.ts +5 -5
  500. package/library/types/components/VcToolCall/UiComponents/VcToolCallValue.vue.d.ts +66 -0
  501. package/library/types/components/VcToolCall/VcToolCall.vue.d.ts +91 -0
  502. package/library/types/components/VcTour/VcTour.vue.d.ts +1 -1
  503. package/library/types/components/VcTransfer/VcTransfer.vue.d.ts +3 -3
  504. package/library/types/components/VcTree/VcTree.vue.d.ts +18 -18
  505. package/library/types/components/VcTree/VcTreeSelect.vue.d.ts +42 -42
  506. package/library/types/components/VcVerticalTabs/VcVerticalTabs.vue.d.ts +3 -3
  507. package/library/types/components/VcVerticalTabs/VerticalTabNav.vue.d.ts +3 -3
  508. package/library/types/components/VcViewSwitcher/VcViewSwitcher.vue.d.ts +9 -9
  509. package/library/types/components/VcWizard/VcSummaryProgress.vue.d.ts +2 -2
  510. package/library/types/components/VcWizard/VcWizardSummary.vue.d.ts +1 -1
  511. package/library/types/components/exports.d.ts +19 -1
  512. package/library/types/components.gen.d.ts +9 -0
  513. package/library/types/composables/input/useFileUploader.d.ts +2 -2
  514. package/library/types/composables/useElapsed.d.ts +38 -0
  515. package/library/types/composables/useThrottledText.d.ts +16 -0
  516. package/library/types/entity/components/Table/VcEntityListTable.vue.d.ts +3 -3
  517. package/library/types/entity/components/Tabs/VcEntityEditableTabs.vue.d.ts +3 -3
  518. package/library/types/enum/constants.d.ts +2 -10
  519. package/library/types/enum/inputDefaults.d.ts +2 -2
  520. package/library/types/localization/locales/en.json.d.ts +365 -194
  521. package/library/types/theme/themes.json.d.ts +177 -227
  522. package/library/types/tokens/tokens.d.ts +2 -1
  523. package/library/types/types/VcAgentRun.types.d.ts +197 -0
  524. package/library/types/types/VcAiChat.types.d.ts +5 -0
  525. package/library/types/types/VcAiReasoning.types.d.ts +67 -0
  526. package/library/types/types/VcApprovalCard.types.d.ts +109 -0
  527. package/library/types/types/VcAskUserCard.types.d.ts +166 -0
  528. package/library/types/types/VcChatComposer.types.d.ts +86 -0
  529. package/library/types/types/VcDropdown.types.d.ts +1 -1
  530. package/library/types/types/VcFileUploader.types.d.ts +26 -0
  531. package/library/types/types/VcJsonViewer.types.d.ts +41 -0
  532. package/library/types/types/VcLightbox.types.d.ts +112 -0
  533. package/library/types/types/VcMessage.types.d.ts +42 -4
  534. package/library/types/types/VcMessagesWrapper.types.d.ts +100 -12
  535. package/library/types/types/VcOtpInput.types.d.ts +1 -1
  536. package/library/types/types/VcPdfViewer.types.d.ts +138 -0
  537. package/library/types/types/VcProgress.types.d.ts +1 -1
  538. package/library/types/types/VcToolCall.types.d.ts +102 -0
  539. package/library/types/types/index.d.ts +9 -1
  540. package/library/types/utils/aiChat.d.ts +50 -0
  541. package/library/types/utils/download.d.ts +5 -0
  542. package/library/types/utils/elementPlusIcons.d.ts +9 -0
  543. package/library/types/utils/fileAccept.d.ts +30 -0
  544. package/library/types/utils/i18nParams.d.ts +8 -0
  545. package/library/types/utils/numberRuns.d.ts +21 -0
  546. package/library/types/utils/themeColor.d.ts +1 -0
  547. package/library/utils/UniqueComponentId.mjs +2 -2
  548. package/library/utils/aiChat.mjs +121 -0
  549. package/library/utils/download.mjs +13 -0
  550. package/library/utils/elementPlusIcons.mjs +14 -0
  551. package/library/utils/fileAccept.mjs +66 -0
  552. package/library/utils/i18nParams.mjs +6 -0
  553. package/library/utils/jsonSchema/index.mjs.gz +0 -0
  554. package/library/utils/numberRuns.mjs +63 -0
  555. package/library/utils/themeColor.mjs +9 -0
  556. package/package.json +216 -215
  557. package/src/theme/index.ts +101 -101
  558. package/src/theme/tailwindScheme.js +70 -37
  559. package/src/theme/theme.types.ts +31 -31
  560. package/src/theme/themeMerge.ts +61 -40
  561. package/src/theme/themes.json +177 -227
  562. package/tailwind.config.d.ts +5 -5
  563. package/tailwind.config.js +176 -192
  564. package/library/types/types/VcTagInput.types.d.ts +0 -1
package/README.md CHANGED
@@ -1,558 +1,1023 @@
1
- # Voicenter UI library for Vue
2
- This is Vue 3.x + Typescript component library made for Voicenter systems.
3
-
4
- > **v3.0.0 is a tree-shaking release with breaking changes.** See [`MIGRATION_v3.md`](./MIGRATION_v3.md). The separate `*-extended` package is gone — every component lives in this package now.
5
-
6
- ## Installation
7
-
8
- ```bash
9
- npm i @voicenter-team/voicenter-ui-plus
10
- npm i vue@^3.5 element-plus @vueuse/core dayjs lodash-es libphonenumber-js maska
11
- ```
12
-
13
- ### Sass compiler (build-time)
14
-
15
- This library customizes element-plus theming via SCSS variable injection at build time. Your bundler needs to be able to compile SCSS. If your project doesn't already use Sass, add it as a dev dependency:
16
-
17
- ```bash
18
- npm i -D sass-embedded
19
- ```
20
-
21
- This is a **build-time only** requirement — it doesn't add anything to your runtime bundle. Most Vue 3 / Vite projects already have it.
22
-
23
- Optional peer deps — install only for the heavy components you use:
24
-
25
- | Component | Peer deps |
26
- |---|---|
27
- | `VcPdfDocument` | `pdfjs-dist@^2.16.105` |
28
- | `VcSoundPlayer` | `wavesurfer.js` |
29
- | `VcExcelFileUploader` | `xlsx` |
30
- | `VcImageUploader` | `vue-advanced-cropper` |
31
- | `VcHtmlEditor` / `VcJsonSchema` | `codemirror @codemirror/lang-html @codemirror/lang-json @codemirror/lang-markdown vue-codemirror6` |
32
- | `VcMdEditor` | `@milkdown/crepe @milkdown/kit @milkdown/vue @prosemirror-adapter/vue` |
33
-
34
- ### If you're on Vite 8 / rolldown (and skipping some optional peers)
35
-
36
- Vite 8's rolldown-based bundler validates named imports against optional-peer-dep stubs and fails the build with `MISSING_EXPORT` errors when a heavy component's peer is uninstalled — even when you don't use that component. Add the unused optional peers to `build.rollupOptions.external` in your `vite.config.ts`:
37
-
38
- ```ts
39
- // vite.config.ts
40
- import { defineConfig } from 'vite'
41
- import vue from '@vitejs/plugin-vue'
42
-
43
- export default defineConfig({
44
- plugins: [ vue() ],
45
- build: {
46
- rollupOptions: {
47
- external: [
48
- // List only the heavy peers you DON'T install
49
- /^@milkdown\//, /^@prosemirror/, /^@codemirror\//, /^codemirror/,
50
- /^vue-codemirror6/, /^vue-advanced-cropper/,
51
- 'wavesurfer.js', 'xlsx', 'pdfjs-dist', /^pdfjs-dist\//
52
- ]
53
- }
54
- }
55
- })
56
- ```
57
-
58
- Earlier Vite versions (5, 6, 7 with rollup) and webpack 5+ don't require this — the older rollup variant warns but doesn't error on optional-peer named imports.
59
-
60
- ## Usage
61
-
62
- ### Tree-shake mode (recommended)
63
- ```ts
64
- import { VcButton, VcInput } from '@voicenter-team/voicenter-ui-plus'
65
- // Use as local components — no app.use() needed.
66
- ```
67
- Bundlers drop unused components and their CSS. A consumer importing only `VcButton` ships ~50–150 KB JS + ~10–30 KB CSS.
68
-
69
- If you use `useConfirmModal`, `useConfirmPopup`, or `NotifyService`, mount global overlays in `App.vue`:
70
-
71
- ```vue
72
- <script setup lang="ts">
73
- import { VcPluginOverlays } from '@voicenter-team/voicenter-ui-plus'
74
- </script>
75
-
76
- <template>
77
- <RouterView />
78
- <VcPluginOverlays />
79
- </template>
80
- ```
81
-
82
- ### Plugin mode (global registration)
83
- ```ts
84
- import VoicenterUI from '@voicenter-team/voicenter-ui-plus/plugin'
85
- import '@voicenter-team/voicenter-ui-plus/style.css'
86
-
87
- // Overlay composables can be imported from the same entry:
88
- // import { useConfirmModal, useConfirmPopup, VcPluginOverlays } from '@voicenter-team/voicenter-ui-plus/plugin'
89
-
90
- app.use(VoicenterUI, {
91
- themeConfig, // theme config (see below)
92
- lang: 'en', // localization
93
- injectIconFont: true // inject icon-font <link> tags into <head>
94
- })
95
- // Confirm modals/popovers/notifications: auto-mounted via VcPluginOverlays
96
- // (mountOverlays: true by default). Opt out with mountOverlays: false and
97
- // add <VcPluginOverlays /> to App.vue — also registered globally by the plugin.
98
- ```
99
-
100
- ### Global overlays
101
-
102
- Several APIs are **state-only** — they update global reactive singletons but do not render UI by themselves:
103
-
104
- | API | Overlay component |
105
- |---|---|
106
- | `useConfirmModal` | `VcConfirmModal` |
107
- | `useConfirmPopup` | `VcConfirmPopover` |
108
- | `NotifyService` / `$notify` | `VcNotification` |
109
-
110
- **Plugin mode:** mounted automatically on `app.use()` (default). Pass `mountOverlays: false` to mount manually.
111
-
112
- **Notifications:** one top-right host by default. For multiple positions, use `overlayNotifications` in plugin config or mount your own:
113
-
114
- ```ts
115
- app.use(VoicenterUI, {
116
- overlayNotifications: [
117
- { group: 'top-right', position: 'top-right' },
118
- { group: 'bottom-right', position: 'bottom-right' },
119
- ],
120
- })
121
- // NotifyService.add({ group: 'bottom-right', ... })
122
- ```
123
-
124
- Or `overlayNotifications: 'none'` and put `<VcNotification />` in App.vue (confirms still auto-mount).
125
-
126
- **Tree-shake mode:** add `<VcPluginOverlays />` to `App.vue` (bundles confirm hosts; configure via `notifications` prop).
127
-
128
- Entity components such as `VcEntityListTable` call `useConfirmModal` internally — delete confirmations require overlays to be mounted.
129
-
130
- ### Tailwind
131
-
132
- Tailwind's colours come from the library scheme, so the utility classes and the theme are one set of tokens. `theme.colors` replaces Tailwind's own palette on purpose: only the library's colours exist as classes.
133
-
134
- ```js
135
- // tailwind.config.js
136
- const voiceTailwindScheme = require('@voicenter-team/voicenter-ui-plus/src/theme/tailwindScheme')
137
-
138
- module.exports = {
139
- ...yourConfiguration,
140
- theme: {
141
- colors: { ...voiceTailwindScheme },
142
- borderColor: { ...voiceTailwindScheme },
143
- fill: voiceTailwindScheme
144
- }
145
- }
146
- ```
147
-
148
- Import the application's own stylesheet after the library, so the application's utilities win ties of equal specificity with the library's CSS (`.hidden` is the usual one).
149
-
150
- ### Theming specification
151
- The `themeConfig` which is passed as options to the VoicenterUI `vue.use` data could have the following specifications:
152
-
153
- ### Local
154
- **Config:**
155
- ```js
156
- {
157
- type: 'local'
158
- themeName: 'red' | 'blue' | '...'
159
- onSetupCallback: () => {
160
- console.log('Loaded!')
161
- }
162
- }
163
- ```
164
- **Description:**
165
-
166
- Such configuration will append to the document element the CSS variables from one of the configuration passed in `themeName` parameter which it will get from theme specification delivered alongside with library
167
-
168
- **Params:**
169
- - **themeName**
170
- - The name of the theme to be injected
171
- - **onSetupCallback**
172
- - The function which will be called right after the variables will be injected into the document element. First parameter of which is the theme object which was set up
173
-
174
- ### Remote
175
- **Config:**
176
- ```js
177
- {
178
- type: 'remote'
179
- brandingSectionName: 'someName'
180
- apiUrl: 'someUrl'
181
- brandingSectionName: {
182
- property: 'data'
183
- }
184
- onSetupCallback: () => {
185
- console.log('Loaded!')
186
- }
187
- }
188
- ```
189
- **Description:**
190
-
191
- Such configuration will initiate the call to the specified apiUrl in order to retrieve the JSON object with key-value properties of the CSS variables to inject to document element
192
-
193
- **Params:**
194
- - **brandingSectionName**
195
- - [Optional] The name of the section (tagSection) in the database configuration which will be passed to the API in payload and on response retrieved replaced from resulted values
196
- - **apiUrl**
197
- - The API url to which the POST request will be initiated
198
- - **onSetupCallback**
199
- - The function which will be called right after the variables will be injected into the document element. First parameter of which is the theme object which was set up
200
- - **brandingSectionName**
201
- - [Optional] The payload data that will be sent to the request
202
-
203
- ### Custom JSON
204
- **Config:**
205
- ```js
206
- {
207
- type: 'customJson'
208
- config: {
209
- black: '#000000'
210
- }
211
- onSetupCallback: () => {
212
- console.log('Loaded!')
213
- }
214
- }
215
- ```
216
- **Description:**
217
-
218
- Such configuration will initiate the styling with custom provided theme
219
-
220
- **Params:**
221
- - **config**
222
- - The object where the key is the variable to be set and the value is the variable value. Check the [themes object](https://github.com/VoicenterTeam/voicenter-ui-plus/blob/master/src/theme/themes.json) to check existing variables
223
- - **onSetupCallback**
224
- - The function which will be called right after the variables will be injected into the document element. First parameter of which is the theme object which was set up
225
-
226
- ### None
227
- `{ type: 'none', onSetupCallback?: (theme) => void }` injects no theme variables; the application sets them itself.
228
-
229
- ## Using ui-plus in an application
230
-
231
- How an application builds its UI with ui-plus. Agents working in a consuming project read this section before any UI work; it describes the version installed next to it.
232
-
233
- ### Where the facts are
234
-
235
- The installed package is the truth. Read it before saying what ui-plus has or how a component behaves.
236
-
237
- - **Every component**: `library/types/components/exports.d.ts`. One component's props, events and slots: `library/types/components/<VcName>/<VcName>.vue.d.ts`.
238
- - **Composables, services, directives, the entity base**: `library/types/composables/`, `library/types/services/`, `library/types/directives/`, `library/types/entity/`.
239
- - **Types**: prop, event and configuration types are exported from the package root (`import type { UIConfig } from '@voicenter-team/voicenter-ui-plus'`). Generic components take type parameters in the template: `<VcSelect<User, 'id', 'name'> v-model="selected" :options="users" value-key="id" label-key="name" />`.
240
- - **Colour tokens**: `src/theme/themes.json` (each key is the CSS variable `--<key>`) and `src/theme/tailwindScheme.js` (the Tailwind colour names).
241
- - **Examples**: the [live documentation](https://voicenter-ui.netlify.app/).
242
-
243
- ### Choosing a component
244
-
245
- - Interaction components come from ui-plus: buttons, inputs, selects, date pickers, checkboxes, tabs, tables, modals, drawers, tooltips, popovers, uploaders, notifications, confirmations. Search `exports.d.ts` by what the user is shown (a picker of people, an on/off switch, a list with a search) before concluding a component is missing.
246
- - A component is used **as the library draws it**: through its props, slots and variants. Fitting it into the layout is free: width, spacing, wrapping, alignment.
247
- - A **custom control** needs the project owner's explicit yes, asked before it is written: which element is needed, what was searched in ui-plus, why nothing fits. Custom means any of:
248
- - a new interaction component;
249
- - a ui-plus component whose own CSS variables (`--el-*`, the ones ui-plus sets on `.vc-*`) or internal classes are overridden to change how it looks or behaves as a control: its track, rows, selected, hover or active state, shape or indicator;
250
- - a ui-plus component used for a role it is not built for, such as a segmented switcher drawn as a searchable list.
251
- - Until that yes, the closest ui-plus component is used as drawn, and the difference from the design is the first open point of the report: what the design draws, which component was used, how they differ. No agent or orchestrator gives this approval in the owner's place.
252
- - A report names a control by what is on screen: a restyled ui-plus component is reported as custom.
253
- - A design hand-off (Figma, mock-up, screenshot, a specification) says what the user should see. It never justifies a restyle or a custom control.
254
-
255
- ### Colours
256
-
257
- - Every colour is a ui-plus token: a Tailwind class from the library scheme (`text-default-text`, `text-secondary-text`, `text-primary`, `bg-main-bg`, `bg-light-bg`, `border-ui-lines`, `text-success`, `text-error`) or a theme variable in a style (`color: var(--default-text)`). Status colours, tags, icons and chart series included.
258
- - Hex values, `rgb()`/`rgba()`, arbitrary classes such as `bg-[#…]` and new colour variables stay out of application code. Such colours already in a project are not a precedent.
259
- - The theme configuration (`themeConfig`, usually a `colors.json`) sets the library theme. It is not a palette to add colours to.
260
-
261
- ### Notifications and confirmations
262
-
263
- `NotifyService`, `useConfirmModal` and `useConfirmPopup` render only through the hosts described in [Global overlays](#global-overlays), mounted once in the application. A `VcNotification` host shows only the messages of its own `group`, so where the application mounts one host per group, every notification names one of those groups.
264
-
265
- ### Text direction
266
-
267
- ui-plus follows the `dir` attribute of `<html>`: `useRTL()` reads it and updates when it changes. The application sets the direction there, once.
268
-
269
- ### Server-side rendering
270
-
271
- ui-plus is built and tested for client-rendered Vue applications. Its composables read `document` and `window` when they are called (`useRTL` among them), and the package ships no Nuxt module. An application with server-side rendering proves one page that uses ui-plus in development and in a production build before relying on it, and reports what fails.
272
-
273
- ### Troubleshooting
274
-
275
- - **Component not found or a blank page**: in tree-shake mode a component is a local import, never a globally registered tag. In plugin mode both `app.use(VoicenterUI, …)` and `import '@voicenter-team/voicenter-ui-plus/style.css'` are present.
276
- - **`Cannot find module 'pdfjs-dist'` (or another optional peer) at build time**: install the peer, or stop importing its component.
277
- - **Duplicate styles, a huge CSS payload**: the two modes are mixed (named imports plus the global `style.css`). Pick one (`MIGRATION_v3.md`, §1).
278
- - **PDF.js worker not loading**: the worker is a sibling asset resolved with `new URL('./pdf.worker.min.js', import.meta.url)`; the bundler must support that pattern (Vite, webpack 5+, Rollup and esbuild do).
279
-
280
- ## Date Handling
281
-
282
- This library uses **dayjs** for all date operations and formatting. When working with date-related components, use dayjs format tokens (NOT date-fns format tokens).
283
-
284
- ### Format Tokens
285
-
286
- **Important**: Use dayjs format tokens:
287
- - `DD` - Day of month (2 digits) - **NOT** `dd`
288
- - `YYYY` - 4-digit year - **NOT** `yyyy`
289
- - `MM` - Month (2 digits)
290
- - `HH` - 24-hour format
291
- - `mm` - Minutes
292
- - `ss` - Seconds
293
-
294
- ### Common Formats
295
-
296
- ```typescript
297
- 'DD/MM/YYYY' // 31/12/2024
298
- 'DD-MM-YYYY' // 31-12-2024
299
- 'YYYY-MM-DD' // 2024-12-31
300
- 'DD/MM/YYYY, HH:mm' // 31/12/2024, 14:30
301
- 'DD/MM/YYYY HH:mm:ss' // 31/12/2024 14:30:45
302
- ```
303
-
304
- ### Usage Example
305
-
306
- ```vue
307
- <VcDatePicker
308
- v-model="date"
309
- format="DD/MM/YYYY"
310
- input-date-format="DD/MM/YYYY"
311
- input-time-format="HH:mm"
312
- />
313
- ```
314
-
315
- ## Date Utility Functions
316
-
317
- The library provides a comprehensive set of date utility functions built on dayjs. These utilities are available for use in external projects.
318
-
319
- ### Import Date Utilities
320
-
321
- ```typescript
322
- import {
323
- formatDate,
324
- parseDate,
325
- addDays,
326
- subtractDays,
327
- getHours,
328
- getMinutes,
329
- getSeconds,
330
- setTime,
331
- isAfter,
332
- isSameAfter,
333
- isBefore,
334
- isSameBefore,
335
- format,
336
- add,
337
- sub,
338
- addFp,
339
- subFp
340
- } from '@voicenter-team/voicenter-ui-plus'
341
- ```
342
-
343
- ### Basic Date Operations
344
-
345
- #### Formatting Dates
346
-
347
- ```typescript
348
- // Format a date with default format (YYYY-MM-DD)
349
- const formatted = formatDate(new Date())
350
- // Result: "2024-12-31"
351
-
352
- // Format with custom format
353
- const custom = formatDate(new Date(), 'DD/MM/YYYY')
354
- // Result: "31/12/2024"
355
-
356
- // Using format function (alias)
357
- const formatted2 = format(new Date(), 'DD/MM/YYYY HH:mm')
358
- // Result: "31/12/2024 14:30"
359
- ```
360
-
361
- #### Parsing Dates
362
-
363
- ```typescript
364
- // Parse a date string with format
365
- const date = parseDate('31/12/2024', 'DD/MM/YYYY')
366
- // Returns: Date object
367
- ```
368
-
369
- ### Date Arithmetic
370
-
371
- #### Adding/Subtracting Days
372
-
373
- ```typescript
374
- // Add days
375
- const futureDate = addDays(new Date(), 7)
376
- // Returns: Date 7 days from now
377
-
378
- // Subtract days
379
- const pastDate = subtractDays(new Date(), 5)
380
- // Returns: Date 5 days ago
381
- ```
382
-
383
- #### Adding/Subtracting Time Units
384
-
385
- ```typescript
386
- // Add multiple time units
387
- const newDate = add(new Date(), {
388
- years: 1,
389
- months: 2,
390
- days: 5,
391
- hours: 3,
392
- minutes: 30
393
- })
394
-
395
- // Subtract multiple time units
396
- const earlierDate = sub(new Date(), {
397
- weeks: 2,
398
- days: 3,
399
- hours: 12
400
- })
401
-
402
- // Functional programming style (reversed arguments)
403
- const fpDate = addFp({ days: 7 }, new Date())
404
- const fpDate2 = subFp({ hours: 5 }, new Date())
405
- ```
406
-
407
- ### Time Operations
408
-
409
- #### Getting Time Components
410
-
411
- ```typescript
412
- const date = new Date('2024-12-31T14:30:45')
413
-
414
- const hours = getHours(date) // 14
415
- const minutes = getMinutes(date) // 30
416
- const seconds = getSeconds(date) // 45
417
- ```
418
-
419
- #### Setting Time
420
-
421
- ```typescript
422
- // Set time on a date (returns new Date object)
423
- const newDate = setTime(new Date(), {
424
- hours: 14,
425
- minutes: 30,
426
- seconds: 0
427
- })
428
- ```
429
-
430
- ### Date Comparisons
431
-
432
- ```typescript
433
- const date1 = new Date('2024-12-31')
434
- const date2 = new Date('2025-01-01')
435
-
436
- // Check if date1 is after date2
437
- const isLater = isAfter(date1, date2, 'day')
438
- // Returns: false
439
-
440
- // Check if date1 is same or after date2
441
- const isSameOrLater = isSameAfter(date1, date2, 'day')
442
- // Returns: false
443
-
444
- // Check if date1 is before date2
445
- const isEarlier = isBefore(date1, date2, 'day')
446
- // Returns: true
447
-
448
- // Check if date1 is same or before date2
449
- const isSameOrEarlier = isSameBefore(date1, date2, 'day')
450
- // Returns: true
451
- ```
452
-
453
- **Comparison Units**: The comparison functions accept a `units` parameter (default: `'minute'`). Valid units:
454
- - `'year'`, `'month'`, `'week'`, `'day'`
455
- - `'hour'`, `'minute'`, `'second'`
456
-
457
- ### Complete Usage Example
458
-
459
- ```typescript
460
- import {
461
- formatDate,
462
- addDays,
463
- isAfter,
464
- format,
465
- add,
466
- getHours,
467
- setTime
468
- } from '@voicenter-team/voicenter-ui-plus'
469
-
470
- // Format today's date
471
- const today = formatDate(new Date(), 'DD/MM/YYYY')
472
-
473
- // Get date 30 days from now
474
- const futureDate = addDays(new Date(), 30)
475
-
476
- // Check if a date is in the future
477
- const isFuture = isAfter(futureDate, new Date(), 'day')
478
-
479
- // Add 2 weeks and 3 days
480
- const deadline = add(new Date(), {
481
- weeks: 2,
482
- days: 3
483
- })
484
-
485
- // Get current hour
486
- const currentHour = getHours(new Date())
487
-
488
- // Set specific time
489
- const meetingTime = setTime(new Date(), {
490
- hours: 14,
491
- minutes: 30
492
- })
493
-
494
- // Format the result
495
- const formattedDeadline = format(deadline, 'DD/MM/YYYY HH:mm')
496
- ```
497
-
498
- ### Notes
499
-
500
- - All functions accept `Date`, `string`, or `number` as date input
501
- - All date manipulation functions return new `Date` objects (immutable)
502
- - Format strings use dayjs format tokens (see Format Tokens section above)
503
- - These utilities are built on dayjs and maintain compatibility with dayjs format patterns
504
-
505
- ## Contributing: adding a new component
506
-
507
- The public component surface is defined in **one place**: [`script/components-manifest.mjs`](./script/components-manifest.mjs) — one line per component.
508
-
509
- ```js
510
- { name: 'VcMyThing', path: 'components/VcMyThing/VcMyThing.vue' },
511
- ```
512
-
513
- `npm run generate:entries` materializes the manifest into three fully
514
- generated files (never edit them by hand — the next generator run
515
- overwrites them, and the verifier fails the build until they match):
516
-
517
- - `src/components.gen.ts` — named exports, re-exported by `src/index.ts`
518
- (tree-shake mode);
519
- - `src/plugin-components.gen.ts` — `registerComponents(app)`, called by
520
- the plugin's install (global registration mode);
521
- - `src/components/exports.ts` — the `GlobalComponents` template typing.
522
-
523
- `src/index.ts` and `src/plugin.ts` themselves stay hand-written and small.
524
- The `.gen` modules are safe to route through only because
525
- `rewriteCssImports()` in `vite.config.ts` strips the CSS imports that
526
- `vite-plugin-lib-inject-css` aggregates onto them — each component's CSS
527
- stays in its own chunk, so per-component CSS tree-shaking survives. Don't
528
- rename the `.gen` files without updating that strip list (the verifier
529
- guards this wiring too).
530
-
531
- Typical flows:
532
-
533
- - **New component**: `node script/create-component.mjs` — scaffolds the
534
- component folder, adds the manifest line, and regenerates all entries.
535
- - **Existing .vue file**: add one line to the manifest, then
536
- `npm run generate:entries`.
537
-
538
- Every manifest entry is exported from the package root AND registered
539
- globally in plugin mode — there are no partial modes.
540
-
541
- `npm run verify:entries` is the safety net: it independently cross-checks
542
- the manifest, the three generated files and the filesystem (a component
543
- file that exists but is missing from the manifest fails too). It runs in
544
- the pre-commit hook (together with `lint-staged` and `ts-check`; hooks are
545
- installed automatically by `npm install` via husky) and in CI, so an
546
- inconsistent component surface cannot reach `master`.
547
-
548
- ## Documentation
549
-
550
- ### Live Documentation
551
- Visit [documentation](https://voicenter-ui.netlify.app/) for interactive component examples and demos.
552
-
553
- ## Project Documentation
554
- For detailed technical documentation, see the [`docs/`](./docs/) directory:
555
-
556
- - **[Quick Start Guide](./docs/AGENTS_QUICK_START.md)** - For developers working on the library
557
- - **[Architecture Overview](./docs/ARCHITECTURE.md)** - Project structure and technical details
558
- - **[Documentation Guide](./docs/DOCUMENTATION_GUIDE.md)** - Working with the documentation system
1
+ # Voicenter UI library for Vue
2
+ This is Vue 3.x + Typescript component library made for Voicenter systems.
3
+
4
+ > **4.x renames the colour tokens, draws Lucide icons and changes some component defaults.** An application on 3.x follows [Migrating from 3.x to 4.x](#migrating-from-3x-to-4x); one on 2.x first follows [`MIGRATION_v3.md`](./MIGRATION_v3.md).
5
+
6
+ ## Installation
7
+
8
+ ```bash
9
+ npm i @voicenter-team/voicenter-ui-plus
10
+ npm i vue@^3.5 element-plus @vueuse/core @lucide/vue dayjs lodash-es libphonenumber-js maska
11
+ ```
12
+
13
+ Until 4.0.0 is released, 4.x is published under the npm tag `beta` and `latest` is 3.x: `npm i @voicenter-team/voicenter-ui-plus@beta`, or an exact `4.0.0-beta.N`.
14
+
15
+ ### Sass compiler (build-time)
16
+
17
+ This library customizes element-plus theming via SCSS variable injection at build time. Your bundler needs to be able to compile SCSS. If your project doesn't already use Sass, add it as a dev dependency:
18
+
19
+ ```bash
20
+ npm i -D sass-embedded
21
+ ```
22
+
23
+ This is a **build-time only** requirement — it doesn't add anything to your runtime bundle. Most Vue 3 / Vite projects already have it.
24
+
25
+ Optional peer deps — install only for the heavy components you use:
26
+
27
+ | Component | Peer deps |
28
+ |---|---|
29
+ | `VcPdfDocument` / `VcPdfViewer` | `pdfjs-dist@^2.16.105` |
30
+ | `VcSoundPlayer` | `wavesurfer.js` |
31
+ | `VcExcelFileUploader` | `xlsx` |
32
+ | `VcImageUploader` | `vue-advanced-cropper` |
33
+ | `VcHtmlEditor` / `VcJsonSchema` | `codemirror @codemirror/lang-html @codemirror/lang-json @codemirror/lang-markdown vue-codemirror6` |
34
+ | `VcMdEditor` | `@milkdown/crepe @milkdown/kit @milkdown/utils @milkdown/vue` (all `^7.22.0`: older releases lose every list with the current `prosemirror-model`) `@prosemirror-adapter/vue codemirror @codemirror/lang-markdown vue-codemirror6` |
35
+ | `VcAiReasoning` | the `VcMdEditor` peers |
36
+ | `VcAgentRunCard` / `VcAgentRunGroup` | the `VcMdEditor` peers and `highlight.js` (tool steps and response data through `VcJsonViewer` / `VcCodeBlock`) |
37
+ | `VcToolCall` / `VcApprovalCard` | `highlight.js` (through `VcJsonViewer` / `VcCodeBlock`) |
38
+ | `VcMessage` | the `VcMdEditor` peers, only when a message has a `markdown` block (the block is loaded on demand) |
39
+ | `VcChatComposer` | `@tiptap/core @tiptap/pm @tiptap/vue-3 @tiptap/extension-document @tiptap/extension-paragraph @tiptap/extension-text @tiptap/extension-bold @tiptap/extension-italic @tiptap/extension-strike @tiptap/extension-code @tiptap/extension-mention @tiptap/extensions @tiptap/suggestion @floating-ui/dom emojibase-data wavesurfer.js` |
40
+ | `VcLightbox` | `element-plus` (its `ElImageViewer`; already a required peer) |
41
+
42
+ ### If you're on Vite 8 / rolldown (and skipping some optional peers)
43
+
44
+ Vite 8's rolldown-based bundler validates named imports against optional-peer-dep stubs and fails the build with `MISSING_EXPORT` errors when a heavy component's peer is uninstalled — even when you don't use that component. Add the unused optional peers to `build.rollupOptions.external` in your `vite.config.ts`:
45
+
46
+ ```ts
47
+ // vite.config.ts
48
+ import { defineConfig } from 'vite'
49
+ import vue from '@vitejs/plugin-vue'
50
+
51
+ export default defineConfig({
52
+ plugins: [ vue() ],
53
+ build: {
54
+ rollupOptions: {
55
+ external: [
56
+ // List only the heavy peers you DON'T install
57
+ /^@milkdown\//, /^@prosemirror/, /^@codemirror\//, /^codemirror/,
58
+ /^vue-codemirror6/, /^vue-advanced-cropper/,
59
+ 'wavesurfer.js', 'xlsx', 'pdfjs-dist', /^pdfjs-dist\//
60
+ ]
61
+ }
62
+ }
63
+ })
64
+ ```
65
+
66
+ Earlier Vite versions (5, 6, 7 with rollup) and webpack 5+ don't require this — the older rollup variant warns but doesn't error on optional-peer named imports.
67
+
68
+ ## Usage
69
+
70
+ ### Tree-shake mode (recommended)
71
+ ```ts
72
+ import { VcButton, VcInput } from '@voicenter-team/voicenter-ui-plus'
73
+ // Use as local components — no app.use() needed.
74
+ ```
75
+ Bundlers drop unused components and their CSS. A consumer importing only `VcButton` ships ~50–150 KB JS + ~10–30 KB CSS.
76
+
77
+ The stylesheet sets the default theme (redGreen) on `:root`. Another theme and the text font are two calls, the ones the plugin makes itself:
78
+
79
+ ```ts
80
+ import Theme from '@voicenter-team/voicenter-ui-plus/theme'
81
+ import { loadTextFont } from '@voicenter-team/voicenter-ui-plus/font'
82
+
83
+ Theme({ type: 'local', themeName: 'voicenter' }) // any themeConfig, see "Theming specification"
84
+ loadTextFont() // Rubik from Google Fonts
85
+ ```
86
+
87
+ If you use `useConfirmModal`, `useConfirmPopup`, or `NotifyService`, mount global overlays in `App.vue`:
88
+
89
+ ```vue
90
+ <script setup lang="ts">
91
+ import { VcPluginOverlays } from '@voicenter-team/voicenter-ui-plus'
92
+ </script>
93
+
94
+ <template>
95
+ <RouterView />
96
+ <VcPluginOverlays />
97
+ </template>
98
+ ```
99
+
100
+ ### Plugin mode (global registration)
101
+ ```ts
102
+ import VoicenterUI from '@voicenter-team/voicenter-ui-plus/plugin'
103
+ import '@voicenter-team/voicenter-ui-plus/style.css'
104
+
105
+ // Overlay composables can be imported from the same entry:
106
+ // import { useConfirmModal, useConfirmPopup, VcPluginOverlays } from '@voicenter-team/voicenter-ui-plus/plugin'
107
+
108
+ app.use(VoicenterUI, {
109
+ themeConfig, // theme config (see below)
110
+ lang: 'en', // localization
111
+ injectIconFont: true // the vc-icon-* font, for vc-icon-* classes
112
+ })
113
+ // Confirm modals/popovers/notifications: auto-mounted via VcPluginOverlays
114
+ // (mountOverlays: true by default). Opt out with mountOverlays: false and
115
+ // add <VcPluginOverlays /> to App.vue — also registered globally by the plugin.
116
+ ```
117
+
118
+ ### Global overlays
119
+
120
+ Several APIs are **state-only** — they update global reactive singletons but do not render UI by themselves:
121
+
122
+ | API | Overlay component |
123
+ |---|---|
124
+ | `useConfirmModal` | `VcConfirmModal` |
125
+ | `useConfirmPopup` | `VcConfirmPopover` |
126
+ | `NotifyService` / `$notify` | `VcNotification` |
127
+
128
+ **Plugin mode:** mounted automatically on `app.use()` (default). Pass `mountOverlays: false` to mount manually.
129
+
130
+ **Notifications:** one top-right host by default. For multiple positions, use `overlayNotifications` in plugin config or mount your own:
131
+
132
+ ```ts
133
+ app.use(VoicenterUI, {
134
+ overlayNotifications: [
135
+ { group: 'top-right', position: 'top-right' },
136
+ { group: 'bottom-right', position: 'bottom-right' },
137
+ ],
138
+ })
139
+ // NotifyService.add({ group: 'bottom-right', ... })
140
+ ```
141
+
142
+ Or `overlayNotifications: 'none'` and put `<VcNotification />` in App.vue (confirms still auto-mount).
143
+
144
+ **Tree-shake mode:** add `<VcPluginOverlays />` to `App.vue` (bundles confirm hosts; configure via `notifications` prop).
145
+
146
+ Entity components such as `VcEntityListTable` call `useConfirmModal` internally — delete confirmations require overlays to be mounted.
147
+
148
+ ### Tailwind
149
+
150
+ The scheme and the shipped `tailwind.config.js` are Tailwind 3 configurations: an application installs `tailwindcss@3`, `postcss` and `autoprefixer` (`npx tailwindcss init -p` creates its configuration).
151
+
152
+ Tailwind's colours come from the library scheme, so the utility classes and the theme are one set of tokens. `theme.colors` replaces Tailwind's own palette on purpose: only the library's colours exist as classes.
153
+
154
+ ```js
155
+ // tailwind.config.js
156
+ const voiceTailwindScheme = require('@voicenter-team/voicenter-ui-plus/src/theme/tailwindScheme')
157
+
158
+ module.exports = {
159
+ ...yourConfiguration,
160
+ theme: {
161
+ colors: { ...voiceTailwindScheme },
162
+ borderColor: { ...voiceTailwindScheme },
163
+ fill: voiceTailwindScheme
164
+ }
165
+ }
166
+ ```
167
+
168
+ The library's own `tailwind.config.js` (shipped as `@voicenter-team/voicenter-ui-plus/tailwind.config`) also has keys for the radii, shadows, font family and font weights of the components; [Corners](#corners), [Shadows](#shadows) and [Text](#text) say what each class is for. Their values are the CSS variables the library stylesheet sets on `:root` in both modes, so a class drawn with them changes together with the library. An application takes these keys from the shipped configuration:
169
+
170
+ ```js
171
+ // tailwind.config.js
172
+ const uiPlusTheme = require('@voicenter-team/voicenter-ui-plus/tailwind.config').theme
173
+
174
+ module.exports = {
175
+ ...yourConfiguration,
176
+ theme: {
177
+ // colours as above
178
+ extend: {
179
+ borderRadius: uiPlusTheme.borderRadius,
180
+ boxShadow: uiPlusTheme.boxShadow,
181
+ transitionProperty: uiPlusTheme.extend.transitionProperty,
182
+ fontFamily: uiPlusTheme.fontFamily,
183
+ fontWeight: uiPlusTheme.extend.fontWeight
184
+ }
185
+ }
186
+ }
187
+ ```
188
+
189
+ Import the application's own stylesheet after the library, so the application's utilities win ties of equal specificity with the library's CSS (`.hidden` is the usual one).
190
+
191
+ Tailwind's preflight (`@tailwind base`) in that stylesheet sets `font-family` on `html` again, Tailwind's sans font, after the library set Rubik there. `html { @apply font-main; }` in the application's `@layer base` keeps the library font on the page.
192
+
193
+ The 3.x colour names are not in the scheme; [Migrating from 3.x to 4.x](#migrating-from-3x-to-4x) lists their 4.x names.
194
+
195
+ ### Theming specification
196
+ The `themeConfig` passed to `app.use(VoicenterUI, { themeConfig })`, or to `Theme()` in tree-shake mode, could have the following specifications.
197
+
198
+ A theme is a flat object of colour tokens. Each key is set on the document element as a CSS variable with `--` in front of it: `vc-action-primary` becomes `--vc-action-primary`. The keys are grouped by role:
199
+
200
+ - `vc-content-*`: text and icons (`primary`, `secondary`, `tertiary`, `disabled`, `success`, `warning`, `danger`, `info`); the built-in themes also set `vc-content-warning-icon`, which no component reads;
201
+ - `vc-bg-*`: backgrounds (`page`, `surface`, `inset`, `inset-strong`, `field`, `muted`, `overlay`);
202
+ - `vc-action-*`: fills of interactive elements (`primary`, `secondary`, `info`, `success`, `warning`, `danger`);
203
+ - `vc-onfill` and `vc-onfill-{fill}`: text on a solid fill. Every built-in theme sets `vc-onfill-primary` and `vc-onfill-warning`; `vc-onfill-secondary`, `vc-onfill-info`, `vc-onfill-success` and `vc-onfill-danger` are optional, and a fill whose key is not set takes `vc-onfill`;
204
+ - `vc-border`, `vc-border-strong`, `vc-input` (field borders), `vc-ring` (focus ring), `vc-shadow-color`;
205
+ - `vc-mix-anchor` and `vc-mix-anchor-{fill}`: the colour hover and pressed states are mixed toward (black darkens, white lightens). Any fill can have its own anchor: a fill whose `vc-mix-anchor-{fill}` key is not set mixes toward `vc-mix-anchor`. Every built-in theme sets `vc-mix-anchor-primary` and `vc-mix-anchor-warning`, the two fills with their own text colour.
206
+
207
+ Hover, pressed, disabled and tinted states (`--vc-action-primary--hover`, `--vc-action-primary--subtle-hover`, …) are mixed from these values by the library, so a theme sets only the base colours. The Element Plus colour variables (`--el-color-primary`, `--el-bg-color`, `--el-border-color`, …) are filled from the same tokens; a theme can still set an `el-*` key to override one. A theme that does not set `vc-content-success`, `vc-content-warning`, `vc-content-danger` or `vc-content-info` takes its `vc-action-*` of the same status for it.
208
+
209
+ The full list of keys and the values of every built-in theme are in [`src/theme/themes.json`](https://github.com/VoicenterTeam/voicenter-ui-plus/blob/master/src/theme/themes.json). The library's stylesheet sets the keys of the default theme (redGreen) on `:root`. Any other key a theme leaves out takes the default theme's value; after a theme switch at run time, a key the new theme leaves out keeps the previous theme's value. Theme keys of 3.x (`primary`, `default-text`, `ui-lines`, …) are not read, and nothing warns about them: a `customJson` or remote theme with 3.x keys draws the default theme. A theme passes the `vc-*` keys ([Migrating from 3.x to 4.x](#migrating-from-3x-to-4x) maps them).
210
+
211
+ ### Local
212
+ **Config:**
213
+ ```js
214
+ {
215
+ type: 'local'
216
+ themeName: 'voicenter' | 'voicenterRed' | 'red' | 'redGreen' | 'black'
217
+ onSetupCallback: () => {
218
+ console.log('Loaded!')
219
+ }
220
+ }
221
+ ```
222
+ **Description:**
223
+
224
+ Such configuration will append to the document element the CSS variables from one of the configuration passed in `themeName` parameter which it will get from theme specification delivered alongside with library
225
+
226
+ **Params:**
227
+ - **themeName**
228
+ - The name of the theme to be injected. `redGreen` is the default (it is also used when no `themeConfig` is passed); `black` is a dark theme; `voicenter` and `voicenterRed` have the same values. An unknown name logs a warning and keeps the default.
229
+ - **onSetupCallback**
230
+ - The function which will be called right after the variables will be injected into the document element. First parameter of which is the theme object which was set up
231
+
232
+ ### Remote
233
+ **Config:**
234
+ ```js
235
+ {
236
+ type: 'remote'
237
+ brandingSectionName: 'someName'
238
+ apiUrl: 'someUrl'
239
+ brandingSectionName: {
240
+ property: 'data'
241
+ }
242
+ onSetupCallback: () => {
243
+ console.log('Loaded!')
244
+ }
245
+ }
246
+ ```
247
+ **Description:**
248
+
249
+ Such configuration will initiate the call to the specified apiUrl in order to retrieve the JSON object with key-value properties of the CSS variables to inject to document element
250
+
251
+ **Params:**
252
+ - **brandingSectionName**
253
+ - [Optional] The name of the section (tagSection) in the database configuration which will be passed to the API in payload and on response retrieved replaced from resulted values
254
+ - **apiUrl**
255
+ - The API url to which the POST request will be initiated
256
+ - **onSetupCallback**
257
+ - The function which will be called right after the variables will be injected into the document element. First parameter of which is the theme object which was set up
258
+ - **brandingSectionName**
259
+ - [Optional] The payload data that will be sent to the request
260
+
261
+ ### Custom JSON
262
+ **Config:**
263
+ ```js
264
+ {
265
+ type: 'customJson'
266
+ config: {
267
+ 'vc-action-primary': '#E80130',
268
+ 'vc-content-primary': '#1F2937'
269
+ }
270
+ onSetupCallback: () => {
271
+ console.log('Loaded!')
272
+ }
273
+ }
274
+ ```
275
+ **Description:**
276
+
277
+ Such configuration will initiate the styling with custom provided theme
278
+
279
+ **Params:**
280
+ - **config**
281
+ - The object where the key is the variable to be set and the value is the variable value. The keys are the theme keys described above; check the [themes object](https://github.com/VoicenterTeam/voicenter-ui-plus/blob/master/src/theme/themes.json) for the full list.
282
+ - **onSetupCallback**
283
+ - The function which will be called right after the variables will be injected into the document element. First parameter of which is the theme object which was set up
284
+
285
+ ### None
286
+ `{ type: 'none', onSetupCallback?: (theme) => void }` injects no theme variables; the application sets them itself.
287
+
288
+ ## Migrating from 3.x to 4.x
289
+
290
+ ### What changed and why
291
+
292
+ - **Colours** are named by their role, and a theme sets only the base colours: the hover, pressed, disabled and tinted states are mixed from them by the library, with one formula for every colour. The 3.x colour names are gone. Details: [Colour names](#colour-names), [CSS variables](#css-variables), [Tailwind colour classes](#tailwind-colour-classes), [Theme keys](#theme-keys) and [Finding the 3.x names](#finding-the-3x-names).
293
+ - **Icons** are Lucide (`@lucide/vue`), the icons of the 4.0 design, where 3.x drew the `vc-icon-*` font. An icon prop still takes a `vc-icon-*` class. Details: [Icons](#icons).
294
+ - **Corners** take one of five radius roles, `control`, `popup`, `card`, `tag` and `inner`, each a CSS variable (`--vc-radius-control`) and a class of the shipped Tailwind configuration (`rounded-control`). They replace the 3.x radius scale and `--base-border-radius`. The classes read the variables the library stylesheet sets, so a corner drawn with them changes together with the library. Details: [Corners](#corners) and [Styles and component defaults](#styles-and-component-defaults).
295
+ - **Text** has one font key, `main`, which names the role rather than the font, so a font change keeps the class; `font-inter`, `font-heebo` and `font-rubik`, which all drew Rubik, are gone. It takes three weights, `font-normal`, `font-medium` and `font-semibold` (`--vc-font-weight-*`): Rubik is a variable font whose stock weights read heavy, so the first two are lighter than in 3.x. Details: [Text](#text) and [Styles and component defaults](#styles-and-component-defaults).
296
+ - **Focus** is one ring, `shadow-focus` (`shadow-focus-inner` draws it inside), in the theme's `vc-ring` colour. The colour-named focus classes are gone: they all drew that one ring, whatever colour the name gave. Details: [Shadows](#shadows) and [Styles and component defaults](#styles-and-component-defaults).
297
+ - **Component defaults**: the fields default to `primary`, and the colours `primary-alternative` and `active` are gone, since both drew the brand colour, as `primary` does. VcTagInput and VcTreeSelect show their values as the muted chips of a multiple VcSelect, a field's prefix icon follows the size of the field, and the close and copy controls of modals, notifications and code blocks are a VcButtonIcon, with the size, radius and hover of the library's controls. Details: [Styles and component defaults](#styles-and-component-defaults).
298
+ - **Removed**: besides the names above, the theme `blue`, which no application on 3.x selects (only applications still on 0.x do), and the classes of the native close controls. The sections below give what replaces each removed name.
299
+
300
+ ### Colour names
301
+
302
+ In 4.x the colours are named by their role: `content` for text and icons, `bg` for backgrounds, `action` for the fills of interactive elements, `onfill` for text on a fill, and `border`, `input` and `ring` for lines. The 3.x colour names are gone: a 3.x CSS variable is not set, a 3.x Tailwind colour class is not generated and a 3.x theme key is not read. An application moves every colour it takes from ui-plus to the 4.x name in the tables below.
303
+
304
+ Hover, pressed and tinted states keep one pattern. In CSS variables, `--focus` (hover) becomes `--hover`, `--pressed` stays `--pressed`, and `-bg--focus` and `-bg--pressed` (the 10% and 20% washes) become `--subtle-hover` and `--subtle-pressed`: `--primary-actions-bg--focus` is `--vc-action-primary--subtle-hover`. Tailwind names use one dash: `bg-action-primary-hover`, `bg-action-primary-subtle-hover`. `destructive` and `error` are both `danger`; `primary-alternative` and `active-elements` are both `primary`.
305
+
306
+ What keeps its name:
307
+
308
+ - the `color` prop values of the components: `primary`, `secondary`, `destructive`, `success` and `warning`; `info` is new, and `active` and `primary-alternative` are removed (see "Styles and component defaults");
309
+ - the shadow classes (`shadow-card`, `shadow-table`, `shadow-hover-outer-primary`, …) apart from the focus classes, `shadow-hover`, `shadow-hover-{colour}` and `shadow-hover-outer-destructive` (see "Styles and component defaults"): they read the 4.x tokens;
310
+ - the Element Plus variables (`--el-color-primary`, `--el-border-color`, …): the library fills them from the 4.x tokens.
311
+
312
+ Props that take a Tailwind colour name take the 4.x name: `VcCollapseItem` `color-icon="action-primary"` and `color-border="border"` (the defaults). The `color` of `VcLoading` takes a component colour (`primary`, `destructive`, …) or a 4.x Tailwind colour name (`content-secondary`).
313
+
314
+ Some 3.x names had a value of their own in the built-in themes and now share a token, so they draw differently:
315
+
316
+ - `icons` and `table-headings` were an accent colour of their own in red and black and the brand colour in redGreen, and `headers` an accent colour in black; they are `content-primary`, the body text colour.
317
+ - `default-text` (red, voicenterRed) and `heading-text` (red) differed from `primary-text`; all three are `content-primary`.
318
+ - `primary-alternative` had a colour of its own in every theme; it is `action-primary`.
319
+ - `active-elements` had a colour of its own in red; it is `action-primary`.
320
+ - `inactive-elements` was the secondary colour in red, redGreen and black; it is `content-disabled`.
321
+ - `progress-line-done` was a neutral grey in red, redGreen and black; it is `action-success`. `progress-line-not-done` was the secondary colour in red and redGreen and a dark grey in black; it is `border`.
322
+ - `scrollbar-track`, `scrollbar-thumb` and `scrollbar-thumb-hover` were fixed greys in red, redGreen and black; they are `bg-surface`, `border` and `content-disabled`, so the scrollbar follows the theme.
323
+ - `destructive` and `error` were two colours in redGreen and black; both are `action-danger`.
324
+
325
+ Some names keep their meaning but have a new value in some themes: `dark-bg` (`bg-inset-strong`) in red and redGreen; `destructive`, `error`, `success`, `warning` and `actions-mix-color` in voicenterRed. The 3.x theme `blue` is not a 4.x theme: `themeName: 'blue'` logs a warning and the default theme is used.
326
+
327
+ For the brand colour, use `action-primary`.
328
+
329
+ ### CSS variables
330
+
331
+ | 3.x variable | 4.x |
332
+ | --- | --- |
333
+ | `--main-bg` | `var(--vc-bg-page)` |
334
+ | `--light-bg` | `var(--vc-bg-surface)` |
335
+ | `--card-bg-color` | `var(--vc-bg-surface)` |
336
+ | `--dark-bg` | `var(--vc-bg-inset-strong)` |
337
+ | `--field-bg` | `var(--vc-bg-field)` |
338
+ | `--overlay-bg` | `var(--vc-bg-overlay)`: it carries its own transparency (3.x components mixed `--overlay-bg` to 40%, so a 3.x value `X` becomes `color-mix(in srgb, X 40%, transparent)`) |
339
+ | `--skeleton-loader` | `var(--vc-bg-muted)` |
340
+ | `--skeleton-loader-animation` | `var(--vc-bg-skeleton-shine)` |
341
+ | `--scrollbar-track` | `var(--vc-bg-surface)` |
342
+ | `--primary-text` | `var(--vc-content-primary)` |
343
+ | `--heading-text` | `var(--vc-content-primary)` |
344
+ | `--headers` | `var(--vc-content-primary)` |
345
+ | `--icons` | `var(--vc-content-primary)` |
346
+ | `--table-headings` | `var(--vc-content-primary)` |
347
+ | `--default-text` | `var(--vc-content-primary)` |
348
+ | `--secondary-text` | `var(--vc-content-secondary)` |
349
+ | `--placeholders` | `var(--vc-content-tertiary)` |
350
+ | `--inactive-text` | `var(--vc-content-disabled)` |
351
+ | `--inactive-elements` | `var(--vc-content-disabled)` |
352
+ | `--btn-filled-text` | `var(--vc-onfill-primary, var(--vc-onfill))` |
353
+ | `--default-loader` | `var(--vc-onfill-primary, var(--vc-onfill))` |
354
+ | `--ui-lines` | `var(--vc-border)` |
355
+ | `--major-ui-lines` | `var(--vc-border-strong)` |
356
+ | `--field-borders` | `var(--vc-input)` |
357
+ | `--scrollbar-thumb` | `var(--vc-border)` |
358
+ | `--scrollbar-thumb-hover` | `var(--vc-content-disabled)` |
359
+ | `--progress-line-done` | `var(--vc-action-success)` |
360
+ | `--progress-line-not-done` | `var(--vc-border)` |
361
+ | `--card-shadow-color` | `color-mix(in srgb, var(--vc-shadow-color) 12%, transparent)` |
362
+ | `--table-shadow-color` | `color-mix(in srgb, var(--vc-shadow-color) 7%, transparent)` |
363
+ | `--actions-mix-color` | `var(--vc-mix-anchor)` |
364
+ | `--primary` | `var(--vc-action-primary)` |
365
+ | `--primary-actions` | `var(--vc-action-primary)` |
366
+ | `--primary-actions--focus` | `var(--vc-action-primary--hover)` |
367
+ | `--primary-actions--pressed` | `var(--vc-action-primary--pressed)` |
368
+ | `--primary-actions-bg--focus` | `var(--vc-action-primary--subtle-hover)` |
369
+ | `--primary-actions-bg--pressed` | `var(--vc-action-primary--subtle-pressed)` |
370
+ | `--primary-alternative` | `var(--vc-action-primary)` |
371
+ | `--primary-alternative-actions` | `var(--vc-action-primary)` |
372
+ | `--primary-alternative-actions--focus` | `var(--vc-action-primary--hover)` |
373
+ | `--primary-alternative-actions--pressed` | `var(--vc-action-primary--pressed)` |
374
+ | `--primary-alternative-actions-bg--focus` | `var(--vc-action-primary--subtle-hover)` |
375
+ | `--primary-alternative-actions-bg--pressed` | `var(--vc-action-primary--subtle-pressed)` |
376
+ | `--secondary` | `var(--vc-action-secondary)` |
377
+ | `--secondary-actions` | `var(--vc-action-secondary)` |
378
+ | `--secondary-actions--focus` | `var(--vc-action-secondary--hover)` |
379
+ | `--secondary-actions--pressed` | `var(--vc-action-secondary--pressed)` |
380
+ | `--secondary-actions-bg--focus` | `var(--vc-action-secondary--subtle-hover)` |
381
+ | `--secondary-actions-bg--pressed` | `var(--vc-action-secondary--subtle-pressed)` |
382
+ | `--destructive` | `var(--vc-action-danger)` (fills); `var(--vc-content-danger)` (text) |
383
+ | `--destructive-actions` | `var(--vc-action-danger)` (fills); `var(--vc-content-danger)` (text) |
384
+ | `--destructive-actions--focus` | `var(--vc-action-danger--hover)` |
385
+ | `--destructive-actions--pressed` | `var(--vc-action-danger--pressed)` |
386
+ | `--destructive-actions-bg--focus` | `var(--vc-action-danger--subtle-hover)` |
387
+ | `--destructive-actions-bg--pressed` | `var(--vc-action-danger--subtle-pressed)` |
388
+ | `--error` | `var(--vc-action-danger)` (fills); `var(--vc-content-danger)` (text) |
389
+ | `--error-actions` | `var(--vc-action-danger)` (fills); `var(--vc-content-danger)` (text) |
390
+ | `--error-actions--focus` | `var(--vc-action-danger--hover)` |
391
+ | `--error-actions--pressed` | `var(--vc-action-danger--pressed)` |
392
+ | `--error-actions-bg--focus` | `var(--vc-action-danger--subtle-hover)` |
393
+ | `--error-actions-bg--pressed` | `var(--vc-action-danger--subtle-pressed)` |
394
+ | `--success` | `var(--vc-action-success)` (fills); `var(--vc-content-success)` (text) |
395
+ | `--success-actions` | `var(--vc-action-success)` (fills); `var(--vc-content-success)` (text) |
396
+ | `--success-actions--focus` | `var(--vc-action-success--hover)` |
397
+ | `--success-actions--pressed` | `var(--vc-action-success--pressed)` |
398
+ | `--success-actions-bg--focus` | `var(--vc-action-success--subtle-hover)` |
399
+ | `--success-actions-bg--pressed` | `var(--vc-action-success--subtle-pressed)` |
400
+ | `--warning` | `var(--vc-action-warning)` (fills); `var(--vc-content-warning)` (text) |
401
+ | `--warning-actions` | `var(--vc-action-warning)` (fills); `var(--vc-content-warning)` (text) |
402
+ | `--warning-actions--focus` | `var(--vc-action-warning--hover)` |
403
+ | `--warning-actions--pressed` | `var(--vc-action-warning--pressed)` |
404
+ | `--warning-actions-bg--focus` | `var(--vc-action-warning--subtle-hover)` |
405
+ | `--warning-actions-bg--pressed` | `var(--vc-action-warning--subtle-pressed)` |
406
+ | `--active-elements` | `var(--vc-action-primary)` |
407
+ | `--active-elements--focus` | `var(--vc-action-primary--hover)` |
408
+ | `--active-elements--pressed` | `var(--vc-action-primary--pressed)` |
409
+ | `--active-elements-bg--focus` | `var(--vc-action-primary--subtle-hover)` |
410
+ | `--active-elements-bg--pressed` | `var(--vc-action-primary--subtle-pressed)` |
411
+ | `--inactive-elements--focus` | `color-mix(in srgb, var(--vc-content-disabled) 80%, var(--vc-mix-anchor))` |
412
+ | `--inactive-elements--pressed` | `color-mix(in srgb, var(--vc-content-disabled) 65%, var(--vc-mix-anchor))` |
413
+ | `--inactive-elements-bg--focus` | `color-mix(in srgb, var(--vc-content-disabled) 10%, transparent)` |
414
+ | `--inactive-elements-bg--pressed` | `color-mix(in srgb, var(--vc-content-disabled) 20%, transparent)` |
415
+ | `--input-font-weight` (the weight of field text, `500`) | `--input-font-weight`, now the normal weight step `var(--vc-font-weight-normal)` |
416
+
417
+ ### Tailwind colour classes
418
+
419
+ A colour name works the same after every colour prefix (`text-`, `bg-`, `border-`, `ring-`, `fill-`, `stroke-`, `divide-`, `outline-`, `placeholder-`, …) and with every variant: `text-default-text` becomes `text-content-primary`, `hover:bg-primary-actions-bg--focus` becomes `hover:bg-action-primary-subtle-hover`, `border-ui-lines` becomes `border-border`.
420
+
421
+ Text and icons in a status colour take the `content` name (`text-content-danger`, `text-content-success`). In most themes it is the same colour as the fill (`bg-action-danger`); voicenter and voicenterRed draw success and warning text and icons darker than the fill.
422
+
423
+ `primary` and `secondary` are not status colours: text and icons in them keep the fill, `text-action-primary` and `text-action-secondary`. `content-secondary` is the 3.x `secondary-text`, a grey.
424
+
425
+ | 3.x colour name | 4.x colour name |
426
+ | --- | --- |
427
+ | `main-bg` | `page` |
428
+ | `light-bg` | `surface` |
429
+ | `card-bg-color` | `surface` |
430
+ | `dark-bg` | `inset-strong` |
431
+ | `field-bg` | `field` |
432
+ | `overlay-bg` | `overlay` (it carries its own transparency, as above) |
433
+ | `skeleton-loader` | `muted` |
434
+ | `skeleton-loader-animation` | no class |
435
+ | `scrollbar-track` | `surface` |
436
+ | `primary-text` | `content-primary` |
437
+ | `heading-text` | `content-primary` |
438
+ | `headers` | `content-primary` |
439
+ | `icons` | `content-primary` |
440
+ | `table-headings` | `content-primary` |
441
+ | `default-text` | `content-primary` |
442
+ | `secondary-text` | `content-secondary` |
443
+ | `placeholders` | `content-tertiary` |
444
+ | `inactive-text` | `content-disabled` |
445
+ | `inactive-elements` | `content-disabled` |
446
+ | `btn-filled-text` | `onfill-primary` |
447
+ | `default-loader` | `onfill-primary` |
448
+ | `ui-lines` | `border` |
449
+ | `major-ui-lines` | `border-strong` |
450
+ | `field-borders` | `input` |
451
+ | `scrollbar-thumb` | `border` |
452
+ | `scrollbar-thumb-hover` | `content-disabled` |
453
+ | `progress-line-done` | `action-success` |
454
+ | `progress-line-not-done` | `border` |
455
+ | `card-shadow-color` | no class; the `shadow-card` and `shadow-table` classes carry it |
456
+ | `table-shadow-color` | no class; the `shadow-table-row` and `shadow-table-header` classes carry it |
457
+ | `actions-mix-color` | no class |
458
+ | `primary` | `action-primary` |
459
+ | `primary-actions` | `action-primary` |
460
+ | `primary-actions--focus` | `action-primary-hover` |
461
+ | `primary-actions--pressed` | `action-primary-pressed` |
462
+ | `primary-actions-bg--focus` | `action-primary-subtle-hover` |
463
+ | `primary-actions-bg--pressed` | `action-primary-subtle-pressed` |
464
+ | `primary-alternative` | `action-primary` |
465
+ | `primary-alternative-actions` | `action-primary` |
466
+ | `primary-alternative-actions--focus` | `action-primary-hover` |
467
+ | `primary-alternative-actions--pressed` | `action-primary-pressed` |
468
+ | `primary-alternative-actions-bg--focus` | `action-primary-subtle-hover` |
469
+ | `primary-alternative-actions-bg--pressed` | `action-primary-subtle-pressed` |
470
+ | `secondary` | `action-secondary` |
471
+ | `secondary-actions` | `action-secondary` |
472
+ | `secondary-actions--focus` | `action-secondary-hover` |
473
+ | `secondary-actions--pressed` | `action-secondary-pressed` |
474
+ | `secondary-actions-bg--focus` | `action-secondary-subtle-hover` |
475
+ | `secondary-actions-bg--pressed` | `action-secondary-subtle-pressed` |
476
+ | `destructive` | `action-danger` (fills); `content-danger` (text) |
477
+ | `destructive-actions` | `action-danger` (fills); `content-danger` (text) |
478
+ | `destructive-actions--focus` | `action-danger-hover` |
479
+ | `destructive-actions--pressed` | `action-danger-pressed` |
480
+ | `destructive-actions-bg--focus` | `action-danger-subtle-hover` |
481
+ | `destructive-actions-bg--pressed` | `action-danger-subtle-pressed` |
482
+ | `error` | `action-danger` (fills); `content-danger` (text) |
483
+ | `error-actions` | `action-danger` (fills); `content-danger` (text) |
484
+ | `error-actions--focus` | `action-danger-hover` |
485
+ | `error-actions--pressed` | `action-danger-pressed` |
486
+ | `error-actions-bg--focus` | `action-danger-subtle-hover` |
487
+ | `error-actions-bg--pressed` | `action-danger-subtle-pressed` |
488
+ | `success` | `action-success` (fills); `content-success` (text) |
489
+ | `success-actions` | `action-success` (fills); `content-success` (text) |
490
+ | `success-actions--focus` | `action-success-hover` |
491
+ | `success-actions--pressed` | `action-success-pressed` |
492
+ | `success-actions-bg--focus` | `action-success-subtle-hover` |
493
+ | `success-actions-bg--pressed` | `action-success-subtle-pressed` |
494
+ | `warning` | `action-warning` (fills); `content-warning` (text) |
495
+ | `warning-actions` | `action-warning` (fills); `content-warning` (text) |
496
+ | `warning-actions--focus` | `action-warning-hover` |
497
+ | `warning-actions--pressed` | `action-warning-pressed` |
498
+ | `warning-actions-bg--focus` | `action-warning-subtle-hover` |
499
+ | `warning-actions-bg--pressed` | `action-warning-subtle-pressed` |
500
+ | `active-elements` | `action-primary` |
501
+ | `active-elements--focus` | `action-primary-hover` |
502
+ | `active-elements--pressed` | `action-primary-pressed` |
503
+ | `active-elements-bg--focus` | `action-primary-subtle-hover` |
504
+ | `active-elements-bg--pressed` | `action-primary-subtle-pressed` |
505
+ | `inactive-elements--focus` | no class |
506
+ | `inactive-elements--pressed` | no class |
507
+ | `inactive-elements-bg--focus` | no class; disabled fields use `bg-inset` |
508
+ | `inactive-elements-bg--pressed` | no class |
509
+
510
+ ### Theme keys
511
+
512
+ A `customJson` or `remote` theme passes the 4.x keys ([Theming specification](#theming-specification)). Where several 3.x keys become one 4.x key, the theme sets it once. When those keys had different values, this is a choice of one colour for all of them, made by whoever owns the theme, not a rename: `default-text`, `primary-text` and `heading-text` are one `vc-content-primary`, `primary` and `primary-alternative` one `vc-action-primary`. An application can also leave its own theme for a built-in one (`type: 'local'`). A 4.x theme sets only base colours: the hover, pressed and tinted states are mixed by the library. A key the theme leaves out takes the default theme's value, as the Theming specification describes.
513
+
514
+ Keys with no 3.x key of their own: `vc-bg-inset`, `vc-ring`, `vc-onfill-warning`, the anchors of single fills `vc-mix-anchor-{fill}` (the built-in themes set `vc-mix-anchor-primary` and `vc-mix-anchor-warning`; set them as `actions-mix-color` was set), `vc-action-info` and `vc-content-info`.
515
+
516
+ A remote branding section gets the `vc-*` keys before the application is upgraded: a 3.x application ignores them, and a 4.x application ignores the 3.x keys, so every key it does not receive takes the default theme's value.
517
+
518
+ | 3.x theme key | 4.x theme key |
519
+ | --- | --- |
520
+ | `main-bg` | `vc-bg-page` |
521
+ | `light-bg` | `vc-bg-surface` |
522
+ | `card-bg-color` | `vc-bg-surface` |
523
+ | `dark-bg` | `vc-bg-inset-strong` |
524
+ | `field-bg` | `vc-bg-field` |
525
+ | `overlay-bg` | `vc-bg-overlay`: it carries its own transparency (3.x components mixed `--overlay-bg` to 40%, so a 3.x value `X` becomes `color-mix(in srgb, X 40%, transparent)`) |
526
+ | `skeleton-loader` | `vc-bg-muted` |
527
+ | `skeleton-loader-animation` | none: mixed from `vc-bg-surface` |
528
+ | `scrollbar-track` | `vc-bg-surface` |
529
+ | `default-text` | `vc-content-primary` |
530
+ | `primary-text` | `vc-content-primary` |
531
+ | `heading-text` | `vc-content-primary` |
532
+ | `headers` | `vc-content-primary` |
533
+ | `icons` | `vc-content-primary` |
534
+ | `table-headings` | `vc-content-primary` |
535
+ | `secondary-text` | `vc-content-secondary` |
536
+ | `placeholders` | `vc-content-tertiary` |
537
+ | `inactive-text` | `vc-content-disabled` |
538
+ | `inactive-elements` | `vc-content-disabled` |
539
+ | `scrollbar-thumb-hover` | `vc-content-disabled` |
540
+ | `btn-filled-text` | `vc-onfill-primary` (text on the primary fill); `vc-onfill` for the other fills |
541
+ | `default-loader` | `vc-onfill-primary` |
542
+ | `ui-lines` | `vc-border` |
543
+ | `scrollbar-thumb` | `vc-border` |
544
+ | `major-ui-lines` | `vc-border-strong` |
545
+ | `progress-line-not-done` | `vc-border` |
546
+ | `field-borders` | `vc-input` |
547
+ | `card-shadow-color` | `vc-shadow-color`: a dark base colour the library mixes down (12% for cards here); the 3.x light-grey value is not reused |
548
+ | `table-shadow-color` | `vc-shadow-color`: a dark base colour the library mixes down (7% for tables here); the 3.x light-grey value is not reused |
549
+ | `actions-mix-color` | `vc-mix-anchor`, and `vc-mix-anchor-{fill}` for a fill with its own anchor (the built-in themes set `vc-mix-anchor-primary` and `vc-mix-anchor-warning`) |
550
+ | `primary` | `vc-action-primary` |
551
+ | `primary-alternative` | `vc-action-primary` |
552
+ | `active-elements` | `vc-action-primary` |
553
+ | `secondary` | `vc-action-secondary` |
554
+ | `destructive` | `vc-action-danger` (fills); `vc-content-danger` (text) |
555
+ | `error` | `vc-action-danger` (fills); `vc-content-danger` (text) |
556
+ | `success` | `vc-action-success` (fills); `vc-content-success` (text) |
557
+ | `progress-line-done` | `vc-action-success` |
558
+ | `warning` | `vc-action-warning` (fills); `vc-content-warning` (text and icons) |
559
+ | `transparent` | none: not a theme key |
560
+ | `current` | none: not a theme key |
561
+ | `white` | none: not a theme key |
562
+ | `black` | none: not a theme key |
563
+
564
+ ### Finding the 3.x names
565
+
566
+ A 3.x name in `@apply` or in `theme('colors.…')` fails the Tailwind build. In a template class or in `var(--…)` it fails silently: the class is not generated and the variable is not set. This finds them in an application (any hit is a 3.x name; the 4.x names do not match):
567
+
568
+ ```bash
569
+ n='(main|light|dark|field|overlay)-bg|card-bg-color|skeleton-loader(-animation)?|scrollbar-(track|thumb(-hover)?)|(primary|heading|default|secondary|inactive|btn-filled)-text|headers|icons|table-headings|placeholders|default-loader|(major-)?ui-lines|field-borders|progress-line-(not-)?done|(card|table)-shadow-color|actions-mix-color|(primary(-alternative)?|secondary|destructive|error|success|warning)(-actions)?|(active|inactive)-elements'
570
+ s='(-bg)?(--(focus|pressed))?'
571
+ grep -rnE "(var\(|['\"])--($n)$s[,)'\"]|(^|[^a-zA-Z0-9_-])(text|bg|border(-[xytrblse])?|ring(-offset)?|fill|stroke|divide|outline|placeholder|shadow|from|via|to|caret|accent|decoration)-($n)$s([^a-zA-Z0-9_-]|$)" src index.html tailwind.config.*
572
+ ```
573
+
574
+ Add every other folder of the application with templates or styles. The Tailwind configuration counts too: a 3.x variable in its `boxShadow` or `colors` draws nothing, with no error.
575
+
576
+ Colour prop values that name a Tailwind colour (`VcCollapseItem` `color-icon` and `color-border`, `VcLoading` `color`) do not match this pattern; check them separately.
577
+
578
+ The theme keys of a `customJson` configuration (`colors.json`) and of a remote branding section move to the `vc-*` keys of the table above. An application with `type: 'none'` sets the 4.x variables itself. `onSetupCallback(theme)` receives the theme with its `vc-*` keys.
579
+
580
+ ### Icons
581
+
582
+ The components draw Lucide icons (`@lucide/vue`) where 3.x drew the `vc-icon-*` font, and the default icon of an icon prop is a Lucide component. A style that targets a `vc-icon-*` class inside a component no longer matches. An icon prop still takes a `vc-icon-*` class, drawn by the icon font that `injectIconFont` loads.
583
+
584
+ ### Styles and component defaults
585
+
586
+ | What | 3.x | 4.x |
587
+ | --- | --- | --- |
588
+ | Close and maximize controls of VcModal, the close control of a notification, the copy control of VcCodeBlock | native buttons with the classes `vc-dialog-header-icon`, `vc-link`, `vc-dialog-header-maximize-icon`, `vc-dialog-header-close-icon` and `vc-toast-close-icon`; the copy control read `--code-block-muted` and `--code-block-selection` | a small secondary VcButtonIcon; those classes are gone (`vc-dialog-header-close`, `vc-dialog-header-maximize`, `vc-toast-icon-close` and `vc-code-block__copy` stay), and the copy control takes the colours of VcButtonIcon instead of `--code-block-muted` and `--code-block-selection` |
589
+ | `--base-border-radius` | set on `<html>` by the theme setup | removed; corners read the component radii `--vc-radius-*` (`--vc-radius-control` for controls) |
590
+ | The radius keys of the shipped `tailwind.config.js` | `xs`, `sm` (0.25rem), `md`, `lg`, `xl`, `xxl`, `tag`, `DEFAULT` (`rounded`) and `horizontal-tab-*` | the radius roles (see "Corners"), `none` and `full`. An application keeps Tailwind's own scale, and its `extend.borderRadius` from the shipped configuration adds the roles: `rounded-sm` is Tailwind's, and `rounded-xs`, `rounded-xxl` and `rounded-horizontal-tab-*` are not generated. A configuration that takes the whole shipped file instead of the keys "Tailwind" lists, such as `merge(require('@voicenter-team/voicenter-ui-plus/tailwind.config'), ownConfig)` with lodash `merge`, has only the roles, `none` and `full`. `borderRadius: require('tailwindcss/defaultTheme').borderRadius` in its own `theme` brings Tailwind's scale back beside the roles, since `merge` joins the two objects. With it `rounded-sm` is 0.125rem (3.x: 0.25rem; `rounded` is the 0.25rem one), and `rounded-2xl` and `rounded-3xl` are generated, which 3.x did not generate. An application with a `theme.borderRadius` of its own (a copy of the 3.x scale) removes it, takes the roles through `extend.borderRadius` and moves its `rounded-*` classes to the roles ([Corners](#corners)) |
591
+ | The font keys of the shipped `tailwind.config.js` and the font classes of the library stylesheet | `main`, `rubik`, `inter` and `heebo`, all four Rubik | `main` only: `font-inter`, `font-heebo` and `font-rubik` are removed; replace them with `font-main`. `@apply font-inter` (or `font-heebo`, `font-rubik`) and `theme('fontFamily.inter')` fail the build. In a template the class is not generated, and text without it inherits whatever font its container sets, so the class is replaced rather than dropped |
592
+ | The component colours `primary-alternative` and `active`: the value of `color` and of any prop that takes a component colour (`prefixIconColor`, `tagColor`, `buttonColor`, `filledColor`, `confirmActionColor`, the `colorKey` of an option) | `primary-alternative` drew a colour of its own, `active` drew `active-elements` | removed: `componentColors` and `COMPONENT_COLOR_TYPE` no longer list them, and no class is generated for them. A project replaces every `primary-alternative` with `primary`, and every `active` given as a colour (`color="active"`, `prefix-icon-color="active"`) with `primary`: both draw the brand colour, and 4.x has no second accent colour. A style that targets their colour classes (`vc-button-color--primary-alternative`, `vc-input--active`, `vc-switch-color-active`, …) targets the `primary` class |
593
+ | The default `color` of VcInput, VcAutocomplete, VcPhoneInput, VcOtpInput, VcTimeInput, VcTagInput, VcSwitch and VcExtendedDatetimeRangePicker; `DEFAULT_COLOR` | `'active'` | `'primary'` |
594
+ | `shadow-hover-outer-active`, `shadow-hover-outer-primary-alternative` | the hover glow of the `active` and `primary-alternative` colours | removed; `shadow-hover-outer-primary` |
595
+ | `shadow-hover-outer-destructive` | the hover glow of the `destructive` colour | `shadow-hover-outer-danger`: a glow class is named by its fill, as `bg-action-danger` |
596
+ | The hover outline of VcCard with `hovered` | replaces the card shadow | fades in over the card shadow, which stays |
597
+ | The divider between VcViewSwitcher items | `secondary-actions` | `border` |
598
+ | `shadow-focus-outer`, `shadow-focus-outer-{primary,secondary,destructive,success,warning,info}`, `shadow-focus-{primary,secondary,destructive,success,warning}` | a focus glow in the colour the class names | removed; `shadow-focus`, the one focus ring, which has no colour of its own. A project whose Tailwind configuration defines these keys itself keeps them |
599
+ | `shadow-hover`, `shadow-hover-{primary,secondary,destructive,success,warning}` | a hover glow, outside and inside, in the colour the class names | removed: no component used them. `shadow-hover-inner`, `shadow-hover-outer`, `shadow-hover-outer-{colour}` and `shadow-hover-outer-off` stay. A project whose Tailwind configuration defines these keys itself keeps them |
600
+ | `tagBorderless` and `tagColor` of VcTagInput and VcTreeSelect | `false`, `'primary'` | `true`, `''`: a value is a borderless chip with no colour, neutral like a VcSelect multiple value (label and close icon `content-secondary`); set them for bordered, coloured tags. `tag-color="secondary"` draws the secondary colour, `action-secondary`, as on any other tag. A 3.x `tag-color` alone now gives a borderless chip in that colour; `:tag-borderless="false"` brings back the 3.x bordered tag |
601
+ | `DEFAULT_ICON_SIZE`, the default `prefixIconSize` of VcInput, VcAutocomplete, VcPhoneInput and VcExtendedDatetimeRangePicker | `'sm'` | `''`: no size class, so the prefix icon follows the size of the field and is larger at the default size; `prefix-icon-size="sm"` keeps the 3.x size |
602
+ | `iconClass` of VcSoundPlayerMarker | `'icon-md'` | `'icon-xs'`: the icon sits on a filled circle of the marker colour |
603
+ | `borderRadius` of VcMeterGroup | `'6px'` | `'var(--vc-radius-inner)'`, the inner radius role |
604
+ | `StatusProgressConfig`, the type of the `statusColorMap` prop of VcProgressCircular | `Record<string, string>` | `Partial<Record<StatusProgress, string>>`: its keys are the `StatusProgress` values, each optional, so an object literal with another key, or code that reads another key, fails the type check |
605
+ | `VcTagInputColor`, exported from the package root | `'active' \| 'primary' \| 'secondary' \| 'destructive'` | removed: no prop took it. The `color` of VcTagInput is `COMPONENT_COLOR_TYPE` and its `tagColor` is `VcTagColorType` |
606
+ | `TEXT_COLORS`, exported from the package root | the Tailwind text class of each component colour (`text-primary`, `text-secondary-actions`, …) | removed; `textColorClass(color)` returns the text class of a component colour, `vc-text-color--<colour>` from the library stylesheet, and `text-<key>` for a Tailwind colour key |
607
+ | The default slot of VcButton and the value of VcBadgeTag | direct children of `.vc-button--content` and of the badge | inside `span.vc-button__label` and `span.vc-badge-tag__value`, which trim the label box to its capitals so the control centres them; a selector that reaches the slot content as a direct child (`.vc-button--content > span`) no longer matches it |
608
+ | `font-normal`, `font-medium`, `font-semibold` | `400`, `500`, `600` | `380`, `480`, `600` (`--vc-font-weight-*`): the three weights of the components' text, in an application too once it takes `extend.fontWeight` (see "Tailwind") |
609
+ | Page text, `b` and `strong`, table headers (`th`) | `400`, `bolder`, the browser's bold | `font-normal`, `font-semibold`, `font-medium` |
610
+ | `font-bold`, `font-extrabold`, `font-black`; `font-thin`, `font-extralight`, `font-light` in an application | Tailwind's weights | unchanged; the 4.x text has the three weights above, so replace the first three with `font-semibold` and the other three with `font-normal` |
611
+ | The colour of an `info` or `warning` notification (`NotifyService`, `$notify`) | `info`: `primary-actions`, the brand colour; `warning`: `warning` | `content-info` and `content-warning`: a notification takes the text colour of the component colour of its type, as `success` takes `content-success` and `error` takes `content-danger` |
612
+ | The border and clear icon of VcTagInput with a `color` | a glow on hover; when focused, the border of the colour | no glow: for every colour, `info` included, the border warms toward the colour on hover and takes the colour's hover shade when focused; the clear icon is the colour's text colour and darkens from it on hover |
613
+ | `color` and `prefixIconColor` of VcTreeSelect | the field drew the same colour whatever its `color` (the colour class did not reach it); a `prefixIconColor` other than `active`, `primary` and `destructive` drew `active-elements` | the field takes its `color` as VcTagInput does: the border warms toward the colour on hover and takes the colour's hover shade while the tree is open; the prefix icon takes the text colour of its `prefixIconColor`, for every colour |
614
+ | The rings of the `circles` loader of VcLoading with a `color` other than `primary`, `secondary` and `destructive` | three rings of the one colour | the outer ring is the colour, the second and third its hover and pressed shades, as for `primary`, `secondary` and `destructive` |
615
+ | The text of an unchecked VcRadioButtonsGroup button on hover | `primary`: the brand colour itself; the other colours: the hover shade of the fill | the hover shade of the colour's text colour, `primary` included: `primary` darkens on hover (lightens in `black`) as the others do, and `success` and `warning` mix from their text colour, which in voicenter and voicenterRed is darker than the fill |
616
+ | The tick of a checked VcCheckbox, the text of a checked VcCheckboxButton and the text inside a VcProgress bar, for a fill other than `primary` | `btn-filled-text`, on every fill | the on-fill colour of that fill, as on a filled button: on the `warning` fill it is `onfill-warning`, dark in voicenter and voicenterRed |
617
+ | A status that the `statusColorMap` of VcProgressCircular leaves out, when the map has no `default` key | `primary-alternative-actions`, the library's default | the fill of that status |
618
+ | The text and underline of a `success` or `warning` VcHyperLink | the fill colour (`success-actions`, `warning-actions`) | the text colour, `content-success` or `content-warning`, for the text and the underline alike: every colour's underline is the colour of its text. In voicenter and voicenterRed these are darker than the fill |
619
+ | The clear icon of a VcInput or VcAutocomplete with a `color`, on hover | the hover shade of the fill | the hover shade of the colour's text colour, the colour the icon has at rest: unchanged for `primary`, `secondary`, `destructive` and `info`; for `success` and `warning` in voicenter and voicenterRed, whose text is darker than the fill, darker than before |
620
+ | Slot content of a VcRadio with a `color` that reads `active-elements` (4.x: `action-primary`) | the radio's colour: the radio redefined `--active-elements` | the brand colour: the radio sets its own `--vc-radio-color` and redefines no theme variable |
621
+ | Slot content of VcFileUploaderArea that reads `icons` (4.x: `content-primary`) | `secondary-text`: the area redefined `--icons` | `content-primary`: the area colours its own label, drop text and file names `content-secondary` and redefines no theme variable |
622
+
623
+ ### AI chat components
624
+
625
+ 4.x adds the components `VcAiReasoning`, `VcToolCall`, `VcApprovalCard`, `VcAskUserCard`, `VcAgentRunCard`, `VcAgentRunGroup`, `VcJsonViewer`, `VcLightbox` and `VcPdfViewer` (their peers are in [Installation](#installation)). `VcMessage`, `VcMessagesWrapper`, `VcChatComposer` and `VcFileItem` gained props, slots and events for AI chats; existing usages render as before. What can need a change in an application:
626
+
627
+ - **`@milkdown/*` must be `^7.22.0`** (was `^7.15.5`). With the `prosemirror-model` that npm resolves today (1.25.12), milkdown before 7.22.0 fails to parse lists (`RangeError: Expected value of type boolean for attribute spread`), and every list of a `VcMdEditor` disappears. A lockfile that still holds an older `prosemirror-model` hides the problem until the next fresh install.
628
+ - **`VcMdEditor` in `readonly` lays out its text by the text's own direction and treats it as untrusted.** Every paragraph, heading, list, quote, table and cell takes its direction from its own text instead of the page's (`<html dir>` at mount, or the direction button): English text in an RTL page now reads left to right, a Hebrew paragraph in an LTR page right to left, a block without letters follows the text around it, and code reads left to right. A link with a protocol other than http(s), mailto and tel loses its `href`, web links open in a new tab (`target="_blank" rel="noopener noreferrer"`), and the table handles are hidden. An editable editor is unchanged. New in `VcMdEditor`: `streaming` (throttled updates and a caret while an AI answer arrives) and `plain` (no field around the text, for bubbles and cards); `minHeight` takes the number `0` (it fell back to 400px, so callers passed the string `'0'`).
629
+ - **`VcMessagesWrapper` is generic** over the message type: extend `VcChatMessage` with your own fields and the slots and events keep your type. `InstanceType<typeof VcMessagesWrapper>` no longer type-checks for a template ref; use the exported interface:
630
+
631
+ ```diff
632
+ - const wrapper = ref<InstanceType<typeof VcMessagesWrapper>>()
633
+ + import type { VcMessagesWrapperExposed } from '@voicenter-team/voicenter-ui-plus'
634
+ + const wrapper = ref<VcMessagesWrapperExposed>()
635
+ ```
636
+
637
+ - **`VcChatMessage.createdAt` is optional.** A message without it starts no date divider and shows no time (AI SDK messages have no timestamp). Code that passes `message.createdAt` on to something that does not accept `undefined` needs a guard, or a message type of your own with a required `createdAt`.
638
+ - **`VcMessageContent` has a `markdown` block** (`{ type: 'markdown', text, streaming? }`). An exhaustive `switch` or a `Record<VcMessageContentType, …>` over the content types needs the new case.
639
+ - **`VcMessage`'s `content` also accepts an array** of blocks, rendered in order in one bubble. `VcChatMessage.content` stays a single block; several blocks in a wrapper go through its `message` slot.
640
+ - **`VcMessage` colours changed.** In 3.x own messages used `--dark-bg` / `--btn-filled-text`, a contrast of 1.13–1.42:1 in every light theme, and the quote of an incoming message used the same pair. In 4.x both sides are neutral, with `--vc-content-primary` text: others on `--vc-bg-surface`, own messages on `--vc-bg-muted`, and the quote takes the other side's background (`--vc-bg-muted` in others' messages, `--vc-bg-surface` in own). The variables keep their 3.x names (`--vc-message-bg`, `--vc-message-text`, `--vc-message-reply-bg`, `--vc-message-reply-text`): a project that sets them keeps working, with any 3.x theme variable in their values replaced by its 4.x token. Markdown links in bubbles take the text colour. A project that styled around the old dark own bubble (e.g. white icons in a custom `footer`) should check its contrast.
641
+ - **The `actions` slot of `VcChatComposer` (3.4.8) is `toolbar-start`**, with the slot props `{ disabled, streaming }`; `toolbar-end` (new) sits right before Send / Stop.
642
+ - **`VcMessagesWrapper`'s `scrollToMessage` takes options**, as in 3.4.8: `scrollToMessage(id, 'auto')` of 3.4.7 and earlier becomes `scrollToMessage(id, { behavior: 'auto' })`, and `block` and `offset` place the message. It scrolls only the wrapper, not the page, and the view stays on the message while the list grows below it.
643
+ - **Exported types**: `VcFileItemProps` (with the new `errorText`), `VcChatComposerEmits`, and props / emits / slot-props / exposed interfaces of every new component.
644
+ - **Localization**: the library ships only `en`. An application with another locale adds the keys new since 3.4.8 with `tVUManage.updateLocaleMessages`: `voicenterUi.jsonViewer.*`, `voicenterUi.aiChat.*`, `voicenterUi.lightbox.*`, `voicenterUi.aiReasoning.*`, `voicenterUi.toolCall.*`, `voicenterUi.approvalCard.*`, `voicenterUi.askUserCard.*`, `voicenterUi.agentRun.*`, `voicenterUi.agentRunGroup.*`, `voicenterUi.pdfViewer.*`, `voicenterUi.messagesWrapper.jumpToBottom`, `voicenterUi.message.download`, `voicenterUi.chatComposer.stop`, `voicenterUi.chatComposer.stopGenerating`, `voicenterUi.chatComposer.unsupportedFile`, `voicenterUi.fileItem.preview`, `voicenterUi.fileItem.remove` (English texts in `src/localization/locales/en.json`). An application on 3.4.7 or earlier also adds the keys of 3.4.8: `voicenterUi.message.video`, `voicenterUi.message.status.*`, `voicenterUi.messagesWrapper.newMessages`.
645
+
646
+ Fixes in the components 3.x had:
647
+
648
+ - **PDFs open without `eval` (CVE-2024-4367).** pdf.js before 4.2.67 compiles font glyphs with `eval`, so a crafted PDF could run JavaScript in the page. `VcPdfDocument` and `VcPdfViewer` now pass `isEvalSupported: false` to `getDocument` (no caller can turn it back on); pdf.js draws the glyphs through its slower interpreted path, the text looks the same. The lasting fix is `pdfjs-dist` 4.2.67 or newer, a separate upgrade of the peer (the library still declares `^2.16.105`).
649
+ - **Lists in `VcMdEditor`** render again with `@milkdown/*` `^7.22.0` (see above).
650
+ - **Code blocks in `VcMdEditor`** take the theme's colours. Copy is a secondary text action (`--vc-action-secondary` text and icon, the `--vc-action-secondary--subtle-hover` hover, a focus ring, visible while it has keyboard focus) instead of Crepe's grey pill without hover or focus states; the line numbers, fold markers, folded-code placeholder, cursor and selection use the theme variables instead of One Dark's colours. The syntax colours are unchanged. Read-only, a code block is framed (`--vc-border`, on `--vc-bg-surface` in `--vc-content-primary`) with no line numbers, active line or language button, Copy floats in its corner on hover or focus, a long line scrolls with a visible scrollbar, and inline code wraps instead of running past the column.
651
+
652
+ ## Using ui-plus in an application
653
+
654
+ How an application builds its UI with ui-plus. Agents working in a consuming project read this section before any UI work; it describes the version installed next to it.
655
+
656
+ ### Where the facts are
657
+
658
+ The installed package is the truth. Read it before saying what ui-plus has or how a component behaves.
659
+
660
+ - **Every component**: `library/types/components/exports.d.ts`. One component's props, events and slots: `library/types/components/<VcName>/<VcName>.vue.d.ts`.
661
+ - **Composables, services, directives, the entity base**: `library/types/composables/`, `library/types/services/`, `library/types/directives/`, `library/types/entity/`.
662
+ - **Types**: prop, event and configuration types are exported from the package root (`import type { UIConfig } from '@voicenter-team/voicenter-ui-plus'`). Generic components take type parameters in the template: `<VcSelect<User, 'id', 'name'> v-model="selected" :options="users" value-key="id" label-key="name" />`.
663
+ - **Colour tokens**: `src/theme/themes.json` (each key is the CSS variable `--<key>`) and `src/theme/tailwindScheme.js` (the Tailwind colour names).
664
+ - **Examples**: the [live documentation](https://voicenter-ui-plus.pages.dev/).
665
+
666
+ ### Choosing a component
667
+
668
+ - Interaction components come from ui-plus: buttons, inputs, selects, date pickers, checkboxes, tabs, tables, modals, drawers, tooltips, popovers, uploaders, notifications, confirmations. Search `exports.d.ts` by what the user is shown (a picker of people, an on/off switch, a list with a search) before concluding a component is missing.
669
+ - A component is used **as the library draws it**: through its props, slots and variants. Fitting it into the layout is free: width, spacing, wrapping, alignment.
670
+ - A **custom control** needs the project owner's explicit yes, asked before it is written: which element is needed, what was searched in ui-plus, why nothing fits. Custom means any of:
671
+ - a new interaction component;
672
+ - a ui-plus component whose own CSS variables (`--el-*`, the ones ui-plus sets on `.vc-*`) or internal classes are overridden to change how it looks or behaves as a control: its track, rows, selected, hover or active state, shape or indicator;
673
+ - a ui-plus component used for a role it is not built for, such as a segmented switcher drawn as a searchable list.
674
+ - Until that yes, the closest ui-plus component is used as drawn, and the difference from the design is the first open point of the report: what the design draws, which component was used, how they differ. No agent or orchestrator gives this approval in the owner's place.
675
+ - A report names a control by what is on screen: a restyled ui-plus component is reported as custom.
676
+ - A design hand-off (Figma, mock-up, screenshot, a specification) says what the user should see. It never justifies a restyle or a custom control.
677
+
678
+ ### Colours
679
+
680
+ - Every colour is a ui-plus token: a Tailwind class from the library scheme (`text-content-primary`, `text-content-secondary`, `text-action-primary`, `bg-page`, `bg-surface`, `border-border`, `text-content-success`, `text-content-danger`) or a theme variable in a style (`color: var(--vc-content-primary)`). Status colours, tags, icons and chart series included.
681
+ - Hex values, `rgb()`/`rgba()`, arbitrary classes such as `bg-[#…]` and new colour variables stay out of application code. Such colours already in a project are not a precedent.
682
+ - The theme configuration (`themeConfig`, usually a `colors.json`) sets the library theme. It is not a palette to add colours to.
683
+
684
+ ### Corners
685
+
686
+ - A corner takes the radius role of what it draws: `rounded-<role>`, a class of the shipped configuration ([Tailwind](#tailwind)), or `var(--vc-radius-<role>)` in a style:
687
+ - `rounded-control`: buttons, icon, toggle and split buttons, inputs, selects, pickers;
688
+ - `rounded-popup`: floating panels (popovers, dropdowns, select panels, tooltips, date-picker panels, notifications);
689
+ - `rounded-card`: cards, the outer frame of a table, modals;
690
+ - `rounded-tag`: tags and chips, drawn as a pill;
691
+ - `rounded-inner`: a part inside a control, popup or card (menu and list items, thumbnails and file icons, inline chips and labels, boxes inside editors and modals, checkbox boxes, colour-picker sliders, tree nodes, skeleton blocks, square tags).
692
+ - Besides the roles the shipped configuration has only `rounded-none` and `rounded-full` (a circle). A role takes Tailwind's side and corner prefixes like any radius: `rounded-t-card`, `rounded-s-control`.
693
+ - Pixel radii and arbitrary classes such as `rounded-[6px]` stay out of application code. Such radii already in a project are not a precedent.
694
+
695
+ ### Shadows
696
+
697
+ - A shadow is a class of the shipped configuration ([Tailwind](#tailwind)):
698
+ - elevation: `shadow-raised` for an element lifted on hover or drag and `shadow-overlay` for a floating panel, read from `--vc-shadow-raised` and `--vc-shadow-overlay`; `shadow-card` for a card;
699
+ - focus: `shadow-focus` draws the one focus ring `--vc-focus-ring`, the theme's `--vc-ring` colour at `--vc-focus-ring-width`, and `shadow-focus-inner` draws it inside.
700
+ - `shadow-vertical-tab-item-hover` is the raised elevation; `shadow-focus-outer-off` is not a focus ring and keeps its own glow.
701
+ - A hand-written `box-shadow` and arbitrary classes such as `shadow-[…]` stay out of application code. Such shadows already in a project are not a precedent.
702
+
703
+ ### Text
704
+
705
+ - Text keeps the library font, Rubik, which covers Latin and Hebrew: `font-main`, the one font key of the shipped configuration, set on `<html>`. The plugin (`app.use(VoicenterUI)`) loads it from Google Fonts. The tree-shake entry does not load it, the stylesheet only names it: `loadTextFont()` loads it ([Tree-shake mode](#tree-shake-mode-recommended)). An application's own Tailwind preflight sets another font on `<html>` ([Tailwind](#tailwind)).
706
+ - Text takes three weights, classes of the shipped configuration ([Tailwind](#tailwind)) read from `--vc-font-weight-*`: `font-normal` (the page text), `font-medium` (table headers, `th`) and `font-semibold` (`b` and `strong`). The other weight classes keep their Tailwind values.
707
+ - `transition-weight` is for text whose weight changes with its state.
708
+ - Other font families and the weights `font-bold` and heavier stay out of application code. Such fonts and weights already in a project are not a precedent.
709
+
710
+ ### Icons
711
+
712
+ - Icons are Lucide (`@lucide/vue`). An icon the application passes to a component or draws itself is a Lucide component imported by name: `import { Search } from '@lucide/vue'`, then `<VcButton :icon="Search">` or `<VcIcon :icon="Search" />`.
713
+ - The type of an icon prop is `TIcon`, exported from the package root.
714
+
715
+ ### Notifications and confirmations
716
+
717
+ `NotifyService`, `useConfirmModal` and `useConfirmPopup` render only through the hosts described in [Global overlays](#global-overlays), mounted once in the application. A `VcNotification` host shows only the messages of its own `group`, so where the application mounts one host per group, every notification names one of those groups.
718
+
719
+ ### Text direction
720
+
721
+ ui-plus follows the `dir` attribute of `<html>`: `useRTL()` reads it and updates when it changes. The application sets the direction there, once.
722
+
723
+ ### AI chat
724
+
725
+ An AI chat is built from the chat components; their props, events and slots are in the installed types, and the [live documentation](https://voicenter-ui-plus.pages.dev/) has an example of each.
726
+
727
+ - The conversation: `VcMessagesWrapper` (its `message` slot renders one AI message from several parts, `hideHeader`, `busy`, the jump-to-latest button) with `VcMessage` (`variant="plain"` for the assistant, several content blocks, the `footer` slot for model / tokens / copy).
728
+ - Assistant text: `VcMdEditor` with `readonly hide-toolbar plain`, and `streaming` while it streams (the renderer of the `markdown` block of `VcMessage`). Reasoning: `VcAiReasoning`. Tool calls: `VcToolCall`. Human approval of a tool: `VcApprovalCard`. Questions the agent asks the user: `VcAskUserCard`. Sub-agents: `VcAgentRunCard` / `VcAgentRunGroup`.
729
+ - Input: `VcChatComposer` with `streaming` (Stop instead of Send). Attachments open in `VcLightbox` (images) or `VcPdfViewer` (an inline PDF viewer for a tab or a panel).
730
+ - The library ships only English texts: an application in another language adds the keys of these components with `tVUManage.updateLocaleMessages` (the list is in [AI chat components](#ai-chat-components)).
731
+
732
+ ### Server-side rendering
733
+
734
+ ui-plus is built and tested for client-rendered Vue applications. Its composables read `document` and `window` when they are called (`useRTL` among them), and the package ships no Nuxt module. An application with server-side rendering proves one page that uses ui-plus in development and in a production build before relying on it, and reports what fails.
735
+
736
+ ### Troubleshooting
737
+
738
+ - **Component not found or a blank page**: in tree-shake mode a component is a local import, never a globally registered tag. In plugin mode both `app.use(VoicenterUI, …)` and `import '@voicenter-team/voicenter-ui-plus/style.css'` are present.
739
+ - **`Cannot find module 'pdfjs-dist'` (or another optional peer) at build time**: install the peer, or stop importing its component.
740
+ - **Duplicate styles, a huge CSS payload**: the two modes are mixed (named imports plus the global `style.css`). Pick one (`MIGRATION_v3.md`, §1).
741
+ - **`InstanceType<typeof VcMessagesWrapper>` does not type-check**: a generic component (`VcMessagesWrapper` since 4.0) has no constructor type. Type its template ref with the exported interface: `ref<VcMessagesWrapperExposed>()`. The other chat components with exposed methods export the same kind of interface (`VcChatComposerExposed`, `VcLightboxExposed`, `VcPdfViewerExposed`, …).
742
+ - **Lists missing from `VcMdEditor` or an AI answer** (`RangeError: Expected value of type boolean for attribute spread` in the console): `@milkdown/*` is older than 7.22.0. Install `^7.22.0` ([AI chat components](#ai-chat-components)).
743
+ - **PDF.js worker not loading, or Symbol / ZapfDingbats glyphs (✓, ✗, ★, Greek letters) drawn with another font or as boxes**: the worker and the standard font data of those two fonts are sibling assets resolved with `new URL('./pdf.worker.min.js', import.meta.url)` and `new URL('./standard_fonts/FoxitDingbats.pfb', import.meta.url)` (and `FoxitSymbol.pfb`); the bundler must support that pattern (Vite, webpack 5+, Rollup and esbuild do) and emits them as assets of the application.
744
+
745
+ ## Date Handling
746
+
747
+ This library uses **dayjs** for all date operations and formatting. When working with date-related components, use dayjs format tokens (NOT date-fns format tokens).
748
+
749
+ ### Format Tokens
750
+
751
+ **Important**: Use dayjs format tokens:
752
+ - `DD` - Day of month (2 digits) - **NOT** `dd`
753
+ - `YYYY` - 4-digit year - **NOT** `yyyy`
754
+ - `MM` - Month (2 digits)
755
+ - `HH` - 24-hour format
756
+ - `mm` - Minutes
757
+ - `ss` - Seconds
758
+
759
+ ### Common Formats
760
+
761
+ ```typescript
762
+ 'DD/MM/YYYY' // 31/12/2024
763
+ 'DD-MM-YYYY' // 31-12-2024
764
+ 'YYYY-MM-DD' // 2024-12-31
765
+ 'DD/MM/YYYY, HH:mm' // 31/12/2024, 14:30
766
+ 'DD/MM/YYYY HH:mm:ss' // 31/12/2024 14:30:45
767
+ ```
768
+
769
+ ### Usage Example
770
+
771
+ ```vue
772
+ <VcDatePicker
773
+ v-model="date"
774
+ format="DD/MM/YYYY"
775
+ input-date-format="DD/MM/YYYY"
776
+ input-time-format="HH:mm"
777
+ />
778
+ ```
779
+
780
+ ## Date Utility Functions
781
+
782
+ The library provides a comprehensive set of date utility functions built on dayjs. These utilities are available for use in external projects.
783
+
784
+ ### Import Date Utilities
785
+
786
+ ```typescript
787
+ import {
788
+ formatDate,
789
+ parseDate,
790
+ addDays,
791
+ subtractDays,
792
+ getHours,
793
+ getMinutes,
794
+ getSeconds,
795
+ setTime,
796
+ isAfter,
797
+ isSameAfter,
798
+ isBefore,
799
+ isSameBefore,
800
+ format,
801
+ add,
802
+ sub,
803
+ addFp,
804
+ subFp
805
+ } from '@voicenter-team/voicenter-ui-plus'
806
+ ```
807
+
808
+ ### Basic Date Operations
809
+
810
+ #### Formatting Dates
811
+
812
+ ```typescript
813
+ // Format a date with default format (YYYY-MM-DD)
814
+ const formatted = formatDate(new Date())
815
+ // Result: "2024-12-31"
816
+
817
+ // Format with custom format
818
+ const custom = formatDate(new Date(), 'DD/MM/YYYY')
819
+ // Result: "31/12/2024"
820
+
821
+ // Using format function (alias)
822
+ const formatted2 = format(new Date(), 'DD/MM/YYYY HH:mm')
823
+ // Result: "31/12/2024 14:30"
824
+ ```
825
+
826
+ #### Parsing Dates
827
+
828
+ ```typescript
829
+ // Parse a date string with format
830
+ const date = parseDate('31/12/2024', 'DD/MM/YYYY')
831
+ // Returns: Date object
832
+ ```
833
+
834
+ ### Date Arithmetic
835
+
836
+ #### Adding/Subtracting Days
837
+
838
+ ```typescript
839
+ // Add days
840
+ const futureDate = addDays(new Date(), 7)
841
+ // Returns: Date 7 days from now
842
+
843
+ // Subtract days
844
+ const pastDate = subtractDays(new Date(), 5)
845
+ // Returns: Date 5 days ago
846
+ ```
847
+
848
+ #### Adding/Subtracting Time Units
849
+
850
+ ```typescript
851
+ // Add multiple time units
852
+ const newDate = add(new Date(), {
853
+ years: 1,
854
+ months: 2,
855
+ days: 5,
856
+ hours: 3,
857
+ minutes: 30
858
+ })
859
+
860
+ // Subtract multiple time units
861
+ const earlierDate = sub(new Date(), {
862
+ weeks: 2,
863
+ days: 3,
864
+ hours: 12
865
+ })
866
+
867
+ // Functional programming style (reversed arguments)
868
+ const fpDate = addFp({ days: 7 }, new Date())
869
+ const fpDate2 = subFp({ hours: 5 }, new Date())
870
+ ```
871
+
872
+ ### Time Operations
873
+
874
+ #### Getting Time Components
875
+
876
+ ```typescript
877
+ const date = new Date('2024-12-31T14:30:45')
878
+
879
+ const hours = getHours(date) // 14
880
+ const minutes = getMinutes(date) // 30
881
+ const seconds = getSeconds(date) // 45
882
+ ```
883
+
884
+ #### Setting Time
885
+
886
+ ```typescript
887
+ // Set time on a date (returns new Date object)
888
+ const newDate = setTime(new Date(), {
889
+ hours: 14,
890
+ minutes: 30,
891
+ seconds: 0
892
+ })
893
+ ```
894
+
895
+ ### Date Comparisons
896
+
897
+ ```typescript
898
+ const date1 = new Date('2024-12-31')
899
+ const date2 = new Date('2025-01-01')
900
+
901
+ // Check if date1 is after date2
902
+ const isLater = isAfter(date1, date2, 'day')
903
+ // Returns: false
904
+
905
+ // Check if date1 is same or after date2
906
+ const isSameOrLater = isSameAfter(date1, date2, 'day')
907
+ // Returns: false
908
+
909
+ // Check if date1 is before date2
910
+ const isEarlier = isBefore(date1, date2, 'day')
911
+ // Returns: true
912
+
913
+ // Check if date1 is same or before date2
914
+ const isSameOrEarlier = isSameBefore(date1, date2, 'day')
915
+ // Returns: true
916
+ ```
917
+
918
+ **Comparison Units**: The comparison functions accept a `units` parameter (default: `'minute'`). Valid units:
919
+ - `'year'`, `'month'`, `'week'`, `'day'`
920
+ - `'hour'`, `'minute'`, `'second'`
921
+
922
+ ### Complete Usage Example
923
+
924
+ ```typescript
925
+ import {
926
+ formatDate,
927
+ addDays,
928
+ isAfter,
929
+ format,
930
+ add,
931
+ getHours,
932
+ setTime
933
+ } from '@voicenter-team/voicenter-ui-plus'
934
+
935
+ // Format today's date
936
+ const today = formatDate(new Date(), 'DD/MM/YYYY')
937
+
938
+ // Get date 30 days from now
939
+ const futureDate = addDays(new Date(), 30)
940
+
941
+ // Check if a date is in the future
942
+ const isFuture = isAfter(futureDate, new Date(), 'day')
943
+
944
+ // Add 2 weeks and 3 days
945
+ const deadline = add(new Date(), {
946
+ weeks: 2,
947
+ days: 3
948
+ })
949
+
950
+ // Get current hour
951
+ const currentHour = getHours(new Date())
952
+
953
+ // Set specific time
954
+ const meetingTime = setTime(new Date(), {
955
+ hours: 14,
956
+ minutes: 30
957
+ })
958
+
959
+ // Format the result
960
+ const formattedDeadline = format(deadline, 'DD/MM/YYYY HH:mm')
961
+ ```
962
+
963
+ ### Notes
964
+
965
+ - All functions accept `Date`, `string`, or `number` as date input
966
+ - All date manipulation functions return new `Date` objects (immutable)
967
+ - Format strings use dayjs format tokens (see Format Tokens section above)
968
+ - These utilities are built on dayjs and maintain compatibility with dayjs format patterns
969
+
970
+ ## Contributing: adding a new component
971
+
972
+ The public component surface is defined in **one place**: [`script/components-manifest.mjs`](./script/components-manifest.mjs) — one line per component.
973
+
974
+ ```js
975
+ { name: 'VcMyThing', path: 'components/VcMyThing/VcMyThing.vue' },
976
+ ```
977
+
978
+ `npm run generate:entries` materializes the manifest into three fully
979
+ generated files (never edit them by hand — the next generator run
980
+ overwrites them, and the verifier fails the build until they match):
981
+
982
+ - `src/components.gen.ts` — named exports, re-exported by `src/index.ts`
983
+ (tree-shake mode);
984
+ - `src/plugin-components.gen.ts` — `registerComponents(app)`, called by
985
+ the plugin's install (global registration mode);
986
+ - `src/components/exports.ts` — the `GlobalComponents` template typing.
987
+
988
+ `src/index.ts` and `src/plugin.ts` themselves stay hand-written and small.
989
+ The `.gen` modules are safe to route through only because
990
+ `rewriteCssImports()` in `vite.config.ts` strips the CSS imports that
991
+ `vite-plugin-lib-inject-css` aggregates onto them — each component's CSS
992
+ stays in its own chunk, so per-component CSS tree-shaking survives. Don't
993
+ rename the `.gen` files without updating that strip list (the verifier
994
+ guards this wiring too).
995
+
996
+ Typical flows:
997
+
998
+ - **New component**: `node script/create-component.mjs` — scaffolds the
999
+ component folder, adds the manifest line, and regenerates all entries.
1000
+ - **Existing .vue file**: add one line to the manifest, then
1001
+ `npm run generate:entries`.
1002
+
1003
+ Every manifest entry is exported from the package root AND registered
1004
+ globally in plugin mode — there are no partial modes.
1005
+
1006
+ `npm run verify:entries` is the safety net: it independently cross-checks
1007
+ the manifest, the three generated files and the filesystem (a component
1008
+ file that exists but is missing from the manifest fails too). It runs in
1009
+ the pre-commit hook (together with `lint-staged` and `ts-check`; hooks are
1010
+ installed automatically by `npm install` via husky) and in CI, so an
1011
+ inconsistent component surface cannot reach `master`.
1012
+
1013
+ ## Documentation
1014
+
1015
+ ### Live Documentation
1016
+ Visit [documentation](https://voicenter-ui-plus.pages.dev/) for interactive component examples and demos.
1017
+
1018
+ ## Project Documentation
1019
+ For detailed technical documentation, see the [`docs/`](./docs/) directory:
1020
+
1021
+ - **[Quick Start Guide](./docs/AGENTS_QUICK_START.md)** - For developers working on the library
1022
+ - **[Architecture Overview](./docs/ARCHITECTURE.md)** - Project structure and technical details
1023
+ - **[Documentation Guide](./docs/DOCUMENTATION_GUIDE.md)** - Working with the documentation system