@vc-shell/framework 1.1.74 → 1.1.76
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.
- package/CHANGELOG.md +13 -0
- package/dist/framework.js +4682 -4500
- package/dist/index.css +1 -1
- package/dist/shared/components/app-switcher/components/vc-app-switcher/vc-app-switcher.vue.d.ts.map +1 -1
- package/dist/shared/components/blade-navigation/components/vc-blade-navigation/_internal/vc-mobile-back-button.vue.d.ts.map +1 -1
- package/dist/shared/components/blade-navigation/components/vc-blade-navigation/vc-blade-navigation.vue.d.ts.map +1 -1
- package/dist/shared/components/change-password/change-password.vue.d.ts.map +1 -1
- package/dist/shared/components/change-password-button/change-password-button.vue.d.ts.map +1 -1
- package/dist/shared/components/common/popup/vc-popup-error.vue.d.ts.map +1 -1
- package/dist/shared/components/common/popup/vc-popup-info.vue.d.ts.map +1 -1
- package/dist/shared/components/common/popup/vc-popup-warning.vue.d.ts.map +1 -1
- package/dist/shared/components/dashboard-widget-card/dashboard-widget-card.vue.d.ts.map +1 -1
- package/dist/shared/components/draggable-dashboard/DraggableDashboard.vue.d.ts.map +1 -1
- package/dist/shared/components/draggable-dashboard/_internal/DashboardWidget.vue.d.ts.map +1 -1
- package/dist/shared/components/generic-dropdown/generic-dropdown.vue.d.ts +2 -2
- package/dist/shared/components/generic-dropdown/generic-dropdown.vue.d.ts.map +1 -1
- package/dist/shared/components/language-selector/language-selector.vue.d.ts.map +1 -1
- package/dist/shared/components/logout-button/logout-button.vue.d.ts.map +1 -1
- package/dist/shared/components/multilanguage-selector/multilanguage-selector.vue.d.ts.map +1 -1
- package/dist/shared/components/notification-dropdown/_internal/notification/notification.vue.d.ts.map +1 -1
- package/dist/shared/components/notification-dropdown/notification-dropdown.vue.d.ts.map +1 -1
- package/dist/shared/components/notification-template/notification-template.vue.d.ts.map +1 -1
- package/dist/shared/components/popup-handler/components/vc-popup-container/vc-popup-container.vue.d.ts.map +1 -1
- package/dist/shared/components/settings-menu/settings-menu.vue.d.ts.map +1 -1
- package/dist/shared/components/settings-menu-item/settings-menu-item.vue.d.ts.map +1 -1
- package/dist/shared/components/sidebar/sidebar.vue.d.ts.map +1 -1
- package/dist/shared/components/sign-in/external-provider.vue.d.ts.map +1 -1
- package/dist/shared/components/sign-in/external-providers.vue.d.ts.map +1 -1
- package/dist/shared/components/theme-selector/theme-selector.vue.d.ts.map +1 -1
- package/dist/shared/components/user-dropdown-button/_internal/user-info.vue.d.ts.map +1 -1
- package/dist/shared/components/user-dropdown-button/_internal/user-sidebar.vue.d.ts.map +1 -1
- package/dist/shared/components/user-dropdown-button/user-dropdown-button.vue.d.ts.map +1 -1
- package/dist/shared/composables/useMenuExpanded.d.ts +1 -1
- package/dist/shared/modules/assets/components/assets-details/assets-details.vue.d.ts.map +1 -1
- package/dist/shared/modules/assets-manager/components/assets-manager/assets-manager.vue.d.ts.map +1 -1
- package/dist/shared/modules/dynamic/pages/dynamic-blade-form.vue.d.ts.map +1 -1
- package/dist/shared/modules/dynamic/pages/dynamic-blade-list.vue.d.ts.map +1 -1
- package/dist/shared/pages/ChangePasswordPage/components/change-password/ChangePassword.vue.d.ts.map +1 -1
- package/dist/shared/pages/InvitePage/components/invite/Invite.vue.d.ts.map +1 -1
- package/dist/shared/pages/LoginPage/components/login/Login.vue.d.ts.map +1 -1
- package/dist/shared/pages/ResetPasswordPage/components/reset-password/ResetPassword.vue.d.ts.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/ui/components/atoms/vc-badge/vc-badge.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-banner/vc-banner.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-button/vc-button.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-card/vc-card.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-col/vc-col.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-container/vc-container.vue.d.ts +2 -2
- package/dist/ui/components/atoms/vc-container/vc-container.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-hint/vc-hint.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-icon/icons/MenuBurgerIcon.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-icon/vc-bootstrap-icon.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-icon/vc-fontawesome-icon.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-icon/vc-icon-examples.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-icon/vc-icon-test.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-icon/vc-icon.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-icon/vc-lucide-icon.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-icon/vc-material-icon.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-icon/vc-svg-icon.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-image/vc-image.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-label/vc-label.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-link/vc-link.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-loading/vc-loading.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-progress/vc-progress.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-row/vc-row.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-skeleton/vc-skeleton.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-status/vc-status.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-status-icon/vc-status-icon.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-tooltip/vc-tooltip.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-video/vc-video.vue.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-widget/vc-widget.vue.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-breadcrumbs/_internal/vc-breadcrumbs-item/vc-breadcrumbs-item.vue.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-breadcrumbs/vc-breadcrumbs.vue.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-checkbox/vc-checkbox.vue.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-editor/_internal/extensions/font-size.d.ts +12 -0
- package/dist/ui/components/molecules/vc-editor/_internal/extensions/font-size.d.ts.map +1 -0
- package/dist/ui/components/molecules/vc-editor/_internal/toolbar-types.d.ts +49 -0
- package/dist/ui/components/molecules/vc-editor/_internal/toolbar-types.d.ts.map +1 -0
- package/dist/ui/components/molecules/vc-editor/_internal/vc-editor-button.vue.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-editor/_internal/vc-editor-custom-button.vue.d.ts +10 -0
- package/dist/ui/components/molecules/vc-editor/_internal/vc-editor-custom-button.vue.d.ts.map +1 -0
- package/dist/ui/components/molecules/vc-editor/_internal/vc-editor-font-selector.vue.d.ts +8 -0
- package/dist/ui/components/molecules/vc-editor/_internal/vc-editor-font-selector.vue.d.ts.map +1 -0
- package/dist/ui/components/molecules/vc-editor/_internal/vc-editor-toolbar.vue.d.ts +4 -1
- package/dist/ui/components/molecules/vc-editor/_internal/vc-editor-toolbar.vue.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-editor/index.d.ts +1 -0
- package/dist/ui/components/molecules/vc-editor/index.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-editor/vc-editor.vue.d.ts +7 -3
- package/dist/ui/components/molecules/vc-editor/vc-editor.vue.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-field/_internal/vc-field-type/vc-field-type.vue.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-field/vc-field.vue.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-file-upload/vc-file-upload.vue.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-form/vc-form.vue.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-input/vc-input.vue.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-input-currency/vc-input-currency.vue.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-input-dropdown/vc-input-dropdown.vue.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-multivalue/vc-multivalue.vue.d.ts +2 -2
- package/dist/ui/components/molecules/vc-multivalue/vc-multivalue.vue.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-pagination/vc-pagination.vue.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-radio-button/vc-radio-button.vue.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-rating/vc-rating.vue.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-select/vc-select.vue.d.ts +2 -2
- package/dist/ui/components/molecules/vc-select/vc-select.vue.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-slider/vc-slider.vue.d.ts +7 -8
- package/dist/ui/components/molecules/vc-slider/vc-slider.vue.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-switch/vc-switch.vue.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-textarea/vc-textarea.vue.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-toast/vc-toast.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-app/_internal/vc-app-bar/_internal/AppBarContent.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-app/_internal/vc-app-bar/_internal/AppBarHeader.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-app/_internal/vc-app-bar/_internal/AppBarMobileActions.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-app/_internal/vc-app-bar/_internal/AppBarOverlay.vue.d.ts +2 -2
- package/dist/ui/components/organisms/vc-app/_internal/vc-app-bar/_internal/AppBarOverlay.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-app/_internal/vc-app-bar/_internal/AppBarSlots.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-app/_internal/vc-app-bar/_internal/AppBarWidgetItem.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-app/_internal/vc-app-bar/_internal/AppBarWidgetsMenu.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-app/_internal/vc-app-bar/_internal/MenuSidebar.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-app/_internal/vc-app-bar/vc-app-bar.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-app/_internal/vc-app-menu/_internal/vc-app-menu-item/_internal/vc-app-menu-link.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-app/_internal/vc-app-menu/_internal/vc-app-menu-item/vc-app-menu-item.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-app/_internal/vc-app-menu/vc-app-menu.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-app/vc-app.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-blade/_internal/vc-blade-header/vc-blade-header.vue.d.ts +2 -2
- package/dist/ui/components/organisms/vc-blade/_internal/vc-blade-header/vc-blade-header.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-blade/_internal/vc-blade-toolbar/_internal/vc-blade-toolbar-buttons/_internal/vc-blade-toolbar-button/vc-blade-toolbar-base-button.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-blade/_internal/vc-blade-toolbar/_internal/vc-blade-toolbar-buttons/_internal/vc-blade-toolbar-button/vc-blade-toolbar-button.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-blade/_internal/vc-blade-toolbar/_internal/vc-blade-toolbar-buttons/_internal/vc-blade-toolbar-button/vc-blade-toolbar-circle-button.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-blade/_internal/vc-blade-toolbar/_internal/vc-blade-toolbar-buttons/desktop/vc-blade-toolbar-desktop.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-blade/_internal/vc-blade-toolbar/_internal/vc-blade-toolbar-buttons/mobile/vc-blade-toolbar-mobile.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-blade/_internal/vc-blade-toolbar/_internal/vc-blade-toolbar-buttons/vc-blade-toolbar-buttons.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-blade/_internal/vc-blade-toolbar/vc-blade-toolbar.vue.d.ts +2 -2
- package/dist/ui/components/organisms/vc-blade/_internal/vc-blade-toolbar/vc-blade-toolbar.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-blade/_internal/vc-blade-widget-container/_internal/vc-widget-container-desktop.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-blade/_internal/vc-blade-widget-container/_internal/vc-widget-container-mobile.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-blade/_internal/vc-blade-widget-container/vc-widget-container.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-blade/vc-blade.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-dynamic-property/vc-dynamic-property.vue.d.ts +2 -2
- package/dist/ui/components/organisms/vc-dynamic-property/vc-dynamic-property.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-gallery/_internal/vc-gallery-item/vc-gallery-item.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-gallery/_internal/vc-gallery-preview/vc-gallery-preview.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-gallery/vc-gallery.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-login-form/vc-login-form.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-popup/vc-popup.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-table/_internal/vc-table-add-new/vc-table-add-new.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-table/_internal/vc-table-base-header/vc-table-base-header.vue.d.ts +2 -2
- package/dist/ui/components/organisms/vc-table/_internal/vc-table-base-header/vc-table-base-header.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-table/_internal/vc-table-cell/vc-table-cell.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-table/_internal/vc-table-column-switcher/vc-table-column-switcher.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-table/_internal/vc-table-counter/vc-table-counter.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-table/_internal/vc-table-desktop-view/_internal/vc-table-body/vc-table-body.vue.d.ts +25 -3
- package/dist/ui/components/organisms/vc-table/_internal/vc-table-desktop-view/_internal/vc-table-body/vc-table-body.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-table/_internal/vc-table-desktop-view/_internal/vc-table-columns-header/vc-table-columns-header.vue.d.ts +2 -2
- package/dist/ui/components/organisms/vc-table/_internal/vc-table-desktop-view/_internal/vc-table-columns-header/vc-table-columns-header.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-table/_internal/vc-table-desktop-view/_internal/vc-table-row/vc-table-row.vue.d.ts +25 -3
- package/dist/ui/components/organisms/vc-table/_internal/vc-table-desktop-view/_internal/vc-table-row/vc-table-row.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-table/_internal/vc-table-desktop-view/_internal/vc-table-select-all-header/vc-table-select-all-header.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-table/_internal/vc-table-desktop-view/vc-table-desktop-view.vue.d.ts +31 -3
- package/dist/ui/components/organisms/vc-table/_internal/vc-table-desktop-view/vc-table-desktop-view.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-table/_internal/vc-table-empty/vc-table-empty.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-table/_internal/vc-table-filter/vc-table-filter.vue.d.ts +2 -2
- package/dist/ui/components/organisms/vc-table/_internal/vc-table-filter/vc-table-filter.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-table/_internal/vc-table-footer/vc-table-footer.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-table/_internal/vc-table-header/vc-table-header.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-table/_internal/vc-table-mobile-item/vc-table-mobile-item.vue.d.ts +2 -2
- package/dist/ui/components/organisms/vc-table/_internal/vc-table-mobile-item/vc-table-mobile-item.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-table/_internal/vc-table-mobile-view/vc-table-mobile-view.vue.d.ts +2 -2
- package/dist/ui/components/organisms/vc-table/_internal/vc-table-mobile-view/vc-table-mobile-view.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-table/_internal/vc-table-select-all/vc-table-select-all.vue.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-table/vc-table.vue.d.ts +28 -3
- package/dist/ui/components/organisms/vc-table/vc-table.vue.d.ts.map +1 -1
- package/dist/vendor-floating-ui-vue-C1Zscv9o.js +836 -0
- package/dist/{vendor-linkifyjs-DTu7SY_Y.js → vendor-linkifyjs-dCH9UYes.js} +183 -187
- package/dist/{vendor-prosemirror-commands-B8fhFbTo.js → vendor-prosemirror-commands-DKHyfRYE.js} +26 -26
- package/dist/{vendor-prosemirror-dropcursor-CdHQ9kQG.js → vendor-prosemirror-dropcursor-Dro-INCI.js} +2 -2
- package/dist/{vendor-prosemirror-gapcursor-W-ky5QTm.js → vendor-prosemirror-gapcursor-BgyglWtH.js} +3 -3
- package/dist/{vendor-prosemirror-history-CrtTR5Cd.js → vendor-prosemirror-history-B4ei16kP.js} +2 -2
- package/dist/{vendor-prosemirror-keymap-DWvoDWf6.js → vendor-prosemirror-keymap-21y6bXc_.js} +1 -1
- package/dist/{vendor-prosemirror-schema-list-Ds6x_KLX.js → vendor-prosemirror-schema-list-Dmi4oPas.js} +11 -11
- package/dist/{vendor-prosemirror-state-CRUasa1V.js → vendor-prosemirror-state-6jGEPgrP.js} +1 -1
- package/dist/{vendor-prosemirror-tables-DzTfCeHX.js → vendor-prosemirror-tables-U7ypaxJu.js} +4 -4
- package/dist/{vendor-prosemirror-transform-BeDaI3CS.js → vendor-prosemirror-transform-Dk6c_eg4.js} +5 -4
- package/dist/vendor-prosemirror-view-Bfe9EVLy.js +1489 -0
- package/dist/vendor-swiper-1bp0oJwt.js +3387 -0
- package/dist/vendor-tiptap-core-CtNT-ozM.js +3096 -0
- package/dist/{vendor-tiptap-extension-blockquote-iAIM-meW.js → vendor-tiptap-extension-blockquote-25QerT8O.js} +6 -8
- package/dist/{vendor-tiptap-extension-bold-bkOLNH6E.js → vendor-tiptap-extension-bold-B-B75KIy.js} +10 -10
- package/dist/{vendor-tiptap-extension-code-CgIql8q6.js → vendor-tiptap-extension-code-CEZA5x7I.js} +8 -10
- package/dist/vendor-tiptap-extension-code-block-BFDiCj59.js +192 -0
- package/dist/vendor-tiptap-extension-document-C8JdW_kC.js +9 -0
- package/dist/{vendor-tiptap-extension-hard-break-DygHhzqw.js → vendor-tiptap-extension-hard-break-D9Nzegu6.js} +4 -6
- package/dist/{vendor-tiptap-extension-heading-C-ArDc3_.js → vendor-tiptap-extension-heading-TmkrHpE2.js} +9 -6
- package/dist/vendor-tiptap-extension-horizontal-rule-BC1YMUau.js +53 -0
- package/dist/{vendor-tiptap-extension-image-DChcWb4v.js → vendor-tiptap-extension-image-BQnBpg7z.js} +9 -3
- package/dist/{vendor-tiptap-extension-italic-BNJrFvrR.js → vendor-tiptap-extension-italic-mSCwLnXY.js} +4 -4
- package/dist/vendor-tiptap-extension-link-CQ0Mw6gd.js +287 -0
- package/dist/vendor-tiptap-extension-list-BwidYizT.js +420 -0
- package/dist/{vendor-tiptap-extension-paragraph-DZfkaJJ-.js → vendor-tiptap-extension-paragraph-C_OQHUNe.js} +3 -5
- package/dist/vendor-tiptap-extension-placeholder-BIojfRhh.js +1 -0
- package/dist/{vendor-tiptap-extension-strike-BlGNozxy.js → vendor-tiptap-extension-strike-Bfc-eud8.js} +3 -3
- package/dist/vendor-tiptap-extension-table-D26aUVrb.js +302 -0
- package/dist/vendor-tiptap-extension-table-cell-DuWy52BP.js +1 -0
- package/dist/vendor-tiptap-extension-table-header-DuWy52BP.js +1 -0
- package/dist/vendor-tiptap-extension-table-row-DuWy52BP.js +1 -0
- package/dist/vendor-tiptap-extension-text-DrXC1h34.js +8 -0
- package/dist/vendor-tiptap-extension-text-style-vv6u__7g.js +230 -0
- package/dist/{vendor-tiptap-extension-underline-CIVtuRLl.js → vendor-tiptap-extension-underline-BfygI164.js} +2 -2
- package/dist/vendor-tiptap-extensions-_4zopegS.js +289 -0
- package/dist/{vendor-tiptap-markdown-CidDIpZ-.js → vendor-tiptap-markdown-pGf8MOss.js} +26 -26
- package/dist/vendor-tiptap-pm-B2DY8bDS.js +7681 -0
- package/dist/vendor-tiptap-starter-kit-DPG4_B0q.js +28 -0
- package/dist/vendor-tiptap-vue-3-Ctgrxv1U.js +157 -0
- package/dist/vendor-vueuse-components-CuLo31bP.js +219 -0
- package/dist/vendor-vueuse-core-A9T6NeUn.js +6880 -0
- package/dist/vendor-vueuse-shared-B2Uva3Md.js +35 -0
- package/package.json +33 -27
- package/ui/components/molecules/vc-editor/_internal/extensions/font-size.ts +59 -0
- package/ui/components/molecules/vc-editor/_internal/toolbar-types.ts +57 -0
- package/ui/components/molecules/vc-editor/_internal/vc-editor-custom-button.vue +79 -0
- package/ui/components/molecules/vc-editor/_internal/vc-editor-font-selector.vue +215 -0
- package/ui/components/molecules/vc-editor/_internal/vc-editor-toolbar.vue +42 -0
- package/ui/components/molecules/vc-editor/index.ts +5 -0
- package/ui/components/molecules/vc-editor/vc-editor.stories.ts +172 -3
- package/ui/components/molecules/vc-editor/vc-editor.vue +49 -26
- package/ui/components/molecules/vc-slider/vc-slider.vue +8 -8
- package/dist/vendor-dom7-wvIUV9pT.js +0 -529
- package/dist/vendor-floating-ui-core-3dy7r5mx.js +0 -349
- package/dist/vendor-floating-ui-dom-DCjH_QK4.js +0 -393
- package/dist/vendor-floating-ui-vue-BUBCqiRN.js +0 -107
- package/dist/vendor-popperjs-core-LGjf7Wza.js +0 -905
- package/dist/vendor-prosemirror-view-BGYdOWiJ.js +0 -3748
- package/dist/vendor-ssr-window-D4k3p53c.js +0 -133
- package/dist/vendor-swiper-DrZzJvo8.js +0 -2825
- package/dist/vendor-tippy-js-nNhcw_JH.js +0 -812
- package/dist/vendor-tiptap-core-dlTW4S11.js +0 -2817
- package/dist/vendor-tiptap-extension-bubble-menu-BRWVLpun.js +0 -128
- package/dist/vendor-tiptap-extension-bullet-list-DfU428XB.js +0 -53
- package/dist/vendor-tiptap-extension-code-block-V26-erQk.js +0 -133
- package/dist/vendor-tiptap-extension-document-BYF_BzDD.js +0 -9
- package/dist/vendor-tiptap-extension-dropcursor-DqjaaFex.js +0 -20
- package/dist/vendor-tiptap-extension-floating-menu-vptdm_Y0.js +0 -99
- package/dist/vendor-tiptap-extension-gapcursor-DxLBw8V0.js +0 -24
- package/dist/vendor-tiptap-extension-history-C41RW3Bv.js +0 -35
- package/dist/vendor-tiptap-extension-horizontal-rule-BGMGd9fo.js +0 -58
- package/dist/vendor-tiptap-extension-link-DFN4ENph.js +0 -270
- package/dist/vendor-tiptap-extension-list-item-3qKYhGHe.js +0 -33
- package/dist/vendor-tiptap-extension-ordered-list-D3QL0eiW.js +0 -71
- package/dist/vendor-tiptap-extension-placeholder-CoOAmd0a.js +0 -52
- package/dist/vendor-tiptap-extension-table-CZn6Xykb.js +0 -213
- package/dist/vendor-tiptap-extension-table-cell-BQuS-XFD.js +0 -40
- package/dist/vendor-tiptap-extension-table-header-ZrtK7HiQ.js +0 -40
- package/dist/vendor-tiptap-extension-table-row-CBrXvqsO.js +0 -22
- package/dist/vendor-tiptap-extension-text-DwA7jrBq.js +0 -8
- package/dist/vendor-tiptap-pm-9TOy65Oe.js +0 -1
- package/dist/vendor-tiptap-starter-kit-BdU6UtqB.js +0 -29
- package/dist/vendor-tiptap-vue-3-CnYccgV4.js +0 -225
- package/dist/vendor-vueuse-components-B0zqjNRW.js +0 -542
- package/dist/vendor-vueuse-core-CYgwn-B2.js +0 -5130
- package/dist/vendor-vueuse-shared-B_uDJJ6V.js +0 -1169
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { unref as t, getCurrentScope as e, onScopeDispose as i, toRef as u, readonly as r, ref as s, customRef as a } from "vue";
|
|
2
|
+
function w(o) {
|
|
3
|
+
return e() ? (i(o), !0) : !1;
|
|
4
|
+
}
|
|
5
|
+
function g(o) {
|
|
6
|
+
return typeof o == "function" ? o() : t(o);
|
|
7
|
+
}
|
|
8
|
+
const c = typeof window < "u" && typeof document < "u";
|
|
9
|
+
typeof WorkerGlobalScope < "u" && globalThis instanceof WorkerGlobalScope;
|
|
10
|
+
const d = Object.prototype.toString, v = (o) => d.call(o) === "[object Object]", f = () => {
|
|
11
|
+
}, b = /* @__PURE__ */ l();
|
|
12
|
+
function l() {
|
|
13
|
+
var o, n;
|
|
14
|
+
return c && ((o = window?.navigator) == null ? void 0 : o.userAgent) && (/iP(?:ad|hone|od)/.test(window.navigator.userAgent) || ((n = window?.navigator) == null ? void 0 : n.maxTouchPoints) > 2 && /iPad|Macintosh/.test(window?.navigator.userAgent));
|
|
15
|
+
}
|
|
16
|
+
const m = {
|
|
17
|
+
mounted: "mounted",
|
|
18
|
+
unmounted: "unmounted"
|
|
19
|
+
};
|
|
20
|
+
function S(...o) {
|
|
21
|
+
if (o.length !== 1)
|
|
22
|
+
return u(...o);
|
|
23
|
+
const n = o[0];
|
|
24
|
+
return typeof n == "function" ? r(a(() => ({ get: n, set: f }))) : s(n);
|
|
25
|
+
}
|
|
26
|
+
export {
|
|
27
|
+
c as a,
|
|
28
|
+
v as b,
|
|
29
|
+
w as c,
|
|
30
|
+
m as d,
|
|
31
|
+
S as e,
|
|
32
|
+
b as i,
|
|
33
|
+
f as n,
|
|
34
|
+
g as t
|
|
35
|
+
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vc-shell/framework",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.76",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "./dist/framework.js",
|
|
6
6
|
"types": "./dist/index.d.ts",
|
|
@@ -39,29 +39,34 @@
|
|
|
39
39
|
"test:coverage": "vitest run --coverage"
|
|
40
40
|
},
|
|
41
41
|
"dependencies": {
|
|
42
|
+
"@floating-ui/dom": "^1.7.4",
|
|
42
43
|
"@floating-ui/vue": "^1.0.6",
|
|
43
44
|
"@fontsource/plus-jakarta-sans": "^5.1.0",
|
|
44
45
|
"@fortawesome/fontawesome-free": "^6.7.2",
|
|
45
46
|
"@headlessui/vue": "^1.7.19",
|
|
46
47
|
"@material-symbols/font-300": "^0.32.0",
|
|
47
48
|
"@microsoft/signalr": "^8.0.0",
|
|
48
|
-
"@tiptap/
|
|
49
|
-
"@tiptap/extension-
|
|
50
|
-
"@tiptap/extension-
|
|
51
|
-
"@tiptap/extension-
|
|
52
|
-
"@tiptap/extension-
|
|
53
|
-
"@tiptap/extension-table
|
|
54
|
-
"@tiptap/extension-table-
|
|
55
|
-
"@tiptap/extension-
|
|
56
|
-
"@tiptap/
|
|
57
|
-
"@tiptap/
|
|
58
|
-
"@tiptap/
|
|
49
|
+
"@tiptap/core": "^3.4.2",
|
|
50
|
+
"@tiptap/extension-font-size": "^3.0.0-next.3",
|
|
51
|
+
"@tiptap/extension-image": "^3.4.2",
|
|
52
|
+
"@tiptap/extension-link": "^3.4.2",
|
|
53
|
+
"@tiptap/extension-placeholder": "^3.4.2",
|
|
54
|
+
"@tiptap/extension-table": "^3.4.2",
|
|
55
|
+
"@tiptap/extension-table-cell": "^3.4.2",
|
|
56
|
+
"@tiptap/extension-table-header": "^3.4.2",
|
|
57
|
+
"@tiptap/extension-table-row": "^3.4.2",
|
|
58
|
+
"@tiptap/extension-text-style": "^3.4.2",
|
|
59
|
+
"@tiptap/extension-underline": "^3.4.2",
|
|
60
|
+
"@tiptap/extensions": "^3.4.2",
|
|
61
|
+
"@tiptap/pm": "^3.4.2",
|
|
62
|
+
"@tiptap/starter-kit": "^3.4.2",
|
|
63
|
+
"@tiptap/vue-3": "^3.4.2",
|
|
59
64
|
"@vee-validate/i18n": "^4.12.4",
|
|
60
65
|
"@vee-validate/rules": "^4.12.4",
|
|
61
66
|
"@vuepic/vue-datepicker": "^11.0.2",
|
|
62
67
|
"@vueuse/components": "^10.7.1",
|
|
63
|
-
"@vueuse/core": "^
|
|
64
|
-
"@vueuse/integrations": "^
|
|
68
|
+
"@vueuse/core": "^13.9.0",
|
|
69
|
+
"@vueuse/integrations": "^13.9.0",
|
|
65
70
|
"bootstrap-icons": "^1.11.3",
|
|
66
71
|
"core-js": "^3.35.0",
|
|
67
72
|
"dompurify": "^3.0.11",
|
|
@@ -69,38 +74,39 @@
|
|
|
69
74
|
"lucide-vue-next": "^0.503.0",
|
|
70
75
|
"moment": "^2.30.1",
|
|
71
76
|
"normalize.css": "^8.0.1",
|
|
72
|
-
"swiper": "^
|
|
73
|
-
"tiptap-markdown": "^0.
|
|
77
|
+
"swiper": "^11.2.10",
|
|
78
|
+
"tiptap-markdown": "^0.9.0",
|
|
74
79
|
"truncate-html": "^1.1.1",
|
|
75
80
|
"vee-validate": "^4.12.4",
|
|
76
|
-
"vue": "^3.5.
|
|
81
|
+
"vue": "^3.5.21",
|
|
77
82
|
"vue-currency-input": "^3.0.5",
|
|
78
83
|
"vue-i18n": "^11.1.11",
|
|
79
|
-
"vue-router": "^4.
|
|
84
|
+
"vue-router": "^4.5.1",
|
|
80
85
|
"vue3-application-insights": "^1.1.0",
|
|
81
86
|
"vue3-touch-events": "^4.1.8",
|
|
82
87
|
"whatwg-fetch": "^3.6.19"
|
|
83
88
|
},
|
|
84
89
|
"devDependencies": {
|
|
85
90
|
"@fullhuman/postcss-purgecss": "^7.0.2",
|
|
86
|
-
"@laynezh/vite-plugin-lib-assets": "
|
|
91
|
+
"@laynezh/vite-plugin-lib-assets": "^2.1.3",
|
|
87
92
|
"@types/dompurify": "^3.0.5",
|
|
88
|
-
"@vc-shell/api-client-generator": "^1.1.
|
|
89
|
-
"@vc-shell/config-generator": "^1.1.
|
|
90
|
-
"@vc-shell/ts-config": "^1.1.
|
|
91
|
-
"@vitejs/plugin-vue": "^
|
|
93
|
+
"@vc-shell/api-client-generator": "^1.1.76",
|
|
94
|
+
"@vc-shell/config-generator": "^1.1.76",
|
|
95
|
+
"@vc-shell/ts-config": "^1.1.76",
|
|
96
|
+
"@vitejs/plugin-vue": "^6.0.1",
|
|
92
97
|
"@vue/test-utils": "^2.4.5",
|
|
93
98
|
"cypress-signalr-mock": "^1.5.0",
|
|
94
99
|
"esbuild": "^0.25.3",
|
|
100
|
+
"postcss": "^8.4.32",
|
|
95
101
|
"sass": "^1.87.0",
|
|
96
102
|
"shx": "^0.3.4",
|
|
97
103
|
"tsc-alias": "^1.8.8",
|
|
98
104
|
"tsx": "^4.7.1",
|
|
99
|
-
"typescript": "^5.
|
|
100
|
-
"vite": "^
|
|
105
|
+
"typescript": "^5.9.2",
|
|
106
|
+
"vite": "^7.1.5",
|
|
101
107
|
"vitest": "^1.3.1",
|
|
102
|
-
"vue-component-type-helpers": "^
|
|
103
|
-
"vue-tsc": "^
|
|
108
|
+
"vue-component-type-helpers": "^3.0.6",
|
|
109
|
+
"vue-tsc": "^3.0.6"
|
|
104
110
|
},
|
|
105
111
|
"publishConfig": {
|
|
106
112
|
"access": "public",
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import { Extension } from '@tiptap/core';
|
|
2
|
+
import '@tiptap/extension-text-style';
|
|
3
|
+
|
|
4
|
+
declare module '@tiptap/core' {
|
|
5
|
+
interface Commands<ReturnType> {
|
|
6
|
+
fontSize: {
|
|
7
|
+
setFontSize: (fontSize: string) => ReturnType;
|
|
8
|
+
unsetFontSize: () => ReturnType;
|
|
9
|
+
};
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export const FontSize = Extension.create({
|
|
14
|
+
name: 'fontSize',
|
|
15
|
+
|
|
16
|
+
addOptions() {
|
|
17
|
+
return {
|
|
18
|
+
types: ['textStyle'],
|
|
19
|
+
};
|
|
20
|
+
},
|
|
21
|
+
|
|
22
|
+
addGlobalAttributes() {
|
|
23
|
+
return [
|
|
24
|
+
{
|
|
25
|
+
types: this.options.types,
|
|
26
|
+
attributes: {
|
|
27
|
+
fontSize: {
|
|
28
|
+
default: null,
|
|
29
|
+
parseHTML: element => element.style.fontSize?.replace(/['"]+/g, ''),
|
|
30
|
+
renderHTML: attributes => {
|
|
31
|
+
if (!attributes.fontSize) {
|
|
32
|
+
return {};
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
return {
|
|
36
|
+
style: `font-size: ${attributes.fontSize}`,
|
|
37
|
+
};
|
|
38
|
+
},
|
|
39
|
+
},
|
|
40
|
+
},
|
|
41
|
+
},
|
|
42
|
+
];
|
|
43
|
+
},
|
|
44
|
+
|
|
45
|
+
addCommands() {
|
|
46
|
+
return {
|
|
47
|
+
setFontSize: (fontSize: string) => ({ chain }) => {
|
|
48
|
+
return chain()
|
|
49
|
+
.setMark('textStyle', { fontSize })
|
|
50
|
+
.run();
|
|
51
|
+
},
|
|
52
|
+
unsetFontSize: () => ({ chain }) => {
|
|
53
|
+
return chain()
|
|
54
|
+
.setMark('textStyle', { fontSize: null })
|
|
55
|
+
.run();
|
|
56
|
+
},
|
|
57
|
+
};
|
|
58
|
+
},
|
|
59
|
+
});
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import type { Editor } from "@tiptap/vue-3";
|
|
2
|
+
|
|
3
|
+
export interface CustomToolbarButton {
|
|
4
|
+
/** Unique identifier for the button */
|
|
5
|
+
id: string;
|
|
6
|
+
/** Button label or title */
|
|
7
|
+
label: string;
|
|
8
|
+
/** Icon name (lucide icon) */
|
|
9
|
+
icon: string;
|
|
10
|
+
/** Action to execute when button is clicked */
|
|
11
|
+
action: (editor: Editor) => void;
|
|
12
|
+
/** Check if button should be active */
|
|
13
|
+
isActive?: (editor: Editor) => boolean;
|
|
14
|
+
/** Check if button should be disabled */
|
|
15
|
+
isDisabled?: (editor: Editor) => boolean;
|
|
16
|
+
/** Custom component to render instead of default button */
|
|
17
|
+
component?: any;
|
|
18
|
+
/** Props to pass to custom component */
|
|
19
|
+
componentProps?: Record<string, any>;
|
|
20
|
+
/** Button group for organizing buttons */
|
|
21
|
+
group?: string;
|
|
22
|
+
/** Sort order within group */
|
|
23
|
+
order?: number;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
export interface CustomToolbarDropdown {
|
|
27
|
+
/** Unique identifier for the dropdown */
|
|
28
|
+
id: string;
|
|
29
|
+
/** Dropdown label */
|
|
30
|
+
label: string;
|
|
31
|
+
/** Dropdown options */
|
|
32
|
+
options: Array<{
|
|
33
|
+
value: string;
|
|
34
|
+
label: string;
|
|
35
|
+
action: (editor: Editor, value: string) => void;
|
|
36
|
+
}>;
|
|
37
|
+
/** Get current value */
|
|
38
|
+
getValue?: (editor: Editor) => string;
|
|
39
|
+
/** Check if dropdown should be disabled */
|
|
40
|
+
isDisabled?: (editor: Editor) => boolean;
|
|
41
|
+
/** Custom styles for dropdown */
|
|
42
|
+
style?: Record<string, any>;
|
|
43
|
+
/** Button group for organizing dropdowns */
|
|
44
|
+
group?: string;
|
|
45
|
+
/** Sort order within group */
|
|
46
|
+
order?: number;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export type CustomToolbarItem = CustomToolbarButton | CustomToolbarDropdown;
|
|
50
|
+
|
|
51
|
+
export function isDropdown(item: CustomToolbarItem): item is CustomToolbarDropdown {
|
|
52
|
+
return 'options' in item;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
export function isButton(item: CustomToolbarItem): item is CustomToolbarButton {
|
|
56
|
+
return !('options' in item);
|
|
57
|
+
}
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<component
|
|
3
|
+
v-if="isButton(customButton) && customButton.component"
|
|
4
|
+
:is="customButton.component"
|
|
5
|
+
:editor="editor"
|
|
6
|
+
:disabled="disabled || isDisabled"
|
|
7
|
+
v-bind="customButton.componentProps || {}"
|
|
8
|
+
/>
|
|
9
|
+
<VcEditorButton
|
|
10
|
+
v-else-if="isButton(customButton)"
|
|
11
|
+
:icon="customButton.icon"
|
|
12
|
+
:active="isActive"
|
|
13
|
+
:disabled="disabled || isDisabled"
|
|
14
|
+
@action="handleAction"
|
|
15
|
+
/>
|
|
16
|
+
<div
|
|
17
|
+
v-else-if="isDropdown(customButton)"
|
|
18
|
+
class="vc-editor-dropdown"
|
|
19
|
+
>
|
|
20
|
+
<select
|
|
21
|
+
:disabled="disabled || isDisabled"
|
|
22
|
+
@change="handleDropdownChange"
|
|
23
|
+
>
|
|
24
|
+
<option
|
|
25
|
+
v-for="option in customButton.options"
|
|
26
|
+
:key="option.value"
|
|
27
|
+
:value="option.value"
|
|
28
|
+
>
|
|
29
|
+
{{ option.label }}
|
|
30
|
+
</option>
|
|
31
|
+
</select>
|
|
32
|
+
</div>
|
|
33
|
+
</template>
|
|
34
|
+
|
|
35
|
+
<script lang="ts" setup>
|
|
36
|
+
import type { Editor } from "@tiptap/vue-3";
|
|
37
|
+
import { computed } from "vue";
|
|
38
|
+
import VcEditorButton from "./vc-editor-button.vue";
|
|
39
|
+
import type { CustomToolbarItem } from "./toolbar-types";
|
|
40
|
+
import { isButton, isDropdown } from "./toolbar-types";
|
|
41
|
+
|
|
42
|
+
interface Props {
|
|
43
|
+
editor: Editor;
|
|
44
|
+
customButton: CustomToolbarItem;
|
|
45
|
+
disabled: boolean;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
const props = defineProps<Props>();
|
|
49
|
+
|
|
50
|
+
const isActive = computed(() => {
|
|
51
|
+
if (isButton(props.customButton) && props.customButton.isActive) {
|
|
52
|
+
return props.customButton.isActive(props.editor);
|
|
53
|
+
}
|
|
54
|
+
return false;
|
|
55
|
+
});
|
|
56
|
+
|
|
57
|
+
const isDisabled = computed(() => {
|
|
58
|
+
if (props.customButton.isDisabled) {
|
|
59
|
+
return props.customButton.isDisabled(props.editor);
|
|
60
|
+
}
|
|
61
|
+
return false;
|
|
62
|
+
});
|
|
63
|
+
|
|
64
|
+
function handleAction() {
|
|
65
|
+
if (isButton(props.customButton)) {
|
|
66
|
+
props.customButton.action(props.editor);
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
function handleDropdownChange(event: Event) {
|
|
71
|
+
const target = event.target as HTMLSelectElement;
|
|
72
|
+
if (isDropdown(props.customButton)) {
|
|
73
|
+
const option = props.customButton.options.find(opt => opt.value === target.value);
|
|
74
|
+
if (option) {
|
|
75
|
+
option.action(props.editor, target.value);
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
</script>
|
|
@@ -0,0 +1,215 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="vc-editor-font-selector">
|
|
3
|
+
<!-- Font Size Dropdown -->
|
|
4
|
+
<div class="vc-editor-font-selector__dropdown">
|
|
5
|
+
<button
|
|
6
|
+
type="button"
|
|
7
|
+
class="vc-editor-font-selector__button"
|
|
8
|
+
:disabled="disabled"
|
|
9
|
+
@click="toggleSizeDropdown"
|
|
10
|
+
>
|
|
11
|
+
<VcIcon icon="lucide-a-large-small" size="s" :use-container="false" />
|
|
12
|
+
<span v-if="currentFontSize" class="vc-editor-font-selector__size-value">{{ currentFontSize }}px</span>
|
|
13
|
+
<VcIcon icon="lucide-chevron-down" size="xs" :use-container="false" />
|
|
14
|
+
</button>
|
|
15
|
+
<div
|
|
16
|
+
v-if="showSizeDropdown"
|
|
17
|
+
class="vc-editor-font-selector__menu"
|
|
18
|
+
@click.stop
|
|
19
|
+
>
|
|
20
|
+
<div
|
|
21
|
+
v-for="size in fontSizes"
|
|
22
|
+
:key="size"
|
|
23
|
+
class="vc-editor-font-selector__option"
|
|
24
|
+
:class="{ 'vc-editor-font-selector__option--active': currentFontSize === size }"
|
|
25
|
+
@click="selectFontSize(size)"
|
|
26
|
+
>
|
|
27
|
+
{{ size }}px
|
|
28
|
+
</div>
|
|
29
|
+
<div class="vc-editor-font-selector__custom">
|
|
30
|
+
<input
|
|
31
|
+
v-model="customSize"
|
|
32
|
+
type="number"
|
|
33
|
+
min="8"
|
|
34
|
+
max="72"
|
|
35
|
+
placeholder="Custom"
|
|
36
|
+
class="vc-editor-font-selector__input"
|
|
37
|
+
@keydown.enter="selectCustomFontSize"
|
|
38
|
+
@blur="selectCustomFontSize"
|
|
39
|
+
/>
|
|
40
|
+
</div>
|
|
41
|
+
</div>
|
|
42
|
+
</div>
|
|
43
|
+
</div>
|
|
44
|
+
</template>
|
|
45
|
+
|
|
46
|
+
<script lang="ts" setup>
|
|
47
|
+
import type { Editor } from "@tiptap/vue-3";
|
|
48
|
+
import { ref, computed, onMounted, onUnmounted } from "vue";
|
|
49
|
+
import { VcIcon } from "../../../atoms";
|
|
50
|
+
|
|
51
|
+
interface Props {
|
|
52
|
+
editor: Editor;
|
|
53
|
+
disabled: boolean;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
const props = defineProps<Props>();
|
|
57
|
+
|
|
58
|
+
const showSizeDropdown = ref(false);
|
|
59
|
+
const customSize = ref<number | null>(null);
|
|
60
|
+
|
|
61
|
+
const fontSizes = [8, 10, 12, 14, 16, 18, 20, 24, 28, 32, 36, 48, 72];
|
|
62
|
+
|
|
63
|
+
const currentFontSize = computed(() => {
|
|
64
|
+
const attrs = props.editor.getAttributes('textStyle');
|
|
65
|
+
return attrs.fontSize ? parseInt(attrs.fontSize.replace('px', '')) : null;
|
|
66
|
+
});
|
|
67
|
+
|
|
68
|
+
function toggleSizeDropdown() {
|
|
69
|
+
showSizeDropdown.value = !showSizeDropdown.value;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
function selectFontSize(size: number) {
|
|
73
|
+
props.editor.chain().focus().setFontSize(`${size}px`).run();
|
|
74
|
+
showSizeDropdown.value = false;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
function selectCustomFontSize() {
|
|
78
|
+
if (customSize.value && customSize.value >= 8 && customSize.value <= 72) {
|
|
79
|
+
props.editor.chain().focus().setFontSize(`${customSize.value}px`).run();
|
|
80
|
+
customSize.value = null;
|
|
81
|
+
showSizeDropdown.value = false;
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
function closeDropdown() {
|
|
86
|
+
showSizeDropdown.value = false;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
function handleClickOutside(event: MouseEvent) {
|
|
90
|
+
const target = event.target as HTMLElement;
|
|
91
|
+
if (!target.closest('.vc-editor-font-selector')) {
|
|
92
|
+
closeDropdown();
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
onMounted(() => {
|
|
97
|
+
document.addEventListener('click', handleClickOutside);
|
|
98
|
+
});
|
|
99
|
+
|
|
100
|
+
onUnmounted(() => {
|
|
101
|
+
document.removeEventListener('click', handleClickOutside);
|
|
102
|
+
});
|
|
103
|
+
</script>
|
|
104
|
+
|
|
105
|
+
<style lang="scss">
|
|
106
|
+
.vc-editor-font-selector {
|
|
107
|
+
display: flex;
|
|
108
|
+
gap: 0.25rem;
|
|
109
|
+
|
|
110
|
+
&__dropdown {
|
|
111
|
+
position: relative;
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
&__button {
|
|
115
|
+
display: inline-flex;
|
|
116
|
+
align-items: center;
|
|
117
|
+
justify-content: center;
|
|
118
|
+
gap: 0.25rem;
|
|
119
|
+
height: 2rem;
|
|
120
|
+
padding: 0 0.5rem;
|
|
121
|
+
border: none;
|
|
122
|
+
border-radius: 6px;
|
|
123
|
+
background-color: transparent;
|
|
124
|
+
color: var(--neutrals-600);
|
|
125
|
+
cursor: pointer;
|
|
126
|
+
transition:
|
|
127
|
+
background-color 0.2s ease,
|
|
128
|
+
color 0.2s ease,
|
|
129
|
+
transform 0.1s ease;
|
|
130
|
+
|
|
131
|
+
&:hover:not(:disabled) {
|
|
132
|
+
background-color: var(--neutrals-100);
|
|
133
|
+
color: var(--neutrals-800);
|
|
134
|
+
transform: translateY(-1px);
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
&:active:not(:disabled) {
|
|
138
|
+
transform: translateY(0);
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
&:disabled {
|
|
142
|
+
color: var(--neutrals-400);
|
|
143
|
+
cursor: not-allowed;
|
|
144
|
+
opacity: 0.5;
|
|
145
|
+
transform: none;
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
&:focus-visible {
|
|
149
|
+
outline: 2px solid var(--primary-500);
|
|
150
|
+
outline-offset: 2px;
|
|
151
|
+
}
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
&__size-value {
|
|
155
|
+
font-size: 0.75rem;
|
|
156
|
+
font-weight: 500;
|
|
157
|
+
min-width: 2rem;
|
|
158
|
+
text-align: center;
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
&__menu {
|
|
162
|
+
position: absolute;
|
|
163
|
+
top: 100%;
|
|
164
|
+
left: 0;
|
|
165
|
+
z-index: 100;
|
|
166
|
+
min-width: 160px;
|
|
167
|
+
max-height: 240px;
|
|
168
|
+
overflow-y: auto;
|
|
169
|
+
background: white;
|
|
170
|
+
border: 1px solid var(--neutrals-300);
|
|
171
|
+
border-radius: 6px;
|
|
172
|
+
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
|
|
173
|
+
margin-top: 0.25rem;
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
&__option {
|
|
177
|
+
padding: 0.5rem 0.75rem;
|
|
178
|
+
cursor: pointer;
|
|
179
|
+
border-bottom: 1px solid var(--neutrals-100);
|
|
180
|
+
transition: background-color 0.15s ease;
|
|
181
|
+
|
|
182
|
+
&:last-child {
|
|
183
|
+
border-bottom: none;
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
&:hover {
|
|
187
|
+
background-color: var(--neutrals-50);
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
&--active {
|
|
191
|
+
background-color: var(--primary-100);
|
|
192
|
+
color: var(--primary-700);
|
|
193
|
+
font-weight: 500;
|
|
194
|
+
}
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
&__custom {
|
|
198
|
+
padding: 0.5rem 0.75rem;
|
|
199
|
+
border-top: 1px solid var(--neutrals-200);
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
&__input {
|
|
203
|
+
width: 100%;
|
|
204
|
+
padding: 0.25rem 0.5rem;
|
|
205
|
+
border: 1px solid var(--neutrals-300);
|
|
206
|
+
border-radius: 4px;
|
|
207
|
+
font-size: 0.875rem;
|
|
208
|
+
|
|
209
|
+
&:focus {
|
|
210
|
+
outline: none;
|
|
211
|
+
border-color: var(--primary-500);
|
|
212
|
+
}
|
|
213
|
+
}
|
|
214
|
+
}
|
|
215
|
+
</style>
|
|
@@ -125,6 +125,25 @@
|
|
|
125
125
|
:disabled="disabled"
|
|
126
126
|
@action="editor.chain().focus().insertTable({ rows: 3, cols: 3, withHeaderRow: true }).run()"
|
|
127
127
|
/>
|
|
128
|
+
|
|
129
|
+
<!-- Font Selector -->
|
|
130
|
+
<VcEditorFontSelector
|
|
131
|
+
v-else-if="item === 'fontSize'"
|
|
132
|
+
:editor="editor"
|
|
133
|
+
:disabled="disabled"
|
|
134
|
+
/>
|
|
135
|
+
</template>
|
|
136
|
+
|
|
137
|
+
<!-- Custom buttons -->
|
|
138
|
+
<template v-if="props.customButtons.length > 0">
|
|
139
|
+
<div class="vc-editor-toolbar__separator" />
|
|
140
|
+
<VcEditorCustomButton
|
|
141
|
+
v-for="customButton in sortedCustomButtons"
|
|
142
|
+
:key="customButton.id"
|
|
143
|
+
:editor="editor"
|
|
144
|
+
:custom-button="customButton"
|
|
145
|
+
:disabled="disabled"
|
|
146
|
+
/>
|
|
128
147
|
</template>
|
|
129
148
|
|
|
130
149
|
<!-- Table controls (always show when table is active) -->
|
|
@@ -173,12 +192,16 @@
|
|
|
173
192
|
import type { Editor } from "@tiptap/vue-3";
|
|
174
193
|
import { computed } from "vue";
|
|
175
194
|
import VcEditorButton from "./vc-editor-button.vue";
|
|
195
|
+
import VcEditorCustomButton from "./vc-editor-custom-button.vue";
|
|
196
|
+
import VcEditorFontSelector from "./vc-editor-font-selector.vue";
|
|
197
|
+
import type { CustomToolbarItem } from "./toolbar-types";
|
|
176
198
|
|
|
177
199
|
export interface Props {
|
|
178
200
|
editor: Editor;
|
|
179
201
|
disabled: boolean;
|
|
180
202
|
contentType: "html" | "markdown";
|
|
181
203
|
toolbar: ToolbarNames[];
|
|
204
|
+
customButtons: CustomToolbarItem[];
|
|
182
205
|
}
|
|
183
206
|
|
|
184
207
|
// Define toolbar button types
|
|
@@ -196,10 +219,12 @@ type ToolbarNames =
|
|
|
196
219
|
| "link"
|
|
197
220
|
| "image"
|
|
198
221
|
| "table"
|
|
222
|
+
| "fontSize"
|
|
199
223
|
| "separator";
|
|
200
224
|
|
|
201
225
|
const props = withDefaults(defineProps<Props>(), {
|
|
202
226
|
contentType: "html",
|
|
227
|
+
customButtons: () => [],
|
|
203
228
|
});
|
|
204
229
|
|
|
205
230
|
const emit = defineEmits(["uploadImage"]);
|
|
@@ -209,6 +234,22 @@ const toolbarItems = computed(() => {
|
|
|
209
234
|
return props.toolbar || [];
|
|
210
235
|
});
|
|
211
236
|
|
|
237
|
+
// Computed property to sort custom buttons
|
|
238
|
+
const sortedCustomButtons = computed(() => {
|
|
239
|
+
return [...props.customButtons].sort((a, b) => {
|
|
240
|
+
const groupA = a.group || 'default';
|
|
241
|
+
const groupB = b.group || 'default';
|
|
242
|
+
const orderA = a.order || 0;
|
|
243
|
+
const orderB = b.order || 0;
|
|
244
|
+
|
|
245
|
+
if (groupA !== groupB) {
|
|
246
|
+
return groupA.localeCompare(groupB);
|
|
247
|
+
}
|
|
248
|
+
|
|
249
|
+
return orderA - orderB;
|
|
250
|
+
});
|
|
251
|
+
});
|
|
252
|
+
|
|
212
253
|
function setLink() {
|
|
213
254
|
const previousUrl = props.editor.getAttributes("link").href;
|
|
214
255
|
const url = window.prompt("URL", previousUrl);
|
|
@@ -248,5 +289,6 @@ function triggerImageUpload() {
|
|
|
248
289
|
margin: 0 0.5rem;
|
|
249
290
|
flex-shrink: 0;
|
|
250
291
|
}
|
|
292
|
+
|
|
251
293
|
}
|
|
252
294
|
</style>
|