@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
|
@@ -18,54 +18,25 @@
|
|
|
18
18
|
:icon="icon"
|
|
19
19
|
:size="small ? 'xs' : 's'"
|
|
20
20
|
></VcIcon>
|
|
21
|
-
<span
|
|
21
|
+
<span
|
|
22
|
+
v-if="$slots['default']"
|
|
23
|
+
class="vc-button__title"
|
|
24
|
+
>
|
|
22
25
|
<slot></slot>
|
|
23
26
|
</span>
|
|
24
27
|
</button>
|
|
25
28
|
</template>
|
|
26
29
|
|
|
27
30
|
<script lang="ts" setup>
|
|
28
|
-
import { VcIcon } from "
|
|
29
|
-
|
|
30
|
-
const props = defineProps({
|
|
31
|
-
icon: {
|
|
32
|
-
type: String,
|
|
33
|
-
default: undefined,
|
|
34
|
-
},
|
|
35
|
-
|
|
36
|
-
variant: {
|
|
37
|
-
type: String,
|
|
38
|
-
enum: ["primary", "secondary", "special", "danger", "widget", "onlytext"],
|
|
39
|
-
default: "primary",
|
|
40
|
-
},
|
|
41
|
-
|
|
42
|
-
disabled: {
|
|
43
|
-
type: Boolean,
|
|
44
|
-
default: false,
|
|
45
|
-
},
|
|
46
|
-
|
|
47
|
-
small: {
|
|
48
|
-
type: Boolean,
|
|
49
|
-
default: false,
|
|
50
|
-
},
|
|
51
|
-
|
|
52
|
-
outline: {
|
|
53
|
-
type: Boolean,
|
|
54
|
-
default: false,
|
|
55
|
-
},
|
|
56
|
-
|
|
57
|
-
selected: {
|
|
58
|
-
type: Boolean,
|
|
59
|
-
default: false,
|
|
60
|
-
},
|
|
61
|
-
});
|
|
62
|
-
|
|
63
|
-
const emit = defineEmits(["click"]);
|
|
31
|
+
import { VcIcon } from "./../../../components";
|
|
32
|
+
import { buttonProps, buttonEmits } from "./vc-button-model";
|
|
64
33
|
|
|
34
|
+
const props = defineProps(buttonProps);
|
|
35
|
+
const emit = defineEmits(buttonEmits);
|
|
65
36
|
function onClick(e: Event): void {
|
|
66
37
|
if (!props.disabled) {
|
|
67
38
|
e.preventDefault();
|
|
68
|
-
emit("click"
|
|
39
|
+
emit("click");
|
|
69
40
|
}
|
|
70
41
|
}
|
|
71
42
|
</script>
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { ComponentPublicInstance } from "vue";
|
|
2
|
+
import { VcCardEmits, VcCardProps } from "./vc-card-model";
|
|
3
|
+
import { ComponentConstructor } from "./../../../types/ts-helpers";
|
|
4
|
+
import Card from "./vc-card.vue";
|
|
5
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
6
|
+
export const VcCard: ComponentConstructor<ComponentPublicInstance<VcCardProps, any, any, any, any, VcCardEmits>> = Card;
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { VNode, PropType } from "vue";
|
|
2
|
+
import { ExtractTypes } from "./../../../types/ts-helpers";
|
|
3
|
+
import { isBoolean } from "./../../../utils";
|
|
4
|
+
|
|
5
|
+
export const cardProps = {
|
|
6
|
+
header: String,
|
|
7
|
+
icon: String,
|
|
8
|
+
isCollapsable: {
|
|
9
|
+
type: Boolean,
|
|
10
|
+
default: false,
|
|
11
|
+
},
|
|
12
|
+
isCollapsed: {
|
|
13
|
+
type: Boolean,
|
|
14
|
+
default: false,
|
|
15
|
+
},
|
|
16
|
+
fill: {
|
|
17
|
+
type: Boolean,
|
|
18
|
+
default: false,
|
|
19
|
+
},
|
|
20
|
+
variant: {
|
|
21
|
+
type: String as PropType<"default" | "success" | "danger">,
|
|
22
|
+
default: "default",
|
|
23
|
+
},
|
|
24
|
+
};
|
|
25
|
+
|
|
26
|
+
export const cardEmits = {
|
|
27
|
+
"header:click": () => true,
|
|
28
|
+
"state:collapsed": (isCollapsedState: boolean) => isBoolean(isCollapsedState),
|
|
29
|
+
};
|
|
30
|
+
|
|
31
|
+
export type VcCardProps = ExtractTypes<typeof cardProps>;
|
|
32
|
+
export type VcCardEmits = typeof cardEmits;
|
|
33
|
+
|
|
34
|
+
export interface VcCardSlots {
|
|
35
|
+
default: () => VNode[];
|
|
36
|
+
actions: () => VNode[];
|
|
37
|
+
}
|
|
@@ -3,10 +3,22 @@
|
|
|
3
3
|
class="vc-card"
|
|
4
4
|
:class="[{ 'vc-card_collapsable': isCollapsable }, `vc-card_${variant}`]"
|
|
5
5
|
>
|
|
6
|
-
<div
|
|
7
|
-
|
|
6
|
+
<div
|
|
7
|
+
class="vc-card__header"
|
|
8
|
+
v-if="header"
|
|
9
|
+
@click="onHeaderClick"
|
|
10
|
+
>
|
|
11
|
+
<VcIcon
|
|
12
|
+
v-if="icon"
|
|
13
|
+
class="vc-card__icon"
|
|
14
|
+
:icon="icon"
|
|
15
|
+
size="xl"
|
|
16
|
+
></VcIcon>
|
|
8
17
|
<div class="vc-card__title">{{ header }}</div>
|
|
9
|
-
<div
|
|
18
|
+
<div
|
|
19
|
+
v-if="$slots['actions']"
|
|
20
|
+
class="vc-card__actions"
|
|
21
|
+
>
|
|
10
22
|
<slot name="actions"></slot>
|
|
11
23
|
</div>
|
|
12
24
|
<VcIcon
|
|
@@ -29,39 +41,11 @@
|
|
|
29
41
|
|
|
30
42
|
<script lang="ts" setup>
|
|
31
43
|
import { ref } from "vue";
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
icon: {
|
|
39
|
-
type: String,
|
|
40
|
-
default: undefined,
|
|
41
|
-
},
|
|
42
|
-
|
|
43
|
-
isCollapsable: {
|
|
44
|
-
type: Boolean,
|
|
45
|
-
default: false,
|
|
46
|
-
},
|
|
47
|
-
|
|
48
|
-
isCollapsed: {
|
|
49
|
-
type: Boolean,
|
|
50
|
-
default: false,
|
|
51
|
-
},
|
|
52
|
-
|
|
53
|
-
fill: {
|
|
54
|
-
type: Boolean,
|
|
55
|
-
default: false,
|
|
56
|
-
},
|
|
57
|
-
|
|
58
|
-
variant: {
|
|
59
|
-
type: String,
|
|
60
|
-
enum: ["default", "success", "danger"],
|
|
61
|
-
default: "default",
|
|
62
|
-
},
|
|
63
|
-
});
|
|
64
|
-
const emit = defineEmits(["header:click", "state:collapsed"]);
|
|
44
|
+
import { cardProps, cardEmits } from "./vc-card-model";
|
|
45
|
+
|
|
46
|
+
const props = defineProps(cardProps);
|
|
47
|
+
|
|
48
|
+
const emit = defineEmits(cardEmits);
|
|
65
49
|
const isCollapsedInternal = ref(props.isCollapsed);
|
|
66
50
|
|
|
67
51
|
function onHeaderClick() {
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { ComponentPublicInstance } from "vue";
|
|
2
|
+
import { VcCheckboxEmits, VcCheckboxProps } from "./vc-checkbox-model";
|
|
3
|
+
import { ComponentConstructor } from "./../../../types/ts-helpers";
|
|
4
|
+
import Checkbox from "./vc-checkbox.vue";
|
|
5
|
+
export const VcCheckbox: ComponentConstructor<
|
|
6
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
7
|
+
ComponentPublicInstance<VcCheckboxProps, any, any, any, any, VcCheckboxEmits>
|
|
8
|
+
> = Checkbox;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { VNode } from "vue";
|
|
2
|
+
import { isBoolean } from "./../../../utils";
|
|
3
|
+
import { ExtractTypes } from "./../../../types/ts-helpers";
|
|
4
|
+
|
|
5
|
+
export const checkboxProps = {
|
|
6
|
+
modelValue: {
|
|
7
|
+
type: Boolean,
|
|
8
|
+
default: false,
|
|
9
|
+
},
|
|
10
|
+
disabled: {
|
|
11
|
+
type: Boolean,
|
|
12
|
+
default: false,
|
|
13
|
+
},
|
|
14
|
+
required: {
|
|
15
|
+
type: Boolean,
|
|
16
|
+
default: false,
|
|
17
|
+
},
|
|
18
|
+
name: {
|
|
19
|
+
type: String,
|
|
20
|
+
default: "Field",
|
|
21
|
+
},
|
|
22
|
+
errorMessage: String,
|
|
23
|
+
};
|
|
24
|
+
|
|
25
|
+
export const checkboxEmits = {
|
|
26
|
+
"update:modelValue": (value: boolean) => isBoolean(value),
|
|
27
|
+
};
|
|
28
|
+
|
|
29
|
+
export type VcCheckboxProps = ExtractTypes<typeof checkboxProps>;
|
|
30
|
+
export type VcCheckboxEmits = typeof checkboxEmits;
|
|
31
|
+
|
|
32
|
+
export interface VcCheckboxSlots {
|
|
33
|
+
default: () => VNode[];
|
|
34
|
+
error: () => VNode[];
|
|
35
|
+
}
|
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<div
|
|
2
|
+
<div
|
|
3
|
+
class="vc-checkbox"
|
|
4
|
+
:class="{ 'vc-checkbox_disabled': disabled }"
|
|
5
|
+
>
|
|
3
6
|
<label class="vc-checkbox__label">
|
|
4
7
|
<input
|
|
5
8
|
type="checkbox"
|
|
@@ -9,7 +12,10 @@
|
|
|
9
12
|
@change="onChange"
|
|
10
13
|
/>
|
|
11
14
|
<span class="vc-checkbox__checkmark"></span>
|
|
12
|
-
<span
|
|
15
|
+
<span
|
|
16
|
+
v-if="$slots['default']"
|
|
17
|
+
class="tw-ml-2"
|
|
18
|
+
>
|
|
13
19
|
<slot></slot>
|
|
14
20
|
</span>
|
|
15
21
|
<span
|
|
@@ -19,7 +25,10 @@
|
|
|
19
25
|
>
|
|
20
26
|
</label>
|
|
21
27
|
|
|
22
|
-
<slot
|
|
28
|
+
<slot
|
|
29
|
+
v-if="errorMessage"
|
|
30
|
+
name="error"
|
|
31
|
+
>
|
|
23
32
|
<VcHint class="vc-checkbox__error tw-mt-1">
|
|
24
33
|
{{ errorMessage }}
|
|
25
34
|
</VcHint>
|
|
@@ -29,34 +38,10 @@
|
|
|
29
38
|
|
|
30
39
|
<script lang="ts" setup>
|
|
31
40
|
import { watch } from "vue";
|
|
41
|
+
import { checkboxProps, checkboxEmits } from "./vc-checkbox-model";
|
|
32
42
|
|
|
33
|
-
const props = defineProps(
|
|
34
|
-
|
|
35
|
-
type: Boolean,
|
|
36
|
-
default: false,
|
|
37
|
-
},
|
|
38
|
-
|
|
39
|
-
disabled: {
|
|
40
|
-
type: Boolean,
|
|
41
|
-
default: false,
|
|
42
|
-
},
|
|
43
|
-
|
|
44
|
-
required: {
|
|
45
|
-
type: Boolean,
|
|
46
|
-
default: false,
|
|
47
|
-
},
|
|
48
|
-
|
|
49
|
-
name: {
|
|
50
|
-
type: String,
|
|
51
|
-
default: "Field",
|
|
52
|
-
},
|
|
53
|
-
|
|
54
|
-
errorMessage: {
|
|
55
|
-
type: String,
|
|
56
|
-
default: undefined
|
|
57
|
-
}
|
|
58
|
-
});
|
|
59
|
-
const emit = defineEmits(["update:modelValue"]);
|
|
43
|
+
const props = defineProps(checkboxProps);
|
|
44
|
+
const emit = defineEmits(checkboxEmits);
|
|
60
45
|
|
|
61
46
|
watch(
|
|
62
47
|
() => props.modelValue,
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { ComponentPublicInstance } from "vue";
|
|
2
|
+
import { VcColProps } from "./vc-col-model";
|
|
3
|
+
import { ComponentConstructor } from "./../../../types/ts-helpers";
|
|
4
|
+
import Col from "./vc-col.vue";
|
|
5
|
+
export const VcCol: ComponentConstructor<ComponentPublicInstance<VcColProps>> = Col;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { VNode } from "vue";
|
|
2
|
+
import { ExtractTypes } from "./../../../types/ts-helpers";
|
|
3
|
+
|
|
4
|
+
export const colProps = {
|
|
5
|
+
size: {
|
|
6
|
+
type: String,
|
|
7
|
+
default: "1",
|
|
8
|
+
},
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
export type VcColProps = ExtractTypes<typeof colProps>;
|
|
12
|
+
|
|
13
|
+
export interface VcColSlots {
|
|
14
|
+
default: () => VNode[];
|
|
15
|
+
}
|
|
@@ -8,13 +8,9 @@
|
|
|
8
8
|
</template>
|
|
9
9
|
|
|
10
10
|
<script lang="ts" setup>
|
|
11
|
-
|
|
12
|
-
size: string;
|
|
13
|
-
}
|
|
11
|
+
import { colProps } from "./vc-col-model";
|
|
14
12
|
|
|
15
|
-
|
|
16
|
-
size: "1",
|
|
17
|
-
});
|
|
13
|
+
defineProps(colProps);
|
|
18
14
|
</script>
|
|
19
15
|
|
|
20
16
|
<style lang="scss">
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { ComponentPublicInstance } from "vue";
|
|
2
|
+
import { VcContainerEmits, VcContainerProps } from "./vc-container-model";
|
|
3
|
+
import { ComponentConstructor } from "./../../../types/ts-helpers";
|
|
4
|
+
import Container from "./vc-container.vue";
|
|
5
|
+
export const VcContainer: ComponentConstructor<
|
|
6
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
7
|
+
ComponentPublicInstance<VcContainerProps, any, any, any, any, VcContainerEmits>
|
|
8
|
+
> = Container;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { VNode } from "vue";
|
|
2
|
+
import { ExtractTypes } from "./../../../types/ts-helpers";
|
|
3
|
+
|
|
4
|
+
export const containerProps = {
|
|
5
|
+
shadow: {
|
|
6
|
+
type: Boolean,
|
|
7
|
+
default: false,
|
|
8
|
+
},
|
|
9
|
+
noPadding: {
|
|
10
|
+
type: Boolean,
|
|
11
|
+
default: false,
|
|
12
|
+
},
|
|
13
|
+
usePtr: {
|
|
14
|
+
type: Boolean,
|
|
15
|
+
default: false,
|
|
16
|
+
},
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
export const containerEmits = {
|
|
20
|
+
"scroll:ptr": () => true,
|
|
21
|
+
};
|
|
22
|
+
|
|
23
|
+
export type VcContainerProps = ExtractTypes<typeof containerProps>;
|
|
24
|
+
export type VcContainerEmits = typeof containerEmits;
|
|
25
|
+
|
|
26
|
+
export interface VcContainerSlots {
|
|
27
|
+
default: () => VNode[];
|
|
28
|
+
}
|
|
@@ -36,23 +36,12 @@
|
|
|
36
36
|
|
|
37
37
|
<script lang="ts" setup>
|
|
38
38
|
import { ref, onMounted, computed, nextTick } from "vue";
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
noPadding: {
|
|
46
|
-
type: Boolean,
|
|
47
|
-
default: false,
|
|
48
|
-
},
|
|
49
|
-
|
|
50
|
-
usePtr: {
|
|
51
|
-
type: Boolean,
|
|
52
|
-
default: false,
|
|
53
|
-
},
|
|
54
|
-
});
|
|
55
|
-
const emit = defineEmits(["scroll:ptr", "scroll:infinite"]);
|
|
39
|
+
import { containerProps, containerEmits } from "./vc-container-model";
|
|
40
|
+
|
|
41
|
+
const props = defineProps(containerProps);
|
|
42
|
+
|
|
43
|
+
const emit = defineEmits(containerEmits);
|
|
44
|
+
|
|
56
45
|
const component = ref<HTMLElement>();
|
|
57
46
|
const scroll = ref(false);
|
|
58
47
|
const startY = ref(0);
|
|
@@ -64,8 +53,7 @@ const delta = ref(0);
|
|
|
64
53
|
|
|
65
54
|
onMounted(() => {
|
|
66
55
|
const observer = new ResizeObserver(() => {
|
|
67
|
-
scroll.value = (component.value &&
|
|
68
|
-
component.value.clientHeight < component.value.scrollHeight) as boolean;
|
|
56
|
+
scroll.value = (component.value && component.value.clientHeight < component.value.scrollHeight) as boolean;
|
|
69
57
|
});
|
|
70
58
|
|
|
71
59
|
if (component.value) {
|
|
@@ -73,9 +61,7 @@ onMounted(() => {
|
|
|
73
61
|
}
|
|
74
62
|
});
|
|
75
63
|
|
|
76
|
-
const touchable = computed(
|
|
77
|
-
() => status.value !== "refresh" && status.value !== "success"
|
|
78
|
-
);
|
|
64
|
+
const touchable = computed(() => status.value !== "refresh" && status.value !== "success");
|
|
79
65
|
|
|
80
66
|
const scrollTop = () => {
|
|
81
67
|
if (component.value) {
|
|
@@ -160,8 +146,8 @@ function ease(distance: number) {
|
|
|
160
146
|
}
|
|
161
147
|
|
|
162
148
|
defineExpose({
|
|
163
|
-
|
|
164
|
-
|
|
149
|
+
scrollTop,
|
|
150
|
+
component,
|
|
165
151
|
});
|
|
166
152
|
</script>
|
|
167
153
|
|
|
@@ -171,8 +157,7 @@ defineExpose({
|
|
|
171
157
|
--container-scroll-color-hover: #cce4f5;
|
|
172
158
|
--container-scroll-width: 8px;
|
|
173
159
|
--container-scroll-padding: 8px;
|
|
174
|
-
--container-scroll-shadow: 0 3px 2px rgba(0, 0, 0, 0.1) inset,
|
|
175
|
-
0 -3px 2px rgba(0, 0, 0, 0.1) inset;
|
|
160
|
+
--container-scroll-shadow: 0 3px 2px rgba(0, 0, 0, 0.1) inset, 0 -3px 2px rgba(0, 0, 0, 0.1) inset;
|
|
176
161
|
}
|
|
177
162
|
|
|
178
163
|
.vc-container {
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { ComponentPublicInstance } from "vue";
|
|
2
|
+
import { VcIconProps } from "./vc-icon-model";
|
|
3
|
+
import { ComponentConstructor } from "./../../../types/ts-helpers";
|
|
4
|
+
import Icon from "./vc-icon.vue";
|
|
5
|
+
export const VcIcon: ComponentConstructor<ComponentPublicInstance<VcIconProps>> = Icon;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { VNode, PropType } from "vue";
|
|
2
|
+
import { ExtractTypes } from "./../../../types/ts-helpers";
|
|
3
|
+
|
|
4
|
+
export const iconProps = {
|
|
5
|
+
icon: {
|
|
6
|
+
type: String,
|
|
7
|
+
default: "fas fa-square-full",
|
|
8
|
+
},
|
|
9
|
+
size: {
|
|
10
|
+
type: String as PropType<"xs" | "s" | "m" | "l" | "xl" | "xxl">,
|
|
11
|
+
default: "m",
|
|
12
|
+
},
|
|
13
|
+
};
|
|
14
|
+
|
|
15
|
+
export type VcIconProps = ExtractTypes<typeof iconProps>;
|
|
16
|
+
|
|
17
|
+
export interface VcIconSlots {
|
|
18
|
+
default: () => VNode[];
|
|
19
|
+
}
|
|
@@ -3,15 +3,9 @@
|
|
|
3
3
|
</template>
|
|
4
4
|
|
|
5
5
|
<script lang="ts" setup>
|
|
6
|
-
|
|
7
|
-
icon?: string;
|
|
8
|
-
size?: "xs" | "s" | "m" | "l" | "xl" | "xxl";
|
|
9
|
-
}
|
|
6
|
+
import { iconProps } from "./vc-icon-model";
|
|
10
7
|
|
|
11
|
-
|
|
12
|
-
icon: "fas fa-square-full",
|
|
13
|
-
size: "m",
|
|
14
|
-
});
|
|
8
|
+
defineProps(iconProps);
|
|
15
9
|
</script>
|
|
16
10
|
|
|
17
11
|
<style lang="scss">
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { ComponentPublicInstance } from "vue";
|
|
2
|
+
import { VcImageEmits, VcImageProps } from "./vc-image-model";
|
|
3
|
+
import { ComponentConstructor } from "./../../../types/ts-helpers";
|
|
4
|
+
import Image from "./vc-image.vue";
|
|
5
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
6
|
+
export const VcImage: ComponentConstructor<ComponentPublicInstance<VcImageProps, any, any, any, any, VcImageEmits>> =
|
|
7
|
+
Image;
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { VNode, PropType } from "vue";
|
|
2
|
+
import { ExtractTypes } from "./../../../types/ts-helpers";
|
|
3
|
+
|
|
4
|
+
export const imageProps = {
|
|
5
|
+
aspect: {
|
|
6
|
+
type: String,
|
|
7
|
+
default: "1x1",
|
|
8
|
+
},
|
|
9
|
+
rounded: {
|
|
10
|
+
type: Boolean,
|
|
11
|
+
default: false,
|
|
12
|
+
},
|
|
13
|
+
bordered: {
|
|
14
|
+
type: Boolean,
|
|
15
|
+
default: false,
|
|
16
|
+
},
|
|
17
|
+
clickable: {
|
|
18
|
+
type: Boolean,
|
|
19
|
+
default: false,
|
|
20
|
+
},
|
|
21
|
+
src: String,
|
|
22
|
+
size: {
|
|
23
|
+
type: String as PropType<"auto" | "1x1" | "16x9" | "4x3" | "3x2" | "xs" | "s" | "m" | "l" | "xl" | "xxl">,
|
|
24
|
+
default: "auto",
|
|
25
|
+
},
|
|
26
|
+
background: {
|
|
27
|
+
type: String as PropType<"cover" | "contain" | "auto">,
|
|
28
|
+
default: "cover",
|
|
29
|
+
},
|
|
30
|
+
};
|
|
31
|
+
|
|
32
|
+
export const imageEmits = {
|
|
33
|
+
click: () => true,
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
export type VcImageProps = ExtractTypes<typeof imageProps>;
|
|
37
|
+
export type VcImageEmits = typeof imageEmits;
|
|
38
|
+
|
|
39
|
+
export interface VcImageSlots {
|
|
40
|
+
default: () => VNode[];
|
|
41
|
+
}
|
|
@@ -25,8 +25,7 @@ const Template: Story = (args) => ({
|
|
|
25
25
|
setup() {
|
|
26
26
|
return { args };
|
|
27
27
|
},
|
|
28
|
-
template:
|
|
29
|
-
'<div style="width: 400px"><vc-image v-bind="args"></vc-image></div>',
|
|
28
|
+
template: '<div style="width: 400px"><vc-image v-bind="args"></vc-image></div>',
|
|
30
29
|
});
|
|
31
30
|
|
|
32
31
|
export const Image = Template.bind({});
|
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<div
|
|
2
|
+
<div
|
|
3
|
+
class="vc-image"
|
|
4
|
+
:class="[`vc-image_${size}`]"
|
|
5
|
+
>
|
|
3
6
|
<div
|
|
4
7
|
:class="[
|
|
5
8
|
`vc-image_${aspect}`,
|
|
@@ -17,7 +20,10 @@
|
|
|
17
20
|
v-if="!src"
|
|
18
21
|
class="tw-absolute tw-w-full tw-h-full tw-flex tw-items-center tw-justify-center tw-text-[#83a3be]"
|
|
19
22
|
>
|
|
20
|
-
<VcIcon
|
|
23
|
+
<VcIcon
|
|
24
|
+
icon="fas fa-image"
|
|
25
|
+
size="xl"
|
|
26
|
+
></VcIcon>
|
|
21
27
|
</div>
|
|
22
28
|
</div>
|
|
23
29
|
</div>
|
|
@@ -25,51 +31,15 @@
|
|
|
25
31
|
|
|
26
32
|
<script lang="ts" setup>
|
|
27
33
|
import { computed } from "vue";
|
|
34
|
+
import { imageProps, imageEmits } from "./vc-image-model";
|
|
28
35
|
|
|
29
|
-
const props = defineProps(
|
|
30
|
-
aspect: {
|
|
31
|
-
type: String,
|
|
32
|
-
default: "1x1",
|
|
33
|
-
},
|
|
36
|
+
const props = defineProps(imageProps);
|
|
34
37
|
|
|
35
|
-
|
|
36
|
-
type: Boolean,
|
|
37
|
-
default: false,
|
|
38
|
-
},
|
|
39
|
-
|
|
40
|
-
bordered: {
|
|
41
|
-
type: Boolean,
|
|
42
|
-
default: false,
|
|
43
|
-
},
|
|
44
|
-
|
|
45
|
-
clickable: {
|
|
46
|
-
type: Boolean,
|
|
47
|
-
default: false,
|
|
48
|
-
},
|
|
49
|
-
|
|
50
|
-
src: {
|
|
51
|
-
type: String,
|
|
52
|
-
default: undefined,
|
|
53
|
-
},
|
|
54
|
-
|
|
55
|
-
size: {
|
|
56
|
-
type: String,
|
|
57
|
-
default: "auto",
|
|
58
|
-
},
|
|
59
|
-
|
|
60
|
-
background: {
|
|
61
|
-
type: String,
|
|
62
|
-
default: "cover",
|
|
63
|
-
},
|
|
64
|
-
});
|
|
65
|
-
|
|
66
|
-
const emit = defineEmits(["click"]);
|
|
38
|
+
const emit = defineEmits(imageEmits);
|
|
67
39
|
|
|
68
40
|
const imageHandler = computed(() => {
|
|
69
41
|
if (props.src) {
|
|
70
|
-
return `background: url(${encodeURI(props.src)}) center / ${
|
|
71
|
-
props.background
|
|
72
|
-
} no-repeat`;
|
|
42
|
+
return `background: url(${encodeURI(props.src)}) center / ${props.background} no-repeat`;
|
|
73
43
|
}
|
|
74
44
|
return undefined;
|
|
75
45
|
});
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { ComponentPublicInstance } from "vue";
|
|
2
|
+
import { VcInfoRowProps } from "./vc-info-row-model";
|
|
3
|
+
import { ComponentConstructor } from "./../../../types/ts-helpers";
|
|
4
|
+
import InfoRow from "./vc-info-row.vue";
|
|
5
|
+
export const VcInfoRow: ComponentConstructor<ComponentPublicInstance<VcInfoRowProps>> = InfoRow;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { VNode, PropType } from "vue";
|
|
2
|
+
import { ExtractTypes } from "./../../../types/ts-helpers";
|
|
3
|
+
|
|
4
|
+
export const infoRowProps = {
|
|
5
|
+
label: {
|
|
6
|
+
type: String,
|
|
7
|
+
default: "",
|
|
8
|
+
},
|
|
9
|
+
value: {
|
|
10
|
+
type: String,
|
|
11
|
+
default: "",
|
|
12
|
+
},
|
|
13
|
+
tooltip: {
|
|
14
|
+
type: String,
|
|
15
|
+
default: "",
|
|
16
|
+
},
|
|
17
|
+
type: {
|
|
18
|
+
type: String as PropType<"default" | "email">,
|
|
19
|
+
default: "",
|
|
20
|
+
},
|
|
21
|
+
};
|
|
22
|
+
|
|
23
|
+
export type VcInfoRowProps = ExtractTypes<typeof infoRowProps>;
|
|
24
|
+
|
|
25
|
+
export interface VcInfoRowSlots {
|
|
26
|
+
default: () => VNode[];
|
|
27
|
+
}
|