@vc-shell/vc-app-skill 2.0.0-alpha.33 → 2.0.0-alpha.34
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 +78 -54
- package/README.md +42 -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 +18 -7
- 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 +28 -24
- 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 +27 -25
- package/runtime/knowledge/docs/core/composables/useBladeRegistry/useBladeRegistry.docs.md +15 -15
- package/runtime/knowledge/docs/core/composables/useBladeWidgets/index.docs.md +43 -47
- 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 +9 -9
- 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/usePlatformLocaleSync/usePlatformLocaleSync.docs.md +28 -0
- 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 +22 -13
- 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 +79 -62
- 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 +91 -83
- 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 +5 -5
- 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 +11 -17
- 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 +100 -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 +55 -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 +92 -65
- package/runtime/knowledge/docs/ui/components/molecules/vc-checkbox-group/vc-checkbox-group.docs.md +22 -36
- package/runtime/knowledge/docs/ui/components/molecules/vc-color-input/vc-color-input.docs.md +65 -23
- package/runtime/knowledge/docs/ui/components/molecules/vc-date-picker/vc-date-picker.docs.md +52 -73
- 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 +56 -73
- package/runtime/knowledge/docs/ui/components/molecules/vc-field/vc-field.docs.md +61 -27
- package/runtime/knowledge/docs/ui/components/molecules/vc-file-upload/vc-file-upload.docs.md +42 -50
- 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 +109 -131
- package/runtime/knowledge/docs/ui/components/molecules/vc-input-currency/vc-input-currency.docs.md +47 -88
- package/runtime/knowledge/docs/ui/components/molecules/vc-input-dropdown/vc-input-dropdown.docs.md +50 -64
- 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 +57 -65
- 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 +55 -20
- package/runtime/knowledge/docs/ui/components/molecules/vc-radio-group/vc-radio-group.docs.md +21 -35
- package/runtime/knowledge/docs/ui/components/molecules/vc-rating/vc-rating.docs.md +38 -33
- package/runtime/knowledge/docs/ui/components/molecules/vc-select/vc-select.docs.md +72 -83
- package/runtime/knowledge/docs/ui/components/molecules/vc-slider/vc-slider.docs.md +21 -16
- package/runtime/knowledge/docs/ui/components/molecules/vc-switch/vc-switch.docs.md +55 -64
- package/runtime/knowledge/docs/ui/components/molecules/vc-textarea/vc-textarea.docs.md +51 -70
- 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 +90 -75
- package/runtime/knowledge/docs/ui/components/organisms/vc-data-table/composables/table-composables.docs.md +99 -48
- package/runtime/knowledge/docs/ui/components/organisms/vc-data-table/vc-data-table.docs.md +548 -367
- 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 +17 -8
- package/runtime/knowledge/migration-prompts/blade-props-migration.md +1 -2
- 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 +8 -3
- package/runtime/knowledge/migration-prompts/nswag-migration.md +25 -29
- 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 +48 -27
- 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 +241 -62
|
@@ -4,18 +4,18 @@ A single-line text input component for forms in vc-shell applications. Supports
|
|
|
4
4
|
|
|
5
5
|
## When to Use
|
|
6
6
|
|
|
7
|
-
| Scenario
|
|
8
|
-
|
|
9
|
-
| Single-line text: names, emails, URLs, phone numbers | **VcInput**
|
|
10
|
-
| Password entry with show/hide toggle
|
|
11
|
-
| Numeric entry (integers or decimals)
|
|
12
|
-
| Input with prefix/suffix text or inner icons
|
|
13
|
-
| Multi-line text
|
|
14
|
-
| Rich text / HTML editing
|
|
15
|
-
| Selecting from a dropdown list
|
|
16
|
-
| Currency with formatting and currency selector
|
|
17
|
-
| Date or date-time picking
|
|
18
|
-
| Color selection
|
|
7
|
+
| Scenario | Component |
|
|
8
|
+
| ---------------------------------------------------- | ---------------------------------------------------------------------- |
|
|
9
|
+
| Single-line text: names, emails, URLs, phone numbers | **VcInput** |
|
|
10
|
+
| Password entry with show/hide toggle | **VcInput** `type="password"` |
|
|
11
|
+
| Numeric entry (integers or decimals) | **VcInput** `type="number"` or `type="integer"` |
|
|
12
|
+
| Input with prefix/suffix text or inner icons | **VcInput** with `prefix`/`suffix` props or slots |
|
|
13
|
+
| Multi-line text | [VcTextarea](../vc-textarea/) |
|
|
14
|
+
| Rich text / HTML editing | [VcEditor](../vc-editor/) |
|
|
15
|
+
| Selecting from a dropdown list | [VcSelect](../vc-select/) |
|
|
16
|
+
| Currency with formatting and currency selector | [VcInputCurrency](../vc-input-currency/) |
|
|
17
|
+
| Date or date-time picking | [VcDatePicker](../vc-date-picker/) (also available via `type="date"`) |
|
|
18
|
+
| Color selection | [VcColorInput](../vc-color-input/) (also available via `type="color"`) |
|
|
19
19
|
|
|
20
20
|
> **Note:** When you set `type="date"`, `type="datetime-local"`, or `type="color"`, VcInput internally delegates to VcDatePicker or VcColorInput. All props are forwarded automatically. You can use VcInput as a single entry point for all these types, but for date/color-specific options (like `datePickerOptions`), consider using the dedicated component directly.
|
|
21
21
|
|
|
@@ -27,7 +27,11 @@ The simplest possible usage -- a text input bound to a reactive ref:
|
|
|
27
27
|
|
|
28
28
|
```vue
|
|
29
29
|
<template>
|
|
30
|
-
<VcInput
|
|
30
|
+
<VcInput
|
|
31
|
+
v-model="productName"
|
|
32
|
+
label="Product Name"
|
|
33
|
+
placeholder="Enter product name"
|
|
34
|
+
/>
|
|
31
35
|
</template>
|
|
32
36
|
|
|
33
37
|
<script setup lang="ts">
|
|
@@ -46,19 +50,19 @@ This renders a labeled text input with placeholder text. The value is two-way bo
|
|
|
46
50
|
|
|
47
51
|
VcInput supports the following `type` values. Each type adjusts the native `<input>` behavior and, in some cases, adds extra UI or filtering logic.
|
|
48
52
|
|
|
49
|
-
| Type
|
|
50
|
-
|
|
51
|
-
| `text` (default) | Standard single-line text input
|
|
52
|
-
| `password`
|
|
53
|
-
| `email`
|
|
54
|
-
| `number`
|
|
55
|
-
| `integer`
|
|
56
|
-
| `tel`
|
|
57
|
-
| `url`
|
|
58
|
-
| `time`
|
|
59
|
-
| `date`
|
|
60
|
-
| `datetime-local` | Delegates to **VcDatePicker** in datetime mode
|
|
61
|
-
| `color`
|
|
53
|
+
| Type | Behavior |
|
|
54
|
+
| ---------------- | ------------------------------------------------------------------------------------ |
|
|
55
|
+
| `text` (default) | Standard single-line text input |
|
|
56
|
+
| `password` | Masked input with a built-in show/hide toggle button |
|
|
57
|
+
| `email` | Native email keyboard on mobile, browser email validation hints |
|
|
58
|
+
| `number` | Numeric input; blocks `-`, `e`, `+` keys; emits parsed `number` or `null` |
|
|
59
|
+
| `integer` | Like `number` but blocks decimal points and non-digit keys; emits truncated integers |
|
|
60
|
+
| `tel` | Telephone keyboard on mobile devices |
|
|
61
|
+
| `url` | URL keyboard on mobile devices |
|
|
62
|
+
| `time` | Native time input |
|
|
63
|
+
| `date` | Delegates to **VcDatePicker** with locale-aware formatting |
|
|
64
|
+
| `datetime-local` | Delegates to **VcDatePicker** in datetime mode |
|
|
65
|
+
| `color` | Delegates to **VcColorInput** |
|
|
62
66
|
|
|
63
67
|
### Number vs. Integer
|
|
64
68
|
|
|
@@ -124,12 +128,7 @@ const form = reactive({
|
|
|
124
128
|
### Multiple Rules
|
|
125
129
|
|
|
126
130
|
```vue
|
|
127
|
-
<Field
|
|
128
|
-
v-slot="{ errorMessage, handleChange, errors }"
|
|
129
|
-
:model-value="form.email"
|
|
130
|
-
name="contactEmail"
|
|
131
|
-
:rules="{ required: true, email: true, max: 128 }"
|
|
132
|
-
>
|
|
131
|
+
<Field v-slot="{ errorMessage, handleChange, errors }" :model-value="form.email" name="contactEmail" :rules="{ required: true, email: true, max: 128 }">
|
|
133
132
|
<VcInput
|
|
134
133
|
v-model="form.email"
|
|
135
134
|
type="email"
|
|
@@ -192,12 +191,7 @@ Shows a spinning loader icon inside the field. The input remains interactive.
|
|
|
192
191
|
Error state is activated when `error` is `true` or `errorMessage` is truthy. The border turns red and an error ring appears. If `errorMessage` is provided, it displays below the field with a slide-up animation.
|
|
193
192
|
|
|
194
193
|
```vue
|
|
195
|
-
<VcInput
|
|
196
|
-
v-model="email"
|
|
197
|
-
label="Email"
|
|
198
|
-
:error="true"
|
|
199
|
-
error-message="Please enter a valid email address"
|
|
200
|
-
/>
|
|
194
|
+
<VcInput v-model="email" label="Email" :error="true" error-message="Please enter a valid email address" />
|
|
201
195
|
```
|
|
202
196
|
|
|
203
197
|
### Required
|
|
@@ -252,7 +246,11 @@ All four positional slots receive a `{ focus }` function in their scope, which y
|
|
|
252
246
|
|
|
253
247
|
```vue
|
|
254
248
|
<template #prepend-inner="{ focus }">
|
|
255
|
-
<VcIcon
|
|
249
|
+
<VcIcon
|
|
250
|
+
icon="lucide-search"
|
|
251
|
+
@click="focus"
|
|
252
|
+
class="tw-cursor-pointer"
|
|
253
|
+
/>
|
|
256
254
|
</template>
|
|
257
255
|
```
|
|
258
256
|
|
|
@@ -273,13 +271,13 @@ Replaces the native `<input>` element entirely while keeping the VcInput shell (
|
|
|
273
271
|
</VcInput>
|
|
274
272
|
```
|
|
275
273
|
|
|
276
|
-
| Scope property | Type
|
|
277
|
-
|
|
278
|
-
| `modelValue`
|
|
279
|
-
| `emitValue`
|
|
280
|
-
| `placeholder`
|
|
281
|
-
| `editable`
|
|
282
|
-
| `focused`
|
|
274
|
+
| Scope property | Type | Description |
|
|
275
|
+
| -------------- | ---------------------------------- | ------------------------------------------------- |
|
|
276
|
+
| `modelValue` | `string \| number \| Date \| null` | Current field value |
|
|
277
|
+
| `emitValue` | `(value) => void` | Call this to update the model (respects debounce) |
|
|
278
|
+
| `placeholder` | `string \| undefined` | The placeholder prop value |
|
|
279
|
+
| `editable` | `boolean \| undefined` | Whether the field is disabled |
|
|
280
|
+
| `focused` | `boolean \| undefined` | Whether autofocus is set |
|
|
283
281
|
|
|
284
282
|
### error / hint slots
|
|
285
283
|
|
|
@@ -302,10 +300,10 @@ Override the default error message or hint text rendering.
|
|
|
302
300
|
|
|
303
301
|
Two size variants are available:
|
|
304
302
|
|
|
305
|
-
| Size
|
|
306
|
-
|
|
307
|
-
| `"default"` | 36px
|
|
308
|
-
| `"small"`
|
|
303
|
+
| Size | Height | Use case |
|
|
304
|
+
| ----------- | ------ | ------------------------------------------ |
|
|
305
|
+
| `"default"` | 36px | Standard forms, blade detail pages |
|
|
306
|
+
| `"small"` | 32px | Compact UI, table inline editing, toolbars |
|
|
309
307
|
|
|
310
308
|
```vue
|
|
311
309
|
<VcInput v-model="tag" label="Tag" size="small" placeholder="Enter tag" />
|
|
@@ -342,11 +340,7 @@ Prefix and suffix elements are non-interactive (`pointer-events: none`) and do n
|
|
|
342
340
|
Delays the `update:modelValue` emission by the specified number of milliseconds. Useful for search fields to avoid firing API requests on every keystroke.
|
|
343
341
|
|
|
344
342
|
```vue
|
|
345
|
-
<VcInput
|
|
346
|
-
v-model="searchQuery"
|
|
347
|
-
placeholder="Search products..."
|
|
348
|
-
:debounce="300"
|
|
349
|
-
/>
|
|
343
|
+
<VcInput v-model="searchQuery" placeholder="Search products..." :debounce="300" />
|
|
350
344
|
```
|
|
351
345
|
|
|
352
346
|
When debounce is set, the internal `temp` value updates immediately (so the user sees their typing), but the `v-model` update and any `@update:model-value` handlers fire only after the debounce period elapses without further input.
|
|
@@ -358,12 +352,7 @@ When debounce is set, the internal `temp` value updates immediately (so the user
|
|
|
358
352
|
When a field supports multiple languages, enable the language badge on the label:
|
|
359
353
|
|
|
360
354
|
```vue
|
|
361
|
-
<VcInput
|
|
362
|
-
v-model="localizedName"
|
|
363
|
-
label="Product Name"
|
|
364
|
-
multilanguage
|
|
365
|
-
current-language="en-US"
|
|
366
|
-
/>
|
|
355
|
+
<VcInput v-model="localizedName" label="Product Name" multilanguage current-language="en-US" />
|
|
367
356
|
```
|
|
368
357
|
|
|
369
358
|
This renders a small language indicator (e.g., "EN-US") next to the label, signaling to the user which language they are editing.
|
|
@@ -375,12 +364,7 @@ This renders a small language indicator (e.g., "EN-US") next to the label, signa
|
|
|
375
364
|
Display additional context about a field via a tooltip icon next to the label:
|
|
376
365
|
|
|
377
366
|
```vue
|
|
378
|
-
<VcInput
|
|
379
|
-
v-model="slug"
|
|
380
|
-
label="URL Slug"
|
|
381
|
-
tooltip="The URL-friendly version of the product name. Used in the storefront URL."
|
|
382
|
-
placeholder="my-product"
|
|
383
|
-
/>
|
|
367
|
+
<VcInput v-model="slug" label="URL Slug" tooltip="The URL-friendly version of the product name. Used in the storefront URL." placeholder="my-product" />
|
|
384
368
|
```
|
|
385
369
|
|
|
386
370
|
---
|
|
@@ -616,12 +600,7 @@ The `required` prop on VcInput only adds a visual asterisk. It does NOT perform
|
|
|
616
600
|
<VcInput v-model="form.name" label="Name" required />
|
|
617
601
|
|
|
618
602
|
<!-- CORRECT: Field enforces the rule; VcInput displays the result -->
|
|
619
|
-
<Field
|
|
620
|
-
v-slot="{ errorMessage, handleChange, errors }"
|
|
621
|
-
:model-value="form.name"
|
|
622
|
-
name="name"
|
|
623
|
-
rules="required"
|
|
624
|
-
>
|
|
603
|
+
<Field v-slot="{ errorMessage, handleChange, errors }" :model-value="form.name" name="name" rules="required">
|
|
625
604
|
<VcInput
|
|
626
605
|
v-model="form.name"
|
|
627
606
|
label="Name"
|
|
@@ -675,51 +654,51 @@ VcInput blocks the minus key for both `number` and `integer` types. If you need
|
|
|
675
654
|
|
|
676
655
|
### Props
|
|
677
656
|
|
|
678
|
-
| Prop
|
|
679
|
-
|
|
680
|
-
| `modelValue`
|
|
681
|
-
| `type`
|
|
682
|
-
| `label`
|
|
683
|
-
| `placeholder`
|
|
684
|
-
| `hint`
|
|
685
|
-
| `tooltip`
|
|
686
|
-
| `prefix`
|
|
687
|
-
| `suffix`
|
|
688
|
-
| `name`
|
|
689
|
-
| `clearable`
|
|
690
|
-
| `disabled`
|
|
691
|
-
| `required`
|
|
692
|
-
| `loading`
|
|
693
|
-
| `autofocus`
|
|
694
|
-
| `error`
|
|
695
|
-
| `errorMessage`
|
|
696
|
-
| `debounce`
|
|
697
|
-
| `maxlength`
|
|
698
|
-
| `step`
|
|
699
|
-
| `size`
|
|
700
|
-
| `multilanguage`
|
|
701
|
-
| `currentLanguage`
|
|
702
|
-
| `datePickerOptions` | `VueDatePickerProps`
|
|
657
|
+
| Prop | Type | Default | Description |
|
|
658
|
+
| ------------------- | ------------------------------------------------------------------------------------------------------------------------------- | ----------- | ----------------------------------------------------------------------------------------------- |
|
|
659
|
+
| `modelValue` | `string \| number \| Date \| null` | `undefined` | Bound value via `v-model` |
|
|
660
|
+
| `type` | `"text" \| "password" \| "email" \| "tel" \| "url" \| "time" \| "number" \| "integer" \| "date" \| "datetime-local" \| "color"` | `"text"` | Input type. `date`/`datetime-local` delegate to VcDatePicker; `color` delegates to VcColorInput |
|
|
661
|
+
| `label` | `string` | -- | Label text displayed above the field |
|
|
662
|
+
| `placeholder` | `string` | -- | Placeholder text inside the field |
|
|
663
|
+
| `hint` | `string` | -- | Help text displayed below the field |
|
|
664
|
+
| `tooltip` | `string` | -- | Tooltip text shown on hover next to the label |
|
|
665
|
+
| `prefix` | `string` | -- | Static text rendered before the input value |
|
|
666
|
+
| `suffix` | `string` | -- | Static text rendered after the input value |
|
|
667
|
+
| `name` | `string` | `"Field"` | HTML `name` attribute on the native input |
|
|
668
|
+
| `clearable` | `boolean` | `false` | Shows a clear (x) button when the field has a value |
|
|
669
|
+
| `disabled` | `boolean` | `false` | Disables the input (also inherits from `VcInputGroup` context) |
|
|
670
|
+
| `required` | `boolean` | `false` | Adds a red asterisk to the label (visual only, no validation) |
|
|
671
|
+
| `loading` | `boolean` | `false` | Shows a spinning loader icon inside the field |
|
|
672
|
+
| `autofocus` | `boolean` | `false` | Auto-focuses the input on mount |
|
|
673
|
+
| `error` | `boolean` | `false` | Activates error styling (red border and ring) |
|
|
674
|
+
| `errorMessage` | `string` | -- | Error text shown below the field; also activates error styling when truthy |
|
|
675
|
+
| `debounce` | `string \| number` | -- | Delay in ms before emitting model updates |
|
|
676
|
+
| `maxlength` | `string \| number` | `"1024"` | Maximum character length |
|
|
677
|
+
| `step` | `string` | `"1"` | Step granularity for number inputs |
|
|
678
|
+
| `size` | `"default" \| "small"` | `"default"` | Field height variant (36px / 32px) |
|
|
679
|
+
| `multilanguage` | `boolean` | `false` | Shows a language indicator badge on the label |
|
|
680
|
+
| `currentLanguage` | `string` | -- | Language code to display in the multilanguage badge |
|
|
681
|
+
| `datePickerOptions` | `VueDatePickerProps` | -- | Options forwarded to VcDatePicker (only when `type` is `date` or `datetime-local`) |
|
|
703
682
|
|
|
704
683
|
### Events
|
|
705
684
|
|
|
706
|
-
| Event
|
|
707
|
-
|
|
685
|
+
| Event | Payload | Description |
|
|
686
|
+
| ------------------- | ----------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------- |
|
|
708
687
|
| `update:modelValue` | `string \| number \| Date \| null \| undefined` | Emitted when the value changes. For `number`/`integer` types, the payload is a parsed number or `null`. Respects `debounce` if set. |
|
|
709
|
-
| `blur`
|
|
710
|
-
| `focus`
|
|
688
|
+
| `blur` | `Event` | Emitted when the native input loses focus |
|
|
689
|
+
| `focus` | -- | Emitted when the native input receives focus |
|
|
711
690
|
|
|
712
691
|
### Slots
|
|
713
692
|
|
|
714
|
-
| Slot
|
|
715
|
-
|
|
716
|
-
| `prepend`
|
|
717
|
-
| `append`
|
|
718
|
-
| `prepend-inner` | `{ focus: () => void }`
|
|
719
|
-
| `append-inner`
|
|
720
|
-
| `control`
|
|
721
|
-
| `error`
|
|
722
|
-
| `hint`
|
|
693
|
+
| Slot | Scope | Description |
|
|
694
|
+
| --------------- | ----------------------------------------------------------- | ----------------------------------------------------------- |
|
|
695
|
+
| `prepend` | `{ focus: () => void }` | Content **outside** the field border, to the left |
|
|
696
|
+
| `append` | `{ focus: () => void }` | Content **outside** the field border, to the right |
|
|
697
|
+
| `prepend-inner` | `{ focus: () => void }` | Content **inside** the field border, to the left |
|
|
698
|
+
| `append-inner` | `{ focus: () => void }` | Content **inside** the field border, to the right |
|
|
699
|
+
| `control` | `{ editable, focused, modelValue, emitValue, placeholder }` | Replaces the native `<input>` element entirely |
|
|
700
|
+
| `error` | -- | Custom error message markup (replaces default VcHint error) |
|
|
701
|
+
| `hint` | -- | Custom hint text markup (replaces default VcHint) |
|
|
723
702
|
|
|
724
703
|
---
|
|
725
704
|
|
|
@@ -727,25 +706,25 @@ VcInput blocks the minus key for both `number` and `integer` types. If you need
|
|
|
727
706
|
|
|
728
707
|
VcInput uses CSS custom properties for theming, defined on `:root`. Override these to customize the appearance across your application.
|
|
729
708
|
|
|
730
|
-
| Variable
|
|
731
|
-
|
|
732
|
-
| `--input-height`
|
|
733
|
-
| `--input-height-small`
|
|
734
|
-
| `--input-border-radius`
|
|
735
|
-
| `--input-border-color`
|
|
736
|
-
| `--input-padding`
|
|
737
|
-
| `--input-background-color`
|
|
738
|
-
| `--input-placeholder-color`
|
|
739
|
-
| `--input-text-color`
|
|
740
|
-
| `--input-clear-color`
|
|
741
|
-
| `--input-clear-color-hover`
|
|
742
|
-
| `--input-disabled-text-color` | `var(--neutrals-500)`
|
|
743
|
-
| `--input-disabled-bg-color`
|
|
744
|
-
| `--input-text-color-error`
|
|
745
|
-
| `--input-border-color-error`
|
|
746
|
-
| `--input-border-color-focus`
|
|
747
|
-
| `--input-focus-ring-color`
|
|
748
|
-
| `--input-error-ring-color`
|
|
709
|
+
| Variable | Default | Description |
|
|
710
|
+
| ----------------------------- | ---------------------- | ---------------------------------------------- |
|
|
711
|
+
| `--input-height` | `36px` | Height of the default size field |
|
|
712
|
+
| `--input-height-small` | `32px` | Height of the small size field |
|
|
713
|
+
| `--input-border-radius` | `6px` | Border radius of the field wrapper |
|
|
714
|
+
| `--input-border-color` | `var(--neutrals-300)` | Border color in the normal state |
|
|
715
|
+
| `--input-padding` | `12px` | Horizontal padding inside the field |
|
|
716
|
+
| `--input-background-color` | `var(--additional-50)` | Background color of the field |
|
|
717
|
+
| `--input-placeholder-color` | `var(--neutrals-400)` | Color of placeholder text |
|
|
718
|
+
| `--input-text-color` | `var(--neutrals-800)` | Color of the input text |
|
|
719
|
+
| `--input-clear-color` | `var(--neutrals-400)` | Color of the clear and show/hide buttons |
|
|
720
|
+
| `--input-clear-color-hover` | `var(--neutrals-600)` | Hover color of the clear and show/hide buttons |
|
|
721
|
+
| `--input-disabled-text-color` | `var(--neutrals-500)` | Text color when disabled |
|
|
722
|
+
| `--input-disabled-bg-color` | `var(--neutrals-200)` | Background color when disabled |
|
|
723
|
+
| `--input-text-color-error` | `var(--danger-500)` | Text color in error state |
|
|
724
|
+
| `--input-border-color-error` | `var(--danger-500)` | Border color in error state |
|
|
725
|
+
| `--input-border-color-focus` | `var(--primary-500)` | Border color when focused |
|
|
726
|
+
| `--input-focus-ring-color` | `var(--primary-100)` | Focus ring color (3px outline) |
|
|
727
|
+
| `--input-error-ring-color` | `var(--danger-100)` | Error ring color (3px outline) |
|
|
749
728
|
|
|
750
729
|
### Theming Example
|
|
751
730
|
|
|
@@ -792,4 +771,3 @@ VcInput follows WAI-ARIA best practices for form fields:
|
|
|
792
771
|
When placed inside a `VcBlade` with `loading=true`, the component automatically renders a skeleton placeholder matching its visual footprint — a label block (when the `label` prop is set) and an input-shaped block. No additional props or configuration needed.
|
|
793
772
|
|
|
794
773
|
This behavior is powered by `BladeLoadingKey` via Vue's provide/inject. The component injects the loading state from the nearest `VcBlade` ancestor.
|
|
795
|
-
|
package/runtime/knowledge/docs/ui/components/molecules/vc-input-currency/vc-input-currency.docs.md
CHANGED
|
@@ -53,14 +53,7 @@ The component uses two `v-model` bindings:
|
|
|
53
53
|
- **`v-model:option`** -- the selected currency code (type `string`)
|
|
54
54
|
|
|
55
55
|
```vue
|
|
56
|
-
<VcInputCurrency
|
|
57
|
-
v-model="amount"
|
|
58
|
-
v-model:option="selectedCurrency"
|
|
59
|
-
:options="currencyList"
|
|
60
|
-
option-label="title"
|
|
61
|
-
option-value="value"
|
|
62
|
-
label="Total"
|
|
63
|
-
/>
|
|
56
|
+
<VcInputCurrency v-model="amount" v-model:option="selectedCurrency" :options="currencyList" option-label="title" option-value="value" label="Total" />
|
|
64
57
|
```
|
|
65
58
|
|
|
66
59
|
The dropdown portion renders the available currencies. Use `optionLabel` and `optionValue` to map your data structure to display labels and values.
|
|
@@ -86,21 +79,15 @@ The `precision` prop controls the number of decimal places (0--15). The formatti
|
|
|
86
79
|
|
|
87
80
|
The `currencyDisplay` prop controls how the currency symbol appears inside the input field:
|
|
88
81
|
|
|
89
|
-
| Value
|
|
90
|
-
|
|
91
|
-
| `"hidden"` (default) | `1,234.56`
|
|
92
|
-
| `"symbol"`
|
|
93
|
-
| `"code"`
|
|
94
|
-
| `"name"`
|
|
82
|
+
| Value | Example | Description |
|
|
83
|
+
| -------------------- | --------------------- | ------------------------ |
|
|
84
|
+
| `"hidden"` (default) | `1,234.56` | No currency symbol shown |
|
|
85
|
+
| `"symbol"` | `$1,234.56` | Locale currency symbol |
|
|
86
|
+
| `"code"` | `USD 1,234.56` | ISO currency code |
|
|
87
|
+
| `"name"` | `1,234.56 US dollars` | Full currency name |
|
|
95
88
|
|
|
96
89
|
```vue
|
|
97
|
-
<VcInputCurrency
|
|
98
|
-
v-model="amount"
|
|
99
|
-
v-model:option="currency"
|
|
100
|
-
:options="currencies"
|
|
101
|
-
currency-display="symbol"
|
|
102
|
-
label="Price"
|
|
103
|
-
/>
|
|
90
|
+
<VcInputCurrency v-model="amount" v-model:option="currency" :options="currencies" currency-display="symbol" label="Price" />
|
|
104
91
|
```
|
|
105
92
|
|
|
106
93
|
### Prefix and Suffix
|
|
@@ -108,21 +95,9 @@ The `currencyDisplay` prop controls how the currency symbol appears inside the i
|
|
|
108
95
|
Add static text decorations before or after the input value:
|
|
109
96
|
|
|
110
97
|
```vue
|
|
111
|
-
<VcInputCurrency
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
:options="currencies"
|
|
115
|
-
prefix="$"
|
|
116
|
-
label="Price with prefix"
|
|
117
|
-
/>
|
|
118
|
-
|
|
119
|
-
<VcInputCurrency
|
|
120
|
-
v-model="amount"
|
|
121
|
-
v-model:option="currency"
|
|
122
|
-
:options="currencies"
|
|
123
|
-
suffix="per unit"
|
|
124
|
-
label="Unit price"
|
|
125
|
-
/>
|
|
98
|
+
<VcInputCurrency v-model="amount" v-model:option="currency" :options="currencies" prefix="$" label="Price with prefix" />
|
|
99
|
+
|
|
100
|
+
<VcInputCurrency v-model="amount" v-model:option="currency" :options="currencies" suffix="per unit" label="Unit price" />
|
|
126
101
|
```
|
|
127
102
|
|
|
128
103
|
### Validation with vee-validate Field
|
|
@@ -185,14 +160,7 @@ const form = reactive({
|
|
|
185
160
|
<VcInputCurrency v-model="price" v-model:option="currency" :options="currencies" label="Price" clearable />
|
|
186
161
|
|
|
187
162
|
<!-- Error -->
|
|
188
|
-
<VcInputCurrency
|
|
189
|
-
v-model="price"
|
|
190
|
-
v-model:option="currency"
|
|
191
|
-
:options="currencies"
|
|
192
|
-
label="Price"
|
|
193
|
-
:error="true"
|
|
194
|
-
error-message="Please enter a valid amount"
|
|
195
|
-
/>
|
|
163
|
+
<VcInputCurrency v-model="price" v-model:option="currency" :options="currencies" label="Price" :error="true" error-message="Please enter a valid amount" />
|
|
196
164
|
```
|
|
197
165
|
|
|
198
166
|
## Recipes
|
|
@@ -252,15 +220,7 @@ A common pattern in e-commerce blade forms:
|
|
|
252
220
|
When working with many currencies, enable the dropdown search:
|
|
253
221
|
|
|
254
222
|
```vue
|
|
255
|
-
<VcInputCurrency
|
|
256
|
-
v-model="amount"
|
|
257
|
-
v-model:option="currency"
|
|
258
|
-
:options="allWorldCurrencies"
|
|
259
|
-
option-label="name"
|
|
260
|
-
option-value="code"
|
|
261
|
-
searchable
|
|
262
|
-
label="Payment amount"
|
|
263
|
-
/>
|
|
223
|
+
<VcInputCurrency v-model="amount" v-model:option="currency" :options="allWorldCurrencies" option-label="name" option-value="code" searchable label="Payment amount" />
|
|
264
224
|
```
|
|
265
225
|
|
|
266
226
|
## Common Mistakes
|
|
@@ -311,46 +271,46 @@ const price = ref<number | null>(100);
|
|
|
311
271
|
|
|
312
272
|
## Props
|
|
313
273
|
|
|
314
|
-
| Prop
|
|
315
|
-
|
|
316
|
-
| `modelValue`
|
|
317
|
-
| `option`
|
|
318
|
-
| `options`
|
|
319
|
-
| `optionValue`
|
|
320
|
-
| `optionLabel`
|
|
321
|
-
| `precision`
|
|
322
|
-
| `currencyDisplay` | `"symbol" \| "code" \| "name" \| "hidden"` | `"hidden"` | How the currency symbol is displayed
|
|
323
|
-
| `label`
|
|
324
|
-
| `placeholder`
|
|
325
|
-
| `hint`
|
|
326
|
-
| `tooltip`
|
|
327
|
-
| `prefix`
|
|
328
|
-
| `suffix`
|
|
329
|
-
| `clearable`
|
|
330
|
-
| `loading`
|
|
331
|
-
| `disabled`
|
|
332
|
-
| `required`
|
|
333
|
-
| `error`
|
|
334
|
-
| `errorMessage`
|
|
335
|
-
| `name`
|
|
336
|
-
| `autofocus`
|
|
337
|
-
| `maxlength`
|
|
338
|
-
| `debounce`
|
|
339
|
-
| `searchable`
|
|
274
|
+
| Prop | Type | Default | Description |
|
|
275
|
+
| ----------------- | ------------------------------------------ | ---------- | ------------------------------------------------ |
|
|
276
|
+
| `modelValue` | `number \| null` | -- | Numeric value via `v-model` |
|
|
277
|
+
| `option` | `string` | -- | Selected currency code via `v-model:option` |
|
|
278
|
+
| `options` | `unknown[]` | `[]` | Available currency options for the dropdown |
|
|
279
|
+
| `optionValue` | `string \| Function` | `"id"` | Property or function to extract the option value |
|
|
280
|
+
| `optionLabel` | `string \| Function` | `"title"` | Property or function to extract the option label |
|
|
281
|
+
| `precision` | `0-15` | `2` | Number of decimal places |
|
|
282
|
+
| `currencyDisplay` | `"symbol" \| "code" \| "name" \| "hidden"` | `"hidden"` | How the currency symbol is displayed |
|
|
283
|
+
| `label` | `string` | -- | Label text above the field |
|
|
284
|
+
| `placeholder` | `string` | -- | Placeholder text |
|
|
285
|
+
| `hint` | `string` | -- | Helper text below the field |
|
|
286
|
+
| `tooltip` | `string` | -- | Tooltip on the label info icon |
|
|
287
|
+
| `prefix` | `string` | -- | Static text before the input value |
|
|
288
|
+
| `suffix` | `string` | -- | Static text after the input value |
|
|
289
|
+
| `clearable` | `boolean` | `false` | Shows a clear button |
|
|
290
|
+
| `loading` | `boolean` | `false` | Shows a spinning loader |
|
|
291
|
+
| `disabled` | `boolean` | `false` | Disables the entire component |
|
|
292
|
+
| `required` | `boolean` | `false` | Shows a required indicator |
|
|
293
|
+
| `error` | `boolean` | `false` | Enables error styling |
|
|
294
|
+
| `errorMessage` | `string` | -- | Error message below the field |
|
|
295
|
+
| `name` | `string` | -- | HTML name attribute |
|
|
296
|
+
| `autofocus` | `boolean` | `false` | Focus on mount |
|
|
297
|
+
| `maxlength` | `string \| number` | `1024` | Maximum input length |
|
|
298
|
+
| `debounce` | `string \| number` | `0` | Debounce for search input (ms) |
|
|
299
|
+
| `searchable` | `boolean` | `false` | Enable search in the currency dropdown |
|
|
340
300
|
|
|
341
301
|
## Events
|
|
342
302
|
|
|
343
|
-
| Event
|
|
344
|
-
|
|
345
|
-
| `update:model-value` | `number \| null` | Emitted when the numeric value changes
|
|
346
|
-
| `update:option`
|
|
347
|
-
| `change`
|
|
348
|
-
| `blur`
|
|
303
|
+
| Event | Payload | Description |
|
|
304
|
+
| -------------------- | ---------------- | ------------------------------------------- |
|
|
305
|
+
| `update:model-value` | `number \| null` | Emitted when the numeric value changes |
|
|
306
|
+
| `update:option` | `unknown` | Emitted when the currency selection changes |
|
|
307
|
+
| `change` | `number \| null` | Emitted on value change (alias) |
|
|
308
|
+
| `blur` | `Event` | Emitted when the input loses focus |
|
|
349
309
|
|
|
350
310
|
## CSS Variables
|
|
351
311
|
|
|
352
|
-
| Variable
|
|
353
|
-
|
|
312
|
+
| Variable | Default | Description |
|
|
313
|
+
| --------------------------- | -------------------- | ---------------------------- |
|
|
354
314
|
| `--input-curr-toggle-color` | `var(--primary-500)` | Dropdown toggle accent color |
|
|
355
315
|
|
|
356
316
|
Additionally inherits all `--input-*` CSS variables from VcInput/VcInputDropdown.
|
|
@@ -374,4 +334,3 @@ Additionally inherits all `--input-*` CSS variables from VcInput/VcInputDropdown
|
|
|
374
334
|
When placed inside a `VcBlade` with `loading=true`, the component automatically renders a skeleton placeholder matching its visual footprint — a label block (when the `label` prop is set) and an input-shaped block. No additional props or configuration needed.
|
|
375
335
|
|
|
376
336
|
This behavior is powered by `BladeLoadingKey` via Vue's provide/inject. The component injects the loading state from the nearest `VcBlade` ancestor.
|
|
377
|
-
|