@histoire/controls 0.12.4 → 0.13.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 (26) hide show
  1. package/dist/components/HstWrapper.vue.d.ts +9 -1
  2. package/dist/components/button/HstButton.vue.d.ts +11 -4
  3. package/dist/components/button/HstButtonGroup.vue.d.ts +11 -4
  4. package/dist/components/checkbox/HstCheckbox.vue.d.ts +9 -2
  5. package/dist/components/checkbox/HstCheckboxList.vue.d.ts +9 -2
  6. package/dist/components/design-tokens/HstColorShades.vue.d.ts +11 -2
  7. package/dist/components/design-tokens/HstTokenGrid.vue.d.ts +14 -1
  8. package/dist/components/design-tokens/HstTokenList.vue.d.ts +15 -2
  9. package/dist/components/json/HstJson.vue.d.ts +9 -2
  10. package/dist/components/number/HstNumber.vue.d.ts +9 -2
  11. package/dist/components/radio/HstRadio.vue.d.ts +9 -2
  12. package/dist/components/select/CustomSelect.vue.d.ts +13 -4
  13. package/dist/components/select/HstSelect.vue.d.ts +9 -2
  14. package/dist/components/text/HstText.vue.d.ts +9 -2
  15. package/dist/components/textarea/HstTextarea.vue.d.ts +9 -2
  16. package/dist/index.d.ts +2221 -337
  17. package/dist/index.es.js +3811 -1814
  18. package/package.json +7 -7
  19. package/src/components/button/HstButtonGroup.story.vue +28 -0
  20. package/src/components/button/HstButtonGroup.vue +12 -8
  21. package/src/components/checkbox/{HstCheckbox.test.ts → HstCheckbox.spec.ts} +0 -0
  22. package/src/components/checkbox/__snapshots__/{HstCheckbox.test.ts.snap → HstCheckbox.spec.ts.snap} +0 -0
  23. package/src/components/design-tokens/HstTokenList.story.vue +1 -1
  24. package/src/components/select/CustomSelect.vue +3 -3
  25. package/src/components/select/HstSelect.story.vue +24 -0
  26. package/dist/components/checkbox/HstCheckbox.test.d.ts +0 -1
@@ -1,4 +1,4 @@
1
- declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
1
+ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
2
2
  title?: string;
3
3
  tag?: string;
4
4
  }>, {
@@ -13,6 +13,9 @@ declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_T
13
13
  }>>>, {
14
14
  title: string;
15
15
  tag: string;
16
+ }>, {
17
+ default: (_: {}) => any;
18
+ actions: (_: {}) => any;
16
19
  }>;
17
20
  export default _default;
18
21
  type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
@@ -29,3 +32,8 @@ type __VLS_WithDefaults<P, D> = {
29
32
  default: D[K];
30
33
  } : P[K];
31
34
  };
35
+ type __VLS_WithTemplateSlots<T, S> = T & {
36
+ new (): {
37
+ $slots: S;
38
+ };
39
+ };
@@ -1,8 +1,10 @@
1
- declare const _default: import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
2
- color?: "default" | "flat" | "primary";
1
+ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
2
+ color?: "flat" | "default" | "primary";
3
3
  }>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<__VLS_TypePropsToRuntimeProps<{
4
- color?: "default" | "flat" | "primary";
5
- }>>>, {}>;
4
+ color?: "flat" | "default" | "primary";
5
+ }>>>, {}>, {
6
+ default: (_: {}) => any;
7
+ }>;
6
8
  export default _default;
7
9
  type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
8
10
  type __VLS_TypePropsToRuntimeProps<T> = {
@@ -13,3 +15,8 @@ type __VLS_TypePropsToRuntimeProps<T> = {
13
15
  required: true;
14
16
  };
15
17
  };
18
+ type __VLS_WithTemplateSlots<T, S> = T & {
19
+ new (): {
20
+ $slots: S;
21
+ };
22
+ };
@@ -1,17 +1,19 @@
1
1
  import { HstControlOption } from '../../types';
2
- declare const _default: import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
2
+ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
3
3
  title?: string;
4
4
  modelValue: string;
5
- options: string[] | HstControlOption[];
5
+ options: string[] | number[] | HstControlOption[] | Record<string, string | number>;
6
6
  }>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
7
7
  "update:modelValue": (value: string) => void;
8
8
  }, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<__VLS_TypePropsToRuntimeProps<{
9
9
  title?: string;
10
10
  modelValue: string;
11
- options: string[] | HstControlOption[];
11
+ options: string[] | number[] | HstControlOption[] | Record<string, string | number>;
12
12
  }>>> & {
13
13
  "onUpdate:modelValue"?: (value: string) => any;
14
- }, {}>;
14
+ }, {}>, {
15
+ actions: (_: {}) => any;
16
+ }>;
15
17
  export default _default;
16
18
  type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
17
19
  type __VLS_TypePropsToRuntimeProps<T> = {
@@ -22,3 +24,8 @@ type __VLS_TypePropsToRuntimeProps<T> = {
22
24
  required: true;
23
25
  };
24
26
  };
27
+ type __VLS_WithTemplateSlots<T, S> = T & {
28
+ new (): {
29
+ $slots: S;
30
+ };
31
+ };
@@ -1,4 +1,4 @@
1
- declare const _default: import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
1
+ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
2
2
  modelValue: boolean;
3
3
  title?: string;
4
4
  }>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
@@ -8,7 +8,9 @@ declare const _default: import("vue").DefineComponent<__VLS_TypePropsToRuntimePr
8
8
  title?: string;
9
9
  }>>> & {
10
10
  "onUpdate:modelValue"?: (newValue: boolean) => any;
11
- }, {}>;
11
+ }, {}>, {
12
+ actions: (_: {}) => any;
13
+ }>;
12
14
  export default _default;
13
15
  type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
14
16
  type __VLS_TypePropsToRuntimeProps<T> = {
@@ -19,3 +21,8 @@ type __VLS_TypePropsToRuntimeProps<T> = {
19
21
  required: true;
20
22
  };
21
23
  };
24
+ type __VLS_WithTemplateSlots<T, S> = T & {
25
+ new (): {
26
+ $slots: S;
27
+ };
28
+ };
@@ -1,5 +1,5 @@
1
1
  import { HstControlOption } from '../../types';
2
- declare const _default: import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
2
+ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
3
3
  title?: string;
4
4
  modelValue: Array<string>;
5
5
  options: string[] | HstControlOption[];
@@ -11,7 +11,9 @@ declare const _default: import("vue").DefineComponent<__VLS_TypePropsToRuntimePr
11
11
  options: string[] | HstControlOption[];
12
12
  }>>> & {
13
13
  "onUpdate:modelValue"?: (value: string[]) => any;
14
- }, {}>;
14
+ }, {}>, {
15
+ actions: (_: {}) => any;
16
+ }>;
15
17
  export default _default;
16
18
  type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
17
19
  type __VLS_TypePropsToRuntimeProps<T> = {
@@ -22,3 +24,8 @@ type __VLS_TypePropsToRuntimeProps<T> = {
22
24
  required: true;
23
25
  };
24
26
  };
27
+ type __VLS_WithTemplateSlots<T, S> = T & {
28
+ new (): {
29
+ $slots: S;
30
+ };
31
+ };
@@ -1,4 +1,4 @@
1
- declare const _default: import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
1
+ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
2
2
  shades: Record<string, any>;
3
3
  getName?: (key: string, color: string) => string;
4
4
  search?: string;
@@ -6,7 +6,11 @@ declare const _default: import("vue").DefineComponent<__VLS_TypePropsToRuntimePr
6
6
  shades: Record<string, any>;
7
7
  getName?: (key: string, color: string) => string;
8
8
  search?: string;
9
- }>>>, {}>;
9
+ }>>>, {}>, {
10
+ default: (_: {
11
+ color: string;
12
+ }) => any;
13
+ }>;
10
14
  export default _default;
11
15
  type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
12
16
  type __VLS_TypePropsToRuntimeProps<T> = {
@@ -17,3 +21,8 @@ type __VLS_TypePropsToRuntimeProps<T> = {
17
21
  required: true;
18
22
  };
19
23
  };
24
+ type __VLS_WithTemplateSlots<T, S> = T & {
25
+ new (): {
26
+ $slots: S;
27
+ };
28
+ };
@@ -1,4 +1,4 @@
1
- declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
1
+ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
2
2
  tokens: Record<string, string | number | any[] | Record<string, any>>;
3
3
  colSize?: number;
4
4
  getName?: (key: string, value: string | number | any[] | Record<string, any>) => string;
@@ -15,6 +15,14 @@ declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_T
15
15
  }>>>, {
16
16
  getName: (key: string, value: string | number | any[] | Record<string, any>) => string;
17
17
  colSize: number;
18
+ }>, {
19
+ default: (_: {
20
+ token: {
21
+ key: string;
22
+ name: string;
23
+ value: string | Record<string, any>;
24
+ };
25
+ }) => any;
18
26
  }>;
19
27
  export default _default;
20
28
  type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
@@ -31,3 +39,8 @@ type __VLS_WithDefaults<P, D> = {
31
39
  default: D[K];
32
40
  } : P[K];
33
41
  };
42
+ type __VLS_WithTemplateSlots<T, S> = T & {
43
+ new (): {
44
+ $slots: S;
45
+ };
46
+ };
@@ -1,10 +1,18 @@
1
- declare const _default: import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
1
+ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
2
2
  tokens: Record<string, string | number | any[] | Record<string, any>>;
3
3
  getName?: (key: string, value: string | number | any[] | Record<string, any>) => string;
4
4
  }>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<__VLS_TypePropsToRuntimeProps<{
5
5
  tokens: Record<string, string | number | any[] | Record<string, any>>;
6
6
  getName?: (key: string, value: string | number | any[] | Record<string, any>) => string;
7
- }>>>, {}>;
7
+ }>>>, {}>, {
8
+ default: (_: {
9
+ token: {
10
+ key: string;
11
+ name: string;
12
+ value: string | Record<string, any>;
13
+ };
14
+ }) => any;
15
+ }>;
8
16
  export default _default;
9
17
  type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
10
18
  type __VLS_TypePropsToRuntimeProps<T> = {
@@ -15,3 +23,8 @@ type __VLS_TypePropsToRuntimeProps<T> = {
15
23
  required: true;
16
24
  };
17
25
  };
26
+ type __VLS_WithTemplateSlots<T, S> = T & {
27
+ new (): {
28
+ $slots: S;
29
+ };
30
+ };
@@ -1,4 +1,4 @@
1
- declare const _default: import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
1
+ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
2
2
  title?: string;
3
3
  modelValue: unknown;
4
4
  }>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
@@ -8,7 +8,9 @@ declare const _default: import("vue").DefineComponent<__VLS_TypePropsToRuntimePr
8
8
  modelValue: unknown;
9
9
  }>>> & {
10
10
  "onUpdate:modelValue"?: (newValue: unknown) => any;
11
- }, {}>;
11
+ }, {}>, {
12
+ actions: (_: {}) => any;
13
+ }>;
12
14
  export default _default;
13
15
  type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
14
16
  type __VLS_TypePropsToRuntimeProps<T> = {
@@ -19,3 +21,8 @@ type __VLS_TypePropsToRuntimeProps<T> = {
19
21
  required: true;
20
22
  };
21
23
  };
24
+ type __VLS_WithTemplateSlots<T, S> = T & {
25
+ new (): {
26
+ $slots: S;
27
+ };
28
+ };
@@ -1,4 +1,4 @@
1
- declare const _default: import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
1
+ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
2
2
  title?: string;
3
3
  modelValue: number;
4
4
  }>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
@@ -8,7 +8,9 @@ declare const _default: import("vue").DefineComponent<__VLS_TypePropsToRuntimePr
8
8
  modelValue: number;
9
9
  }>>> & {
10
10
  "onUpdate:modelValue"?: (newValue: number) => any;
11
- }, {}>;
11
+ }, {}>, {
12
+ actions: (_: {}) => any;
13
+ }>;
12
14
  export default _default;
13
15
  type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
14
16
  type __VLS_TypePropsToRuntimeProps<T> = {
@@ -19,3 +21,8 @@ type __VLS_TypePropsToRuntimeProps<T> = {
19
21
  required: true;
20
22
  };
21
23
  };
24
+ type __VLS_WithTemplateSlots<T, S> = T & {
25
+ new (): {
26
+ $slots: S;
27
+ };
28
+ };
@@ -1,5 +1,5 @@
1
1
  import { HstControlOption } from '../../types';
2
- declare const _default: import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
2
+ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
3
3
  title?: string;
4
4
  modelValue: string;
5
5
  options: HstControlOption[];
@@ -11,7 +11,9 @@ declare const _default: import("vue").DefineComponent<__VLS_TypePropsToRuntimePr
11
11
  options: HstControlOption[];
12
12
  }>>> & {
13
13
  "onUpdate:modelValue"?: (value: string) => any;
14
- }, {}>;
14
+ }, {}>, {
15
+ actions: (_: {}) => any;
16
+ }>;
15
17
  export default _default;
16
18
  type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
17
19
  type __VLS_TypePropsToRuntimeProps<T> = {
@@ -22,3 +24,8 @@ type __VLS_TypePropsToRuntimeProps<T> = {
22
24
  required: true;
23
25
  };
24
26
  };
27
+ type __VLS_WithTemplateSlots<T, S> = T & {
28
+ new (): {
29
+ $slots: S;
30
+ };
31
+ };
@@ -1,15 +1,19 @@
1
1
  import { HstControlOption } from '../../types';
2
- declare const _default: import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
2
+ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
3
3
  modelValue: string;
4
- options: Record<string, any> | string[] | HstControlOption[];
4
+ options: Record<string, any> | string[] | number[] | HstControlOption[];
5
5
  }>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
6
6
  "update:modelValue": (value: string) => void;
7
7
  }, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<__VLS_TypePropsToRuntimeProps<{
8
8
  modelValue: string;
9
- options: Record<string, any> | string[] | HstControlOption[];
9
+ options: Record<string, any> | string[] | number[] | HstControlOption[];
10
10
  }>>> & {
11
11
  "onUpdate:modelValue"?: (value: string) => any;
12
- }, {}>;
12
+ }, {}>, {
13
+ default: (_: {
14
+ label: string;
15
+ }) => any;
16
+ }>;
13
17
  export default _default;
14
18
  type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
15
19
  type __VLS_TypePropsToRuntimeProps<T> = {
@@ -20,3 +24,8 @@ type __VLS_TypePropsToRuntimeProps<T> = {
20
24
  required: true;
21
25
  };
22
26
  };
27
+ type __VLS_WithTemplateSlots<T, S> = T & {
28
+ new (): {
29
+ $slots: S;
30
+ };
31
+ };
@@ -1,5 +1,5 @@
1
1
  import { HstControlOption } from '../../types';
2
- declare const _default: import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
2
+ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
3
3
  title?: string;
4
4
  modelValue: string;
5
5
  options: Record<string, any> | string[] | HstControlOption[];
@@ -11,7 +11,9 @@ declare const _default: import("vue").DefineComponent<__VLS_TypePropsToRuntimePr
11
11
  options: Record<string, any> | string[] | HstControlOption[];
12
12
  }>>> & {
13
13
  "onUpdate:modelValue"?: (value: any) => any;
14
- }, {}>;
14
+ }, {}>, {
15
+ actions: (_: {}) => any;
16
+ }>;
15
17
  export default _default;
16
18
  type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
17
19
  type __VLS_TypePropsToRuntimeProps<T> = {
@@ -22,3 +24,8 @@ type __VLS_TypePropsToRuntimeProps<T> = {
22
24
  required: true;
23
25
  };
24
26
  };
27
+ type __VLS_WithTemplateSlots<T, S> = T & {
28
+ new (): {
29
+ $slots: S;
30
+ };
31
+ };
@@ -1,4 +1,4 @@
1
- declare const _default: import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
1
+ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
2
2
  title?: string;
3
3
  modelValue: string;
4
4
  }>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
@@ -8,7 +8,9 @@ declare const _default: import("vue").DefineComponent<__VLS_TypePropsToRuntimePr
8
8
  modelValue: string;
9
9
  }>>> & {
10
10
  "onUpdate:modelValue"?: (newValue: string) => any;
11
- }, {}>;
11
+ }, {}>, {
12
+ actions: (_: {}) => any;
13
+ }>;
12
14
  export default _default;
13
15
  type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
14
16
  type __VLS_TypePropsToRuntimeProps<T> = {
@@ -19,3 +21,8 @@ type __VLS_TypePropsToRuntimeProps<T> = {
19
21
  required: true;
20
22
  };
21
23
  };
24
+ type __VLS_WithTemplateSlots<T, S> = T & {
25
+ new (): {
26
+ $slots: S;
27
+ };
28
+ };
@@ -1,4 +1,4 @@
1
- declare const _default: import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
1
+ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
2
2
  title?: string;
3
3
  modelValue: string;
4
4
  }>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
@@ -8,7 +8,9 @@ declare const _default: import("vue").DefineComponent<__VLS_TypePropsToRuntimePr
8
8
  modelValue: string;
9
9
  }>>> & {
10
10
  "onUpdate:modelValue"?: (newValue: string) => any;
11
- }, {}>;
11
+ }, {}>, {
12
+ actions: (_: {}) => any;
13
+ }>;
12
14
  export default _default;
13
15
  type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
14
16
  type __VLS_TypePropsToRuntimeProps<T> = {
@@ -19,3 +21,8 @@ type __VLS_TypePropsToRuntimeProps<T> = {
19
21
  required: true;
20
22
  };
21
23
  };
24
+ type __VLS_WithTemplateSlots<T, S> = T & {
25
+ new (): {
26
+ $slots: S;
27
+ };
28
+ };