@vc-shell/framework 1.0.52 → 1.0.54
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/core/composables/index.ts +0 -1
- package/core/composables/useApiClient/index.ts +9 -4
- package/core/composables/useAsync/index.ts +2 -6
- package/core/composables/useAutosave/index.ts +1 -3
- package/core/composables/useFunctions/debounce.ts +1 -4
- package/core/composables/useFunctions/delay.ts +1 -4
- package/core/composables/useFunctions/once.ts +1 -3
- package/core/composables/useFunctions/throttle.ts +1 -4
- package/core/composables/useI18n/index.ts +3 -24
- package/core/composables/useLoading/index.ts +1 -3
- package/core/composables/useNotifications/index.ts +6 -13
- package/core/composables/usePermissions/index.ts +1 -1
- package/core/composables/useSettings/index.ts +3 -4
- package/core/composables/useUser/index.ts +27 -66
- package/core/directives/permissions/index.ts +1 -1
- package/core/plugins/i18n/index.ts +8 -0
- package/core/plugins/index.ts +3 -1
- package/core/plugins/modularity/index.ts +32 -0
- package/core/plugins/moment/humanize.ts +1 -4
- package/core/plugins/validation/index.ts +11 -1
- package/core/plugins/validation/rules.ts +48 -170
- package/core/types/index.ts +7 -9
- package/dist/core/composables/index.d.ts +0 -1
- package/dist/core/composables/index.d.ts.map +1 -1
- package/dist/core/composables/useApiClient/index.d.ts +9 -3
- package/dist/core/composables/useApiClient/index.d.ts.map +1 -1
- package/dist/core/composables/useAsync/index.d.ts.map +1 -1
- package/dist/core/composables/useAutosave/index.d.ts.map +1 -1
- package/dist/core/composables/useFunctions/debounce.d.ts.map +1 -1
- package/dist/core/composables/useFunctions/delay.d.ts.map +1 -1
- package/dist/core/composables/useFunctions/once.d.ts.map +1 -1
- package/dist/core/composables/useFunctions/throttle.d.ts.map +1 -1
- package/dist/core/composables/useI18n/index.d.ts +2 -4
- package/dist/core/composables/useI18n/index.d.ts.map +1 -1
- package/dist/core/composables/useLoading/index.d.ts.map +1 -1
- package/dist/core/composables/useNotifications/index.d.ts +1 -1
- package/dist/core/composables/useNotifications/index.d.ts.map +1 -1
- package/dist/core/composables/useSettings/index.d.ts.map +1 -1
- package/dist/core/composables/useUser/index.d.ts +2 -2
- package/dist/core/composables/useUser/index.d.ts.map +1 -1
- package/dist/core/plugins/i18n/index.d.ts +3 -0
- package/dist/core/plugins/i18n/index.d.ts.map +1 -0
- package/dist/core/plugins/index.d.ts +3 -1
- package/dist/core/plugins/index.d.ts.map +1 -1
- package/dist/core/plugins/modularity/index.d.ts +8 -0
- package/dist/core/plugins/modularity/index.d.ts.map +1 -0
- package/dist/core/plugins/moment/humanize.d.ts.map +1 -1
- package/dist/core/plugins/validation/index.d.ts +3 -1
- package/dist/core/plugins/validation/index.d.ts.map +1 -1
- package/dist/core/plugins/validation/rules.d.ts +32 -11
- package/dist/core/plugins/validation/rules.d.ts.map +1 -1
- package/dist/core/types/index.d.ts +5 -6
- package/dist/core/types/index.d.ts.map +1 -1
- package/dist/framework.esm.js +42553 -0
- package/dist/framework.js +74 -72
- package/dist/index.d.ts.map +1 -1
- package/dist/shared/app-switcher/composables/useAppSwitcher/index.d.ts +1 -1
- package/dist/shared/app-switcher/composables/useAppSwitcher/index.d.ts.map +1 -1
- package/dist/shared/app-switcher/index.d.ts +2 -3
- package/dist/shared/app-switcher/index.d.ts.map +1 -1
- package/dist/shared/assets/components/index.d.ts +1 -1
- package/dist/shared/assets/components/index.d.ts.map +1 -1
- package/dist/shared/assets/index.d.ts +2 -3
- package/dist/shared/assets/index.d.ts.map +1 -1
- package/dist/shared/blade-navigation/composables/index.d.ts +1 -1
- package/dist/shared/blade-navigation/composables/index.d.ts.map +1 -1
- package/dist/shared/blade-navigation/composables/useBladeNavigation/index.d.ts +2 -2
- package/dist/shared/blade-navigation/composables/useBladeNavigation/index.d.ts.map +1 -1
- package/dist/shared/blade-navigation/index.d.ts +2 -3
- package/dist/shared/blade-navigation/index.d.ts.map +1 -1
- package/dist/shared/blade-navigation/types/index.d.ts +1 -1
- package/dist/shared/blade-navigation/types/index.d.ts.map +1 -1
- package/dist/shared/index.d.ts +4 -1
- package/dist/shared/index.d.ts.map +1 -1
- package/dist/style.css +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/ui/components/atoms/vc-badge/index.d.ts +3 -3
- package/dist/ui/components/atoms/vc-badge/index.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-badge/vc-badge-model.d.ts +20 -20
- package/dist/ui/components/atoms/vc-badge/vc-badge-model.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-button/index.d.ts +3 -3
- package/dist/ui/components/atoms/vc-button/index.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-button/vc-button-model.d.ts +30 -24
- package/dist/ui/components/atoms/vc-button/vc-button-model.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-card/index.d.ts +5 -0
- package/dist/ui/components/atoms/vc-card/index.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-card/vc-card-model.d.ts +33 -0
- package/dist/ui/components/atoms/vc-card/vc-card-model.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-checkbox/index.d.ts +5 -0
- package/dist/ui/components/atoms/vc-checkbox/index.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-checkbox/vc-checkbox-model.d.ts +31 -0
- package/dist/ui/components/atoms/vc-checkbox/vc-checkbox-model.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-col/index.d.ts +5 -0
- package/dist/ui/components/atoms/vc-col/index.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-col/vc-col-model.d.ts +13 -0
- package/dist/ui/components/atoms/vc-col/vc-col-model.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-container/index.d.ts +5 -0
- package/dist/ui/components/atoms/vc-container/index.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-container/vc-container-model.d.ts +25 -0
- package/dist/ui/components/atoms/vc-container/vc-container-model.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-hint/index.d.ts +2 -0
- package/dist/ui/components/atoms/vc-hint/index.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-hint/vc-hint-model.d.ts +5 -0
- package/dist/ui/components/atoms/vc-hint/vc-hint-model.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-icon/index.d.ts +5 -0
- package/dist/ui/components/atoms/vc-icon/index.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-icon/vc-icon-model.d.ts +17 -0
- package/dist/ui/components/atoms/vc-icon/vc-icon-model.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-image/index.d.ts +5 -0
- package/dist/ui/components/atoms/vc-image/index.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-image/vc-image-model.d.ts +38 -0
- package/dist/ui/components/atoms/vc-image/vc-image-model.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-image/vc-image.stories.d.ts.map +1 -1
- package/dist/ui/components/atoms/vc-info-row/index.d.ts +5 -0
- package/dist/ui/components/atoms/vc-info-row/index.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-info-row/vc-info-row-model.d.ts +25 -0
- package/dist/ui/components/atoms/vc-info-row/vc-info-row-model.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-label/index.d.ts +5 -0
- package/dist/ui/components/atoms/vc-label/index.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-label/vc-label-model.d.ts +18 -0
- package/dist/ui/components/atoms/vc-label/vc-label-model.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-link/index.d.ts +5 -0
- package/dist/ui/components/atoms/vc-link/index.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-link/vc-link-model.d.ts +21 -0
- package/dist/ui/components/atoms/vc-link/vc-link-model.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-loading/index.d.ts +5 -0
- package/dist/ui/components/atoms/vc-loading/index.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-loading/vc-loading-model.d.ts +13 -0
- package/dist/ui/components/atoms/vc-loading/vc-loading-model.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-progress/index.d.ts +5 -0
- package/dist/ui/components/atoms/vc-progress/index.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-progress/vc-progress-model.d.ts +17 -0
- package/dist/ui/components/atoms/vc-progress/vc-progress-model.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-row/index.d.ts +2 -0
- package/dist/ui/components/atoms/vc-row/index.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-row/vc-row-model.d.ts +5 -0
- package/dist/ui/components/atoms/vc-row/vc-row-model.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-status/index.d.ts +5 -0
- package/dist/ui/components/atoms/vc-status/index.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-status/vc-status-model.d.ts +21 -0
- package/dist/ui/components/atoms/vc-status/vc-status-model.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-status-icon/index.d.ts +5 -0
- package/dist/ui/components/atoms/vc-status-icon/index.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-status-icon/vc-status-icon-model.d.ts +13 -0
- package/dist/ui/components/atoms/vc-status-icon/vc-status-icon-model.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-switch/index.d.ts +5 -0
- package/dist/ui/components/atoms/vc-switch/index.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-switch/vc-switch-model.d.ts +30 -0
- package/dist/ui/components/atoms/vc-switch/vc-switch-model.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-widget/index.d.ts +5 -0
- package/dist/ui/components/atoms/vc-widget/index.d.ts.map +1 -0
- package/dist/ui/components/atoms/vc-widget/vc-widget-model.d.ts +20 -0
- package/dist/ui/components/atoms/vc-widget/vc-widget-model.d.ts.map +1 -0
- package/dist/ui/components/index.d.ts +34 -34
- package/dist/ui/components/index.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-breadcrumbs/index.d.ts +5 -0
- package/dist/ui/components/molecules/vc-breadcrumbs/index.d.ts.map +1 -0
- package/dist/ui/components/molecules/vc-breadcrumbs/vc-breadcrumbs-model.d.ts +19 -0
- package/dist/ui/components/molecules/vc-breadcrumbs/vc-breadcrumbs-model.d.ts.map +1 -0
- package/dist/ui/components/molecules/vc-editor/index.d.ts +5 -0
- package/dist/ui/components/molecules/vc-editor/index.d.ts.map +1 -0
- package/dist/ui/components/molecules/vc-editor/vc-editor-model.d.ts +33 -0
- package/dist/ui/components/molecules/vc-editor/vc-editor-model.d.ts.map +1 -0
- package/dist/ui/components/molecules/vc-file-upload/index.d.ts +5 -0
- package/dist/ui/components/molecules/vc-file-upload/index.d.ts.map +1 -0
- package/dist/ui/components/molecules/vc-file-upload/vc-file-upload-model.d.ts +34 -0
- package/dist/ui/components/molecules/vc-file-upload/vc-file-upload-model.d.ts.map +1 -0
- package/dist/ui/components/molecules/vc-form/index.d.ts +2 -0
- package/dist/ui/components/molecules/vc-form/index.d.ts.map +1 -0
- package/dist/ui/components/molecules/vc-form/vc-form-model.d.ts +5 -0
- package/dist/ui/components/molecules/vc-form/vc-form-model.d.ts.map +1 -0
- package/dist/ui/components/molecules/vc-input/index.d.ts +3 -3
- package/dist/ui/components/molecules/vc-input/index.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-input/vc-input-model.d.ts +48 -25
- package/dist/ui/components/molecules/vc-input/vc-input-model.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-input-currency/index.d.ts +3 -3
- package/dist/ui/components/molecules/vc-input-currency/index.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-input-currency/vc-input-currency-model.d.ts +36 -28
- package/dist/ui/components/molecules/vc-input-currency/vc-input-currency-model.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-notification/index.d.ts +5 -0
- package/dist/ui/components/molecules/vc-notification/index.d.ts.map +1 -0
- package/dist/ui/components/molecules/vc-notification/vc-notification-model.d.ts +18 -0
- package/dist/ui/components/molecules/vc-notification/vc-notification-model.d.ts.map +1 -0
- package/dist/ui/components/molecules/vc-pagination/index.d.ts +5 -0
- package/dist/ui/components/molecules/vc-pagination/index.d.ts.map +1 -0
- package/dist/ui/components/molecules/vc-pagination/vc-pagination-model.d.ts +25 -0
- package/dist/ui/components/molecules/vc-pagination/vc-pagination-model.d.ts.map +1 -0
- package/dist/ui/components/molecules/vc-rating/index.d.ts +5 -0
- package/dist/ui/components/molecules/vc-rating/index.d.ts.map +1 -0
- package/dist/ui/components/molecules/vc-rating/vc-rating-model.d.ts +21 -0
- package/dist/ui/components/molecules/vc-rating/vc-rating-model.d.ts.map +1 -0
- package/dist/ui/components/molecules/vc-select/index.d.ts +3 -3
- package/dist/ui/components/molecules/vc-select/index.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-select/vc-select-model.d.ts +67 -32
- package/dist/ui/components/molecules/vc-select/vc-select-model.d.ts.map +1 -1
- package/dist/ui/components/molecules/vc-slider/index.d.ts +5 -0
- package/dist/ui/components/molecules/vc-slider/index.d.ts.map +1 -0
- package/dist/ui/components/molecules/vc-slider/vc-slider-model.d.ts +33 -0
- package/dist/ui/components/molecules/vc-slider/vc-slider-model.d.ts.map +1 -0
- package/dist/ui/components/molecules/vc-textarea/index.d.ts +5 -0
- package/dist/ui/components/molecules/vc-textarea/index.d.ts.map +1 -0
- package/dist/ui/components/molecules/vc-textarea/vc-textarea-model.d.ts +37 -0
- package/dist/ui/components/molecules/vc-textarea/vc-textarea-model.d.ts.map +1 -0
- package/dist/ui/components/organisms/vc-app/index.d.ts +5 -0
- package/dist/ui/components/organisms/vc-app/index.d.ts.map +1 -0
- package/dist/ui/components/organisms/vc-app/vc-app-model.d.ts +61 -0
- package/dist/ui/components/organisms/vc-app/vc-app-model.d.ts.map +1 -0
- package/dist/ui/components/organisms/vc-blade/index.d.ts +5 -0
- package/dist/ui/components/organisms/vc-blade/index.d.ts.map +1 -0
- package/dist/ui/components/organisms/vc-blade/vc-blade-model.d.ts +34 -0
- package/dist/ui/components/organisms/vc-blade/vc-blade-model.d.ts.map +1 -0
- package/dist/ui/components/organisms/vc-blade/vc-blade.stories.d.ts.map +1 -1
- package/dist/ui/components/organisms/vc-dynamic-property/index.d.ts +5 -0
- package/dist/ui/components/organisms/vc-dynamic-property/index.d.ts.map +1 -0
- package/dist/ui/components/organisms/vc-dynamic-property/vc-dynamic-property-model.d.ts +43 -0
- package/dist/ui/components/organisms/vc-dynamic-property/vc-dynamic-property-model.d.ts.map +1 -0
- package/dist/ui/components/organisms/vc-gallery/index.d.ts +5 -0
- package/dist/ui/components/organisms/vc-gallery/index.d.ts.map +1 -0
- package/dist/ui/components/organisms/vc-gallery/vc-gallery-model.d.ts +74 -0
- package/dist/ui/components/organisms/vc-gallery/vc-gallery-model.d.ts.map +1 -0
- package/dist/ui/components/organisms/vc-login-form/index.d.ts +5 -0
- package/dist/ui/components/organisms/vc-login-form/index.d.ts.map +1 -0
- package/dist/ui/components/organisms/vc-login-form/vc-login-form-model.d.ts +15 -0
- package/dist/ui/components/organisms/vc-login-form/vc-login-form-model.d.ts.map +1 -0
- package/dist/ui/components/organisms/vc-popup/index.d.ts +5 -0
- package/dist/ui/components/organisms/vc-popup/index.d.ts.map +1 -0
- package/dist/ui/components/organisms/vc-popup/vc-popup-model.d.ts +22 -0
- package/dist/ui/components/organisms/vc-popup/vc-popup-model.d.ts.map +1 -0
- package/dist/ui/components/organisms/vc-table/index.d.ts +5 -0
- package/dist/ui/components/organisms/vc-table/index.d.ts.map +1 -0
- package/dist/ui/components/organisms/vc-table/vc-table-model.d.ts +135 -0
- package/dist/ui/components/organisms/vc-table/vc-table-model.d.ts.map +1 -0
- package/dist/ui/types/index.d.ts +76 -6
- package/dist/ui/types/index.d.ts.map +1 -1
- package/dist/ui/types/ts-helpers.d.ts +14 -4
- package/dist/ui/types/ts-helpers.d.ts.map +1 -1
- package/dist/ui/utils/index.d.ts +2 -0
- package/dist/ui/utils/index.d.ts.map +1 -0
- package/dist/ui/utils/types.d.ts +3 -0
- package/dist/ui/utils/types.d.ts.map +1 -0
- package/dist/vite.config.d.ts +1 -1
- package/dist/vite.config.d.ts.map +1 -1
- package/package.json +9 -11
- package/shared/app-switcher/components/vc-app-switcher/vc-app-switcher.vue +3 -6
- package/shared/app-switcher/composables/useAppSwitcher/index.ts +3 -8
- package/shared/app-switcher/index.ts +3 -10
- package/shared/assets/components/assets-details/assets-details.vue +10 -31
- package/shared/assets/components/index.ts +1 -1
- package/shared/assets/index.ts +3 -15
- package/shared/blade-navigation/components/vc-blade-navigation/vc-blade-navigation.vue +2 -7
- package/shared/blade-navigation/composables/index.ts +1 -1
- package/shared/blade-navigation/composables/useBladeNavigation/index.ts +8 -37
- package/shared/blade-navigation/index.ts +3 -10
- package/shared/blade-navigation/types/index.ts +1 -1
- package/shared/index.ts +9 -11
- package/ui/components/atoms/vc-badge/index.ts +5 -5
- package/ui/components/atoms/vc-badge/vc-badge-model.ts +21 -20
- package/ui/components/atoms/vc-badge/vc-badge.vue +5 -11
- package/ui/components/atoms/vc-button/index.ts +5 -5
- package/ui/components/atoms/vc-button/vc-button-model.ts +31 -24
- package/ui/components/atoms/vc-button/vc-button.vue +9 -38
- package/ui/components/atoms/vc-card/index.ts +6 -0
- package/ui/components/atoms/vc-card/vc-card-model.ts +37 -0
- package/ui/components/atoms/vc-card/vc-card.vue +20 -36
- package/ui/components/atoms/vc-checkbox/index.ts +8 -0
- package/ui/components/atoms/vc-checkbox/vc-checkbox-model.ts +35 -0
- package/ui/components/atoms/vc-checkbox/vc-checkbox.vue +15 -30
- package/ui/components/atoms/vc-col/index.ts +5 -0
- package/ui/components/atoms/vc-col/vc-col-model.ts +15 -0
- package/ui/components/atoms/vc-col/vc-col.vue +2 -6
- package/ui/components/atoms/vc-container/index.ts +8 -0
- package/ui/components/atoms/vc-container/vc-container-model.ts +28 -0
- package/ui/components/atoms/vc-container/vc-container.vue +11 -26
- package/ui/components/atoms/vc-hint/index.ts +2 -0
- package/ui/components/atoms/vc-hint/vc-hint-model.ts +5 -0
- package/ui/components/atoms/vc-icon/index.ts +5 -0
- package/ui/components/atoms/vc-icon/vc-icon-model.ts +19 -0
- package/ui/components/atoms/vc-icon/vc-icon.vue +2 -8
- package/ui/components/atoms/vc-image/index.ts +7 -0
- package/ui/components/atoms/vc-image/vc-image-model.ts +41 -0
- package/ui/components/atoms/vc-image/vc-image.stories.ts +1 -2
- package/ui/components/atoms/vc-image/vc-image.vue +12 -42
- package/ui/components/atoms/vc-info-row/index.ts +5 -0
- package/ui/components/atoms/vc-info-row/vc-info-row-model.ts +27 -0
- package/ui/components/atoms/vc-info-row/vc-info-row.vue +14 -24
- package/ui/components/atoms/vc-label/index.ts +5 -0
- package/ui/components/atoms/vc-label/vc-label-model.ts +20 -0
- package/ui/components/atoms/vc-label/vc-label.vue +11 -15
- package/ui/components/atoms/vc-link/index.ts +6 -0
- package/ui/components/atoms/vc-link/vc-link-model.ts +24 -0
- package/ui/components/atoms/vc-link/vc-link.vue +4 -11
- package/ui/components/atoms/vc-loading/index.ts +5 -0
- package/ui/components/atoms/vc-loading/vc-loading-model.ts +15 -0
- package/ui/components/atoms/vc-loading/vc-loading.vue +5 -11
- package/ui/components/atoms/vc-progress/index.ts +5 -0
- package/ui/components/atoms/vc-progress/vc-progress-model.ts +19 -0
- package/ui/components/atoms/vc-progress/vc-progress.vue +5 -20
- package/ui/components/atoms/vc-row/index.ts +2 -0
- package/ui/components/atoms/vc-row/vc-row-model.ts +5 -0
- package/ui/components/atoms/vc-status/index.ts +5 -0
- package/ui/components/atoms/vc-status/vc-status-model.ts +23 -0
- package/ui/components/atoms/vc-status/vc-status.vue +3 -21
- package/ui/components/atoms/vc-status-icon/index.ts +5 -0
- package/ui/components/atoms/vc-status-icon/vc-status-icon-model.ts +15 -0
- package/ui/components/atoms/vc-status-icon/vc-status-icon.vue +11 -9
- package/ui/components/atoms/vc-switch/index.ts +7 -0
- package/ui/components/atoms/vc-switch/vc-switch-model.ts +34 -0
- package/ui/components/atoms/vc-switch/vc-switch.vue +12 -28
- package/ui/components/atoms/vc-widget/index.ts +7 -0
- package/ui/components/atoms/vc-widget/vc-widget-model.ts +23 -0
- package/ui/components/atoms/vc-widget/vc-widget.vue +15 -22
- package/ui/components/index.ts +34 -34
- package/ui/components/molecules/vc-breadcrumbs/_internal/vc-breadcrumbs-item/vc-breadcrumbs-item.vue +1 -1
- package/ui/components/molecules/vc-breadcrumbs/index.ts +5 -0
- package/ui/components/molecules/vc-breadcrumbs/vc-breadcrumbs-model.ts +23 -0
- package/ui/components/molecules/vc-breadcrumbs/vc-breadcrumbs.vue +6 -14
- package/ui/components/molecules/vc-editor/index.ts +7 -0
- package/ui/components/molecules/vc-editor/vc-editor-model.ts +37 -0
- package/ui/components/molecules/vc-editor/vc-editor.vue +25 -56
- package/ui/components/molecules/vc-file-upload/index.ts +8 -0
- package/ui/components/molecules/vc-file-upload/vc-file-upload-model.ts +37 -0
- package/ui/components/molecules/vc-file-upload/vc-file-upload.vue +11 -36
- package/ui/components/molecules/vc-form/index.ts +2 -0
- package/ui/components/molecules/vc-form/vc-form-model.ts +5 -0
- package/ui/components/molecules/vc-input/index.ts +5 -6
- package/ui/components/molecules/vc-input/vc-input-model.ts +53 -35
- package/ui/components/molecules/vc-input/vc-input.vue +41 -29
- package/ui/components/molecules/vc-input-currency/index.ts +4 -3
- package/ui/components/molecules/vc-input-currency/vc-input-currency-model.ts +42 -32
- package/ui/components/molecules/vc-input-currency/vc-input-currency.vue +12 -7
- package/ui/components/molecules/vc-notification/index.ts +8 -0
- package/ui/components/molecules/vc-notification/vc-notification-model.ts +21 -0
- package/ui/components/molecules/vc-notification/vc-notification.vue +4 -13
- package/ui/components/molecules/vc-pagination/index.ts +8 -0
- package/ui/components/molecules/vc-pagination/vc-pagination-model.ts +29 -0
- package/ui/components/molecules/vc-pagination/vc-pagination.vue +21 -23
- package/ui/components/molecules/vc-rating/index.ts +5 -0
- package/ui/components/molecules/vc-rating/vc-rating-model.ts +23 -0
- package/ui/components/molecules/vc-rating/vc-rating.vue +11 -13
- package/ui/components/molecules/vc-select/index.ts +5 -5
- package/ui/components/molecules/vc-select/vc-select-model.ts +74 -44
- package/ui/components/molecules/vc-select/vc-select.vue +128 -173
- package/ui/components/molecules/vc-slider/index.ts +5 -0
- package/ui/components/molecules/vc-slider/vc-slider-model.ts +34 -0
- package/ui/components/molecules/vc-slider/vc-slider.vue +2 -26
- package/ui/components/molecules/vc-textarea/index.ts +8 -0
- package/ui/components/molecules/vc-textarea/vc-textarea-model.ts +41 -0
- package/ui/components/molecules/vc-textarea/vc-textarea.vue +19 -53
- package/ui/components/organisms/vc-app/_internal/vc-app-bar/vc-app-bar.vue +16 -12
- package/ui/components/organisms/vc-app/_internal/vc-app-menu/_internal/vc-app-menu-item/_internal/vc-app-menu-link.vue +13 -4
- package/ui/components/organisms/vc-app/_internal/vc-app-menu/_internal/vc-app-menu-item/vc-app-menu-item.vue +18 -15
- package/ui/components/organisms/vc-app/_internal/vc-app-menu/vc-app-menu.vue +11 -5
- package/ui/components/organisms/vc-app/index.ts +6 -0
- package/ui/components/organisms/vc-app/vc-app-model.ts +65 -0
- package/ui/components/organisms/vc-app/vc-app.vue +10 -52
- package/ui/components/organisms/vc-blade/_internal/vc-blade-header/vc-blade-header.vue +40 -40
- package/ui/components/organisms/vc-blade/_internal/vc-blade-toolbar/_internal/vc-blade-toolbar-button/vc-blade-toolbar-button.vue +20 -14
- package/ui/components/organisms/vc-blade/_internal/vc-blade-toolbar/vc-blade-toolbar.vue +14 -12
- package/ui/components/organisms/vc-blade/index.ts +7 -0
- package/ui/components/organisms/vc-blade/vc-blade-model.ts +37 -0
- package/ui/components/organisms/vc-blade/vc-blade.stories.ts +1 -2
- package/ui/components/organisms/vc-blade/vc-blade.vue +13 -40
- package/ui/components/organisms/vc-dynamic-property/index.ts +5 -0
- package/ui/components/organisms/vc-dynamic-property/vc-dynamic-property-model.ts +58 -0
- package/ui/components/organisms/vc-dynamic-property/vc-dynamic-property.vue +101 -125
- package/ui/components/organisms/vc-gallery/_internal/vc-gallery-item/vc-gallery-item.vue +41 -24
- package/ui/components/organisms/vc-gallery/_internal/vc-gallery-preview/vc-gallery-preview.vue +16 -11
- package/ui/components/organisms/vc-gallery/index.ts +8 -0
- package/ui/components/organisms/vc-gallery/vc-gallery-model.ts +78 -0
- package/ui/components/organisms/vc-gallery/vc-gallery.vue +11 -88
- package/ui/components/organisms/vc-login-form/index.ts +5 -0
- package/ui/components/organisms/vc-login-form/vc-login-form-model.ts +16 -0
- package/ui/components/organisms/vc-login-form/vc-login-form.vue +2 -15
- package/ui/components/organisms/vc-popup/index.ts +7 -0
- package/ui/components/organisms/vc-popup/vc-popup-model.ts +25 -0
- package/ui/components/organisms/vc-popup/vc-popup.vue +7 -18
- package/ui/components/organisms/vc-table/_internal/vc-table-cell/vc-table-cell.vue +21 -27
- package/ui/components/organisms/vc-table/_internal/vc-table-counter/vc-table-counter.vue +2 -6
- package/ui/components/organisms/vc-table/_internal/vc-table-filter/vc-table-filter.vue +9 -3
- package/ui/components/organisms/vc-table/_internal/vc-table-mobile-item/vc-table-mobile-item.vue +31 -43
- package/ui/components/organisms/vc-table/index.ts +7 -0
- package/ui/components/organisms/vc-table/vc-table-model.ts +116 -0
- package/ui/components/organisms/vc-table/vc-table.vue +108 -139
- package/ui/types/index.ts +106 -15
- package/ui/types/ts-helpers.ts +23 -3
- package/ui/utils/index.ts +1 -0
- package/ui/utils/types.ts +2 -0
- package/core/composables/useLogger/index.ts +0 -24
- package/dist/core/composables/useLogger/index.d.ts +0 -5
- package/dist/core/composables/useLogger/index.d.ts.map +0 -1
|
@@ -12,9 +12,17 @@
|
|
|
12
12
|
]"
|
|
13
13
|
>
|
|
14
14
|
<!-- Input label -->
|
|
15
|
-
<VcLabel
|
|
15
|
+
<VcLabel
|
|
16
|
+
v-if="label"
|
|
17
|
+
class="tw-mb-2"
|
|
18
|
+
:required="required"
|
|
19
|
+
>
|
|
16
20
|
<span>{{ label }}</span>
|
|
17
|
-
<template
|
|
21
|
+
<template
|
|
22
|
+
v-if="tooltip"
|
|
23
|
+
v-slot:tooltip
|
|
24
|
+
>{{ tooltip }}</template
|
|
25
|
+
>
|
|
18
26
|
</VcLabel>
|
|
19
27
|
|
|
20
28
|
<div class="tw-flex tw-flex-nowrap tw-items-start">
|
|
@@ -25,9 +33,7 @@
|
|
|
25
33
|
>
|
|
26
34
|
<slot name="prepend"></slot>
|
|
27
35
|
</div>
|
|
28
|
-
<div
|
|
29
|
-
class="tw-flex tw-flex-col tw-flex-nowrap tw-flex-auto tw-relative"
|
|
30
|
-
>
|
|
36
|
+
<div class="tw-flex tw-flex-col tw-flex-nowrap tw-flex-auto tw-relative">
|
|
31
37
|
<div class="vc-input__field-wrapper">
|
|
32
38
|
<div class="tw-flex tw-flex-nowrap tw-flex-auto tw-h-full">
|
|
33
39
|
<div
|
|
@@ -72,13 +78,14 @@
|
|
|
72
78
|
{{ suffix }}
|
|
73
79
|
</div>
|
|
74
80
|
<div
|
|
75
|
-
v-if="
|
|
76
|
-
clearable && modelValue && !disabled && type !== 'password'
|
|
77
|
-
"
|
|
81
|
+
v-if="clearable && modelValue && !disabled && type !== 'password'"
|
|
78
82
|
class="vc-input__clear"
|
|
79
83
|
@click="onReset"
|
|
80
84
|
>
|
|
81
|
-
<VcIcon
|
|
85
|
+
<VcIcon
|
|
86
|
+
size="s"
|
|
87
|
+
icon="fas fa-times"
|
|
88
|
+
></VcIcon>
|
|
82
89
|
</div>
|
|
83
90
|
|
|
84
91
|
<div
|
|
@@ -86,7 +93,10 @@
|
|
|
86
93
|
v-if="type === 'password' && internalType === 'password'"
|
|
87
94
|
@click="internalType = 'text'"
|
|
88
95
|
>
|
|
89
|
-
<VcIcon
|
|
96
|
+
<VcIcon
|
|
97
|
+
size="s"
|
|
98
|
+
icon="fas fa-eye-slash"
|
|
99
|
+
></VcIcon>
|
|
90
100
|
</div>
|
|
91
101
|
|
|
92
102
|
<div
|
|
@@ -94,7 +104,10 @@
|
|
|
94
104
|
v-if="type === 'password' && internalType === 'text'"
|
|
95
105
|
@click="internalType = 'password'"
|
|
96
106
|
>
|
|
97
|
-
<VcIcon
|
|
107
|
+
<VcIcon
|
|
108
|
+
size="s"
|
|
109
|
+
icon="fas fa-eye"
|
|
110
|
+
></VcIcon>
|
|
98
111
|
</div>
|
|
99
112
|
</div>
|
|
100
113
|
|
|
@@ -116,20 +129,27 @@
|
|
|
116
129
|
</div>
|
|
117
130
|
</div>
|
|
118
131
|
</div>
|
|
119
|
-
<div
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
132
|
+
<div class="tw-absolute tw-translate-y-full tw-left-0 tw-right-0 tw-bottom-0 tw-min-h-[20px]">
|
|
133
|
+
<Transition
|
|
134
|
+
name="slide-up"
|
|
135
|
+
mode="out-in"
|
|
136
|
+
>
|
|
123
137
|
<div v-if="error">
|
|
124
138
|
<slot name="error">
|
|
125
|
-
<VcHint
|
|
139
|
+
<VcHint
|
|
140
|
+
class="vc-input__error"
|
|
141
|
+
v-if="errorMessage"
|
|
142
|
+
>
|
|
126
143
|
{{ errorMessage }}
|
|
127
144
|
</VcHint>
|
|
128
145
|
</slot>
|
|
129
146
|
</div>
|
|
130
147
|
<div v-else>
|
|
131
148
|
<slot name="hint">
|
|
132
|
-
<VcHint
|
|
149
|
+
<VcHint
|
|
150
|
+
class="vc-input__desc"
|
|
151
|
+
v-if="hint"
|
|
152
|
+
>
|
|
133
153
|
{{ hint }}
|
|
134
154
|
</VcHint>
|
|
135
155
|
</slot>
|
|
@@ -151,19 +171,11 @@
|
|
|
151
171
|
|
|
152
172
|
<script lang="ts" setup>
|
|
153
173
|
import { computed, ref, unref, watch } from "vue";
|
|
154
|
-
import {
|
|
174
|
+
import { inputEmits, inputProps } from "./vc-input-model";
|
|
155
175
|
|
|
156
|
-
const props =
|
|
157
|
-
modelValue: null,
|
|
158
|
-
clearable: false,
|
|
159
|
-
required: false,
|
|
160
|
-
disabled: false,
|
|
161
|
-
type: "text",
|
|
162
|
-
name: "Field",
|
|
163
|
-
maxlength: "1024",
|
|
164
|
-
});
|
|
176
|
+
const props = defineProps(inputProps);
|
|
165
177
|
|
|
166
|
-
const emit = defineEmits(
|
|
178
|
+
const emit = defineEmits(inputEmits);
|
|
167
179
|
|
|
168
180
|
let emitTimer;
|
|
169
181
|
let emitValueFn;
|
|
@@ -194,7 +206,7 @@ function onInput(e: Event) {
|
|
|
194
206
|
emitValue(newValue);
|
|
195
207
|
}
|
|
196
208
|
|
|
197
|
-
function emitValue(val) {
|
|
209
|
+
function emitValue(val: string) {
|
|
198
210
|
emitValueFn = () => {
|
|
199
211
|
if (props.modelValue !== val) {
|
|
200
212
|
emit("update:modelValue", val);
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { ComponentPublicInstance } from "vue";
|
|
2
|
-
import { VcInputCurrencyProps } from "./vc-input-currency-model";
|
|
3
|
-
import { ComponentConstructor } from "
|
|
2
|
+
import { VcInputCurrencyEmits, VcInputCurrencyProps } from "./vc-input-currency-model";
|
|
3
|
+
import { ComponentConstructor } from "./../../../types/ts-helpers";
|
|
4
4
|
import InputCurrency from "./vc-input-currency.vue";
|
|
5
5
|
|
|
6
6
|
export const VcInputCurrency: ComponentConstructor<
|
|
7
|
-
|
|
7
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
8
|
+
ComponentPublicInstance<VcInputCurrencyProps, any, any, any, any, VcInputCurrencyEmits>
|
|
8
9
|
> = InputCurrency;
|
|
@@ -1,114 +1,124 @@
|
|
|
1
|
-
import { VNode } from "vue";
|
|
1
|
+
import { PropType, VNode } from "vue";
|
|
2
|
+
import { ExtractTypes } from "./../../../types/ts-helpers";
|
|
3
|
+
import { isString, isNumber } from "./../../../utils";
|
|
2
4
|
|
|
3
|
-
export type OptionProp =
|
|
4
|
-
| ((option: string | Record<string, unknown>) => string)
|
|
5
|
-
| string
|
|
6
|
-
| undefined;
|
|
5
|
+
export type OptionProp = ((option: string | Record<string, unknown>) => string) | string | undefined;
|
|
7
6
|
|
|
8
|
-
export
|
|
7
|
+
export const inputCurrencyProps = {
|
|
9
8
|
/**
|
|
10
9
|
* Model of the currency component; Use with a listener for 'update:price' event OR use v-model:price directive
|
|
11
10
|
*/
|
|
12
|
-
modelValue
|
|
11
|
+
modelValue: [String, Number, Date],
|
|
13
12
|
/**
|
|
14
13
|
* Input label text
|
|
15
14
|
*/
|
|
16
|
-
label
|
|
15
|
+
label: String,
|
|
17
16
|
/**
|
|
18
17
|
* Input placeholder text
|
|
19
18
|
*/
|
|
20
|
-
placeholder
|
|
19
|
+
placeholder: String,
|
|
21
20
|
/**
|
|
22
21
|
* Input description (hint) text below input component
|
|
23
22
|
*/
|
|
24
|
-
hint
|
|
23
|
+
hint: String,
|
|
25
24
|
/**
|
|
26
25
|
* Appends clearable icon when a value is set;
|
|
27
26
|
* When clicked, model becomes null
|
|
28
27
|
*/
|
|
29
|
-
clearable
|
|
28
|
+
clearable: Boolean,
|
|
30
29
|
/**
|
|
31
30
|
* Prefix
|
|
32
31
|
*/
|
|
33
|
-
prefix
|
|
32
|
+
prefix: String,
|
|
34
33
|
/**
|
|
35
34
|
* Suffix
|
|
36
35
|
*/
|
|
37
|
-
suffix
|
|
36
|
+
suffix: String,
|
|
38
37
|
/**
|
|
39
38
|
* Used to specify the name of the control; If not specified, it takes the value 'Field'
|
|
40
39
|
*/
|
|
41
|
-
name
|
|
40
|
+
name: String,
|
|
42
41
|
/**
|
|
43
42
|
* Signals the user a process is in progress by displaying a spinner
|
|
44
43
|
*/
|
|
45
|
-
loading
|
|
44
|
+
loading: Boolean,
|
|
46
45
|
/**
|
|
47
46
|
* Debounce amount (in milliseconds) for search input
|
|
48
47
|
* Default: 0
|
|
49
48
|
*/
|
|
50
|
-
debounce
|
|
49
|
+
debounce: {
|
|
50
|
+
type: [String, Number],
|
|
51
|
+
default: 0,
|
|
52
|
+
},
|
|
51
53
|
/**
|
|
52
54
|
* Put component in disabled mode
|
|
53
55
|
*/
|
|
54
|
-
disabled
|
|
56
|
+
disabled: Boolean,
|
|
55
57
|
/**
|
|
56
58
|
* Focus field on initial component render
|
|
57
59
|
*/
|
|
58
|
-
autofocus
|
|
60
|
+
autofocus: Boolean,
|
|
59
61
|
/**
|
|
60
62
|
* Does field have validation errors?
|
|
61
63
|
*/
|
|
62
|
-
error
|
|
64
|
+
error: Boolean,
|
|
63
65
|
/**
|
|
64
66
|
* Validation error message (gets displayed only if 'error' is set to 'true')
|
|
65
67
|
*/
|
|
66
|
-
errorMessage
|
|
68
|
+
errorMessage: String,
|
|
67
69
|
/**
|
|
68
70
|
* Specify a max length of model
|
|
69
71
|
* Default value: 1024
|
|
70
72
|
*/
|
|
71
|
-
maxlength
|
|
73
|
+
maxlength: [String, Number],
|
|
72
74
|
/**
|
|
73
75
|
* Input tooltip information
|
|
74
76
|
*/
|
|
75
|
-
tooltip
|
|
77
|
+
tooltip: String,
|
|
76
78
|
/**
|
|
77
79
|
* Input required state
|
|
78
80
|
*/
|
|
79
|
-
required
|
|
81
|
+
required: Boolean,
|
|
80
82
|
/**
|
|
81
83
|
* Option label
|
|
82
84
|
*/
|
|
83
|
-
option
|
|
85
|
+
option: String,
|
|
84
86
|
/**
|
|
85
87
|
* Available options that the user can select from.
|
|
86
88
|
* Default value: []
|
|
87
89
|
*/
|
|
88
|
-
|
|
90
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
91
|
+
options: Array as PropType<any[]>,
|
|
89
92
|
/**
|
|
90
93
|
* Property of option which holds the 'value'
|
|
91
94
|
* Default value: id
|
|
92
95
|
* @param option The current option being processed
|
|
93
96
|
* @returns Value of the current option
|
|
94
97
|
*/
|
|
95
|
-
optionValue
|
|
98
|
+
optionValue: [Function, String] as PropType<OptionProp>,
|
|
96
99
|
/**
|
|
97
100
|
* Property of option which holds the 'label'
|
|
98
101
|
* Default value: title
|
|
99
102
|
* @param option The current option being processed
|
|
100
103
|
* @returns Label of the current option
|
|
101
104
|
*/
|
|
102
|
-
optionLabel
|
|
105
|
+
optionLabel: [Function, String] as PropType<OptionProp>,
|
|
106
|
+
};
|
|
107
|
+
|
|
108
|
+
export const inputCurrencyEmits = {
|
|
103
109
|
/**
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
"
|
|
110
|
+
* Emitted when the component needs to change the model; Is also used by v-model
|
|
111
|
+
*/
|
|
112
|
+
"update:modelValue": (value: string | number | null) => isString(value) || isNumber(value) || value === null,
|
|
107
113
|
/**
|
|
108
114
|
* Emitted when the component needs to change the options model; Is also used by v-model:option
|
|
109
115
|
*/
|
|
110
|
-
"
|
|
111
|
-
}
|
|
116
|
+
"update:option": (value: string | number | null) => isString(value) || isNumber(value) || value === null,
|
|
117
|
+
};
|
|
118
|
+
|
|
119
|
+
export type VcInputCurrencyProps = ExtractTypes<typeof inputCurrencyProps>;
|
|
120
|
+
export type VcInputCurrencyEmits = typeof inputCurrencyEmits;
|
|
121
|
+
|
|
112
122
|
export interface VcInputCurrencySlots {
|
|
113
123
|
/**
|
|
114
124
|
* Slot for custom dropdown open handler
|
|
@@ -31,7 +31,10 @@
|
|
|
31
31
|
@update:modelValue="$emit('update:modelValue', +$event)"
|
|
32
32
|
>
|
|
33
33
|
<template v-slot:append-inner>
|
|
34
|
-
<slot
|
|
34
|
+
<slot
|
|
35
|
+
name="button"
|
|
36
|
+
:toggleHandler="toggleHandler"
|
|
37
|
+
>
|
|
35
38
|
<button
|
|
36
39
|
class="tw-text-[#43b0e6] tw-not-italic tw-font-medium tw-text-[13px] tw-leading-[20px] tw-cursor-pointer"
|
|
37
40
|
@click.stop.prevent="toggleHandler"
|
|
@@ -41,7 +44,11 @@
|
|
|
41
44
|
</slot>
|
|
42
45
|
</template>
|
|
43
46
|
<template v-slot:control="{ placeholder }">
|
|
44
|
-
<input
|
|
47
|
+
<input
|
|
48
|
+
type="text"
|
|
49
|
+
ref="inputRef"
|
|
50
|
+
:placeholder="placeholder"
|
|
51
|
+
/>
|
|
45
52
|
</template>
|
|
46
53
|
</VcInput>
|
|
47
54
|
</template>
|
|
@@ -49,15 +56,13 @@
|
|
|
49
56
|
</template>
|
|
50
57
|
|
|
51
58
|
<script lang="ts" setup>
|
|
52
|
-
import {
|
|
59
|
+
import { inputCurrencyEmits, inputCurrencyProps } from "./vc-input-currency-model";
|
|
53
60
|
import { useCurrencyInput, CurrencyDisplay } from "vue-currency-input";
|
|
54
61
|
import { watch } from "vue";
|
|
55
62
|
|
|
56
|
-
const props =
|
|
57
|
-
debounce: 0,
|
|
58
|
-
});
|
|
63
|
+
const props = defineProps(inputCurrencyProps);
|
|
59
64
|
|
|
60
|
-
defineEmits(
|
|
65
|
+
defineEmits(inputCurrencyEmits);
|
|
61
66
|
|
|
62
67
|
const { inputRef, setOptions } = useCurrencyInput({
|
|
63
68
|
locale: navigator.language,
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { ComponentPublicInstance } from "vue";
|
|
2
|
+
import { VcNotificationEmits, VcNotificationProps } from "./vc-notification-model";
|
|
3
|
+
import { ComponentConstructor } from "./../../../types/ts-helpers";
|
|
4
|
+
import Notification from "./vc-notification.vue";
|
|
5
|
+
export const VcNotification: ComponentConstructor<
|
|
6
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
7
|
+
ComponentPublicInstance<VcNotificationProps, any, any, any, any, VcNotificationEmits>
|
|
8
|
+
> = Notification;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { VNode } from "vue";
|
|
2
|
+
import { ExtractTypes } from "./../../../types/ts-helpers";
|
|
3
|
+
|
|
4
|
+
export const notificationProps = {
|
|
5
|
+
timeout: {
|
|
6
|
+
type: Number,
|
|
7
|
+
default: 0,
|
|
8
|
+
},
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
export const notificationEmits = {
|
|
12
|
+
dismiss: () => true,
|
|
13
|
+
expired: () => true,
|
|
14
|
+
};
|
|
15
|
+
|
|
16
|
+
export type VcNotificationProps = ExtractTypes<typeof notificationProps>;
|
|
17
|
+
export type VcNotificationEmits = typeof notificationEmits;
|
|
18
|
+
|
|
19
|
+
export interface VcNotificationSlots {
|
|
20
|
+
default: () => VNode[];
|
|
21
|
+
}
|
|
@@ -17,21 +17,12 @@
|
|
|
17
17
|
</template>
|
|
18
18
|
|
|
19
19
|
<script lang="ts" setup>
|
|
20
|
-
import { VcIcon } from "
|
|
20
|
+
import { VcIcon } from "./../../../components";
|
|
21
|
+
import { notificationEmits, notificationProps } from "./vc-notification-model";
|
|
21
22
|
|
|
22
|
-
const props = defineProps(
|
|
23
|
-
variant: {
|
|
24
|
-
type: String,
|
|
25
|
-
default: "info",
|
|
26
|
-
},
|
|
23
|
+
const props = defineProps(notificationProps);
|
|
27
24
|
|
|
28
|
-
|
|
29
|
-
type: Number,
|
|
30
|
-
default: 0,
|
|
31
|
-
},
|
|
32
|
-
});
|
|
33
|
-
|
|
34
|
-
const emit = defineEmits(["dismiss", "expired"]);
|
|
25
|
+
const emit = defineEmits(notificationEmits);
|
|
35
26
|
|
|
36
27
|
function Timer(callback: (...args: unknown[]) => unknown, delay: number) {
|
|
37
28
|
let timerId: number;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { ComponentPublicInstance } from "vue";
|
|
2
|
+
import { VcPaginationEmits, VcPaginationProps } from "./vc-pagination-model";
|
|
3
|
+
import { ComponentConstructor } from "./../../../types/ts-helpers";
|
|
4
|
+
import Pagination from "./vc-pagination.vue";
|
|
5
|
+
export const VcPagination: ComponentConstructor<
|
|
6
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
7
|
+
ComponentPublicInstance<VcPaginationProps, any, any, any, any, VcPaginationEmits>
|
|
8
|
+
> = Pagination;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { VNode } from "vue";
|
|
2
|
+
import { ExtractTypes } from "./../../../types/ts-helpers";
|
|
3
|
+
import { isNumber } from "./../../../utils";
|
|
4
|
+
|
|
5
|
+
export const paginationProps = {
|
|
6
|
+
expanded: {
|
|
7
|
+
type: Boolean,
|
|
8
|
+
default: false,
|
|
9
|
+
},
|
|
10
|
+
pages: {
|
|
11
|
+
type: Number,
|
|
12
|
+
default: 1,
|
|
13
|
+
},
|
|
14
|
+
currentPage: {
|
|
15
|
+
type: Number,
|
|
16
|
+
default: 1,
|
|
17
|
+
},
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
export const paginationEmits = {
|
|
21
|
+
itemClick: (pages: number) => isNumber(pages),
|
|
22
|
+
};
|
|
23
|
+
|
|
24
|
+
export type VcPaginationProps = ExtractTypes<typeof paginationProps>;
|
|
25
|
+
export type VcPaginationEmits = typeof paginationEmits;
|
|
26
|
+
|
|
27
|
+
export interface VcPaginationSlots {
|
|
28
|
+
default: () => VNode[];
|
|
29
|
+
}
|
|
@@ -8,7 +8,10 @@
|
|
|
8
8
|
}"
|
|
9
9
|
@click="currentPage !== 1 && $emit('itemClick', 1)"
|
|
10
10
|
>
|
|
11
|
-
<VcIcon
|
|
11
|
+
<VcIcon
|
|
12
|
+
size="xs"
|
|
13
|
+
icon="fas fa-angle-double-left"
|
|
14
|
+
></VcIcon>
|
|
12
15
|
</div>
|
|
13
16
|
|
|
14
17
|
<!-- To previous page arrow -->
|
|
@@ -19,7 +22,10 @@
|
|
|
19
22
|
}"
|
|
20
23
|
@click="currentPage !== 1 && $emit('itemClick', currentPage - 1)"
|
|
21
24
|
>
|
|
22
|
-
<VcIcon
|
|
25
|
+
<VcIcon
|
|
26
|
+
size="xs"
|
|
27
|
+
icon="fas fa-arrow-left"
|
|
28
|
+
></VcIcon>
|
|
23
29
|
</div>
|
|
24
30
|
|
|
25
31
|
<template v-if="expanded && $isDesktop.value">
|
|
@@ -75,7 +81,10 @@
|
|
|
75
81
|
}"
|
|
76
82
|
@click="currentPage !== pages && $emit('itemClick', currentPage + 1)"
|
|
77
83
|
>
|
|
78
|
-
<VcIcon
|
|
84
|
+
<VcIcon
|
|
85
|
+
size="xs"
|
|
86
|
+
icon="fas fa-arrow-right"
|
|
87
|
+
></VcIcon>
|
|
79
88
|
</div>
|
|
80
89
|
|
|
81
90
|
<!-- To last page chevron -->
|
|
@@ -86,32 +95,21 @@
|
|
|
86
95
|
}"
|
|
87
96
|
@click="currentPage !== pages && $emit('itemClick', pages)"
|
|
88
97
|
>
|
|
89
|
-
<VcIcon
|
|
98
|
+
<VcIcon
|
|
99
|
+
size="xs"
|
|
100
|
+
icon="fas fa-angle-double-right"
|
|
101
|
+
></VcIcon>
|
|
90
102
|
</div>
|
|
91
103
|
</div>
|
|
92
104
|
</template>
|
|
93
105
|
|
|
94
106
|
<script lang="ts" setup>
|
|
95
|
-
import { VcIcon } from "
|
|
107
|
+
import { VcIcon } from "./../../../components";
|
|
108
|
+
import { paginationEmits, paginationProps } from "./vc-pagination-model";
|
|
96
109
|
|
|
97
|
-
defineProps(
|
|
98
|
-
expanded: {
|
|
99
|
-
type: Boolean,
|
|
100
|
-
default: false,
|
|
101
|
-
},
|
|
110
|
+
defineProps(paginationProps);
|
|
102
111
|
|
|
103
|
-
|
|
104
|
-
type: Number,
|
|
105
|
-
default: 1,
|
|
106
|
-
},
|
|
107
|
-
|
|
108
|
-
currentPage: {
|
|
109
|
-
type: Number,
|
|
110
|
-
default: 1,
|
|
111
|
-
},
|
|
112
|
-
});
|
|
113
|
-
|
|
114
|
-
defineEmits(["itemClick"]);
|
|
112
|
+
defineEmits(paginationEmits);
|
|
115
113
|
</script>
|
|
116
114
|
|
|
117
115
|
<style lang="scss">
|
|
@@ -119,7 +117,7 @@ defineEmits(["itemClick"]);
|
|
|
119
117
|
--pagination-item-width: 30px;
|
|
120
118
|
--pagination-item-height: 30px;
|
|
121
119
|
--pagination-item-color: #000000;
|
|
122
|
-
--pagination-item-color-hover:
|
|
120
|
+
--pagination-item-color-hover: #000000;
|
|
123
121
|
--pagination-item-color-current: #ffffff;
|
|
124
122
|
--pagination-item-color-disabled: #9c9c9c;
|
|
125
123
|
--pagination-item-background-color: #ffffff;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { ComponentPublicInstance } from "vue";
|
|
2
|
+
import { VcRatingProps } from "./vc-rating-model";
|
|
3
|
+
import { ComponentConstructor } from "./../../../types/ts-helpers";
|
|
4
|
+
import Rating from "./vc-rating.vue";
|
|
5
|
+
export const VcRating: ComponentConstructor<ComponentPublicInstance<VcRatingProps>> = Rating;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { PropType, VNode } from "vue";
|
|
2
|
+
import { ExtractTypes } from "./../../../types/ts-helpers";
|
|
3
|
+
|
|
4
|
+
export const ratingProps = {
|
|
5
|
+
label: String,
|
|
6
|
+
placeholder: String,
|
|
7
|
+
tooltip: String,
|
|
8
|
+
rating: Number,
|
|
9
|
+
max: {
|
|
10
|
+
type: Number,
|
|
11
|
+
default: 5,
|
|
12
|
+
},
|
|
13
|
+
variant: {
|
|
14
|
+
type: String as PropType<"stars" | "star-and-text" | "text">,
|
|
15
|
+
default: "stars",
|
|
16
|
+
},
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
export type VcRatingProps = ExtractTypes<typeof ratingProps>;
|
|
20
|
+
|
|
21
|
+
export interface VcRatingSlots {
|
|
22
|
+
details: () => VNode[];
|
|
23
|
+
}
|
|
@@ -1,9 +1,15 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div class="vc-rating">
|
|
3
3
|
<!-- Rating label -->
|
|
4
|
-
<VcLabel
|
|
4
|
+
<VcLabel
|
|
5
|
+
v-if="label"
|
|
6
|
+
class="tw-mb-2"
|
|
7
|
+
>
|
|
5
8
|
<span>{{ label }}</span>
|
|
6
|
-
<template
|
|
9
|
+
<template
|
|
10
|
+
v-if="tooltip"
|
|
11
|
+
v-slot:tooltip
|
|
12
|
+
>
|
|
7
13
|
<span v-html="tooltip"></span>
|
|
8
14
|
</template>
|
|
9
15
|
</VcLabel>
|
|
@@ -41,18 +47,10 @@
|
|
|
41
47
|
</template>
|
|
42
48
|
|
|
43
49
|
<script lang="ts" setup>
|
|
44
|
-
import { VcIcon, VcLabel } from "
|
|
50
|
+
import { VcIcon, VcLabel } from "./../../../components";
|
|
51
|
+
import { ratingProps } from "./vc-rating-model";
|
|
45
52
|
|
|
46
|
-
|
|
47
|
-
label?: string;
|
|
48
|
-
placeholder?: string;
|
|
49
|
-
tooltip?: string;
|
|
50
|
-
rating: number | undefined;
|
|
51
|
-
max?: number;
|
|
52
|
-
variant?: "stars" | "star-and-text" | "text";
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
withDefaults(defineProps<Props>(), { max: 5, variant: "stars" });
|
|
53
|
+
defineProps(ratingProps);
|
|
56
54
|
</script>
|
|
57
55
|
|
|
58
56
|
<style lang="scss">
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { ComponentPublicInstance } from "vue";
|
|
2
|
-
import { VcSelectProps } from "./vc-select-model";
|
|
3
|
-
import { ComponentConstructor } from "
|
|
2
|
+
import { VcSelectProps, VcSelectEmits } from "./vc-select-model";
|
|
3
|
+
import { ComponentConstructor } from "./../../../types/ts-helpers";
|
|
4
4
|
import Select from "./vc-select.vue";
|
|
5
5
|
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
6
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
7
|
+
export const VcSelect: ComponentConstructor<ComponentPublicInstance<VcSelectProps, any, any, any, any, VcSelectEmits>> =
|
|
8
|
+
Select;
|