@maltjoy/core-vue 3.26.0 → 3.27.1

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.
Files changed (96) hide show
  1. package/dist/components/JoyAvailability/JoyAvailability.types.d.ts +1 -2
  2. package/dist/components/JoyAvailability/VJoyAvailability.vue.d.ts +4 -3
  3. package/dist/components/JoyAvatar/JoyAvatar.types.d.ts +4 -6
  4. package/dist/components/JoyAvatar/VJoyAvatar.vue.d.ts +3 -3
  5. package/dist/components/JoyAvatarsList/VJoyAvatarsList.vue.d.ts +14 -4
  6. package/dist/components/JoyBadge/JoyBadge.types.d.ts +1 -2
  7. package/dist/components/JoyBadge/VJoyBadge.vue.d.ts +14 -8
  8. package/dist/components/JoyBadgeLevel/VJoyBadgeLevel.vue.d.ts +8 -4
  9. package/dist/components/JoyBlockSkeleton/VJoyBlockSkeleton.vue.d.ts +2 -0
  10. package/dist/components/JoyBottomSheet/VJoyBottomSheet.vue.d.ts +20 -7
  11. package/dist/components/JoyBottomSheetTrigger/VJoyBottomSheetTrigger.vue.d.ts +12 -6
  12. package/dist/components/JoyButton/JoyButton.types.d.ts +4 -20
  13. package/dist/components/JoyButton/VJoyButton.vue.d.ts +13 -13
  14. package/dist/components/JoyCheckbox/VJoyCheckbox.vue.d.ts +10 -3
  15. package/dist/components/JoyCollapse/VJoyCollapse.vue.d.ts +10 -4
  16. package/dist/components/JoyCollapseItem/VJoyCollapseItem.vue.d.ts +12 -4
  17. package/dist/components/JoyCompanyAvatar/JoyCompanyAvatar.types.d.ts +2 -3
  18. package/dist/components/JoyCompanyAvatar/VJoyCompanyAvatar.vue.d.ts +6 -0
  19. package/dist/components/JoyCounter/VJoyCounter.vue.d.ts +11 -6
  20. package/dist/components/JoyDialog/JoyDialog.types.d.ts +2 -3
  21. package/dist/components/JoyDialog/VJoyDialog.vue.d.ts +30 -8
  22. package/dist/components/JoyDialogTrigger/VJoyDialogTrigger.vue.d.ts +56 -20
  23. package/dist/components/JoyDividerCta/VJoyDividerCta.vue.d.ts +10 -3
  24. package/dist/components/JoyDrawer/JoyDrawer.types.d.ts +1 -2
  25. package/dist/components/JoyDrawer/VJoyDrawer.vue.d.ts +42 -12
  26. package/dist/components/JoyDrawerTrigger/VJoyDrawerTrigger.vue.d.ts +84 -30
  27. package/dist/components/JoyDropdown/JoyDropdown.types.d.ts +3 -4
  28. package/dist/components/JoyDropdown/VJoyDropdown.vue.d.ts +29 -22
  29. package/dist/components/JoyDropdownList/JoyDropdownList.types.d.ts +2 -3
  30. package/dist/components/JoyDropdownList/VJoyDropdownList.vue.d.ts +22 -21
  31. package/dist/components/JoyFilterBar/VJoyFilterBar.vue.d.ts +8 -2
  32. package/dist/components/JoyFilterBarButton/VJoyFilterBarButton.vue.d.ts +10 -2
  33. package/dist/components/JoyFormError/VJoyFormError.vue.d.ts +6 -2
  34. package/dist/components/JoyFunnel/JoyFunnel.types.d.ts +2 -4
  35. package/dist/components/JoyFunnel/VJoyFunnel.vue.d.ts +8 -0
  36. package/dist/components/JoyHighlight/JoyHighlight.types.d.ts +2 -4
  37. package/dist/components/JoyHighlight/VJoyHighlight.vue.d.ts +21 -9
  38. package/dist/components/JoyIcon/JoyIcon.types.d.ts +3 -4
  39. package/dist/components/JoyIcon/VJoyIcon.vue.d.ts +9 -6
  40. package/dist/components/JoyIndicator/VJoyIndicator.vue.d.ts +4 -3
  41. package/dist/components/JoyIndicators/JoyIndicators.types.d.ts +1 -2
  42. package/dist/components/JoyIndicators/VJoyIndicators.vue.d.ts +9 -6
  43. package/dist/components/JoyInput/JoyInput.types.d.ts +2 -3
  44. package/dist/components/JoyInput/VJoyInput.vue.d.ts +10 -7
  45. package/dist/components/JoyLabel/JoyLabel.types.d.ts +2 -3
  46. package/dist/components/JoyLabel/VJoyLabel.vue.d.ts +10 -7
  47. package/dist/components/JoyLink/JoyLink.types.d.ts +1 -2
  48. package/dist/components/JoyLink/VJoyLink.vue.d.ts +8 -7
  49. package/dist/components/JoyMenu/VJoyMenu.vue.d.ts +6 -10
  50. package/dist/components/JoyMultiCheckbox/VJoyMultiCheckbox.vue.d.ts +16 -19
  51. package/dist/components/JoyPagination/VJoyPagination.vue.d.ts +14 -6
  52. package/dist/components/JoyPanel/JoyPanel.types.d.ts +3 -5
  53. package/dist/components/JoyPanel/VJoyPanel.vue.d.ts +30 -14
  54. package/dist/components/JoyProgressBar/JoyProgressBar.types.d.ts +2 -3
  55. package/dist/components/JoyProgressBar/VJoyProgressBar.vue.d.ts +5 -3
  56. package/dist/components/JoyRadio/JoyRadio.types.d.ts +1 -2
  57. package/dist/components/JoyRadio/VJoyRadio.vue.d.ts +20 -7
  58. package/dist/components/JoyRadioGroup/JoyRadioGroup.types.d.ts +1 -2
  59. package/dist/components/JoyRadioGroup/VJoyRadioGroup.vue.d.ts +14 -6
  60. package/dist/components/JoyRatingStars/JoyRatingStars.types.d.ts +2 -3
  61. package/dist/components/JoyRatingStars/VJoyRatingStars.vue.d.ts +10 -2
  62. package/dist/components/JoyScreenLoader/VJoyScreenLoader.types.d.ts +1 -2
  63. package/dist/components/JoyScreenLoader/VJoyScreenLoader.vue.d.ts +14 -6
  64. package/dist/components/JoySelect/JoySelect.types.d.ts +2 -3
  65. package/dist/components/JoySelect/VJoySelect.vue.d.ts +9 -4
  66. package/dist/components/JoySelectableItemGroup/VJoySelectableItemGroup.vue.d.ts +10 -65
  67. package/dist/components/JoySeparator/JoySeparator.types.d.ts +2 -3
  68. package/dist/components/JoySnackbar/JoySnackbar.types.d.ts +2 -3
  69. package/dist/components/JoySnackbar/VJoySnackbar.vue.d.ts +6 -2
  70. package/dist/components/JoySnackbar/index.d.ts +1 -1
  71. package/dist/components/JoySpinner/JoySpinner.types.d.ts +1 -2
  72. package/dist/components/JoySpinner/VJoySpinner.vue.d.ts +2 -4
  73. package/dist/components/JoyStep/VJoyStep.vue.d.ts +14 -2
  74. package/dist/components/JoyStepper/VJoyStepper.vue.d.ts +10 -2
  75. package/dist/components/JoyTabs/VJoyTabs.vue.d.ts +2 -0
  76. package/dist/components/JoyTag/JoyTag.types.d.ts +3 -5
  77. package/dist/components/JoyTag/VJoyTag.vue.d.ts +13 -3
  78. package/dist/components/JoyTagsInput/VJoyTagsInput.vue.d.ts +34 -19
  79. package/dist/components/JoyTagsList/JoyTagsList.types.d.ts +1 -2
  80. package/dist/components/JoyTagsList/VJoyTagsList.vue.d.ts +9 -9
  81. package/dist/components/JoyTemplate/JoyTemplate.types.d.ts +1 -2
  82. package/dist/components/JoyTemplate/VJoyTemplate.vue.d.ts +67 -15
  83. package/dist/components/JoyText/VJoyText.vue.d.ts +6 -2
  84. package/dist/components/JoyTextarea/VJoyTextarea.vue.d.ts +6 -5
  85. package/dist/components/JoyToggle/VJoyToggle.vue.d.ts +6 -2
  86. package/dist/components/JoyTooltip/JoyTooltip.types.d.ts +0 -1
  87. package/dist/components/JoyUserCard/VJoyUserCard.vue.d.ts +20 -6
  88. package/dist/components/JoyWrapper/JoyWrapper.types.d.ts +5 -10
  89. package/dist/components/JoyWrapper/VJoyWrapper.vue.d.ts +19 -18
  90. package/dist/components/main.d.ts +1 -1
  91. package/dist/helpers/index.d.ts +2 -2
  92. package/dist/joy-vue.js +2091 -2152
  93. package/dist/joy-vue.umd.cjs +4 -4
  94. package/dist/style.css +1 -1
  95. package/dist/types/index.d.ts +7 -10
  96. package/package.json +20 -24
@@ -1,4 +1,5 @@
1
1
  import { PropType } from 'vue';
2
+ import { TJoyDropdownDirections } from './JoyDropdown.types';
2
3
  import { TJoyDropdownListSizes } from '../JoyDropdownList/JoyDropdownList.types';
3
4
  export interface Option {
4
5
  id: string;
@@ -35,12 +36,12 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
35
36
  };
36
37
  /** Dropdown vertical position according to the trigger */
37
38
  direction: {
38
- type: PropType<"up" | "down">;
39
+ type: PropType<TJoyDropdownDirections>;
39
40
  default: string;
40
41
  };
41
42
  /** Dropdown horizontal justify according to the trigger */
42
43
  justify: {
43
- type: PropType<"left" | "right">;
44
+ type: PropType<import("../../types").TPositions>;
44
45
  default: string;
45
46
  };
46
47
  /**
@@ -57,7 +58,6 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
57
58
  size: {
58
59
  type: PropType<TJoyDropdownListSizes>;
59
60
  default: string;
60
- validator(size: TJoyDropdownListSizes): boolean;
61
61
  };
62
62
  /** Use v-model */
63
63
  modelValue: {
@@ -125,12 +125,12 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
125
125
  };
126
126
  /** Dropdown vertical position according to the trigger */
127
127
  direction: {
128
- type: PropType<"up" | "down">;
128
+ type: PropType<TJoyDropdownDirections>;
129
129
  default: string;
130
130
  };
131
131
  /** Dropdown horizontal justify according to the trigger */
132
132
  justify: {
133
- type: PropType<"left" | "right">;
133
+ type: PropType<import("../../types").TPositions>;
134
134
  default: string;
135
135
  };
136
136
  /**
@@ -147,7 +147,6 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
147
147
  size: {
148
148
  type: PropType<TJoyDropdownListSizes>;
149
149
  default: string;
150
- validator(size: TJoyDropdownListSizes): boolean;
151
150
  };
152
151
  /** Use v-model */
153
152
  modelValue: {
@@ -196,8 +195,8 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
196
195
  size: TJoyDropdownListSizes;
197
196
  width: string;
198
197
  height: string;
199
- justify: "left" | "right";
200
- direction: "up" | "down";
198
+ justify: import("../../types").TPositions;
199
+ direction: TJoyDropdownDirections;
201
200
  options: Option[];
202
201
  reset: boolean;
203
202
  modelValue: string;
@@ -205,20 +204,28 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
205
204
  disableTeleport: boolean;
206
205
  closeOnSelect: boolean;
207
206
  dropdownGap: string;
208
- }, {}>, {
209
- "dropdown-button"?(_: {}): any;
210
- "dropdown-header"?(_: {}): any;
211
- "dropdown-items"?(_: {}): any;
212
- "dropdown-item"?(_: {
213
- [x: string]: any;
214
- id: string;
215
- value?: string | undefined;
216
- label: string;
217
- href?: string | undefined;
218
- disabled?: boolean | undefined;
219
- checked?: boolean | undefined;
220
- }): any;
221
- "dropdown-footer"?(_: {}): any;
207
+ }, {}>, Readonly<{
208
+ /** The trigger required to display the dropdown list. Can be anything as soon as it's focusable. */
209
+ 'dropdown-button': () => any;
210
+ /** Header that will be injected in the VJoyDropdownList */
211
+ 'dropdown-header'?: (() => any) | undefined;
212
+ /** Free slot in order to render any kind of component. Can be handy to use it with VJoyMultiCheckbox for instance. */
213
+ 'dropdown-items'?: (() => any) | undefined;
214
+ /** Use it to customize the innerHTML of the li item. See https://vuejs.org/guide/components/slots.html#scoped-slots */
215
+ 'dropdown-item'?: (() => any) | undefined;
216
+ /** Footer that will be injected in the VJoyDropdownList */
217
+ 'dropdown-footer'?: (() => any) | undefined;
218
+ }> & {
219
+ /** The trigger required to display the dropdown list. Can be anything as soon as it's focusable. */
220
+ 'dropdown-button': () => any;
221
+ /** Header that will be injected in the VJoyDropdownList */
222
+ 'dropdown-header'?: (() => any) | undefined;
223
+ /** Free slot in order to render any kind of component. Can be handy to use it with VJoyMultiCheckbox for instance. */
224
+ 'dropdown-items'?: (() => any) | undefined;
225
+ /** Use it to customize the innerHTML of the li item. See https://vuejs.org/guide/components/slots.html#scoped-slots */
226
+ 'dropdown-item'?: (() => any) | undefined;
227
+ /** Footer that will be injected in the VJoyDropdownList */
228
+ 'dropdown-footer'?: (() => any) | undefined;
222
229
  }>;
223
230
  export default _default;
224
231
  type __VLS_WithTemplateSlots<T, S> = T & {
@@ -1,3 +1,2 @@
1
- import { SIZES } from '../../types';
2
- export type TJoyDropdownListSizes = Extract<(typeof SIZES)[number], 'xsmall' | 'small' | 'medium'>;
3
- export declare const DROPDOWNLIST_SIZES: TJoyDropdownListSizes[];
1
+ import { TSizes } from '../../types';
2
+ export type TJoyDropdownListSizes = Extract<TSizes, 'xsmall' | 'small' | 'medium'>;
@@ -27,7 +27,6 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
27
27
  size: {
28
28
  type: PropType<TJoyDropdownListSizes>;
29
29
  default: string;
30
- validator(size: TJoyDropdownListSizes): boolean;
31
30
  };
32
31
  modelValue: {
33
32
  type: StringConstructor;
@@ -71,7 +70,6 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
71
70
  size: {
72
71
  type: PropType<TJoyDropdownListSizes>;
73
72
  default: string;
74
- validator(size: TJoyDropdownListSizes): boolean;
75
73
  };
76
74
  modelValue: {
77
75
  type: StringConstructor;
@@ -107,25 +105,28 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
107
105
  height: string;
108
106
  options: Option[];
109
107
  reset: boolean;
110
- }, {}>, {
111
- "dropdown-list-header"?(_: {}): any;
112
- "dropdown-list-items"?(_: {}): any;
113
- label?(_: {
114
- [x: string]: any;
115
- id: string;
116
- value?: string | undefined;
117
- label: string;
118
- href?: string | undefined;
119
- /**
120
- * @default false
121
- */
122
- disabled?: boolean | undefined;
123
- /**
124
- * @default false
125
- */
126
- checked?: boolean | undefined;
127
- }): any;
128
- "dropdown-list-footer"?(_: {}): any;
108
+ }, {}>, Readonly<{
109
+ /** Use it to customize the innerHTML of the <li> item. See https://vuejs.org/guide/components/slots.html#scoped-slots */
110
+ label?: ((option: Option) => any) | undefined;
111
+ /** Header that will be injected in the VJoyDropdownList */
112
+ 'dropdown-list-header'?: (() => any) | undefined;
113
+ /** Free slot in order to render any kind of component. Can be handy to use it with VJoyMultiCheckbox for instance. */
114
+ 'dropdown-list-items'?: (() => any) | undefined;
115
+ /** Use it to customize the innerHTML of the li item. See https://vuejs.org/guide/components/slots.html#scoped-slots */
116
+ 'dropdown-list-item'?: (() => any) | undefined;
117
+ /** Footer that will be injected in the VJoyDropdownList */
118
+ 'dropdown-list-footer'?: (() => any) | undefined;
119
+ }> & {
120
+ /** Use it to customize the innerHTML of the <li> item. See https://vuejs.org/guide/components/slots.html#scoped-slots */
121
+ label?: ((option: Option) => any) | undefined;
122
+ /** Header that will be injected in the VJoyDropdownList */
123
+ 'dropdown-list-header'?: (() => any) | undefined;
124
+ /** Free slot in order to render any kind of component. Can be handy to use it with VJoyMultiCheckbox for instance. */
125
+ 'dropdown-list-items'?: (() => any) | undefined;
126
+ /** Use it to customize the innerHTML of the li item. See https://vuejs.org/guide/components/slots.html#scoped-slots */
127
+ 'dropdown-list-item'?: (() => any) | undefined;
128
+ /** Footer that will be injected in the VJoyDropdownList */
129
+ 'dropdown-list-footer'?: (() => any) | undefined;
129
130
  }>;
130
131
  export default _default;
131
132
  type __VLS_WithTemplateSlots<T, S> = T & {
@@ -1,9 +1,15 @@
1
1
  declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
2
+ /** To give a label to the whole component */
2
3
  ariaLabel: StringConstructor;
3
4
  }, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
5
+ /** To give a label to the whole component */
4
6
  ariaLabel: StringConstructor;
5
- }>>, {}, {}>, {
6
- default?(_: {}): any;
7
+ }>>, {}, {}>, Readonly<{
8
+ /** Use it to inject VJoyFilterBarButton or whatever you need */
9
+ default(): any;
10
+ }> & {
11
+ /** Use it to inject VJoyFilterBarButton or whatever you need */
12
+ default(): any;
7
13
  }>;
8
14
  export default _default;
9
15
  type __VLS_WithTemplateSlots<T, S> = T & {
@@ -1,5 +1,7 @@
1
1
  declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
2
+ /** Label to inject inside the button */
2
3
  label: StringConstructor;
4
+ /** Required when used in the `VJoyFilterBar` to properly handle v-model */
3
5
  value: {
4
6
  type: StringConstructor;
5
7
  required: true;
@@ -11,7 +13,9 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
11
13
  }, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
12
14
  filter: (value: string) => void;
13
15
  }, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
16
+ /** Label to inject inside the button */
14
17
  label: StringConstructor;
18
+ /** Required when used in the `VJoyFilterBar` to properly handle v-model */
15
19
  value: {
16
20
  type: StringConstructor;
17
21
  required: true;
@@ -24,8 +28,12 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
24
28
  onFilter?: ((value: string) => any) | undefined;
25
29
  }, {
26
30
  active: boolean;
27
- }, {}>, {
28
- default?(_: {}): any;
31
+ }, {}>, Readonly<{
32
+ /** Free slot if you need more than the label property. */
33
+ default(): any;
34
+ }> & {
35
+ /** Free slot if you need more than the label property. */
36
+ default(): any;
29
37
  }>;
30
38
  export default _default;
31
39
  type __VLS_WithTemplateSlots<T, S> = T & {
@@ -16,8 +16,12 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
16
16
  noHtmlErrorText: StringConstructor;
17
17
  }>>, {
18
18
  visible: boolean;
19
- }, {}>, {
20
- default?(_: {}): any;
19
+ }, {}>, Readonly<{
20
+ /** If you need a list of error, use this slot with a simple ul/li */
21
+ default?: (() => any) | undefined;
22
+ }> & {
23
+ /** If you need a list of error, use this slot with a simple ul/li */
24
+ default?: (() => any) | undefined;
21
25
  }>;
22
26
  export default _default;
23
27
  type __VLS_WithTemplateSlots<T, S> = T & {
@@ -1,5 +1,3 @@
1
- import { Profiles, SIZES } from '../../types';
2
- export type TJoyFunnelLayoutWidths = Extract<(typeof SIZES)[number], 'medium' | 'large'>;
3
- export declare const JOYFUNNEL_LAYOUT_WIDTHS: TJoyFunnelLayoutWidths[];
1
+ import { Profiles, TSizes } from '../../types';
2
+ export type TJoyFunnelLayoutWidths = Extract<TSizes, 'medium' | 'large'>;
4
3
  export type TJoyFunnelProfiles = `${Profiles.STRATEGY}` | `${Profiles.DEFAULT}`;
5
- export declare const JOYFUNNEL_PROFILES: string[];
@@ -40,14 +40,22 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
40
40
  hideShapes: boolean;
41
41
  layoutWidth: TJoyFunnelLayoutWidths;
42
42
  }, {}>, Readonly<{
43
+ /** Use VJoyTemplate here */
43
44
  default: () => any;
45
+ /** Use VJoyHeader here */
44
46
  'funnel-header': () => any;
47
+ /** Use VJoyStepper here */
45
48
  'funnel-stepper'?: (() => any) | undefined;
49
+ /** Use VJoyFooter here */
46
50
  'funnel-footer'?: (() => any) | undefined;
47
51
  }> & {
52
+ /** Use VJoyTemplate here */
48
53
  default: () => any;
54
+ /** Use VJoyHeader here */
49
55
  'funnel-header': () => any;
56
+ /** Use VJoyStepper here */
50
57
  'funnel-stepper'?: (() => any) | undefined;
58
+ /** Use VJoyFooter here */
51
59
  'funnel-footer'?: (() => any) | undefined;
52
60
  }>;
53
61
  export default _default;
@@ -1,5 +1,3 @@
1
- import { LEVELS } from '../../types';
2
- export type TJoyHighlightLevels = (typeof LEVELS)[number];
3
- export declare const HIGHLIGHT_LEVELS: ("neutral" | "success" | "info" | "warning" | "error")[];
1
+ import { TLevels } from '../../types';
2
+ export type TJoyHighlightLevels = TLevels;
4
3
  export type TJoyHighlightVariants = 'ai' | 'default';
5
- export declare const HIGHLIGHT_VARIANTS: string[];
@@ -9,13 +9,14 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
9
9
  type: BooleanConstructor;
10
10
  default: boolean;
11
11
  };
12
+ /** Based on maltjoy/icons availabilities. Works in pair with displayIcon boolean prop. */
12
13
  icon: {
13
14
  type: PropType<import("@maltjoy/icons").JoyIconsId>;
14
15
  };
16
+ /** import `TJoyHighlightLevels` */
15
17
  level: {
16
- type: PropType<"neutral" | "success" | "info" | "warning" | "error">;
18
+ type: PropType<import("../../types").TLevels>;
17
19
  default: string;
18
- validator(level: "neutral" | "success" | "info" | "warning" | "error"): boolean;
19
20
  };
20
21
  /** Please note that 'default' variant has no effect. This property is meant to completely override "level" prop style */
21
22
  variant: {
@@ -33,13 +34,14 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
33
34
  type: BooleanConstructor;
34
35
  default: boolean;
35
36
  };
37
+ /** Based on maltjoy/icons availabilities. Works in pair with displayIcon boolean prop. */
36
38
  icon: {
37
39
  type: PropType<import("@maltjoy/icons").JoyIconsId>;
38
40
  };
41
+ /** import `TJoyHighlightLevels` */
39
42
  level: {
40
- type: PropType<"neutral" | "success" | "info" | "warning" | "error">;
43
+ type: PropType<import("../../types").TLevels>;
41
44
  default: string;
42
- validator(level: "neutral" | "success" | "info" | "warning" | "error"): boolean;
43
45
  };
44
46
  /** Please note that 'default' variant has no effect. This property is meant to completely override "level" prop style */
45
47
  variant: {
@@ -48,13 +50,23 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
48
50
  };
49
51
  }>>, {
50
52
  variant: TJoyHighlightVariants;
51
- level: "neutral" | "success" | "info" | "warning" | "error";
53
+ level: import("../../types").TLevels;
52
54
  accent: boolean;
53
55
  displayIcon: boolean;
54
- }, {}>, {
55
- "highlight-decorator"?(_: {}): any;
56
- "highlight-title"?(_: {}): any;
57
- default?(_: {}): any;
56
+ }, {}>, Readonly<{
57
+ /** Main content of the highlight */
58
+ default(): any;
59
+ /** Use it if you want to customize the default icon associated with the highlight. You can inject whatever you want here */
60
+ 'highlight-decorator': () => any;
61
+ /** Not mandatory, renders a bold title above the main content */
62
+ 'highlight-title': () => any;
63
+ }> & {
64
+ /** Main content of the highlight */
65
+ default(): any;
66
+ /** Use it if you want to customize the default icon associated with the highlight. You can inject whatever you want here */
67
+ 'highlight-decorator': () => any;
68
+ /** Not mandatory, renders a bold title above the main content */
69
+ 'highlight-title': () => any;
58
70
  }>;
59
71
  export default _default;
60
72
  type __VLS_WithTemplateSlots<T, S> = T & {
@@ -1,6 +1,5 @@
1
1
  import type { JoyIconsId } from '@maltjoy/icons';
2
- export declare const JOY_ICONS_COLORS: readonly [...("neutral" | "success" | "info" | "warning" | "error")[], "primary", "secondary", "tertiary", "quaternary", "brand-primary", "brand-secondary", "white"];
3
- export type TJoyIconsColors = (typeof JOY_ICONS_COLORS)[number];
4
- export declare const JOY_ICONS_SIZES: readonly ["xlarge", "large", "medium", "small", "xsmall", "xxsmall"];
5
- export type TJoyIconSizes = (typeof JOY_ICONS_SIZES)[number];
2
+ import { TSizes, TLevels } from '../../types';
3
+ export type TJoyIconsColors = TLevels | 'primary' | 'secondary' | 'tertiary' | 'quaternary' | 'brand-primary' | 'brand-secondary' | 'white';
4
+ export type TJoyIconSizes = TSizes;
6
5
  export type TJoyIconsNames = JoyIconsId;
@@ -1,4 +1,5 @@
1
1
  import { PropType } from 'vue';
2
+ import { TJoyIconsColors } from './JoyIcon.types';
2
3
  declare const _default: import("vue").DefineComponent<{
3
4
  ariaLabel: {
4
5
  type: StringConstructor;
@@ -18,11 +19,12 @@ declare const _default: import("vue").DefineComponent<{
18
19
  required: true;
19
20
  };
20
21
  color: {
21
- type: PropType<"primary" | "secondary" | "neutral" | "success" | "info" | "warning" | "error" | "tertiary" | "quaternary" | "white" | "brand-primary" | "brand-secondary">;
22
+ type: PropType<TJoyIconsColors>;
22
23
  default: string;
23
24
  };
25
+ /** Use `TJoyIconSizes` */
24
26
  size: {
25
- type: PropType<"small" | "xlarge" | "large" | "medium" | "xsmall" | "xxsmall">;
27
+ type: PropType<import("../../types").TSizes>;
26
28
  default: string;
27
29
  };
28
30
  }, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
@@ -44,16 +46,17 @@ declare const _default: import("vue").DefineComponent<{
44
46
  required: true;
45
47
  };
46
48
  color: {
47
- type: PropType<"primary" | "secondary" | "neutral" | "success" | "info" | "warning" | "error" | "tertiary" | "quaternary" | "white" | "brand-primary" | "brand-secondary">;
49
+ type: PropType<TJoyIconsColors>;
48
50
  default: string;
49
51
  };
52
+ /** Use `TJoyIconSizes` */
50
53
  size: {
51
- type: PropType<"small" | "xlarge" | "large" | "medium" | "xsmall" | "xxsmall">;
54
+ type: PropType<import("../../types").TSizes>;
52
55
  default: string;
53
56
  };
54
57
  }>>, {
55
- size: "small" | "xlarge" | "large" | "medium" | "xsmall" | "xxsmall";
56
- color: "primary" | "secondary" | "neutral" | "success" | "info" | "warning" | "error" | "tertiary" | "quaternary" | "white" | "brand-primary" | "brand-secondary";
58
+ size: import("../../types").TSizes;
59
+ color: TJoyIconsColors;
57
60
  tabIndex: number;
58
61
  }, {}>;
59
62
  export default _default;
@@ -1,4 +1,5 @@
1
1
  import { PropType } from 'vue';
2
+ import { TJoyIndicatorsVariants } from '../JoyIndicators/JoyIndicators.types';
2
3
  declare const _default: import("vue").DefineComponent<{
3
4
  /** Value is used for the parent v-model. Mandatory */
4
5
  value: {
@@ -11,7 +12,7 @@ declare const _default: import("vue").DefineComponent<{
11
12
  default: boolean;
12
13
  };
13
14
  variant: {
14
- type: PropType<"default" | "light">;
15
+ type: PropType<TJoyIndicatorsVariants>;
15
16
  default: string;
16
17
  };
17
18
  /** Indicators are text-less buttons by design. To make the more accessible, you can pass them an aria-label that will describe more their action. */
@@ -30,7 +31,7 @@ declare const _default: import("vue").DefineComponent<{
30
31
  default: boolean;
31
32
  };
32
33
  variant: {
33
- type: PropType<"default" | "light">;
34
+ type: PropType<TJoyIndicatorsVariants>;
34
35
  default: string;
35
36
  };
36
37
  /** Indicators are text-less buttons by design. To make the more accessible, you can pass them an aria-label that will describe more their action. */
@@ -38,7 +39,7 @@ declare const _default: import("vue").DefineComponent<{
38
39
  type: StringConstructor;
39
40
  };
40
41
  }>>, {
41
- variant: "default" | "light";
42
+ variant: TJoyIndicatorsVariants;
42
43
  selected: boolean;
43
44
  }, {}>;
44
45
  export default _default;
@@ -1,2 +1 @@
1
- export declare const JOY_INDICATORS_VARIANT: readonly ["default", "light"];
2
- export type TJoyIndicatorsVariants = (typeof JOY_INDICATORS_VARIANT)[number];
1
+ export type TJoyIndicatorsVariants = 'default' | 'light';
@@ -1,9 +1,10 @@
1
1
  import { PropType } from 'vue';
2
- import { VJoyIndicator } from '..';
2
+ import VJoyIndicator from '../JoyIndicator/VJoyIndicator.vue';
3
+ import { TJoyIndicatorsVariants } from './JoyIndicators.types';
3
4
  declare function isSelected(indicator: typeof VJoyIndicator): boolean;
4
5
  declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
5
6
  variant: {
6
- type: PropType<"default" | "light">;
7
+ type: PropType<TJoyIndicatorsVariants>;
7
8
  };
8
9
  /** Use the component with a v-model to easily handle selected items */
9
10
  modelValue: {
@@ -20,7 +21,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
20
21
  default: boolean;
21
22
  };
22
23
  variant: {
23
- type: PropType<"default" | "light">;
24
+ type: PropType<TJoyIndicatorsVariants>;
24
25
  default: string;
25
26
  };
26
27
  ariaLabel: {
@@ -36,14 +37,14 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
36
37
  default: boolean;
37
38
  };
38
39
  variant: {
39
- type: PropType<"default" | "light">;
40
+ type: PropType<TJoyIndicatorsVariants>;
40
41
  default: string;
41
42
  };
42
43
  ariaLabel: {
43
44
  type: StringConstructor;
44
45
  };
45
46
  }>>, {
46
- variant: "default" | "light";
47
+ variant: TJoyIndicatorsVariants;
47
48
  selected: boolean;
48
49
  }, {}>[]>;
49
50
  isSelected: typeof isSelected;
@@ -51,7 +52,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
51
52
  "update:modelValue": (value: string | number) => void;
52
53
  }, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
53
54
  variant: {
54
- type: PropType<"default" | "light">;
55
+ type: PropType<TJoyIndicatorsVariants>;
55
56
  };
56
57
  /** Use the component with a v-model to easily handle selected items */
57
58
  modelValue: {
@@ -60,8 +61,10 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
60
61
  }>> & {
61
62
  "onUpdate:modelValue"?: ((value: string | number) => any) | undefined;
62
63
  }, {}, {}>, Readonly<{
64
+ /** Use VJoyIndicator children here */
63
65
  default(): any;
64
66
  }> & {
67
+ /** Use VJoyIndicator children here */
65
68
  default(): any;
66
69
  }>;
67
70
  export default _default;
@@ -1,3 +1,2 @@
1
- import { SIZES } from '../../types';
2
- export type TJoyInputSizes = Extract<(typeof SIZES)[number], 'small' | 'medium' | 'large'>;
3
- export declare const INPUT_SIZES: TJoyInputSizes[];
1
+ import { TSizes } from '../../types';
2
+ export type TJoyInputSizes = Extract<TSizes, 'small' | 'medium' | 'large'>;
@@ -1,5 +1,6 @@
1
1
  import { PropType } from 'vue';
2
2
  import { TJoyInputSizes } from './JoyInput.types';
3
+ import { TJoyLabelSizes } from '../JoyLabel/JoyLabel.types';
3
4
  declare function focus(): void;
4
5
  declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
5
6
  autofocus: {
@@ -32,7 +33,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
32
33
  label: StringConstructor;
33
34
  /** Overrides the default label size. See JoyLabel stories */
34
35
  labelSize: {
35
- type: PropType<"small" | "large" | "medium">;
36
+ type: PropType<TJoyLabelSizes>;
36
37
  default: string;
37
38
  };
38
39
  /** If your component is not required, we can add a label to explicitely tell that it's not mandatory */
@@ -59,7 +60,6 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
59
60
  size: {
60
61
  type: PropType<TJoyInputSizes>;
61
62
  default: string;
62
- validator(size: TJoyInputSizes): boolean;
63
63
  };
64
64
  type: {
65
65
  type: StringConstructor;
@@ -107,7 +107,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
107
107
  label: StringConstructor;
108
108
  /** Overrides the default label size. See JoyLabel stories */
109
109
  labelSize: {
110
- type: PropType<"small" | "large" | "medium">;
110
+ type: PropType<TJoyLabelSizes>;
111
111
  default: string;
112
112
  };
113
113
  /** If your component is not required, we can add a label to explicitely tell that it's not mandatory */
@@ -134,7 +134,6 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
134
134
  size: {
135
135
  type: PropType<TJoyInputSizes>;
136
136
  default: string;
137
- validator(size: TJoyInputSizes): boolean;
138
137
  };
139
138
  type: {
140
139
  type: StringConstructor;
@@ -156,15 +155,19 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
156
155
  disabled: boolean;
157
156
  invalid: boolean;
158
157
  autofocus: boolean;
159
- labelSize: "small" | "large" | "medium";
158
+ labelSize: TJoyLabelSizes;
160
159
  requiredMark: boolean;
161
160
  modelModifiers: {
162
161
  lazy: boolean;
163
162
  };
164
163
  clearable: boolean;
165
164
  readonly: boolean;
166
- }, {}>, {
167
- default?(_: {}): any;
165
+ }, {}>, Readonly<{
166
+ /** Default slot to display a label on top of the element. You can use label property as well */
167
+ default?: (() => any) | undefined;
168
+ }> & {
169
+ /** Default slot to display a label on top of the element. You can use label property as well */
170
+ default?: (() => any) | undefined;
168
171
  }>;
169
172
  export default _default;
170
173
  type __VLS_WithTemplateSlots<T, S> = T & {
@@ -1,3 +1,2 @@
1
- /** LABEL SIZES */
2
- export declare const LABEL_SIZES: readonly ["small", "medium", "large"];
3
- export type TJoyLabelSizes = (typeof LABEL_SIZES)[number];
1
+ import { TSizes } from '@/types';
2
+ export type TJoyLabelSizes = Extract<TSizes, 'small' | 'medium' | 'large'>;
@@ -1,9 +1,9 @@
1
1
  import { PropType } from 'vue';
2
+ import { TJoyLabelSizes } from './JoyLabel.types';
2
3
  declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
3
4
  size: {
4
- type: PropType<"small" | "large" | "medium">;
5
+ type: PropType<TJoyLabelSizes>;
5
6
  default: string;
6
- validator(size: "small" | "large" | "medium"): boolean;
7
7
  };
8
8
  tagName: {
9
9
  type: PropType<"label" | "legend">;
@@ -19,9 +19,8 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
19
19
  text: StringConstructor;
20
20
  }, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
21
21
  size: {
22
- type: PropType<"small" | "large" | "medium">;
22
+ type: PropType<TJoyLabelSizes>;
23
23
  default: string;
24
- validator(size: "small" | "large" | "medium"): boolean;
25
24
  };
26
25
  tagName: {
27
26
  type: PropType<"label" | "legend">;
@@ -36,11 +35,15 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
36
35
  };
37
36
  text: StringConstructor;
38
37
  }>>, {
39
- size: "small" | "large" | "medium";
38
+ size: TJoyLabelSizes;
40
39
  required: boolean;
41
40
  tagName: "label" | "legend";
42
- }, {}>, {
43
- default?(_: {}): any;
41
+ }, {}>, Readonly<{
42
+ /** Label text here */
43
+ default: () => any;
44
+ }> & {
45
+ /** Label text here */
46
+ default: () => any;
44
47
  }>;
45
48
  export default _default;
46
49
  type __VLS_WithTemplateSlots<T, S> = T & {
@@ -1,2 +1 @@
1
- export declare const LINK_COLORS: readonly ["teal", "white"];
2
- export type LinkColors = (typeof LINK_COLORS)[number];
1
+ export type TJoyLinkColors = 'teal' | 'white';