@vc-shell/vc-app-skill 2.0.0-alpha.32 → 2.0.0-alpha.33-pr220.455e322
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +59 -47
- package/README.md +18 -12
- package/package.json +4 -4
- package/runtime/VERSION +1 -1
- package/runtime/agents/api-analyzer.md +31 -16
- package/runtime/agents/blade-enhancer.md +15 -9
- package/runtime/agents/details-blade-generator.md +47 -31
- package/runtime/agents/list-blade-generator.md +21 -37
- package/runtime/agents/locales-generator.md +3 -0
- package/runtime/agents/migration-agent.md +94 -0
- package/runtime/agents/module-analyzer.md +2 -0
- package/runtime/agents/module-assembler.md +15 -0
- package/runtime/agents/promote-agent.md +15 -4
- package/runtime/agents/type-checker.md +11 -0
- package/runtime/knowledge/docs/_BUILD_HASH.md +1 -1
- package/runtime/knowledge/docs/core/api/platform.docs.md +30 -30
- package/runtime/knowledge/docs/core/blade-navigation/blade-nav-composables.docs.md +41 -41
- package/runtime/knowledge/docs/core/composables/bladeContext/index.docs.md +12 -10
- package/runtime/knowledge/docs/core/composables/useApiClient/useApiClient.docs.md +11 -14
- package/runtime/knowledge/docs/core/composables/useAppBarMobileButtons/useAppBarMobileButtons.docs.md +35 -35
- package/runtime/knowledge/docs/core/composables/useAppBarWidget/useAppBarWidget.docs.md +35 -35
- package/runtime/knowledge/docs/core/composables/useAppInsights/useAppInsights.docs.md +15 -15
- package/runtime/knowledge/docs/core/composables/useAssets/useAssets.docs.md +21 -18
- package/runtime/knowledge/docs/core/composables/useAssetsManager/useAssetsManager.docs.md +31 -27
- package/runtime/knowledge/docs/core/composables/useAsync/useAsync.docs.md +90 -61
- package/runtime/knowledge/docs/core/composables/useBeforeUnload/useBeforeUnload.docs.md +19 -18
- package/runtime/knowledge/docs/core/composables/useBlade/useBlade.docs.md +89 -68
- package/runtime/knowledge/docs/core/composables/useBladeForm/useBladeForm.docs.md +75 -19
- package/runtime/knowledge/docs/core/composables/useBladeRegistry/useBladeRegistry.docs.md +15 -15
- package/runtime/knowledge/docs/core/composables/useBladeWidgets/index.docs.md +74 -78
- package/runtime/knowledge/docs/core/composables/useBreadcrumbs/useBreadcrumbs.docs.md +11 -11
- package/runtime/knowledge/docs/core/composables/useConnectionStatus/useConnectionStatus.docs.md +27 -15
- package/runtime/knowledge/docs/core/composables/useDashboard/useDashboard.docs.md +30 -30
- package/runtime/knowledge/docs/core/composables/useDynamicProperties/useDynamicProperties.docs.md +34 -36
- package/runtime/knowledge/docs/core/composables/useErrorHandler/useErrorHandler.docs.md +44 -23
- package/runtime/knowledge/docs/core/composables/useFunctions/useFunctions.docs.md +14 -11
- package/runtime/knowledge/docs/core/composables/useKeyboardNavigation/useKeyboardNavigation.docs.md +47 -38
- package/runtime/knowledge/docs/core/composables/useLanguages/useLanguages.docs.md +37 -28
- package/runtime/knowledge/docs/core/composables/useLoading/useLoading.docs.md +23 -17
- package/runtime/knowledge/docs/core/composables/useMenuExpanded/index.docs.md +10 -10
- package/runtime/knowledge/docs/core/composables/useMenuService/useMenuService.docs.md +42 -42
- package/runtime/knowledge/docs/core/composables/useModificationTracker/useModificationTracker.docs.md +22 -12
- package/runtime/knowledge/docs/core/composables/useNotifications/useNotifications.docs.md +33 -41
- package/runtime/knowledge/docs/core/composables/usePermissions/usePermissions.docs.md +16 -16
- package/runtime/knowledge/docs/core/composables/usePopup/usePopup.docs.md +32 -24
- package/runtime/knowledge/docs/core/composables/useResponsive/useResponsive.docs.md +32 -11
- package/runtime/knowledge/docs/core/composables/useSettings/useSettings.docs.md +24 -15
- package/runtime/knowledge/docs/core/composables/useSettingsMenu/useSettingsMenu.docs.md +7 -7
- package/runtime/knowledge/docs/core/composables/useSidebarState/useSidebarState.docs.md +32 -24
- package/runtime/knowledge/docs/core/composables/useSlowNetworkDetection/useSlowNetworkDetection.docs.md +21 -17
- package/runtime/knowledge/docs/core/composables/useTheme/useTheme.docs.md +24 -24
- package/runtime/knowledge/docs/core/composables/useToolbar/useToolbar.docs.md +28 -31
- package/runtime/knowledge/docs/core/composables/useUser/useUser.docs.md +43 -24
- package/runtime/knowledge/docs/core/composables/useUserManagement/useUserManagement.docs.md +68 -48
- package/runtime/knowledge/docs/core/composables/useWebVitals/useWebVitals.docs.md +19 -19
- package/runtime/knowledge/docs/core/composables/useWidgets/useWidgets.docs.md +42 -47
- package/runtime/knowledge/docs/core/directives/autofocus/autofocus.docs.md +10 -4
- package/runtime/knowledge/docs/core/directives/loading/loading.docs.md +35 -20
- package/runtime/knowledge/docs/core/notifications/notifications.docs.md +36 -35
- package/runtime/knowledge/docs/core/plugins/ai-agent/ai-agent.docs.md +38 -38
- package/runtime/knowledge/docs/core/plugins/extension-points/extension-points.docs.md +107 -91
- package/runtime/knowledge/docs/core/plugins/global-error-handler/global-error-handler.docs.md +10 -10
- package/runtime/knowledge/docs/core/plugins/i18n/i18n.docs.md +21 -23
- package/runtime/knowledge/docs/core/plugins/modularity/modularity.docs.md +98 -90
- package/runtime/knowledge/docs/core/plugins/permissions/permissions.docs.md +10 -16
- package/runtime/knowledge/docs/core/plugins/signalR/signalR.docs.md +9 -9
- package/runtime/knowledge/docs/core/plugins/validation/validation.docs.md +65 -22
- package/runtime/knowledge/docs/core/services/services.docs.md +19 -22
- package/runtime/knowledge/docs/core/types/types.docs.md +40 -40
- package/runtime/knowledge/docs/core/utilities/date/date-utilities.docs.md +27 -27
- package/runtime/knowledge/docs/core/utilities/shared-utilities.docs.md +23 -23
- package/runtime/knowledge/docs/core/utilities/thumbnail/thumbnail.docs.md +22 -25
- package/runtime/knowledge/docs/core/utilities/utilities.docs.md +64 -64
- package/runtime/knowledge/docs/injection-keys.docs.md +52 -51
- package/runtime/knowledge/docs/modules/assets-manager/assets-manager.docs.md +9 -9
- package/runtime/knowledge/docs/shell/_internal/popup/common/popup-common.docs.md +23 -43
- package/runtime/knowledge/docs/shell/auth/ChangePasswordPage/change-password-page.docs.md +102 -0
- package/runtime/knowledge/docs/shell/auth/ForgotPasswordPage/forgot-password-page.docs.md +5 -5
- package/runtime/knowledge/docs/shell/auth/InvitePage/invite-page.docs.md +8 -7
- package/runtime/knowledge/docs/shell/auth/LoginPage/login-page.docs.md +7 -7
- package/runtime/knowledge/docs/shell/auth/ResetPasswordPage/reset-password-page.docs.md +8 -7
- package/runtime/knowledge/docs/shell/auth/sign-in/sign-in.docs.md +29 -13
- package/runtime/knowledge/docs/shell/components/change-password/change-password.docs.md +13 -16
- package/runtime/knowledge/docs/shell/components/change-password-button/change-password-button.docs.md +1 -7
- package/runtime/knowledge/docs/shell/components/error-interceptor/error-interceptor.docs.md +5 -5
- package/runtime/knowledge/docs/shell/components/language-selector/language-selector.docs.md +1 -1
- package/runtime/knowledge/docs/shell/components/logout-button/logout-button.docs.md +1 -1
- package/runtime/knowledge/docs/shell/components/notification-template/notification-template.docs.md +17 -9
- package/runtime/knowledge/docs/shell/components/settings-menu/settings-menu.docs.md +12 -18
- package/runtime/knowledge/docs/shell/components/settings-menu-item/settings-menu-item.docs.md +34 -65
- package/runtime/knowledge/docs/shell/components/sidebar/sidebar.docs.md +16 -26
- package/runtime/knowledge/docs/shell/components/theme-selector/theme-selector.docs.md +2 -2
- package/runtime/knowledge/docs/shell/components/user-dropdown-button/user-dropdown-button.docs.md +7 -9
- package/runtime/knowledge/docs/shell/dashboard/dashboard-charts/dashboard-charts.docs.md +30 -40
- package/runtime/knowledge/docs/shell/dashboard/dashboard-widget-card/dashboard-widget-card.docs.md +26 -19
- package/runtime/knowledge/docs/shell/dashboard/draggable-dashboard/draggable-dashboard.docs.md +15 -12
- package/runtime/knowledge/docs/ui/components/atoms/vc-badge/vc-badge.docs.md +15 -26
- package/runtime/knowledge/docs/ui/components/atoms/vc-banner/vc-banner.docs.md +21 -19
- package/runtime/knowledge/docs/ui/components/atoms/vc-button/vc-button.docs.md +83 -67
- package/runtime/knowledge/docs/ui/components/atoms/vc-card/vc-card.docs.md +104 -59
- package/runtime/knowledge/docs/ui/components/atoms/vc-col/vc-col.docs.md +28 -11
- package/runtime/knowledge/docs/ui/components/atoms/vc-container/vc-container.docs.md +20 -17
- package/runtime/knowledge/docs/ui/components/atoms/vc-hint/vc-hint.docs.md +26 -17
- package/runtime/knowledge/docs/ui/components/atoms/vc-icon/vc-icon.docs.md +30 -32
- package/runtime/knowledge/docs/ui/components/atoms/vc-image/vc-image.docs.md +25 -48
- package/runtime/knowledge/docs/ui/components/atoms/vc-label/vc-label.docs.md +29 -24
- package/runtime/knowledge/docs/ui/components/atoms/vc-link/vc-link.docs.md +23 -15
- package/runtime/knowledge/docs/ui/components/atoms/vc-loading/vc-loading.docs.md +22 -13
- package/runtime/knowledge/docs/ui/components/atoms/vc-progress/vc-progress.docs.md +33 -18
- package/runtime/knowledge/docs/ui/components/atoms/vc-row/vc-row.docs.md +56 -15
- package/runtime/knowledge/docs/ui/components/atoms/vc-scrollable-container/vc-scrollable-container.docs.md +28 -15
- package/runtime/knowledge/docs/ui/components/atoms/vc-skeleton/vc-skeleton.docs.md +40 -20
- package/runtime/knowledge/docs/ui/components/atoms/vc-status/vc-status.docs.md +25 -14
- package/runtime/knowledge/docs/ui/components/atoms/vc-status-icon/vc-status-icon.docs.md +40 -14
- package/runtime/knowledge/docs/ui/components/atoms/vc-tooltip/vc-tooltip.docs.md +54 -42
- package/runtime/knowledge/docs/ui/components/atoms/vc-video/vc-video.docs.md +17 -17
- package/runtime/knowledge/docs/ui/components/atoms/vc-widget/vc-widget.docs.md +21 -21
- package/runtime/knowledge/docs/ui/components/molecules/multilanguage-selector/multilanguage-selector.docs.md +23 -10
- package/runtime/knowledge/docs/ui/components/molecules/vc-accordion/vc-accordion.docs.md +59 -44
- package/runtime/knowledge/docs/ui/components/molecules/vc-breadcrumbs/vc-breadcrumbs.docs.md +23 -20
- package/runtime/knowledge/docs/ui/components/molecules/vc-checkbox/vc-checkbox.docs.md +96 -64
- package/runtime/knowledge/docs/ui/components/molecules/vc-checkbox-group/vc-checkbox-group.docs.md +26 -35
- package/runtime/knowledge/docs/ui/components/molecules/vc-color-input/vc-color-input.docs.md +69 -22
- package/runtime/knowledge/docs/ui/components/molecules/vc-date-picker/vc-date-picker.docs.md +58 -72
- package/runtime/knowledge/docs/ui/components/molecules/vc-dropdown/vc-dropdown.docs.md +91 -85
- package/runtime/knowledge/docs/ui/components/molecules/vc-dropdown-panel/vc-dropdown-panel.docs.md +38 -42
- package/runtime/knowledge/docs/ui/components/molecules/vc-editor/vc-editor.docs.md +60 -72
- package/runtime/knowledge/docs/ui/components/molecules/vc-field/vc-field.docs.md +65 -26
- package/runtime/knowledge/docs/ui/components/molecules/vc-file-upload/vc-file-upload.docs.md +46 -49
- package/runtime/knowledge/docs/ui/components/molecules/vc-form/vc-form.docs.md +35 -64
- package/runtime/knowledge/docs/ui/components/molecules/vc-image-tile/vc-image-tile.docs.md +38 -41
- package/runtime/knowledge/docs/ui/components/molecules/vc-input/vc-input.docs.md +115 -130
- package/runtime/knowledge/docs/ui/components/molecules/vc-input-currency/vc-input-currency.docs.md +53 -87
- package/runtime/knowledge/docs/ui/components/molecules/vc-input-dropdown/vc-input-dropdown.docs.md +56 -63
- package/runtime/knowledge/docs/ui/components/molecules/vc-input-group/vc-input-group.docs.md +29 -24
- package/runtime/knowledge/docs/ui/components/molecules/vc-menu/vc-menu.docs.md +32 -28
- package/runtime/knowledge/docs/ui/components/molecules/vc-multivalue/vc-multivalue.docs.md +63 -64
- package/runtime/knowledge/docs/ui/components/molecules/vc-pagination/vc-pagination.docs.md +28 -26
- package/runtime/knowledge/docs/ui/components/molecules/vc-radio-button/vc-radio-button.docs.md +59 -19
- package/runtime/knowledge/docs/ui/components/molecules/vc-radio-group/vc-radio-group.docs.md +25 -34
- package/runtime/knowledge/docs/ui/components/molecules/vc-rating/vc-rating.docs.md +42 -32
- package/runtime/knowledge/docs/ui/components/molecules/vc-select/vc-select.docs.md +78 -82
- package/runtime/knowledge/docs/ui/components/molecules/vc-slider/vc-slider.docs.md +25 -15
- package/runtime/knowledge/docs/ui/components/molecules/vc-switch/vc-switch.docs.md +59 -63
- package/runtime/knowledge/docs/ui/components/molecules/vc-textarea/vc-textarea.docs.md +57 -69
- package/runtime/knowledge/docs/ui/components/molecules/vc-toast/vc-toast.docs.md +58 -57
- package/runtime/knowledge/docs/ui/components/organisms/vc-app/vc-app.docs.md +49 -26
- package/runtime/knowledge/docs/ui/components/organisms/vc-auth-layout/vc-auth-layout.docs.md +82 -28
- package/runtime/knowledge/docs/ui/components/organisms/vc-blade/vc-blade.docs.md +120 -75
- package/runtime/knowledge/docs/ui/components/organisms/vc-data-table/composables/table-composables.docs.md +30 -44
- package/runtime/knowledge/docs/ui/components/organisms/vc-data-table/vc-data-table.docs.md +536 -365
- package/runtime/knowledge/docs/ui/components/organisms/vc-dynamic-property/vc-dynamic-property.docs.md +35 -52
- package/runtime/knowledge/docs/ui/components/organisms/vc-gallery/vc-gallery.docs.md +33 -62
- package/runtime/knowledge/docs/ui/components/organisms/vc-image-upload/vc-image-upload.docs.md +17 -23
- package/runtime/knowledge/docs/ui/components/organisms/vc-popup/vc-popup.docs.md +109 -68
- package/runtime/knowledge/docs/ui/components/organisms/vc-sidebar/vc-sidebar.docs.md +82 -44
- package/runtime/knowledge/docs/ui/composables/ui-composables.docs.md +8 -8
- package/runtime/knowledge/docs/ui/composables/useDataTablePagination.docs.md +164 -0
- package/runtime/knowledge/docs/ui/composables/useDataTableSort.docs.md +34 -26
- package/runtime/knowledge/docs/ui/composables/useTableSelection.docs.md +48 -40
- package/runtime/knowledge/docs/ui/composables/useTableSort.docs.md +30 -17
- package/runtime/knowledge/docs/ui/types/ui-types.docs.md +40 -29
- package/runtime/knowledge/examples/offers-module.md +15 -13
- package/runtime/knowledge/examples/team-module.md +82 -119
- package/runtime/knowledge/examples/videos-module.md +44 -17
- package/runtime/knowledge/index.md +22 -0
- package/runtime/knowledge/migration-prompts/blade-form-migration.md +255 -0
- package/runtime/knowledge/migration-prompts/blade-props-migration.md +194 -0
- package/runtime/knowledge/migration-prompts/datatable-migration.md +801 -0
- package/runtime/knowledge/migration-prompts/icon-migration.md +97 -0
- package/runtime/knowledge/migration-prompts/manual-migration-audit.md +117 -0
- package/runtime/knowledge/migration-prompts/notifications-migration.md +223 -0
- package/runtime/knowledge/migration-prompts/nswag-migration.md +244 -0
- package/runtime/knowledge/migration-prompts/use-assets-migration.md +164 -0
- package/runtime/knowledge/migration-prompts/use-data-table-pagination-migration.md +176 -0
- package/runtime/knowledge/migration-prompts/widgets-migration.md +178 -0
- package/runtime/knowledge/patterns/assets-management.md +20 -20
- package/runtime/knowledge/patterns/blade-navigation.md +7 -14
- package/runtime/knowledge/patterns/blade-widget.md +19 -17
- package/runtime/knowledge/patterns/child-blade-flow.md +19 -7
- package/runtime/knowledge/patterns/composable-details.md +20 -50
- package/runtime/knowledge/patterns/composable-list.md +43 -31
- package/runtime/knowledge/patterns/dashboard-widget.md +14 -16
- package/runtime/knowledge/patterns/datatable-pattern.md +521 -0
- package/runtime/knowledge/patterns/details-blade-pattern.md +78 -116
- package/runtime/knowledge/patterns/extension-points-usage.md +53 -44
- package/runtime/knowledge/patterns/form-validation.md +28 -64
- package/runtime/knowledge/patterns/list-blade-pattern.md +33 -21
- package/runtime/knowledge/patterns/module-structure.md +7 -1
- package/runtime/knowledge/patterns/multilanguage-fields.md +8 -14
- package/runtime/knowledge/patterns/notification-template.md +21 -14
- package/runtime/knowledge/patterns/signalr-notifications.md +30 -32
- package/runtime/knowledge/patterns/toolbar-pattern.md +18 -20
- package/runtime/vc-app.md +354 -49
- package/runtime/knowledge/docs/core/constants/constants.docs.md +0 -185
|
@@ -45,13 +45,7 @@ Combine with other account-related settings entries in a module setup:
|
|
|
45
45
|
|
|
46
46
|
```ts
|
|
47
47
|
// my-module/index.ts
|
|
48
|
-
import {
|
|
49
|
-
useSettingsMenu,
|
|
50
|
-
ChangePasswordButton,
|
|
51
|
-
LogoutButton,
|
|
52
|
-
ThemeSelector,
|
|
53
|
-
LanguageSelector,
|
|
54
|
-
} from "@vc-shell/framework";
|
|
48
|
+
import { useSettingsMenu, ChangePasswordButton, LogoutButton, ThemeSelector, LanguageSelector } from "@vc-shell/framework";
|
|
55
49
|
|
|
56
50
|
export default {
|
|
57
51
|
install() {
|
|
@@ -17,16 +17,16 @@ The component is renderless -- it renders its default slot and passes the curren
|
|
|
17
17
|
|
|
18
18
|
## Props
|
|
19
19
|
|
|
20
|
-
| Prop
|
|
21
|
-
|
|
20
|
+
| Prop | Type | Default | Description |
|
|
21
|
+
| --------- | --------- | ------- | ------------------------------------------------ |
|
|
22
22
|
| `capture` | `boolean` | `false` | Force error capture even outside a blade context |
|
|
23
23
|
|
|
24
24
|
## Slot Props
|
|
25
25
|
|
|
26
|
-
| Prop
|
|
27
|
-
|
|
26
|
+
| Prop | Type | Description |
|
|
27
|
+
| ------- | -------------------------- | --------------------------------------- |
|
|
28
28
|
| `error` | `DisplayableError \| null` | The captured error, or null if no error |
|
|
29
|
-
| `reset` | `() => void`
|
|
29
|
+
| `reset` | `() => void` | Clears the error state |
|
|
30
30
|
|
|
31
31
|
## Usage
|
|
32
32
|
|
|
@@ -87,7 +87,7 @@ async function onLogin(user) {
|
|
|
87
87
|
## Tips
|
|
88
88
|
|
|
89
89
|
- The component only shows locales that have been registered with vue-i18n. If a locale file is missing, the language will not appear in the selector.
|
|
90
|
-
- Use the `check
|
|
90
|
+
- Use the `check:locales` script (`yarn check:locales`) to validate that all locale files have the same keys. Missing keys fall back to the `fallbackLocale`.
|
|
91
91
|
- The `LanguageSelector` changes the UI language. To let users switch the content editing language for multilingual fields (e.g., product names), use the `MultilanguageSelector` component instead.
|
|
92
92
|
|
|
93
93
|
## Related Components
|
package/runtime/knowledge/docs/shell/components/notification-template/notification-template.docs.md
CHANGED
|
@@ -31,13 +31,13 @@ const notification = computed(() => notificationRef.value);
|
|
|
31
31
|
|
|
32
32
|
## Key Props
|
|
33
33
|
|
|
34
|
-
| Prop
|
|
35
|
-
|
|
36
|
-
| `title`
|
|
37
|
-
| `notification` | `IPushNotification` | --
|
|
38
|
-
| `icon`
|
|
39
|
-
| `color`
|
|
40
|
-
| `severity`
|
|
34
|
+
| Prop | Type | Default | Description |
|
|
35
|
+
| -------------- | ------------------- | ----------- | ------------------------------------------------- |
|
|
36
|
+
| `title` | `string` | -- | Notification headline text |
|
|
37
|
+
| `notification` | `IPushNotification` | -- | Full notification object (required for timestamp) |
|
|
38
|
+
| `icon` | `string` | `undefined` | Icon name displayed in a circular badge |
|
|
39
|
+
| `color` | `string` | `undefined` | Background color for the icon badge |
|
|
40
|
+
| `severity` | `string` | `undefined` | Semantic severity level |
|
|
41
41
|
|
|
42
42
|
## Recipe: Custom Notification for Order Events
|
|
43
43
|
|
|
@@ -129,7 +129,10 @@ const isRunning = computed(() => (notification.value as any).isRunning ?? false)
|
|
|
129
129
|
icon="lucide-upload"
|
|
130
130
|
color="var(--info-500)"
|
|
131
131
|
>
|
|
132
|
-
<div
|
|
132
|
+
<div
|
|
133
|
+
v-if="isRunning"
|
|
134
|
+
class="tw-mt-1"
|
|
135
|
+
>
|
|
133
136
|
<div class="tw-h-2 tw-bg-gray-200 tw-rounded">
|
|
134
137
|
<div
|
|
135
138
|
class="tw-h-full tw-bg-blue-500 tw-rounded tw-transition-all"
|
|
@@ -138,7 +141,12 @@ const isRunning = computed(() => (notification.value as any).isRunning ?? false)
|
|
|
138
141
|
</div>
|
|
139
142
|
<span class="tw-text-xs tw-text-gray-500">{{ progress }}% complete</span>
|
|
140
143
|
</div>
|
|
141
|
-
<p
|
|
144
|
+
<p
|
|
145
|
+
v-else
|
|
146
|
+
class="tw-text-sm tw-text-green-600"
|
|
147
|
+
>
|
|
148
|
+
Import completed.
|
|
149
|
+
</p>
|
|
142
150
|
</NotificationTemplate>
|
|
143
151
|
</template>
|
|
144
152
|
```
|
|
@@ -46,15 +46,9 @@ This component has no props. All content is driven by the settings menu service
|
|
|
46
46
|
A typical module registers all its settings entries during the module install phase:
|
|
47
47
|
|
|
48
48
|
```ts
|
|
49
|
-
//
|
|
49
|
+
// my-module/index.ts
|
|
50
50
|
import { markRaw } from "vue";
|
|
51
|
-
import {
|
|
52
|
-
useSettingsMenu,
|
|
53
|
-
ThemeSelector,
|
|
54
|
-
LanguageSelector,
|
|
55
|
-
ChangePasswordButton,
|
|
56
|
-
LogoutButton,
|
|
57
|
-
} from "@vc-shell/framework";
|
|
51
|
+
import { useSettingsMenu, ThemeSelector, LanguageSelector, ChangePasswordButton, LogoutButton } from "@vc-shell/framework";
|
|
58
52
|
|
|
59
53
|
export default {
|
|
60
54
|
install() {
|
|
@@ -97,21 +91,21 @@ export default {
|
|
|
97
91
|
|
|
98
92
|
### Registration options
|
|
99
93
|
|
|
100
|
-
| Option
|
|
101
|
-
|
|
102
|
-
| `id`
|
|
103
|
-
| `group`
|
|
104
|
-
| `order`
|
|
105
|
-
| `component` | `Component` | Yes
|
|
94
|
+
| Option | Type | Required | Description |
|
|
95
|
+
| ----------- | ----------- | -------- | ---------------------------------------------------------- |
|
|
96
|
+
| `id` | `string` | Yes | Unique identifier for the entry |
|
|
97
|
+
| `group` | `string` | Yes | Group name (entries are grouped and separated by dividers) |
|
|
98
|
+
| `order` | `number` | Yes | Sort order within the group (lower = higher position) |
|
|
99
|
+
| `component` | `Component` | Yes | Vue component to render as the menu item |
|
|
106
100
|
|
|
107
101
|
### Group rendering
|
|
108
102
|
|
|
109
103
|
Groups are separated by a horizontal divider and items within each group are sorted by `order`. Common group names used by convention:
|
|
110
104
|
|
|
111
|
-
| Group
|
|
112
|
-
|
|
113
|
-
| `"preferences"` | User preferences (theme, language)
|
|
114
|
-
| `"account"`
|
|
105
|
+
| Group | Description | Typical order range |
|
|
106
|
+
| --------------- | ----------------------------------------- | ------------------- |
|
|
107
|
+
| `"preferences"` | User preferences (theme, language) | 10-29 |
|
|
108
|
+
| `"account"` | Account actions (change password, logout) | 30-100 |
|
|
115
109
|
|
|
116
110
|
## Details
|
|
117
111
|
|
package/runtime/knowledge/docs/shell/components/settings-menu-item/settings-menu-item.docs.md
CHANGED
|
@@ -44,34 +44,34 @@ import { SettingsMenuItem } from "@vc-shell/framework";
|
|
|
44
44
|
|
|
45
45
|
## Key Props
|
|
46
46
|
|
|
47
|
-
| Prop
|
|
48
|
-
|
|
49
|
-
| `title`
|
|
50
|
-
| `icon`
|
|
51
|
-
| `image`
|
|
52
|
-
| `value`
|
|
53
|
-
| `showChevron`
|
|
54
|
-
| `isActive`
|
|
55
|
-
| `disabled`
|
|
56
|
-
| `triggerAction` | `"click" \| "hover" \| "none"` | `"click"`
|
|
47
|
+
| Prop | Type | Default | Description |
|
|
48
|
+
| --------------- | ------------------------------ | ----------- | -------------------------------------------------------------------------------- |
|
|
49
|
+
| `title` | `string` | `undefined` | Menu item label |
|
|
50
|
+
| `icon` | `string \| Component` | `undefined` | Icon name or component |
|
|
51
|
+
| `image` | `string` | `undefined` | Image URL (alternative to icon) |
|
|
52
|
+
| `value` | `string` | `undefined` | Current value displayed on the right |
|
|
53
|
+
| `showChevron` | `boolean` | `false` | Shows right chevron for sub-menus (auto-enabled when `submenu` slot is provided) |
|
|
54
|
+
| `isActive` | `boolean` | `false` | Highlights the item (auto-managed when `submenu` slot is provided) |
|
|
55
|
+
| `disabled` | `boolean` | `false` | Disables click interaction |
|
|
56
|
+
| `triggerAction` | `"click" \| "hover" \| "none"` | `"click"` | What interaction opens the item |
|
|
57
57
|
|
|
58
58
|
## Events
|
|
59
59
|
|
|
60
|
-
| Event
|
|
61
|
-
|
|
62
|
-
| `trigger:click` | --
|
|
63
|
-
| `trigger:hover` | --
|
|
60
|
+
| Event | Payload | Description |
|
|
61
|
+
| --------------- | ------- | -------------------------------------------------------------------- |
|
|
62
|
+
| `trigger:click` | -- | Emitted when the item is clicked (only when `triggerAction="click"`) |
|
|
63
|
+
| `trigger:hover` | -- | Emitted when hovered (only when `triggerAction="hover"`) |
|
|
64
64
|
|
|
65
65
|
## Slots
|
|
66
66
|
|
|
67
|
-
| Slot
|
|
68
|
-
|
|
69
|
-
| `trigger`
|
|
70
|
-
| `icon`
|
|
71
|
-
| `title`
|
|
72
|
-
| `additional` | Custom right-side content (replaces `value` display)
|
|
73
|
-
| `submenu`
|
|
74
|
-
| `content`
|
|
67
|
+
| Slot | Description |
|
|
68
|
+
| ------------ | --------------------------------------------------------------------------------------------- |
|
|
69
|
+
| `trigger` | Custom trigger content (replaces the entire row) |
|
|
70
|
+
| `icon` | Custom icon area |
|
|
71
|
+
| `title` | Custom title content |
|
|
72
|
+
| `additional` | Custom right-side content (replaces `value` display) |
|
|
73
|
+
| `submenu` | **Sub-menu items.** Desktop: floating dropdown. Mobile: inline accordion. Chevron auto-shown. |
|
|
74
|
+
| `content` | Legacy slot for arbitrary content below the trigger |
|
|
75
75
|
|
|
76
76
|
## Common Patterns
|
|
77
77
|
|
|
@@ -95,7 +95,7 @@ const currentTheme = ref("light");
|
|
|
95
95
|
<SettingsMenuItem
|
|
96
96
|
icon="lucide-palette"
|
|
97
97
|
title="Theme"
|
|
98
|
-
:value="themes.find(t => t.key === currentTheme)?.name"
|
|
98
|
+
:value="themes.find((t) => t.key === currentTheme)?.name"
|
|
99
99
|
>
|
|
100
100
|
<template #submenu>
|
|
101
101
|
<VcDropdownItem
|
|
@@ -112,42 +112,27 @@ const currentTheme = ref("light");
|
|
|
112
112
|
|
|
113
113
|
**What happens on each platform:**
|
|
114
114
|
|
|
115
|
-
| Platform | Behavior
|
|
116
|
-
|
|
117
|
-
| Desktop
|
|
118
|
-
| Mobile
|
|
115
|
+
| Platform | Behavior |
|
|
116
|
+
| -------- | ----------------------------------------------------------------- |
|
|
117
|
+
| Desktop | Click triggers a floating panel to the right of the item |
|
|
118
|
+
| Mobile | Click expands an inline list below the item with chevron rotation |
|
|
119
119
|
|
|
120
120
|
### Simple action item (no sub-menu)
|
|
121
121
|
|
|
122
122
|
```vue
|
|
123
|
-
<SettingsMenuItem
|
|
124
|
-
icon="lucide-log-out"
|
|
125
|
-
title="Sign Out"
|
|
126
|
-
@trigger:click="handleSignOut"
|
|
127
|
-
/>
|
|
123
|
+
<SettingsMenuItem icon="lucide-log-out" title="Sign Out" @trigger:click="handleSignOut" />
|
|
128
124
|
```
|
|
129
125
|
|
|
130
126
|
### Item with user avatar image
|
|
131
127
|
|
|
132
128
|
```vue
|
|
133
|
-
<SettingsMenuItem
|
|
134
|
-
:image="user.avatarUrl"
|
|
135
|
-
:title="user.displayName"
|
|
136
|
-
:value="user.roleName"
|
|
137
|
-
:show-chevron="true"
|
|
138
|
-
@trigger:click="openUserMenu"
|
|
139
|
-
/>
|
|
129
|
+
<SettingsMenuItem :image="user.avatarUrl" :title="user.displayName" :value="user.roleName" :show-chevron="true" @trigger:click="openUserMenu" />
|
|
140
130
|
```
|
|
141
131
|
|
|
142
132
|
### Disabled item
|
|
143
133
|
|
|
144
134
|
```vue
|
|
145
|
-
<SettingsMenuItem
|
|
146
|
-
icon="lucide-shield"
|
|
147
|
-
title="Security Settings"
|
|
148
|
-
disabled
|
|
149
|
-
value="Admin only"
|
|
150
|
-
/>
|
|
135
|
+
<SettingsMenuItem icon="lucide-shield" title="Security Settings" disabled value="Admin only" />
|
|
151
136
|
```
|
|
152
137
|
|
|
153
138
|
### Custom submenu content
|
|
@@ -169,21 +154,8 @@ The `submenu` slot can contain any content, not just `VcDropdownItem`:
|
|
|
169
154
|
Before (manual dropdown management):
|
|
170
155
|
|
|
171
156
|
```vue
|
|
172
|
-
<SettingsMenuItem
|
|
173
|
-
|
|
174
|
-
icon="lucide-palette"
|
|
175
|
-
title="Theme"
|
|
176
|
-
:value="currentTheme"
|
|
177
|
-
:show-chevron="true"
|
|
178
|
-
:is-active="isOpen"
|
|
179
|
-
@trigger:click="isOpen = !isOpen"
|
|
180
|
-
/>
|
|
181
|
-
<VcDropdownPanel
|
|
182
|
-
v-model:show="isOpen"
|
|
183
|
-
:anchor-ref="menuItemRef?.triggerRef ?? null"
|
|
184
|
-
placement="right-start"
|
|
185
|
-
width="180px"
|
|
186
|
-
>
|
|
157
|
+
<SettingsMenuItem ref="menuItemRef" icon="lucide-palette" title="Theme" :value="currentTheme" :show-chevron="true" :is-active="isOpen" @trigger:click="isOpen = !isOpen" />
|
|
158
|
+
<VcDropdownPanel v-model:show="isOpen" :anchor-ref="menuItemRef?.triggerRef ?? null" placement="right-start" width="180px">
|
|
187
159
|
<!-- options -->
|
|
188
160
|
</VcDropdownPanel>
|
|
189
161
|
```
|
|
@@ -191,11 +163,7 @@ Before (manual dropdown management):
|
|
|
191
163
|
After (submenu slot):
|
|
192
164
|
|
|
193
165
|
```vue
|
|
194
|
-
<SettingsMenuItem
|
|
195
|
-
icon="lucide-palette"
|
|
196
|
-
title="Theme"
|
|
197
|
-
:value="currentTheme"
|
|
198
|
-
>
|
|
166
|
+
<SettingsMenuItem icon="lucide-palette" title="Theme" :value="currentTheme">
|
|
199
167
|
<template #submenu>
|
|
200
168
|
<!-- same options, no wrapper needed -->
|
|
201
169
|
</template>
|
|
@@ -203,6 +171,7 @@ After (submenu slot):
|
|
|
203
171
|
```
|
|
204
172
|
|
|
205
173
|
**What changes:**
|
|
174
|
+
|
|
206
175
|
- Remove `ref`, `isOpen`, `:show-chevron`, `:is-active`, `@trigger:click` toggle -- all auto-managed
|
|
207
176
|
- Remove `VcDropdownPanel` wrapper entirely
|
|
208
177
|
- Move dropdown content into `#submenu` slot
|
|
@@ -10,37 +10,31 @@ On mobile, the sidebar teleports itself out of the normal DOM flow to overlay th
|
|
|
10
10
|
|
|
11
11
|
## Props
|
|
12
12
|
|
|
13
|
-
| Prop
|
|
14
|
-
|
|
15
|
-
| `isExpanded` | `boolean`
|
|
16
|
-
| `position`
|
|
17
|
-
| `render`
|
|
18
|
-
| `title`
|
|
19
|
-
| `closeCross` | `boolean`
|
|
13
|
+
| Prop | Type | Default | Description |
|
|
14
|
+
| ------------ | ----------------------------------- | ---------- | ------------------------------------------ |
|
|
15
|
+
| `isExpanded` | `boolean` | (required) | Whether the sidebar is currently open |
|
|
16
|
+
| `position` | `"left" \| "right"` | `"right"` | Slide-in direction |
|
|
17
|
+
| `render` | `"always" \| "mobile" \| "desktop"` | `"always"` | When to render as a sidebar vs. inline |
|
|
18
|
+
| `title` | `string` | -- | Optional title shown in the sidebar header |
|
|
19
|
+
| `closeCross` | `boolean` | `true` | Whether to show the close button |
|
|
20
20
|
|
|
21
21
|
## Events
|
|
22
22
|
|
|
23
|
-
| Event
|
|
24
|
-
|
|
25
|
-
| `close` | --
|
|
23
|
+
| Event | Payload | Description |
|
|
24
|
+
| ------- | ------- | ---------------------------------------- |
|
|
25
|
+
| `close` | -- | Emitted when the user closes the sidebar |
|
|
26
26
|
|
|
27
27
|
## Slots
|
|
28
28
|
|
|
29
|
-
| Slot
|
|
30
|
-
|
|
31
|
-
| `header`
|
|
32
|
-
| `content` | --
|
|
29
|
+
| Slot | Scope | Description |
|
|
30
|
+
| --------- | ----------------------- | -------------------------------------------------- |
|
|
31
|
+
| `header` | `{ close: () => void }` | Custom header content; receives a `close` function |
|
|
32
|
+
| `content` | -- | The main sidebar body content |
|
|
33
33
|
|
|
34
34
|
## Usage
|
|
35
35
|
|
|
36
36
|
```vue
|
|
37
|
-
<Sidebar
|
|
38
|
-
:is-expanded="showFilters"
|
|
39
|
-
position="right"
|
|
40
|
-
render="always"
|
|
41
|
-
title="Filters"
|
|
42
|
-
@close="showFilters = false"
|
|
43
|
-
>
|
|
37
|
+
<Sidebar :is-expanded="showFilters" position="right" render="always" title="Filters" @close="showFilters = false">
|
|
44
38
|
<template #content>
|
|
45
39
|
<FilterPanel />
|
|
46
40
|
</template>
|
|
@@ -50,11 +44,7 @@ On mobile, the sidebar teleports itself out of the normal DOM flow to overlay th
|
|
|
50
44
|
### Mobile-only sidebar
|
|
51
45
|
|
|
52
46
|
```vue
|
|
53
|
-
<Sidebar
|
|
54
|
-
:is-expanded="showDetails"
|
|
55
|
-
render="mobile"
|
|
56
|
-
@close="showDetails = false"
|
|
57
|
-
>
|
|
47
|
+
<Sidebar :is-expanded="showDetails" render="mobile" @close="showDetails = false">
|
|
58
48
|
<template #content>
|
|
59
49
|
<DetailView />
|
|
60
50
|
</template>
|
|
@@ -50,8 +50,8 @@ const { register, setTheme, currentTheme } = useTheme();
|
|
|
50
50
|
|
|
51
51
|
// Register available themes during app initialization
|
|
52
52
|
register([
|
|
53
|
-
{ key: "light" },
|
|
54
|
-
{ key: "dark" },
|
|
53
|
+
{ key: "light" }, // Default light theme
|
|
54
|
+
{ key: "dark" }, // Dark mode
|
|
55
55
|
{ key: "contrast" }, // High-contrast accessibility theme
|
|
56
56
|
]);
|
|
57
57
|
|
package/runtime/knowledge/docs/shell/components/user-dropdown-button/user-dropdown-button.docs.md
CHANGED
|
@@ -26,12 +26,12 @@ import { UserDropdownButton } from "@vc-shell/framework";
|
|
|
26
26
|
|
|
27
27
|
## Key Props
|
|
28
28
|
|
|
29
|
-
| Prop
|
|
30
|
-
|
|
31
|
-
| `name`
|
|
32
|
-
| `role`
|
|
33
|
-
| `avatarUrl` | `string`
|
|
34
|
-
| `disabled`
|
|
29
|
+
| Prop | Type | Default | Description |
|
|
30
|
+
| ----------- | --------- | ----------- | ----------------------------- |
|
|
31
|
+
| `name` | `string` | `undefined` | User display name |
|
|
32
|
+
| `role` | `string` | `undefined` | User role label |
|
|
33
|
+
| `avatarUrl` | `string` | `undefined` | URL for the user avatar image |
|
|
34
|
+
| `disabled` | `boolean` | `false` | Prevents menu from opening |
|
|
35
35
|
|
|
36
36
|
## Recipe: Wiring to User Management Composable
|
|
37
37
|
|
|
@@ -45,9 +45,7 @@ import { useUserManagement } from "@vc-shell/framework";
|
|
|
45
45
|
|
|
46
46
|
const { currentUser } = useUserManagement();
|
|
47
47
|
|
|
48
|
-
const displayName = computed(() =>
|
|
49
|
-
currentUser.value ? `${currentUser.value.firstName} ${currentUser.value.lastName}` : ""
|
|
50
|
-
);
|
|
48
|
+
const displayName = computed(() => (currentUser.value ? `${currentUser.value.firstName} ${currentUser.value.lastName}` : ""));
|
|
51
49
|
const role = computed(() => currentUser.value?.roles?.[0]?.name ?? "");
|
|
52
50
|
const avatarUrl = computed(() => currentUser.value?.photoUrl);
|
|
53
51
|
</script>
|
|
@@ -18,11 +18,11 @@ The charts are designed to work inside `DashboardWidgetCard` components, automat
|
|
|
18
18
|
|
|
19
19
|
## Components
|
|
20
20
|
|
|
21
|
-
| Component
|
|
22
|
-
|
|
23
|
-
| `DashboardLineChart`
|
|
24
|
-
| `DashboardBarChart`
|
|
25
|
-
| `DashboardDonutChart` | Circular chart for part-to-whole relationships
|
|
21
|
+
| Component | Description |
|
|
22
|
+
| --------------------- | ------------------------------------------------------- |
|
|
23
|
+
| `DashboardLineChart` | Time-series or continuous data with connected points |
|
|
24
|
+
| `DashboardBarChart` | Grouped or single bar charts for categorical comparison |
|
|
25
|
+
| `DashboardDonutChart` | Circular chart for part-to-whole relationships |
|
|
26
26
|
|
|
27
27
|
## Basic Usage
|
|
28
28
|
|
|
@@ -54,35 +54,38 @@ const config: ChartConfig = {
|
|
|
54
54
|
|
|
55
55
|
## Key Props (shared across chart types)
|
|
56
56
|
|
|
57
|
-
| Prop
|
|
58
|
-
|
|
59
|
-
| `data`
|
|
60
|
-
| `config`
|
|
61
|
-
| `xKey`
|
|
62
|
-
| `yKeys`
|
|
63
|
-
| `showTooltip` | `boolean`
|
|
64
|
-
| `showLegend`
|
|
65
|
-
| `rangeStart`
|
|
66
|
-
| `rangeEnd`
|
|
57
|
+
| Prop | Type | Default | Description |
|
|
58
|
+
| ------------- | ------------- | ----------- | ------------------------------------ |
|
|
59
|
+
| `data` | `T[]` | -- | Array of data points |
|
|
60
|
+
| `config` | `ChartConfig` | -- | Series color and label configuration |
|
|
61
|
+
| `xKey` | `keyof T` | -- | Key for x-axis values (line/bar) |
|
|
62
|
+
| `yKeys` | `(keyof T)[]` | -- | Keys for y-axis series (line/bar) |
|
|
63
|
+
| `showTooltip` | `boolean` | `true` | Enable hover tooltips |
|
|
64
|
+
| `showLegend` | `boolean` | `true` | Show color legend below chart |
|
|
65
|
+
| `rangeStart` | `number` | `undefined` | Filter data from this x value |
|
|
66
|
+
| `rangeEnd` | `number` | `undefined` | Filter data up to this x value |
|
|
67
67
|
|
|
68
68
|
### Donut-specific props
|
|
69
69
|
|
|
70
|
-
| Prop
|
|
71
|
-
|
|
72
|
-
| `valueKey`
|
|
73
|
-
| `centralLabel`
|
|
74
|
-
| `centralSubLabel` | `string`
|
|
75
|
-
| `arcWidth`
|
|
70
|
+
| Prop | Type | Default | Description |
|
|
71
|
+
| ----------------- | --------- | ----------- | ------------------------------ |
|
|
72
|
+
| `valueKey` | `keyof T` | -- | Key for segment values |
|
|
73
|
+
| `centralLabel` | `string` | `undefined` | Large text in donut center |
|
|
74
|
+
| `centralSubLabel` | `string` | `undefined` | Small text below central label |
|
|
75
|
+
| `arcWidth` | `number` | `60` | Donut arc thickness |
|
|
76
76
|
|
|
77
77
|
## ChartConfig Type
|
|
78
78
|
|
|
79
79
|
The `ChartConfig` object maps data field names to their visual configuration:
|
|
80
80
|
|
|
81
81
|
```typescript
|
|
82
|
-
type ChartConfig = Record<
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
82
|
+
type ChartConfig = Record<
|
|
83
|
+
string,
|
|
84
|
+
{
|
|
85
|
+
label: string; // Display name in legend and tooltip
|
|
86
|
+
color: string; // CSS color value (hex, var(), rgb, etc.)
|
|
87
|
+
}
|
|
88
|
+
>;
|
|
86
89
|
```
|
|
87
90
|
|
|
88
91
|
## Common Patterns
|
|
@@ -117,26 +120,13 @@ const salesConfig: ChartConfig = {
|
|
|
117
120
|
### Bar Chart with Formatted Axes
|
|
118
121
|
|
|
119
122
|
```vue
|
|
120
|
-
<DashboardBarChart
|
|
121
|
-
:data="quarterlyData"
|
|
122
|
-
:config="quarterConfig"
|
|
123
|
-
x-key="quarter"
|
|
124
|
-
:y-keys="['electronics', 'clothing']"
|
|
125
|
-
:x-tick-format="(v) => ['Q1', 'Q2', 'Q3', 'Q4'][v]"
|
|
126
|
-
:y-tick-format="(v) => '$' + (v / 1000).toFixed(0) + 'k'"
|
|
127
|
-
/>
|
|
123
|
+
<DashboardBarChart :data="quarterlyData" :config="quarterConfig" x-key="quarter" :y-keys="['electronics', 'clothing']" :x-tick-format="(v) => ['Q1', 'Q2', 'Q3', 'Q4'][v]" :y-tick-format="(v) => '$' + (v / 1000).toFixed(0) + 'k'" />
|
|
128
124
|
```
|
|
129
125
|
|
|
130
126
|
### Donut Chart
|
|
131
127
|
|
|
132
128
|
```vue
|
|
133
|
-
<DashboardDonutChart
|
|
134
|
-
:data="categoryData"
|
|
135
|
-
:config="categoryConfig"
|
|
136
|
-
value-key="count"
|
|
137
|
-
central-label="1,000"
|
|
138
|
-
central-sub-label="Total Products"
|
|
139
|
-
/>
|
|
129
|
+
<DashboardDonutChart :data="categoryData" :config="categoryConfig" value-key="count" central-label="1,000" central-sub-label="Total Products" />
|
|
140
130
|
```
|
|
141
131
|
|
|
142
132
|
### Chart Inside a Widget Card
|
package/runtime/knowledge/docs/shell/dashboard/dashboard-widget-card/dashboard-widget-card.docs.md
CHANGED
|
@@ -24,7 +24,10 @@ import { DashboardWidgetCard } from "@vc-shell/framework";
|
|
|
24
24
|
</script>
|
|
25
25
|
|
|
26
26
|
<template>
|
|
27
|
-
<DashboardWidgetCard
|
|
27
|
+
<DashboardWidgetCard
|
|
28
|
+
header="Products"
|
|
29
|
+
icon="lucide-package-open"
|
|
30
|
+
>
|
|
28
31
|
<template #content>
|
|
29
32
|
<div class="tw-p-4">Widget body content here</div>
|
|
30
33
|
</template>
|
|
@@ -34,21 +37,21 @@ import { DashboardWidgetCard } from "@vc-shell/framework";
|
|
|
34
37
|
|
|
35
38
|
## Key Props
|
|
36
39
|
|
|
37
|
-
| Prop
|
|
38
|
-
|
|
39
|
-
| `header`
|
|
40
|
-
| `icon`
|
|
41
|
-
| `loading` | `boolean` | `false`
|
|
40
|
+
| Prop | Type | Default | Description |
|
|
41
|
+
| --------- | --------- | ----------- | ----------------------------------- |
|
|
42
|
+
| `header` | `string` | `undefined` | Card title text |
|
|
43
|
+
| `icon` | `string` | `undefined` | Icon displayed next to the header |
|
|
44
|
+
| `loading` | `boolean` | `false` | Shows a loading overlay on the body |
|
|
42
45
|
|
|
43
46
|
## Slots
|
|
44
47
|
|
|
45
|
-
| Slot
|
|
46
|
-
|
|
47
|
-
| `header`
|
|
48
|
-
| `actions` | Action buttons in the header row (right side)
|
|
49
|
-
| `stats`
|
|
50
|
-
| `content` | Main body content
|
|
51
|
-
| `footer`
|
|
48
|
+
| Slot | Description |
|
|
49
|
+
| --------- | --------------------------------------------------------------- |
|
|
50
|
+
| `header` | Override the entire header area (replaces default icon + title) |
|
|
51
|
+
| `actions` | Action buttons in the header row (right side) |
|
|
52
|
+
| `stats` | KPI stat items below the header |
|
|
53
|
+
| `content` | Main body content |
|
|
54
|
+
| `footer` | Footer area with links or actions |
|
|
52
55
|
|
|
53
56
|
## Common Patterns
|
|
54
57
|
|
|
@@ -134,7 +137,11 @@ onMounted(() => loadData());
|
|
|
134
137
|
</script>
|
|
135
138
|
|
|
136
139
|
<template>
|
|
137
|
-
<DashboardWidgetCard
|
|
140
|
+
<DashboardWidgetCard
|
|
141
|
+
header="System Status"
|
|
142
|
+
icon="lucide-activity"
|
|
143
|
+
:loading="loading"
|
|
144
|
+
>
|
|
138
145
|
<template #content>
|
|
139
146
|
<!-- Content shown when not loading -->
|
|
140
147
|
</template>
|
|
@@ -164,11 +171,11 @@ dashboard.register({
|
|
|
164
171
|
|
|
165
172
|
## Companion Components
|
|
166
173
|
|
|
167
|
-
| Component
|
|
168
|
-
|
|
169
|
-
| `DashboardStatItem` | Single KPI stat with value, label, and optional color variant
|
|
170
|
-
| `DashboardFeedList` | Scrollable list container for feed rows
|
|
171
|
-
| `DashboardFeedRow`
|
|
174
|
+
| Component | Description |
|
|
175
|
+
| ------------------- | --------------------------------------------------------------- |
|
|
176
|
+
| `DashboardStatItem` | Single KPI stat with value, label, and optional color variant |
|
|
177
|
+
| `DashboardFeedList` | Scrollable list container for feed rows |
|
|
178
|
+
| `DashboardFeedRow` | Individual feed item with icon, title, subtitle, and meta slots |
|
|
172
179
|
|
|
173
180
|
## Tip: Set a Minimum Height
|
|
174
181
|
|