tide-design-system 2.3.0 → 2.3.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 (43) hide show
  1. package/README.md +1 -0
  2. package/dist/css/variables.css +1 -1
  3. package/dist/style.css +1 -1
  4. package/dist/tide-design-system.cjs +2 -2
  5. package/dist/tide-design-system.esm.js +471 -455
  6. package/package.json +1 -1
  7. package/src/assets/css/variables.css +1 -1
  8. package/src/components/TideAlert.vue +2 -4
  9. package/src/components/TideInputCheckbox.vue +2 -2
  10. package/src/components/TideInputRadio.vue +4 -4
  11. package/src/components/TideModal.vue +18 -6
  12. package/src/components/TideSheet.vue +11 -1
  13. package/src/docs/upgrading.md +29 -0
  14. package/src/stories/Template.stories.ts +4 -2
  15. package/src/stories/TideAccordionItem.stories.ts +7 -1
  16. package/src/stories/TideAlert.stories.ts +5 -1
  17. package/src/stories/TideBadge.stories.ts +3 -1
  18. package/src/stories/TideBadgeTrustedPartner.stories.ts +3 -1
  19. package/src/stories/TideBadgeVerifiedVehicle.stories.ts +3 -1
  20. package/src/stories/TideButton.stories.ts +5 -1
  21. package/src/stories/TideButtonIcon.stories.ts +5 -1
  22. package/src/stories/TideButtonPagination.stories.ts +5 -1
  23. package/src/stories/TideButtonSegmented.stories.ts +7 -2
  24. package/src/stories/TideCard.stories.ts +5 -1
  25. package/src/stories/TideCarousel.stories.ts +8 -2
  26. package/src/stories/TideChipAction.stories.ts +3 -1
  27. package/src/stories/TideChipFilter.stories.ts +8 -2
  28. package/src/stories/TideChipInput.stories.ts +5 -1
  29. package/src/stories/TideDivider.stories.ts +6 -2
  30. package/src/stories/TideImageBackground.stories.ts +3 -1
  31. package/src/stories/TideIndicator.stories.ts +3 -1
  32. package/src/stories/TideInputCheckbox.stories.ts +8 -2
  33. package/src/stories/TideInputRadio.stories.ts +8 -2
  34. package/src/stories/TideInputSelect.stories.ts +7 -2
  35. package/src/stories/TideInputText.stories.ts +6 -2
  36. package/src/stories/TideInputTextarea.stories.ts +6 -2
  37. package/src/stories/TideLink.stories.ts +7 -3
  38. package/src/stories/TideModal.stories.ts +85 -44
  39. package/src/stories/TidePagination.stories.ts +8 -2
  40. package/src/stories/TidePopover.stories.ts +6 -1
  41. package/src/stories/TideSeoLinks.stories.ts +3 -1
  42. package/src/stories/TideSheet.stories.ts +9 -3
  43. package/src/stories/TideSwitch.stories.ts +7 -1
package/package.json CHANGED
@@ -61,7 +61,7 @@
61
61
  "main": "dist/tide-design-system.cjs",
62
62
  "module": "dist/tide-design-system.esm.js",
63
63
  "types": "dist/tide-design-system.esm.d.ts",
64
- "version": "2.3.0",
64
+ "version": "2.3.1",
65
65
  "dependencies": {
66
66
  "@floating-ui/vue": "^1.1.6"
67
67
  }
@@ -53,7 +53,7 @@
53
53
  --tide-transparent-400: color-mix(in srgb, black 50%, transparent);
54
54
 
55
55
  /* Blur */
56
- --tide-bg-blur: 8px;
56
+ --tide-bg-blur: blur(8px);
57
57
 
58
58
  /* Global tonal palette */
59
59
  --tide-gray-100: #FFFFFF;
@@ -69,10 +69,8 @@
69
69
  />
70
70
  </div>
71
71
 
72
- <div :class="['tide-alert-heading', CSS.DISPLAY.FLEX, CSS.AXIS2.CENTER]">
73
- <h2 :class="[CSS.FONT.ROLE.LABEL_1_SEMIBOLD]">
74
- {{ props.heading }}
75
- </h2>
72
+ <div :class="['tide-alert-heading', CSS.DISPLAY.FLEX, CSS.AXIS2.CENTER, CSS.FONT.ROLE.LABEL_1_SEMIBOLD]">
73
+ {{ props.heading }}
76
74
  </div>
77
75
 
78
76
  <TideButtonIcon
@@ -104,7 +104,7 @@
104
104
  }
105
105
 
106
106
  .tide-input-checkbox-custom {
107
- width: var(--tide-font-28);
108
- height: var(--tide-font-28);
107
+ width: 24px;
108
+ height: 24px;
109
109
  }
110
110
  </style>
@@ -100,12 +100,12 @@
100
100
  }
101
101
 
102
102
  .tide-input-radio-custom {
103
- width: var(--tide-font-28);
104
- height: var(--tide-font-28);
103
+ width: 24px;
104
+ height: 24px;
105
105
  }
106
106
 
107
107
  .tide-input-radio-check {
108
- width: 1rem;
109
- height: 1rem;
108
+ width: 16px;
109
+ height: 16px;
110
110
  }
111
111
  </style>
@@ -108,12 +108,15 @@
108
108
  <header
109
109
  :class="[
110
110
  'tide-modal-header',
111
- CSS.DISPLAY.FLEX,
112
111
  CSS.AXIS2.CENTER,
113
- CSS.GAP.HALF,
114
- CSS.PADDING.Y.ONE,
115
112
  CSS.BORDER.BOTTOM.ONE,
116
113
  CSS.BORDER.COLOR.LOW,
114
+ CSS.DISPLAY.FLEX,
115
+ CSS.GAP.HALF,
116
+ CSS.ISOLATION.ISOLATE,
117
+ CSS.PADDING.Y.ONE,
118
+ CSS.POSITION.RELATIVE,
119
+ CSS.Z_INDEX.ONE,
117
120
  ]"
118
121
  >
119
122
  <TideButtonIcon
@@ -142,10 +145,11 @@
142
145
  :class="[
143
146
  'tide-modal-content',
144
147
  CSS.DISPLAY.GRID,
145
- CSS.OVERFLOW.Y.AUTO,
148
+ CSS.ISOLATION.ISOLATE,
146
149
  CSS.OVERFLOW.X.HIDDEN,
147
- CSS.WIDTH.FULL,
150
+ CSS.OVERFLOW.Y.AUTO,
148
151
  CSS.PADDING.Y.TWO,
152
+ CSS.WIDTH.FULL,
149
153
  ]"
150
154
  ref="modalContent"
151
155
  >
@@ -153,7 +157,15 @@
153
157
  </div>
154
158
 
155
159
  <footer
156
- :class="['tide-modal-footer', CSS.AXIS1.END, CSS.DISPLAY.FLEX, CSS.GAP.TWO, CSS.PADDING.Y.ONE, CSS.SHADOW.TOP]"
160
+ :class="[
161
+ 'tide-modal-footer',
162
+ CSS.AXIS1.END,
163
+ CSS.DISPLAY.FLEX,
164
+ CSS.GAP.TWO,
165
+ CSS.ISOLATION.ISOLATE,
166
+ CSS.PADDING.Y.ONE,
167
+ CSS.SHADOW.TOP,
168
+ ]"
157
169
  v-if="$slots.footer"
158
170
  >
159
171
  <slot name="footer" />
@@ -87,7 +87,16 @@
87
87
  CSS.WIDTH.FULL,
88
88
  ]"
89
89
  >
90
- <header :class="[CSS.DISPLAY.FLEX, CSS.PADDING.X.ONE, CSS.PADDING.TOP.ONE]">
90
+ <header
91
+ :class="[
92
+ CSS.DISPLAY.FLEX,
93
+ CSS.ISOLATION.ISOLATE,
94
+ CSS.PADDING.TOP.ONE,
95
+ CSS.PADDING.X.ONE,
96
+ CSS.POSITION.RELATIVE,
97
+ CSS.Z_INDEX.ONE,
98
+ ]"
99
+ >
91
100
  <TideButtonIcon
92
101
  :class="[CSS.FLEX.GROW.OFF, CSS.FLEX.SHRINK.OFF]"
93
102
  :icon="ICON.CHEVRON_LEFT"
@@ -114,6 +123,7 @@
114
123
  CSS.OVERFLOW.X.HIDDEN,
115
124
  CSS.WIDTH.FULL,
116
125
  CSS.PADDING.BOTTOM.ONE,
126
+ CSS.ISOLATION.ISOLATE,
117
127
  ]"
118
128
  >
119
129
  <slot />
@@ -0,0 +1,29 @@
1
+ # Upgrading Versions
2
+
3
+ This document provides step-by-step instructions for upgrading from previous versions of the library.
4
+
5
+ ---
6
+
7
+ ## Upgrading from 2.2 → 2.3
8
+
9
+ **Summary**
10
+ Version **2.3** consolidates certain CSS files. The same utilities can now be made globally available in a TIDE consumer repository leveraging [partial integration](./integration-partial.md) by cherry-picking a smaller set of `dist` files from the `node_modules` subdirectory.
11
+
12
+ **Important:** Upgrading to **2.3** introduces breaking changes unless deprecated imports are removed.
13
+
14
+ ### Migration steps
15
+
16
+ 1. **Remove deprecated imports**
17
+ Delete any imports that match:
18
+ ```css
19
+ node_modules/tide-design-system/dist/css/utilities-*.css
20
+ node_modules/tide-design-system/dist/css/dynamic-*.css
21
+ ```
22
+
23
+ 2. **Use the consolidated file**
24
+ All utilities are now declared in:
25
+ ```css
26
+ node_modules/tide-design-system/dist/css/utilities.css
27
+ ```
28
+
29
+ ✅ After these changes your project should be compatible with **TIDE 2.3**.
@@ -5,6 +5,8 @@ import TideChipInput from '@/components/TideChipInput.vue';
5
5
  import { ICON } from '@/types/Icon';
6
6
  import { argTypeBooleanUnrequired, formatArgType, formatSnippet } from '@/utilities/storybook';
7
7
 
8
+ type Args = InstanceType<typeof TideChipInput>['$props'];
9
+
8
10
  // PARAMETERS
9
11
  const parameters = {
10
12
  docs: {
@@ -17,11 +19,11 @@ const parameters = {
17
19
  };
18
20
 
19
21
  // STANDARD FUNCTIONS
20
- const formatArgs = (args: any) => {
22
+ const formatArgs = (args: Args) => {
21
23
  return { args };
22
24
  };
23
25
 
24
- const render = (args: any) => ({
26
+ const render = (args: Args) => ({
25
27
  components: { TideChipInput },
26
28
  setup() {
27
29
  return formatArgs(args);
@@ -3,7 +3,13 @@ import { action } from '@storybook/addon-actions';
3
3
  import TideAccordionItem from '@/components/TideAccordionItem.vue';
4
4
  import { argTypeBooleanUnrequired, dataTrack, disabledArgType, doSomething, parameters } from '@/utilities/storybook';
5
5
 
6
- const render = (args: any, context: any) => ({
6
+ import type { StoryContext } from '@storybook/vue3';
7
+
8
+ type Args = InstanceType<typeof TideAccordionItem>['$props'] & {
9
+ handleToggle: string;
10
+ };
11
+
12
+ const render = (args: Args, context: StoryContext) => ({
7
13
  components: { TideAccordionItem },
8
14
  methods: {
9
15
  doSomething,
@@ -12,7 +12,11 @@ import {
12
12
  prependNoneAsUndefined,
13
13
  } from '@/utilities/storybook';
14
14
 
15
- const render = (args: any) => ({
15
+ type Args = InstanceType<typeof TideAlert>['$props'] & {
16
+ handleClose: string;
17
+ };
18
+
19
+ const render = (args: Args) => ({
16
20
  components: { TideAlert },
17
21
  methods: {
18
22
  doSomething,
@@ -5,6 +5,8 @@ import { argTypeBooleanUnrequired, formatArgType, prependNoneAsUndefined } from
5
5
 
6
6
  import type { StoryContext } from '@storybook/vue3';
7
7
 
8
+ type Args = InstanceType<typeof TideBadge>['$props'];
9
+
8
10
  const BADGE_COLOR = prependNoneAsUndefined(STANDARD_BADGE_COLOR);
9
11
  const ICON = prependNoneAsUndefined(STANDARD_ICON.ICON);
10
12
 
@@ -34,7 +36,7 @@ const parameters = {
34
36
  },
35
37
  };
36
38
 
37
- const render = (args: any) => ({
39
+ const render = (args: Args) => ({
38
40
  components: { TideBadge },
39
41
  setup: () => ({ args }),
40
42
  template: `<TideBadge v-bind="args" />`,
@@ -2,9 +2,11 @@ import TideBadgeTrustedPartner from '@/components/TideBadgeTrustedPartner.vue';
2
2
  import * as STANDARD_BADGE from '@/types/Storybook';
3
3
  import { formatArgType, parameters, prependNoneAsUndefined } from '@/utilities/storybook';
4
4
 
5
+ type Args = InstanceType<typeof TideBadgeTrustedPartner>['$props'];
6
+
5
7
  const BADGE_TRUSTED = prependNoneAsUndefined(STANDARD_BADGE.BADGE_TRUSTED);
6
8
 
7
- const render = (args: any) => ({
9
+ const render = (args: Args) => ({
8
10
  components: { TideBadgeTrustedPartner },
9
11
  setup: () => ({ args }),
10
12
  template: `<TideBadgeTrustedPartner v-bind="args" />`,
@@ -1,7 +1,9 @@
1
1
  import TideBadgeVerifiedVehicle from '@/components/TideBadgeVerifiedVehicle.vue';
2
2
  import { parameters } from '@/utilities/storybook';
3
3
 
4
- const render = (args: any) => ({
4
+ type Args = InstanceType<typeof TideBadgeVerifiedVehicle>['$props'];
5
+
6
+ const render = (args: Args) => ({
5
7
  components: { TideBadgeVerifiedVehicle },
6
8
  setup: () => ({ args }),
7
9
  template: `<TideBadgeVerifiedVehicle v-bind="args" />`,
@@ -15,12 +15,16 @@ import {
15
15
  prependNoneAsUndefined,
16
16
  } from '@/utilities/storybook';
17
17
 
18
+ type Args = InstanceType<typeof TideButton>['$props'] & {
19
+ click: string;
20
+ };
21
+
18
22
  const ELEMENT = prependNoneAsUndefined(STANDARD_ELEMENT.ELEMENT);
19
23
  const ICON = prependNoneAsUndefined(STANDARD_ICON.ICON);
20
24
  const PRIORITY = prependNoneAsUndefined(STANDARD_PRIORITY.PRIORITY);
21
25
  const SIZE_BUTTON = prependNoneAsUndefined(STANDARD_SIZE_BUTTON.SIZE_BUTTON);
22
26
 
23
- const render = (args: any) => ({
27
+ const render = (args: Args) => ({
24
28
  components: { TideButton },
25
29
  methods: {
26
30
  doSomething,
@@ -14,10 +14,14 @@ import {
14
14
  prependNoneAsUndefined,
15
15
  } from '@/utilities/storybook';
16
16
 
17
+ type Args = InstanceType<typeof TideButtonIcon>['$props'] & {
18
+ click: string;
19
+ };
20
+
17
21
  const ELEMENT = prependNoneAsUndefined(STANDARD_ELEMENT.ELEMENT);
18
22
  const PRIORITY = prependNoneAsUndefined(STANDARD_PRIORITY.PRIORITY);
19
23
 
20
- const render = (args: any) => ({
24
+ const render = (args: Args) => ({
21
25
  components: { TideButtonIcon },
22
26
  methods: {
23
27
  doSomething,
@@ -12,9 +12,13 @@ import {
12
12
  prependNoneAsUndefined,
13
13
  } from '@/utilities/storybook';
14
14
 
15
+ type Args = InstanceType<typeof TideButtonPagination>['$props'] & {
16
+ click: string;
17
+ };
18
+
15
19
  const ELEMENT_TEXT_AS_ICON = prependNoneAsUndefined(STANDARD_ELEMENT.ELEMENT_TEXT_AS_ICON);
16
20
 
17
- const render = (args: any) => ({
21
+ const render = (args: Args) => ({
18
22
  components: { TideButtonPagination },
19
23
  methods: {
20
24
  doSomething,
@@ -4,6 +4,11 @@ import TideButtonSegmented from '@/components/TideButtonSegmented.vue';
4
4
  import { change, disabledArgType, doSomething, getLabelsFromOptions, parameters } from '@/utilities/storybook';
5
5
 
6
6
  import type { Tab } from '@/types/Tab';
7
+ import type { StoryContext } from '@storybook/vue3';
8
+
9
+ type Args = InstanceType<typeof TideButtonSegmented>['$props'] & {
10
+ handleChange: string;
11
+ };
7
12
 
8
13
  const options = {
9
14
  'None': undefined,
@@ -27,13 +32,13 @@ const tabs: Tab[] = [
27
32
  },
28
33
  ];
29
34
 
30
- const render = (args: any, { updateArgs }: any) => ({
35
+ const render = (args: Args, context: StoryContext) => ({
31
36
  components: { TideButtonSegmented },
32
37
  methods: {
33
38
  doSomething,
34
39
  handleChange: (index: number) => {
35
40
  action(`Current tab ${index}`)(index);
36
- updateArgs({ ...args, activeTab: index });
41
+ context.updateArgs({ ...args, activeTab: index });
37
42
 
38
43
  try {
39
44
  const callback = eval(args.handleChange);
@@ -12,10 +12,14 @@ import {
12
12
  prependNoneAsUndefined,
13
13
  } from '@/utilities/storybook';
14
14
 
15
+ type Args = InstanceType<typeof TideCard>['$props'] & {
16
+ click: string;
17
+ };
18
+
15
19
  const TYPE_CARD = prependNoneAsUndefined(STANDARD_TYPE_CARD);
16
20
  const CARD_ICON = prependNoneAsUndefined(ICON);
17
21
 
18
- const render = (args: any) => ({
22
+ const render = (args: Args) => ({
19
23
  components: { TideCard },
20
24
  methods: {
21
25
  doSomething,
@@ -6,6 +6,12 @@ import { argTypeBooleanUnrequired, disabledArgType, doSomething, lineBreak, tab
6
6
 
7
7
  import type { StoryContext } from '@storybook/vue3';
8
8
 
9
+ type Args = InstanceType<typeof TideCarousel>['$props'] & {
10
+ bleed: number | string;
11
+ handleSlideChange: string;
12
+ handleSlidesAddedToView: string;
13
+ };
14
+
9
15
  const formatSnippet = (code: string, context: StoryContext) => {
10
16
  const { args } = context;
11
17
 
@@ -44,7 +50,7 @@ const parameters = {
44
50
  },
45
51
  };
46
52
 
47
- const render = (args: any) => ({
53
+ const render = (args: Args) => ({
48
54
  components: { TideCard, TideCarousel },
49
55
  methods: {
50
56
  doSomething,
@@ -94,7 +100,7 @@ const render = (args: any) => ({
94
100
  </li>
95
101
  </TideCarousel>`,
96
102
  updated() {
97
- if (args.bleed === '') {
103
+ if (typeof args.bleed === 'string' && args.bleed === '') {
98
104
  args.bleed = 0;
99
105
  }
100
106
 
@@ -9,9 +9,11 @@ import {
9
9
  prependNoneAsUndefined,
10
10
  } from '@/utilities/storybook';
11
11
 
12
+ type Args = InstanceType<typeof TideChipAction>['$props'];
13
+
12
14
  const ELEMENT = prependNoneAsUndefined(STANDARD_ELEMENT.ELEMENT);
13
15
 
14
- const render = (args: any) => ({
16
+ const render = (args: Args) => ({
15
17
  components: { TideChipAction },
16
18
  setup: () => ({ args }),
17
19
  template: '<TideChipAction class="tide-display-inline-flex" v-bind="args" />',
@@ -3,13 +3,19 @@ import { action } from '@storybook/addon-actions';
3
3
  import TideChipFilter from '@/components/TideChipFilter.vue';
4
4
  import { argTypeBooleanUnrequired, click, dataTrack, doSomething, parameters } from '@/utilities/storybook';
5
5
 
6
- const render = (args: any, { updateArgs }: any) => ({
6
+ import type { StoryContext } from '@storybook/vue3';
7
+
8
+ type Args = InstanceType<typeof TideChipFilter>['$props'] & {
9
+ handleClose: string;
10
+ };
11
+
12
+ const render = (args: Args, context: StoryContext) => ({
7
13
  components: { TideChipFilter },
8
14
  methods: {
9
15
  doSomething,
10
16
  handleClick: () => {
11
17
  action('TideChipFilter clicked')({});
12
- updateArgs({ ...args, isActive: !args.isActive });
18
+ context.updateArgs({ ...args, isActive: !args.isActive });
13
19
 
14
20
  try {
15
21
  const callback = eval(args.handleClose);
@@ -3,7 +3,11 @@ import { action } from '@storybook/addon-actions';
3
3
  import TideChipInput from '@/components/TideChipInput.vue';
4
4
  import { click, dataTrack, doSomething, parameters } from '@/utilities/storybook';
5
5
 
6
- const render = (args: any) => ({
6
+ type Args = InstanceType<typeof TideChipInput>['$props'] & {
7
+ click: string;
8
+ };
9
+
10
+ const render = (args: Args) => ({
7
11
  components: { TideChipInput },
8
12
  methods: {
9
13
  doSomething,
@@ -2,13 +2,17 @@ import TideDivider from '@/components/TideDivider.vue';
2
2
  import { ORIENTATION as STANDARD_ORIENTATION } from '@/types/Orientation';
3
3
  import { disabledArgType, formatArgType, parameters, prependNoneAsUndefined } from '@/utilities/storybook';
4
4
 
5
- const formatArgs = (args: any) => {
5
+ type Args = InstanceType<typeof TideDivider>['$props'] & {
6
+ flexDirection: string;
7
+ };
8
+
9
+ const formatArgs = (args: Args) => {
6
10
  args.flexDirection = args.orientation === ORIENTATION.VERTICAL ? 'tide-flex-row' : 'tide-flex-column';
7
11
 
8
12
  return { args };
9
13
  };
10
14
 
11
- const render = (args: any) => ({
15
+ const render = (args: Args) => ({
12
16
  components: { TideDivider },
13
17
  setup: () => formatArgs(args),
14
18
  template: `<div :class="['tide-display-inline-flex', args.flexDirection]">
@@ -5,6 +5,8 @@ import { argTypeBooleanUnrequired } from '@/utilities/storybook';
5
5
  import type { Source } from '@/types/Source';
6
6
  import type { StoryContext } from '@storybook/vue3';
7
7
 
8
+ type Args = InstanceType<typeof TideImageBackground>['$props'];
9
+
8
10
  const formatSnippet = (_code: string, context: StoryContext) => {
9
11
  const { args } = context;
10
12
  const argsWithValues: string[] = [`alt="${args.alt}"`];
@@ -28,7 +30,7 @@ const parameters = {
28
30
  },
29
31
  };
30
32
 
31
- const render = (args: any) => ({
33
+ const render = (args: Args) => ({
32
34
  components: { TideImageBackground },
33
35
  setup() {
34
36
  return { args };
@@ -1,7 +1,9 @@
1
1
  import TideIndicator from '@/components/TideIndicator.vue';
2
2
  import { parameters } from '@/utilities/storybook';
3
3
 
4
- const render = (args: any) => ({
4
+ type Args = InstanceType<typeof TideIndicator>['$props'];
5
+
6
+ const render = (args: Args) => ({
5
7
  components: { TideIndicator },
6
8
  setup: () => ({ args }),
7
9
  template: `<TideIndicator v-bind="args" />`,
@@ -3,7 +3,13 @@ import { action } from '@storybook/addon-actions';
3
3
  import TideInputCheckbox from '@/components/TideInputCheckbox.vue';
4
4
  import { argTypeBooleanUnrequired, click, dataTrack, doSomething, parameters } from '@/utilities/storybook';
5
5
 
6
- const render = (args: any, context: any) => ({
6
+ import type { StoryContext } from '@storybook/vue3';
7
+
8
+ type Args = InstanceType<typeof TideInputCheckbox>['$props'] & {
9
+ click: string;
10
+ };
11
+
12
+ const render = (args: Args, context: StoryContext) => ({
7
13
  components: { TideInputCheckbox },
8
14
  methods: {
9
15
  doSomething,
@@ -11,7 +17,7 @@ const render = (args: any, context: any) => ({
11
17
  const input = context.canvasElement.querySelector('input');
12
18
 
13
19
  action('TideInputCheckbox clicked')({});
14
- context.updateArgs({ ...args, checked: !input.checked === true, indeterminate: undefined });
20
+ context.updateArgs({ ...args, checked: !input?.checked === true, indeterminate: undefined });
15
21
 
16
22
  try {
17
23
  const callback = eval(args.click);
@@ -3,7 +3,13 @@ import { action } from '@storybook/addon-actions';
3
3
  import TideInputRadio from '@/components/TideInputRadio.vue';
4
4
  import { argTypeBooleanUnrequired, click, dataTrack, doSomething, parameters } from '@/utilities/storybook';
5
5
 
6
- const render = (args: any, context: any) => ({
6
+ import type { StoryContext } from '@storybook/vue3';
7
+
8
+ type Args = InstanceType<typeof TideInputRadio>['$props'] & {
9
+ click: string;
10
+ };
11
+
12
+ const render = (args: Args, context: StoryContext) => ({
7
13
  components: { TideInputRadio },
8
14
  methods: {
9
15
  doSomething,
@@ -11,7 +17,7 @@ const render = (args: any, context: any) => ({
11
17
  const input = context.canvasElement.querySelector('input');
12
18
 
13
19
  action('TideInputRadio changed')({});
14
- context.updateArgs({ ...args, checked: !input.checked });
20
+ context.updateArgs({ ...args, checked: !input?.checked });
15
21
 
16
22
  try {
17
23
  const callback = eval(args.click);
@@ -12,6 +12,11 @@ import {
12
12
  } from '@/utilities/storybook';
13
13
 
14
14
  import type { SelectOption, SelectOptionGroup } from '@/types/Select';
15
+ import type { StoryContext } from '@storybook/vue3';
16
+
17
+ type Args = InstanceType<typeof TideInputSelect>['$props'] & {
18
+ change: string;
19
+ };
15
20
 
16
21
  const options = {
17
22
  'Any': '',
@@ -82,7 +87,7 @@ const selectOptions: SelectOption[] = [
82
87
  },
83
88
  ];
84
89
 
85
- const render = (args: any, { updateArgs }: any) => ({
90
+ const render = (args: Args, context: StoryContext) => ({
86
91
  components: { TideInputSelect },
87
92
  methods: {
88
93
  doSomething,
@@ -90,7 +95,7 @@ const render = (args: any, { updateArgs }: any) => ({
90
95
  const value = (event?.target as HTMLSelectElement).value;
91
96
 
92
97
  action('TideInputSelect changed')({});
93
- updateArgs({ ...args, value });
98
+ context.updateArgs({ ...args, value });
94
99
 
95
100
  try {
96
101
  const callback = eval(args.change);
@@ -15,18 +15,22 @@ import {
15
15
  prependNoneAsUndefined,
16
16
  } from '@/utilities/storybook';
17
17
 
18
+ import type { StoryContext } from '@storybook/vue3';
19
+
20
+ type Args = InstanceType<typeof TideInputText>['$props'];
21
+
18
22
  const FORMAT = prependNoneAsUndefined(STANDARD_FORMAT.FORMAT);
19
23
  const ICON = prependNoneAsUndefined(STANDARD_ICON.ICON);
20
24
  const TEXT_INPUT_TYPE = prependNoneAsUndefined(STANDARD_TEXT_INPUT_TYPE.TEXT_INPUT_TYPE);
21
25
 
22
- const render = (args: any, context: any) => ({
26
+ const render = (args: Args, context: StoryContext) => ({
23
27
  components: { TideInputText },
24
28
  methods: {
25
29
  handleChange: () => {
26
30
  const input = context.canvasElement.querySelector('input');
27
31
 
28
32
  action('TideInputText changed')({});
29
- context.updateArgs({ ...args, value: input.value });
33
+ context.updateArgs({ ...args, value: input?.value });
30
34
  },
31
35
  },
32
36
  setup: () => ({ args }),
@@ -3,14 +3,18 @@ import { action } from '@storybook/addon-actions';
3
3
  import TideInputTextarea from '@/components/TideInputTextarea.vue';
4
4
  import { argTypeBooleanUnrequired, dataTrack, parameters } from '@/utilities/storybook';
5
5
 
6
- const render = (args: any, context: any) => ({
6
+ import type { StoryContext } from '@storybook/vue3';
7
+
8
+ type Args = InstanceType<typeof TideInputTextarea>['$props'];
9
+
10
+ const render = (args: Args, context: StoryContext) => ({
7
11
  components: { TideInputTextarea },
8
12
  methods: {
9
13
  handleChange: () => {
10
14
  const input = context.canvasElement.querySelector('textarea');
11
15
 
12
16
  action('TideInputTextarea changed')({});
13
- context.updateArgs({ ...args, value: input.value });
17
+ context.updateArgs({ ...args, value: input?.value });
14
18
  },
15
19
  },
16
20
  setup: () => ({ args }),