@khsura/sui 1.20.0 → 1.21.0
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/@types/components/avatar/index.d.ts +2 -0
- package/@types/components/avatar/sAvatar.vue.d.ts +13 -0
- package/@types/components/avatar/sAvatarGroup.vue.d.ts +16 -0
- package/@types/components/form/index.d.ts +1 -0
- package/@types/components/form/sFormRow.vue.d.ts +1 -1
- package/@types/components/form/sNumberInput.vue.d.ts +29 -0
- package/@types/components/form/sSelect.vue.d.ts +8 -3
- package/@types/components/index.d.ts +5 -0
- package/@types/components/sAutocomplete.vue.d.ts +8 -1
- package/@types/components/sEmptyState.vue.d.ts +26 -0
- package/@types/components/sFileInput.vue.d.ts +35 -0
- package/@types/components/sPagination.vue.d.ts +21 -0
- package/@types/components/sSkeletonLoader.vue.d.ts +19 -0
- package/@types/components/toggleButtonGroup/sToggleButtonGroup.vue.d.ts +2 -0
- package/@types/configs/fileInput.d.ts +5 -0
- package/@types/configs/index.d.ts +2 -0
- package/@types/configs/provider.d.ts +1 -0
- package/@types/configs/skeletonLoader.d.ts +57 -0
- package/@types/constants/avatar.d.ts +3 -0
- package/@types/constants/fileInput.d.ts +31 -0
- package/@types/constants/index.d.ts +5 -0
- package/@types/constants/layout.d.ts +2 -0
- package/@types/constants/numberInput.d.ts +22 -0
- package/@types/constants/pagination.d.ts +20 -0
- package/@types/constants/skeletonLoader.d.ts +33 -0
- package/@types/constants/tabs.d.ts +6 -0
- package/@types/definitions/props/index.d.ts +7 -0
- package/@types/definitions/props/propsAutocomplete.d.ts +2 -0
- package/@types/definitions/props/propsAvatar.d.ts +13 -0
- package/@types/definitions/props/propsAvatarGroup.d.ts +8 -0
- package/@types/definitions/props/propsEmptyState.d.ts +17 -0
- package/@types/definitions/props/propsFileInput.d.ts +41 -0
- package/@types/definitions/props/propsNumberInput.d.ts +46 -0
- package/@types/definitions/props/propsPagination.d.ts +32 -0
- package/@types/definitions/props/propsRow.d.ts +1 -0
- package/@types/definitions/props/propsSelect.d.ts +2 -0
- package/@types/definitions/props/propsSkeletonLoader.d.ts +18 -0
- package/@types/definitions/props/propsTabs.d.ts +4 -0
- package/@types/helpers/fileInputRules.d.ts +18 -0
- package/@types/helpers/index.d.ts +1 -0
- package/@types/lib/escapeHtml.d.ts +2 -0
- package/@types/lib/flattenVNodes.d.ts +2 -0
- package/@types/lib/index.d.ts +3 -0
- package/@types/lib/numberInput.d.ts +23 -0
- package/@types/lib/revealInScroller.d.ts +14 -0
- package/@types/services/appBarService.d.ts +14 -0
- package/@types/services/core/layoutCoreService.d.ts +4 -0
- package/@types/services/index.d.ts +2 -0
- package/@types/services/layoutProviderService.d.ts +6 -0
- package/@types/services/layoutService.d.ts +4 -0
- package/@types/services/paginationService.d.ts +39 -0
- package/@types/services/skeletonLoaderService.d.ts +22 -0
- package/@types/services/tabsService.d.ts +6 -1
- package/@types/types/emits.d.ts +12 -0
- package/@types/types/fileInput.d.ts +28 -0
- package/@types/types/index.d.ts +4 -0
- package/@types/types/numberInput.d.ts +12 -0
- package/@types/types/pagination.d.ts +17 -0
- package/@types/types/skeletonLoader.d.ts +16 -0
- package/dist/s-ui.css +1 -1
- package/dist/s-ui.js +3966 -2856
- package/dist/s-ui.umd.cjs +1 -1
- package/dist/styles/components/avatar/_variables.scss +17 -0
- package/dist/styles/components/avatar/index.scss +1 -0
- package/dist/styles/components/index.scss +1 -0
- package/dist/sui-api.json +1208 -235
- package/package.json +3 -2
- package/sui-plugin/.claude-plugin/plugin.json +1 -1
- package/sui-plugin/skills/sui-component/SKILL.md +10 -3
- package/sui-plugin/skills/sui-component/references/autocomplete.md +51 -48
- package/sui-plugin/skills/sui-component/references/avatar-group.md +66 -0
- package/sui-plugin/skills/sui-component/references/avatar.md +76 -0
- package/sui-plugin/skills/sui-component/references/badge.md +4 -4
- package/sui-plugin/skills/sui-component/references/button.md +11 -11
- package/sui-plugin/skills/sui-component/references/calendar.md +1 -1
- package/sui-plugin/skills/sui-component/references/cards.md +9 -9
- package/sui-plugin/skills/sui-component/references/carousel.md +9 -9
- package/sui-plugin/skills/sui-component/references/chip.md +1 -1
- package/sui-plugin/skills/sui-component/references/date-picker.md +12 -12
- package/sui-plugin/skills/sui-component/references/dialog.md +8 -8
- package/sui-plugin/skills/sui-component/references/droppable.md +8 -8
- package/sui-plugin/skills/sui-component/references/empty-state.md +104 -0
- package/sui-plugin/skills/sui-component/references/file-input.md +106 -0
- package/sui-plugin/skills/sui-component/references/form.md +27 -25
- package/sui-plugin/skills/sui-component/references/image.md +8 -8
- package/sui-plugin/skills/sui-component/references/layout.md +47 -44
- package/sui-plugin/skills/sui-component/references/list.md +1 -1
- package/sui-plugin/skills/sui-component/references/menu.md +8 -8
- package/sui-plugin/skills/sui-component/references/number-input.md +102 -0
- package/sui-plugin/skills/sui-component/references/pagination.md +83 -0
- package/sui-plugin/skills/sui-component/references/progress.md +4 -4
- package/sui-plugin/skills/sui-component/references/sheet.md +8 -8
- package/sui-plugin/skills/sui-component/references/skeleton-loader.md +75 -0
- package/sui-plugin/skills/sui-component/references/slide-group.md +1 -1
- package/sui-plugin/skills/sui-component/references/snackbar.md +3 -3
- package/sui-plugin/skills/sui-component/references/split-view.md +2 -2
- package/sui-plugin/skills/sui-component/references/table.md +2 -1
- package/sui-plugin/skills/sui-component/references/tabs.md +18 -15
- package/sui-plugin/skills/sui-component/references/toggle-button-group.md +5 -4
- package/sui-plugin/skills/sui-component/references/toolbar.md +5 -5
- package/sui-plugin/skills/sui-component/references/tooltip.md +9 -9
- package/sui-plugin/skills/sui-component/references/window.md +1 -1
- package/sui-plugin/skills/sui-form/SKILL.md +6 -3
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@khsura/sui",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.21.0",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "git+https://github.com/khsura/sui.git",
|
|
@@ -27,7 +27,8 @@
|
|
|
27
27
|
"storybook:build": "storybook build",
|
|
28
28
|
"build:api": "yarn g:vite-node scripts/apiMetadata/generateApiMetadata.ts",
|
|
29
29
|
"sync:skills": "yarn g:vite-node scripts/apiMetadata/syncSkillTables.ts",
|
|
30
|
-
"check:skills": "yarn g:vite-node scripts/apiMetadata/syncSkillTables.ts --check"
|
|
30
|
+
"check:skills": "yarn g:vite-node scripts/apiMetadata/syncSkillTables.ts --check",
|
|
31
|
+
"scaffold:component": "yarn g:vite-node scripts/scaffoldComponent/scaffoldComponent.ts"
|
|
31
32
|
},
|
|
32
33
|
"files": [
|
|
33
34
|
"dist",
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "sui-plugin",
|
|
3
3
|
"description": "Skills for building Vue 3 / Nuxt apps with @khsura/sui — setup (npm install, styles, icons, theming, i18n), per-component references, forms, layouts and utilities",
|
|
4
|
-
"version": "1.
|
|
4
|
+
"version": "1.37.0",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Sura Kh",
|
|
7
7
|
"email": "sura0111@gmail.com"
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: sui-component
|
|
3
|
-
description: Look up and use any component from @khsura/sui (SButton, SCard, SDialog, SMenu, STooltip, STable, SList, STabs, SStepper, SCarousel, SExpansionPanels, SDatePicker, SCalendar, SToggleButtonGroup, SSlideGroup, SToolbar, SSplitView, SDroppable, SBadge, SChip, SIcon, SImage, SAlert, SOverlay, …) in a Vue or Nuxt app. Use when writing or fixing template code with an S-prefixed component, choosing props/slots/events, debugging a SUI component that renders wrong or ignores a prop, or styling SUI components with theme colors. Loads one per-family reference file with the verified props table, slots, events, example and gotchas.
|
|
3
|
+
description: Look up and use any component from @khsura/sui (SButton, SCard, SDialog, SMenu, STooltip, STable, SList, STabs, SStepper, SCarousel, SExpansionPanels, SDatePicker, SNumberInput, SCalendar, SToggleButtonGroup, SSlideGroup, SToolbar, SSplitView, SDroppable, SBadge, SChip, SAvatar, SPagination, SEmptyState, SSkeletonLoader, SFileInput, SIcon, SImage, SAlert, SOverlay, …) in a Vue or Nuxt app. Use when writing or fixing template code with an S-prefixed component, choosing props/slots/events, debugging a SUI component that renders wrong or ignores a prop, or styling SUI components with theme colors. Loads one per-family reference file with the verified props table, slots, events, example and gotchas.
|
|
4
4
|
argument-hint: [component name or description of what you need]
|
|
5
5
|
---
|
|
6
6
|
|
|
@@ -22,6 +22,8 @@ All components import from `@khsura/sui`. App setup (registry, `SApp`, styles, `
|
|
|
22
22
|
|---|---|
|
|
23
23
|
| `SAlert` | [references/alert.md](references/alert.md) |
|
|
24
24
|
| `SAutocomplete` | [references/autocomplete.md](references/autocomplete.md) |
|
|
25
|
+
| `SAvatar` | [references/avatar.md](references/avatar.md) |
|
|
26
|
+
| `SAvatarGroup` | [references/avatar-group.md](references/avatar-group.md) |
|
|
25
27
|
| `SBadge` | [references/badge.md](references/badge.md) |
|
|
26
28
|
| `SBreadcrumbs` | [references/breadcrumbs.md](references/breadcrumbs.md) |
|
|
27
29
|
| `SButton` | [references/button.md](references/button.md) |
|
|
@@ -33,16 +35,21 @@ All components import from `@khsura/sui`. App setup (registry, `SApp`, styles, `
|
|
|
33
35
|
| `SDialog` | [references/dialog.md](references/dialog.md) |
|
|
34
36
|
| `SDivider` | [references/divider.md](references/divider.md) |
|
|
35
37
|
| `SDroppable` | [references/droppable.md](references/droppable.md) |
|
|
38
|
+
| `SEmptyState` | [references/empty-state.md](references/empty-state.md) |
|
|
36
39
|
| `SExpansionPanels`, `SExpansionPanel`, `SExpansionPanelHeader`, `SExpansionPanelContent` | [references/expansion-panels.md](references/expansion-panels.md) |
|
|
40
|
+
| `SFileInput` | [references/file-input.md](references/file-input.md) |
|
|
37
41
|
| `SForm`, `SFormRow`, `SInput`, `STextarea`, `SSelect`, `SCheckbox`, `SRadioGroup`, `SRadio`, `SSwitch` | [references/form.md](references/form.md) (and the **sui-form** skill) |
|
|
38
42
|
| `SIcon` | [references/icon.md](references/icon.md) |
|
|
39
43
|
| `SImage` | [references/image.md](references/image.md) |
|
|
40
44
|
| `SApp`, `SLayout`, `SAppBar`, `SNavigationDrawer`, `SMain`, `SFooter`, `SBottomNavigation`, `SContainer`, `SRow`, `SColumn`, `SSpacer` | [references/layout.md](references/layout.md) (and the **sui-layout** skill) |
|
|
41
45
|
| `SList`, `SListItem`, `SListItemIcon`, `SListItemContent`, `SListItemTitle`, `SListItemSubtitle`, `SListItemAction`, `SListItemGroup` | [references/list.md](references/list.md) |
|
|
42
46
|
| `SMenu` | [references/menu.md](references/menu.md) |
|
|
47
|
+
| `SNumberInput` (since 1.21.0) | [references/number-input.md](references/number-input.md) (numbers: quantities, money, percentages) |
|
|
43
48
|
| `SOverlay` | [references/overlay.md](references/overlay.md) |
|
|
49
|
+
| `SPagination` | [references/pagination.md](references/pagination.md) |
|
|
44
50
|
| `SProgressLinear`, `SProgressCircular` | [references/progress.md](references/progress.md) |
|
|
45
51
|
| `SSheet` | [references/sheet.md](references/sheet.md) |
|
|
52
|
+
| `SSkeletonLoader` | [references/skeleton-loader.md](references/skeleton-loader.md) |
|
|
46
53
|
| `SSlideGroup`, `SSlideItem` | [references/slide-group.md](references/slide-group.md) |
|
|
47
54
|
| `SSnackbar` | [references/snackbar.md](references/snackbar.md) |
|
|
48
55
|
| `SSplitView`, `SSplitViewItem` | [references/split-view.md](references/split-view.md) |
|
|
@@ -60,10 +67,10 @@ All components import from `@khsura/sui`. App setup (registry, `SApp`, styles, `
|
|
|
60
67
|
|
|
61
68
|
| ❌ Name | ✅ Use instead |
|
|
62
69
|
|---|---|
|
|
63
|
-
| `SSkeletonLoader` | `SProgressCircular indeterminate` in a centered div |
|
|
64
70
|
| `STextField` | `SInput` (single line) or `STextarea` (multi-line) |
|
|
71
|
+
| `SFileUpload` / `<SInput type="file">` | `SFileInput` (`variant="dropzone"` for a drop area) |
|
|
65
72
|
| `SCol` | `SColumn` |
|
|
66
|
-
| `STablePagination` (not exported) | `STable`'s built-in pagination |
|
|
73
|
+
| `STablePagination` (not exported) | `STable`'s built-in pagination, or `SPagination` for a standalone pager |
|
|
67
74
|
| `SNavigationDrawer` inside a feature component | App shell only — use `<SDialog location="end">` for feature slide-in panels |
|
|
68
75
|
|
|
69
76
|
---
|
|
@@ -11,57 +11,60 @@ Types: `node_modules/@khsura/sui/@types/definitions/props/propsAutocomplete.d.ts
|
|
|
11
11
|
|
|
12
12
|
**SAutocomplete props**
|
|
13
13
|
|
|
14
|
-
| Prop | Type | Default | Required | Values |
|
|
15
|
-
| --- | --- | --- | --- | --- |
|
|
16
|
-
| `activator` | `string \|
|
|
17
|
-
| `allowUnlisted` | `boolean` | — | no | — |
|
|
18
|
-
| `ariaLabel` | `string \| null` | — | no | — |
|
|
19
|
-
| `autocomplete` | `string` | `"off"` | no | — |
|
|
20
|
-
| `chips` | `boolean` | — | no | — |
|
|
21
|
-
| `clearAriaLabel` | `string` | `"Clear"` | no | — |
|
|
22
|
-
| `clearable` | `boolean` | — | no | — |
|
|
23
|
-
| `closableChips` | `boolean` | — | no | — |
|
|
24
|
-
| `closeOnClick` | `boolean` | — | no | — |
|
|
25
|
-
| `closeOnContentClick` | `boolean` | — | no | — |
|
|
26
|
-
| `closeOnScroll` | `boolean` | — | no | — |
|
|
27
|
-
| `contentClass` | `string \|
|
|
28
|
-
| `contentStyle` | `StyleValue` | — | no | — |
|
|
29
|
-
| `debounce` | `number` | `500` | no | — |
|
|
30
|
-
| `delimiter` | `string \| RegExp \| string[]` | — | no | — |
|
|
31
|
-
| `dense` | `boolean` | — | no | — |
|
|
32
|
-
| `disabled` | `boolean \| null` | — | no | — |
|
|
33
|
-
| `divided` | `boolean` | — | no | — |
|
|
34
|
-
| `filter` | `((item: SelectItem, queryText: string) => boolean)` | — | no | — |
|
|
35
|
-
| `filterMode` | `"
|
|
36
|
-
| `height` | `
|
|
37
|
-
| `hideDetails` | `boolean` | — | no | — |
|
|
38
|
-
| `id` | `string` | — | no | — |
|
|
39
|
-
| `items` | `
|
|
40
|
-
| `label` | `string \| null` | — | no | — |
|
|
41
|
-
| `loading` | `boolean` | — | no | — |
|
|
42
|
-
| `loadingAriaLabel` | `string` | `"Loading"` | no | — |
|
|
43
|
-
| `location` | `LocationRaw` | `"bottom"` | no | — |
|
|
44
|
-
| `maxHeight` | `
|
|
45
|
-
| `maxWidth` | `
|
|
46
|
-
| `minHeight` | `
|
|
47
|
-
| `minWidth` | `
|
|
48
|
-
| `modelValue` | `(AutocompleteModelType<T> & (AutocompleteModelType<T> \| null))` | — | no | — |
|
|
49
|
-
| `multiple` | `T` | — | no | — |
|
|
50
|
-
| `name` | `string` | — | no | — |
|
|
51
|
-
| `
|
|
52
|
-
| `
|
|
53
|
-
| `
|
|
54
|
-
| `
|
|
55
|
-
| `
|
|
56
|
-
| `
|
|
57
|
-
| `
|
|
58
|
-
| `
|
|
59
|
-
| `
|
|
60
|
-
| `
|
|
14
|
+
| Prop | Type | Default | Required | Values | Description |
|
|
15
|
+
| --- | --- | --- | --- | --- | --- |
|
|
16
|
+
| `activator` | `string \| ComponentPublicInstance \| HTMLElement \| null` | — | no | — | — |
|
|
17
|
+
| `allowUnlisted` | `boolean` | — | no | — | — |
|
|
18
|
+
| `ariaLabel` | `string \| null` | — | no | — | — |
|
|
19
|
+
| `autocomplete` | `string` | `"off"` | no | — | — |
|
|
20
|
+
| `chips` | `boolean` | — | no | — | — |
|
|
21
|
+
| `clearAriaLabel` | `string` | `"Clear"` | no | — | — |
|
|
22
|
+
| `clearable` | `boolean` | — | no | — | — |
|
|
23
|
+
| `closableChips` | `boolean` | — | no | — | — |
|
|
24
|
+
| `closeOnClick` | `boolean` | — | no | — | — |
|
|
25
|
+
| `closeOnContentClick` | `boolean` | — | no | — | — |
|
|
26
|
+
| `closeOnScroll` | `boolean` | — | no | — | — |
|
|
27
|
+
| `contentClass` | `string \| Record<string, boolean> \| string[]` | — | no | — | — |
|
|
28
|
+
| `contentStyle` | `StyleValue` | — | no | — | — |
|
|
29
|
+
| `debounce` | `number` | `500` | no | — | — |
|
|
30
|
+
| `delimiter` | `string \| RegExp \| string[]` | — | no | — | — |
|
|
31
|
+
| `dense` | `boolean` | — | no | — | — |
|
|
32
|
+
| `disabled` | `boolean \| null` | — | no | — | — |
|
|
33
|
+
| `divided` | `boolean` | — | no | — | — |
|
|
34
|
+
| `filter` | `((item: SelectItem, queryText: string) => boolean)` | — | no | — | — |
|
|
35
|
+
| `filterMode` | `"contains" \| "exact" \| "none" \| "start"` | `"contains"` | no | `contains`, `exact`, `none`, `start` | — |
|
|
36
|
+
| `height` | `number \| string \| null` | — | no | — | — |
|
|
37
|
+
| `hideDetails` | `boolean` | — | no | — | — |
|
|
38
|
+
| `id` | `string` | — | no | — | — |
|
|
39
|
+
| `items` | `SelectItem[] \| string[]` | — | no | — | — |
|
|
40
|
+
| `label` | `string \| null` | — | no | — | — |
|
|
41
|
+
| `loading` | `boolean` | — | no | — | — |
|
|
42
|
+
| `loadingAriaLabel` | `string` | `"Loading"` | no | — | — |
|
|
43
|
+
| `location` | `LocationRaw` | `"bottom"` | no | — | — |
|
|
44
|
+
| `maxHeight` | `number \| string \| null` | — | no | — | — |
|
|
45
|
+
| `maxWidth` | `number \| string \| null` | — | no | — | — |
|
|
46
|
+
| `minHeight` | `number \| string \| null` | — | no | — | — |
|
|
47
|
+
| `minWidth` | `number \| string \| null` | — | no | — | — |
|
|
48
|
+
| `modelValue` | `(AutocompleteModelType<T> & (AutocompleteModelType<T> \| null))` | — | no | — | — |
|
|
49
|
+
| `multiple` | `T` | — | no | — | — |
|
|
50
|
+
| `name` | `string` | — | no | — | — |
|
|
51
|
+
| `noDataText` | `string` | — | no | — | Message shown in the open menu when no item matches the query (and there is no "Add" option). Without it (and without the `noData` slot) the menu stays blank. Put an `SEmptyState` in the `noData` slot for an icon or an action. |
|
|
52
|
+
| `offsetX` | `number \| null` | — | no | — | — |
|
|
53
|
+
| `offsetY` | `number \| null` | — | no | — | — |
|
|
54
|
+
| `onUpdateSearchInput` | `((value: string) => void)` | — | no | — | — |
|
|
55
|
+
| `placeholder` | `string` | — | no | — | — |
|
|
56
|
+
| `position` | `Position` | — | no | `absolute`, `fixed`, `relative`, `static`, `sticky` | — |
|
|
57
|
+
| `preventCloseOnClick` | `boolean` | — | no | — | — |
|
|
58
|
+
| `readonly` | `boolean \| null` | — | no | — | — |
|
|
59
|
+
| `screenPadding` | `number \| null` | — | no | — | — |
|
|
60
|
+
| `size` | `SizePropertyType` | — | no | `default`, `extra`, `large`, `mini`, `small` | — |
|
|
61
|
+
| `width` | `number \| string \| null` | — | no | — | — |
|
|
61
62
|
|
|
62
63
|
**SAutocomplete slots**
|
|
63
64
|
|
|
64
|
-
|
|
65
|
+
| Slot | Slot props | Description |
|
|
66
|
+
| --- | --- | --- |
|
|
67
|
+
| `noData` | `{ query: string; }` | Replaces `noDataText` when no option is left, such as an `SEmptyState`. Receives the typed `query`. |
|
|
65
68
|
|
|
66
69
|
**SAutocomplete events**
|
|
67
70
|
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
# SAvatarGroup
|
|
2
|
+
|
|
3
|
+
**Import:** `import { SAvatarGroup } from '@khsura/sui'`
|
|
4
|
+
|
|
5
|
+
A row of overlapping `SAvatar`s, such as project members (`role="group"`). With `max`, it shows the first `max` avatars and one "+N" avatar for the rest. See [avatar.md](avatar.md) for the avatar itself.
|
|
6
|
+
|
|
7
|
+
Types: `node_modules/@khsura/sui/@types/definitions/props/propsAvatarGroup.d.ts`
|
|
8
|
+
|
|
9
|
+
Docs: https://sui.surakh.com/?path=/docs/ui-components-avatargroup--docs
|
|
10
|
+
|
|
11
|
+
<!-- generated:api:start SAvatarGroup -->
|
|
12
|
+
<!-- Generated from sui-api.json by `yarn sync:skills` (packages/app). Do not edit by hand. -->
|
|
13
|
+
|
|
14
|
+
**SAvatarGroup props**
|
|
15
|
+
|
|
16
|
+
| Prop | Type | Default | Required | Values | Description |
|
|
17
|
+
| --- | --- | --- | --- | --- | --- |
|
|
18
|
+
| `color` | `string` | — | no | — | — |
|
|
19
|
+
| `colorThreshold` | `number` | — | no | — | — |
|
|
20
|
+
| `max` | `number` | — | no | — | The most avatars shown. The rest collapse into one "+N" avatar. Shows every avatar when unset. |
|
|
21
|
+
| `moreLabel` | `string` | — | no | — | Accessible name of the "+N" avatar. `{count}` is replaced with the number of hidden avatars. Defaults to `{count} more`. |
|
|
22
|
+
| `size` | `SizePropertyUnionType` | — | no | — | — |
|
|
23
|
+
| `theme` | `AppThemeType` | — | no | `dark`, `light` | — |
|
|
24
|
+
|
|
25
|
+
**SAvatarGroup slots**
|
|
26
|
+
|
|
27
|
+
| Slot | Slot props |
|
|
28
|
+
| --- | --- |
|
|
29
|
+
| `default` | `any` |
|
|
30
|
+
| `more` | `{ count: number; }` |
|
|
31
|
+
|
|
32
|
+
**SAvatarGroup events**
|
|
33
|
+
|
|
34
|
+
None.
|
|
35
|
+
|
|
36
|
+
<!-- generated:api:end SAvatarGroup -->
|
|
37
|
+
|
|
38
|
+
**SAvatarGroup notes**
|
|
39
|
+
|
|
40
|
+
- `size` applies to every avatar that has no `size` of its own.
|
|
41
|
+
- `color`, `colorThreshold` and `theme` style the "+N" avatar.
|
|
42
|
+
- `more` slot (`{ count }`) replaces the "+N" avatar.
|
|
43
|
+
- Without `max`, a long group wraps onto more lines instead of overflowing.
|
|
44
|
+
|
|
45
|
+
## Usage
|
|
46
|
+
|
|
47
|
+
```vue
|
|
48
|
+
<SAvatarGroup :max="3" size="small" color="primary" aria-label="Project members">
|
|
49
|
+
<SAvatar
|
|
50
|
+
v-for="member in members"
|
|
51
|
+
:key="member.id"
|
|
52
|
+
:image="member.photoUrl"
|
|
53
|
+
:text="member.initials"
|
|
54
|
+
:alt="member.name"
|
|
55
|
+
/>
|
|
56
|
+
</SAvatarGroup>
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
## Gotchas
|
|
60
|
+
|
|
61
|
+
| ❌ | ✅ |
|
|
62
|
+
|----|----|
|
|
63
|
+
| `<SAvatarGroup><div v-for="m in members"><SAvatar … /></div></SAvatarGroup>` (no overlap) | `<SAvatarGroup><SAvatar v-for="m in members" :key="m.id" … /></SAvatarGroup>` |
|
|
64
|
+
| `members.slice(0, 3)` plus a hand-made "+N" element | `<SAvatarGroup :max="3">` with every member |
|
|
65
|
+
| A tooltip around each avatar in the group | Wrap the whole group, or show the names in a list |
|
|
66
|
+
| `<SAvatar>` without `alt` in a group (names are not visible) | `:alt="member.name"` on each avatar |
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
# SAvatar
|
|
2
|
+
|
|
3
|
+
**Import:** `import { SAvatar } from '@khsura/sui'`
|
|
4
|
+
|
|
5
|
+
A round picture of a person or thing. It shows the `image`; when there is no image or it fails to load, the `text` initials; without those, the `icon` (`mdi-account` by default). Use it instead of a hand-built `<div>` + `<img>`. For overlapping avatars with a "+N", see [avatar-group.md](avatar-group.md).
|
|
6
|
+
|
|
7
|
+
Types: `node_modules/@khsura/sui/@types/definitions/props/propsAvatar.d.ts`
|
|
8
|
+
|
|
9
|
+
Docs: https://sui.surakh.com/?path=/docs/ui-components-avatar--docs
|
|
10
|
+
|
|
11
|
+
<!-- generated:api:start SAvatar -->
|
|
12
|
+
<!-- Generated from sui-api.json by `yarn sync:skills` (packages/app). Do not edit by hand. -->
|
|
13
|
+
|
|
14
|
+
**SAvatar props**
|
|
15
|
+
|
|
16
|
+
| Prop | Type | Default | Required | Values | Description |
|
|
17
|
+
| --- | --- | --- | --- | --- | --- |
|
|
18
|
+
| `alt` | `string` | — | no | — | Accessible name of the avatar, usually the person's name. Used as the image `alt` and as the `aria-label`. Leave it empty for a decorative avatar. |
|
|
19
|
+
| `borderRadius` | `` number \| "rounded" \| "tile" \| `${number}%` \| `${number}em` \| `${number}px` \| `${number}rem` \| `${number}vh` \| `${number}vw` \| null `` | — | no | — | — |
|
|
20
|
+
| `color` | `string` | — | no | — | — |
|
|
21
|
+
| `colorThreshold` | `number` | — | no | — | — |
|
|
22
|
+
| `icon` | `string` | — | no | — | Material Design icon shown when there is neither an image nor text. Defaults to `mdi-account`. |
|
|
23
|
+
| `image` | `string` | — | no | — | Image URL. When it is missing or fails to load, the avatar shows `text`, then `icon`. Do not put an `<img>` in the slot. |
|
|
24
|
+
| `outlined` | `boolean \| null` | — | no | — | — |
|
|
25
|
+
| `size` | `SizePropertyUnionType` | — | no | — | — |
|
|
26
|
+
| `text` | `string` | — | no | — | Initials shown when there is no image or it fails to load. Keep it to 1–3 characters, such as `JD`, not a full name. |
|
|
27
|
+
| `theme` | `AppThemeType` | — | no | `dark`, `light` | — |
|
|
28
|
+
|
|
29
|
+
**SAvatar slots**
|
|
30
|
+
|
|
31
|
+
| Slot | Slot props |
|
|
32
|
+
| --- | --- |
|
|
33
|
+
| `default` | `any` |
|
|
34
|
+
|
|
35
|
+
**SAvatar events**
|
|
36
|
+
|
|
37
|
+
None.
|
|
38
|
+
|
|
39
|
+
<!-- generated:api:end SAvatar -->
|
|
40
|
+
|
|
41
|
+
**SAvatar notes**
|
|
42
|
+
|
|
43
|
+
- `size`: a preset (`mini` 24 px, `small` 32, `default` 40, `large` 48, `extra` 56) or any length (`64`, `'4rem'`). In an `SAvatarGroup` the group's size is the default.
|
|
44
|
+
- `borderRadius`: round by default; `rounded` gives rounded corners, `tile` square ones.
|
|
45
|
+
- `outlined`: a border in `color` and no background.
|
|
46
|
+
- `alt` sets `role="img"` and `aria-label`; without it the avatar is decorative and its initials are read as text.
|
|
47
|
+
|
|
48
|
+
## Usage
|
|
49
|
+
|
|
50
|
+
```vue
|
|
51
|
+
<!-- Photo, falling back to initials, then the account icon -->
|
|
52
|
+
<SAvatar :image="user.photoUrl" :text="user.initials" :alt="user.name" color="primary" />
|
|
53
|
+
|
|
54
|
+
<SAvatar text="JD" color="secondary" size="small" />
|
|
55
|
+
<SAvatar icon="mdi-domain" outlined color="primary" />
|
|
56
|
+
|
|
57
|
+
<!-- Leading item of a list item, chip or card title: sized and spaced for you -->
|
|
58
|
+
<SListItem>
|
|
59
|
+
<SAvatar :image="user.photoUrl" :alt="user.name" />
|
|
60
|
+
<SListItemContent><SListItemTitle>{{ user.name }}</SListItemTitle></SListItemContent>
|
|
61
|
+
</SListItem>
|
|
62
|
+
<SChip><SAvatar text="JD" color="primary" /> Jane Doe</SChip>
|
|
63
|
+
<SCardTitle><SAvatar :image="user.photoUrl" :alt="user.name" /> {{ user.name }}</SCardTitle>
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
## Gotchas
|
|
67
|
+
|
|
68
|
+
| ❌ | ✅ |
|
|
69
|
+
|----|----|
|
|
70
|
+
| `<SAvatar><img :src="url" /></SAvatar>` (no fallback when it fails) | `<SAvatar :image="url" :text="initials" :alt="name" />` |
|
|
71
|
+
| `<SAvatar :src="url" />` (Vuetify / Quasar name) | `<SAvatar :image="url" />` |
|
|
72
|
+
| `<SAvatar text="Jane Doe" />` (clipped to "JA") | `<SAvatar text="JD" alt="Jane Doe" />` |
|
|
73
|
+
| `<SAvatar style="width: 64px; height: 64px">` (font and icon keep the old size) | `<SAvatar :size="64">` |
|
|
74
|
+
| `<SAvatar rounded="0">` / `tile` (Vuetify props) | `<SAvatar border-radius="tile">` |
|
|
75
|
+
| `<SImage … style="border-radius: 50%">` for a user picture | `<SAvatar :image="url" :alt="name" />` |
|
|
76
|
+
| `<div class="avatar" style="border-radius:50%;background:…">JD</div>` | `<SAvatar text="JD" color="primary" />` |
|
|
@@ -16,14 +16,14 @@ Types: `node_modules/@khsura/sui/@types/definitions/props/propsBadge.d.ts`
|
|
|
16
16
|
| `bottom` | `boolean` | — | no | — |
|
|
17
17
|
| `color` | `string` | — | no | — |
|
|
18
18
|
| `colorThreshold` | `number` | — | no | — |
|
|
19
|
-
| `content` | `
|
|
19
|
+
| `content` | `number \| string` | — | no | — |
|
|
20
20
|
| `dot` | `boolean` | — | no | — |
|
|
21
21
|
| `icon` | `string` | — | no | — |
|
|
22
22
|
| `inline` | `boolean` | — | no | — |
|
|
23
23
|
| `label` | `string` | — | no | — |
|
|
24
24
|
| `left` | `boolean` | — | no | — |
|
|
25
|
-
| `offsetX` | `
|
|
26
|
-
| `offsetY` | `
|
|
25
|
+
| `offsetX` | `number \| string` | — | no | — |
|
|
26
|
+
| `offsetY` | `number \| string` | — | no | — |
|
|
27
27
|
| `overlap` | `boolean` | — | no | — |
|
|
28
28
|
| `theme` | `AppThemeType` | — | no | `dark`, `light` |
|
|
29
29
|
| `tile` | `boolean` | — | no | — |
|
|
@@ -82,7 +82,7 @@ None.
|
|
|
82
82
|
<template #badge>
|
|
83
83
|
<SIcon icon="mdi-check" />
|
|
84
84
|
</template>
|
|
85
|
-
<
|
|
85
|
+
<SAvatar image="avatar.jpg" text="JD" alt="Jane Doe" />
|
|
86
86
|
</SBadge>
|
|
87
87
|
|
|
88
88
|
<!-- Bottom-right -->
|
|
@@ -15,18 +15,18 @@ Types: `node_modules/@khsura/sui/@types/definitions/props/propsButton.d.ts`
|
|
|
15
15
|
| --- | --- | --- | --- | --- |
|
|
16
16
|
| `activeClass` | `string \| null` | — | no | — |
|
|
17
17
|
| `block` | `boolean` | — | no | — |
|
|
18
|
-
| `borderRadius` | `` number \| "
|
|
18
|
+
| `borderRadius` | `` number \| "rounded" \| "tile" \| `${number}%` \| `${number}em` \| `${number}px` \| `${number}rem` \| `${number}vh` \| `${number}vw` \| null `` | — | no | — |
|
|
19
19
|
| `color` | `string` | — | no | — |
|
|
20
20
|
| `colorThreshold` | `number` | — | no | — |
|
|
21
21
|
| `disabled` | `boolean \| null` | — | no | — |
|
|
22
|
-
| `elevation` | `"" \|
|
|
23
|
-
| `height` | `
|
|
22
|
+
| `elevation` | `"" \| "1" \| "2" \| "3" \| "4" \| "5" \| "6" \| "7" \| "8" \| "9" \| "10" \| "11" \| "12" \| "13" \| "14" \| "15" \| "16" \| "17" \| "18" \| "19" \| "20" \| "21" \| "22" \| "23" \| "24" \| 0 \| 1 \| 2 \| 3 \| 4 \| 5 \| 6 \| 7 \| 8 \| 9 \| 10 \| 11 \| 12 \| 13 \| 14 \| 15 \| 16 \| 17 \| 18 \| 19 \| 20 \| 21 \| 22 \| 23 \| 24 \| null` | — | no | — |
|
|
23
|
+
| `height` | `number \| string \| null` | — | no | — |
|
|
24
24
|
| `href` | `string \| null` | — | no | — |
|
|
25
25
|
| `loading` | `boolean` | — | no | — |
|
|
26
|
-
| `maxHeight` | `
|
|
27
|
-
| `maxWidth` | `
|
|
28
|
-
| `minHeight` | `
|
|
29
|
-
| `minWidth` | `
|
|
26
|
+
| `maxHeight` | `number \| string \| null` | — | no | — |
|
|
27
|
+
| `maxWidth` | `number \| string \| null` | — | no | — |
|
|
28
|
+
| `minHeight` | `number \| string \| null` | — | no | — |
|
|
29
|
+
| `minWidth` | `number \| string \| null` | — | no | — |
|
|
30
30
|
| `outlined` | `boolean \| null` | — | no | — |
|
|
31
31
|
| `readonly` | `boolean \| null` | — | no | — |
|
|
32
32
|
| `rel` | `string \| null` | — | no | — |
|
|
@@ -34,14 +34,14 @@ Types: `node_modules/@khsura/sui/@types/definitions/props/propsButton.d.ts`
|
|
|
34
34
|
| `selected` | `boolean` | — | no | — |
|
|
35
35
|
| `size` | `SizePropertyType` | — | no | `default`, `extra`, `large`, `mini`, `small` |
|
|
36
36
|
| `tag` | `"a" \| "button" \| null` | `"button"` | no | `a`, `button` |
|
|
37
|
-
| `target` | `"_blank" \| "
|
|
37
|
+
| `target` | `"_blank" \| "_parent" \| "_self" \| "_top"` | — | no | `_blank`, `_parent`, `_self`, `_top` |
|
|
38
38
|
| `theme` | `AppThemeType` | — | no | `dark`, `light` |
|
|
39
39
|
| `to` | `LinkLocation \| null` | — | no | — |
|
|
40
40
|
| `type` | `ButtonTypeType` | — | no | `button`, `reset`, `submit` |
|
|
41
41
|
| `underlined` | `boolean \| null` | — | no | — |
|
|
42
|
-
| `value` | `
|
|
43
|
-
| `variant` | `"
|
|
44
|
-
| `width` | `
|
|
42
|
+
| `value` | `boolean \| number \| string` | — | no | — |
|
|
43
|
+
| `variant` | `"fab" \| "icon" \| "text" \| null` | — | no | `fab`, `icon`, `text` |
|
|
44
|
+
| `width` | `number \| string \| null` | — | no | — |
|
|
45
45
|
|
|
46
46
|
**SButton slots**
|
|
47
47
|
|
|
@@ -18,7 +18,7 @@ Types: `node_modules/@khsura/sui/@types/definitions/props/propsCalendar.d.ts`
|
|
|
18
18
|
| `color` | `string` | — | no | — |
|
|
19
19
|
| `colorThreshold` | `number` | — | no | — |
|
|
20
20
|
| `eventColor` | `((event: T) => string)` | — | no | — |
|
|
21
|
-
| `eventOverlapMode` | `"
|
|
21
|
+
| `eventOverlapMode` | `"column" \| "stacked"` | — | no | `column`, `stacked` |
|
|
22
22
|
| `events` | `T[]` | — | no | — |
|
|
23
23
|
| `focus` | `string` | — | no | — |
|
|
24
24
|
| `hideHeader` | `boolean` | — | no | — |
|
|
@@ -17,24 +17,24 @@ Types: `node_modules/@khsura/sui/@types/definitions/props/propsCard.d.ts`
|
|
|
17
17
|
|
|
18
18
|
| Prop | Type | Default | Required | Values |
|
|
19
19
|
| --- | --- | --- | --- | --- |
|
|
20
|
-
| `borderRadius` | `` number \| "
|
|
20
|
+
| `borderRadius` | `` number \| "rounded" \| "tile" \| `${number}%` \| `${number}em` \| `${number}px` \| `${number}rem` \| `${number}vh` \| `${number}vw` \| null `` | — | no | — |
|
|
21
21
|
| `color` | `string` | — | no | — |
|
|
22
22
|
| `colorThreshold` | `number` | — | no | — |
|
|
23
|
-
| `elevation` | `"" \|
|
|
24
|
-
| `height` | `
|
|
23
|
+
| `elevation` | `"" \| "1" \| "2" \| "3" \| "4" \| "5" \| "6" \| "7" \| "8" \| "9" \| "10" \| "11" \| "12" \| "13" \| "14" \| "15" \| "16" \| "17" \| "18" \| "19" \| "20" \| "21" \| "22" \| "23" \| "24" \| 0 \| 1 \| 2 \| 3 \| 4 \| 5 \| 6 \| 7 \| 8 \| 9 \| 10 \| 11 \| 12 \| 13 \| 14 \| 15 \| 16 \| 17 \| 18 \| 19 \| 20 \| 21 \| 22 \| 23 \| 24 \| null` | — | no | — |
|
|
24
|
+
| `height` | `number \| string \| null` | — | no | — |
|
|
25
25
|
| `href` | `string \| null` | — | no | — |
|
|
26
|
-
| `maxHeight` | `
|
|
27
|
-
| `maxWidth` | `
|
|
28
|
-
| `minHeight` | `
|
|
29
|
-
| `minWidth` | `
|
|
26
|
+
| `maxHeight` | `number \| string \| null` | — | no | — |
|
|
27
|
+
| `maxWidth` | `number \| string \| null` | — | no | — |
|
|
28
|
+
| `minHeight` | `number \| string \| null` | — | no | — |
|
|
29
|
+
| `minWidth` | `number \| string \| null` | — | no | — |
|
|
30
30
|
| `outlined` | `boolean \| null` | — | no | — |
|
|
31
31
|
| `rel` | `string \| null` | — | no | — |
|
|
32
32
|
| `tag` | `HtmlTagName \| null` | — | no | `a`, `abbr`, `acronym`, `address`, `applet`, `area`, `article`, `aside`, `audio`, `b`, `base`, `basefont`, `bdi`, `bdo`, `big`, `blockquote`, `body`, `br`, `button`, `canvas`, `caption`, `center`, `cite`, `code`, `col`, `colgroup`, `data`, `datalist`, `dd`, `del`, `details`, `dfn`, `dialog`, `dir`, `div`, `dl`, `dt`, `em`, `embed`, `fieldset`, `figcaption`, `figure`, `font`, `footer`, `form`, `frame`, `frameset`, `h1`, `h1> to <h6`, `h2`, `h3`, `h4`, `h5`, `h6`, `head`, `header`, `hr`, `html`, `i`, `iframe`, `img`, `input`, `ins`, `kbd`, `label`, `legend`, `li`, `link`, `main`, `map`, `mark`, `meta`, `meter`, `nav`, `noframes`, `noscript`, `object`, `ol`, `optgroup`, `option`, `output`, `p`, `param`, `picture`, `pre`, `progress`, `q`, `rp`, `rt`, `ruby`, `s`, `samp`, `script`, `section`, `select`, `small`, `source`, `span`, `strike`, `strong`, `style`, `sub`, `summary`, `sup`, `svg`, `table`, `tbody`, `td`, `template`, `textarea`, `tfoot`, `th`, `thead`, `time`, `title`, `tr`, `track`, `tt`, `u`, `ul`, `var`, `video`, `wbr` |
|
|
33
|
-
| `target` | `"_blank" \| "
|
|
33
|
+
| `target` | `"_blank" \| "_parent" \| "_self" \| "_top"` | — | no | `_blank`, `_parent`, `_self`, `_top` |
|
|
34
34
|
| `theme` | `AppThemeType` | — | no | `dark`, `light` |
|
|
35
35
|
| `to` | `LinkLocation \| null` | — | no | — |
|
|
36
36
|
| `underlined` | `boolean \| null` | — | no | — |
|
|
37
|
-
| `width` | `
|
|
37
|
+
| `width` | `number \| string \| null` | — | no | — |
|
|
38
38
|
|
|
39
39
|
**SCard slots**
|
|
40
40
|
|
|
@@ -24,7 +24,7 @@ Types: `node_modules/@khsura/sui/@types/definitions/props/propsCarousel.d.ts`, `
|
|
|
24
24
|
| `cycle` | `boolean` | `true` | no | — |
|
|
25
25
|
| `delimiterIcon` | `string` | `"mdi-circle"` | no | — |
|
|
26
26
|
| `disabled` | `boolean \| null` | — | no | — |
|
|
27
|
-
| `height` | `
|
|
27
|
+
| `height` | `number \| string` | `500` | no | — |
|
|
28
28
|
| `hideArrows` | `boolean` | — | no | — |
|
|
29
29
|
| `hideDelimiterBackground` | `boolean` | — | no | — |
|
|
30
30
|
| `hideDelimiters` | `boolean` | — | no | — |
|
|
@@ -98,17 +98,17 @@ Each item renders an `SImage`. Your default-slot content is drawn as an overlay
|
|
|
98
98
|
| `activeClass` | `string \| null` | — | no | — |
|
|
99
99
|
| `alt` | `string \| null` | — | no | — |
|
|
100
100
|
| `aspectRatio` | `number \| null` | — | no | — |
|
|
101
|
-
| `height` | `
|
|
101
|
+
| `height` | `number \| string \| null` | — | no | — |
|
|
102
102
|
| `lazyLoad` | `LazyLoad \| null` | — | no | — |
|
|
103
|
-
| `maxHeight` | `
|
|
104
|
-
| `maxWidth` | `
|
|
105
|
-
| `minHeight` | `
|
|
106
|
-
| `minWidth` | `
|
|
107
|
-
| `objectFit` | `"
|
|
103
|
+
| `maxHeight` | `number \| string \| null` | — | no | — |
|
|
104
|
+
| `maxWidth` | `number \| string \| null` | — | no | — |
|
|
105
|
+
| `minHeight` | `number \| string \| null` | — | no | — |
|
|
106
|
+
| `minWidth` | `number \| string \| null` | — | no | — |
|
|
107
|
+
| `objectFit` | `"contain" \| "cover" \| "fill" \| "none" \| "scale-down"` | — | no | `contain`, `cover`, `fill`, `none`, `scale-down` |
|
|
108
108
|
| `selected` | `boolean` | — | no | — |
|
|
109
109
|
| `src` | `string \| null` | — | yes | — |
|
|
110
|
-
| `value` | `
|
|
111
|
-
| `width` | `
|
|
110
|
+
| `value` | `boolean \| number \| string` | — | no | — |
|
|
111
|
+
| `width` | `number \| string \| null` | — | no | — |
|
|
112
112
|
|
|
113
113
|
**SCarouselItem slots**
|
|
114
114
|
|
|
@@ -13,7 +13,7 @@ Types: `node_modules/@khsura/sui/@types/definitions/props/propsChip.d.ts`
|
|
|
13
13
|
|
|
14
14
|
| Prop | Type | Default | Required | Values |
|
|
15
15
|
| --- | --- | --- | --- | --- |
|
|
16
|
-
| `borderRadius` | `` number \| "
|
|
16
|
+
| `borderRadius` | `` number \| "rounded" \| "tile" \| `${number}%` \| `${number}em` \| `${number}px` \| `${number}rem` \| `${number}vh` \| `${number}vw` \| null `` | — | no | — |
|
|
17
17
|
| `closable` | `boolean` | — | no | — |
|
|
18
18
|
| `color` | `string` | — | no | — |
|
|
19
19
|
| `colorThreshold` | `number` | — | no | — |
|
|
@@ -18,21 +18,21 @@ Types: `node_modules/@khsura/sui/@types/definitions/props/propsDatePicker.d.ts`
|
|
|
18
18
|
| `dateFormat` | `string` | `datePickerDisplayFormat.date` | no | — |
|
|
19
19
|
| `dense` | `boolean` | — | no | — |
|
|
20
20
|
| `disabled` | `boolean` | — | no | — |
|
|
21
|
-
| `height` | `
|
|
21
|
+
| `height` | `number \| string \| null` | — | no | — |
|
|
22
22
|
| `hideTitle` | `boolean` | — | no | — |
|
|
23
23
|
| `max` | `string` | — | no | — |
|
|
24
|
-
| `maxHeight` | `
|
|
25
|
-
| `maxWidth` | `
|
|
24
|
+
| `maxHeight` | `number \| string \| null` | — | no | — |
|
|
25
|
+
| `maxWidth` | `number \| string \| null` | — | no | — |
|
|
26
26
|
| `min` | `string` | — | no | — |
|
|
27
|
-
| `minHeight` | `
|
|
28
|
-
| `minWidth` | `
|
|
27
|
+
| `minHeight` | `number \| string \| null` | — | no | — |
|
|
28
|
+
| `minWidth` | `number \| string \| null` | — | no | — |
|
|
29
29
|
| `modelValue` | `string \| null` | — | no | — |
|
|
30
30
|
| `monthFormat` | `string` | `datePickerDisplayFormat.month` | no | — |
|
|
31
31
|
| `readonly` | `boolean` | — | no | — |
|
|
32
32
|
| `theme` | `AppThemeType` | — | no | `dark`, `light` |
|
|
33
33
|
| `today` | `string` | `dayjs().format("YYYY-MM-DD")` | no | — |
|
|
34
34
|
| `type` | `DatePickerTypeType` | `"date"` | yes | `date`, `month`, `year` |
|
|
35
|
-
| `width` | `
|
|
35
|
+
| `width` | `number \| string \| null` | — | no | — |
|
|
36
36
|
| `yearFormat` | `string` | `datePickerDisplayFormat.year` | no | — |
|
|
37
37
|
|
|
38
38
|
**SDatePicker slots**
|
|
@@ -136,18 +136,18 @@ Types: `node_modules/@khsura/sui/@types/definitions/props/propsDatePickerInput.d
|
|
|
136
136
|
| `dirty` | `boolean` | — | no | — | — |
|
|
137
137
|
| `disabled` | `boolean` | — | no | — | — |
|
|
138
138
|
| `error` | `boolean` | — | no | — | — |
|
|
139
|
-
| `height` | `
|
|
139
|
+
| `height` | `number \| string \| null` | — | no | — | — |
|
|
140
140
|
| `hideDetails` | `boolean` | — | no | — | — |
|
|
141
141
|
| `hideError` | `boolean` | — | no | — | — |
|
|
142
142
|
| `hideTitle` | `boolean` | — | no | — | — |
|
|
143
143
|
| `id` | `string` | — | no | — | — |
|
|
144
144
|
| `label` | `string \| null` | — | no | — | — |
|
|
145
145
|
| `max` | `string` | — | no | — | — |
|
|
146
|
-
| `maxHeight` | `
|
|
147
|
-
| `maxWidth` | `
|
|
146
|
+
| `maxHeight` | `number \| string \| null` | — | no | — | — |
|
|
147
|
+
| `maxWidth` | `number \| string \| null` | — | no | — | — |
|
|
148
148
|
| `min` | `string` | — | no | — | — |
|
|
149
|
-
| `minHeight` | `
|
|
150
|
-
| `minWidth` | `
|
|
149
|
+
| `minHeight` | `number \| string \| null` | — | no | — | — |
|
|
150
|
+
| `minWidth` | `number \| string \| null` | — | no | — | — |
|
|
151
151
|
| `modelValue` | `string \| null` | — | no | — | — |
|
|
152
152
|
| `monthFormat` | `string` | `datePickerDisplayFormat.month` | no | — | — |
|
|
153
153
|
| `placeholder` | `string \| null` | — | no | — | — |
|
|
@@ -159,7 +159,7 @@ Types: `node_modules/@khsura/sui/@types/definitions/props/propsDatePickerInput.d
|
|
|
159
159
|
| `tile` | `boolean` | — | no | — | — |
|
|
160
160
|
| `today` | `string` | `dayjs().format("YYYY-MM-DD")` | no | — | — |
|
|
161
161
|
| `type` | `DatePickerTypeType` | `"date"` | yes | `date`, `month`, `year` | — |
|
|
162
|
-
| `width` | `
|
|
162
|
+
| `width` | `number \| string \| null` | — | no | — | — |
|
|
163
163
|
| `yearFormat` | `string` | `datePickerDisplayFormat.year` | no | — | — |
|
|
164
164
|
|
|
165
165
|
**SDatePickerInput slots**
|
|
@@ -13,18 +13,18 @@ Types: `node_modules/@khsura/sui/@types/definitions/props/propsDialog.d.ts`
|
|
|
13
13
|
|
|
14
14
|
| Prop | Type | Default | Required | Values |
|
|
15
15
|
| --- | --- | --- | --- | --- |
|
|
16
|
-
| `activator` | `string \|
|
|
16
|
+
| `activator` | `string \| ComponentPublicInstance \| HTMLElement \| null` | — | no | — |
|
|
17
17
|
| `borderless` | `boolean` | — | no | — |
|
|
18
18
|
| `closeOnClick` | `boolean` | — | no | — |
|
|
19
19
|
| `disabled` | `boolean \| null` | — | no | — |
|
|
20
|
-
| `elevation` | `"" \|
|
|
20
|
+
| `elevation` | `"" \| "1" \| "2" \| "3" \| "4" \| "5" \| "6" \| "7" \| "8" \| "9" \| "10" \| "11" \| "12" \| "13" \| "14" \| "15" \| "16" \| "17" \| "18" \| "19" \| "20" \| "21" \| "22" \| "23" \| "24" \| 0 \| 1 \| 2 \| 3 \| 4 \| 5 \| 6 \| 7 \| 8 \| 9 \| 10 \| 11 \| 12 \| 13 \| 14 \| 15 \| 16 \| 17 \| 18 \| 19 \| 20 \| 21 \| 22 \| 23 \| 24 \| null` | — | no | — |
|
|
21
21
|
| `fullscreen` | `boolean` | — | no | — |
|
|
22
|
-
| `height` | `
|
|
22
|
+
| `height` | `number \| string \| null` | — | no | — |
|
|
23
23
|
| `location` | `LocationRaw` | — | no | — |
|
|
24
|
-
| `maxHeight` | `
|
|
25
|
-
| `maxWidth` | `
|
|
26
|
-
| `minHeight` | `
|
|
27
|
-
| `minWidth` | `
|
|
24
|
+
| `maxHeight` | `number \| string \| null` | — | no | — |
|
|
25
|
+
| `maxWidth` | `number \| string \| null` | — | no | — |
|
|
26
|
+
| `minHeight` | `number \| string \| null` | — | no | — |
|
|
27
|
+
| `minWidth` | `number \| string \| null` | — | no | — |
|
|
28
28
|
| `modelValue` | `boolean` | — | no | — |
|
|
29
29
|
| `offsetX` | `number \| null` | — | no | — |
|
|
30
30
|
| `offsetY` | `number \| null` | — | no | — |
|
|
@@ -33,7 +33,7 @@ Types: `node_modules/@khsura/sui/@types/definitions/props/propsDialog.d.ts`
|
|
|
33
33
|
| `readonly` | `boolean \| null` | — | no | — |
|
|
34
34
|
| `scrollable` | `boolean` | — | no | — |
|
|
35
35
|
| `scrollableBackground` | `boolean` | — | no | — |
|
|
36
|
-
| `width` | `
|
|
36
|
+
| `width` | `number \| string \| null` | — | no | — |
|
|
37
37
|
| `zIndex` | `number` | — | no | — |
|
|
38
38
|
|
|
39
39
|
**SDialog slots**
|