@integry/sdk 4.5.15 → 4.5.16

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 (30) hide show
  1. package/dist/esm/index.csm.js +639 -639
  2. package/dist/umd/index.umd.js +639 -639
  3. package/package.json +9 -8
  4. package/src/stories/Button.stories.tsx +0 -83
  5. package/src/stories/Checkbox/Checkbox.stories.tsx +0 -41
  6. package/src/stories/Checkbox/CheckboxGroup.stories.tsx +0 -46
  7. package/src/stories/EditableText.stories.tsx +0 -35
  8. package/src/stories/Input/BaseInput.stories.tsx +0 -48
  9. package/src/stories/Input/DateInput.stories.tsx +0 -28
  10. package/src/stories/Input/Input.stories.tsx +0 -24
  11. package/src/stories/Input/PasswordInput.stories.tsx +0 -26
  12. package/src/stories/Introduction.stories.mdx +0 -211
  13. package/src/stories/Label.stories.tsx +0 -27
  14. package/src/stories/Listbox.stories.tsx +0 -122
  15. package/src/stories/Radio/Radio.stories.tsx +0 -39
  16. package/src/stories/Radio/RadioGroup.stories.tsx +0 -46
  17. package/src/stories/StepNavigation/NavItem.stories.tsx +0 -31
  18. package/src/stories/StepNavigation/StepNavigation.stories.tsx +0 -50
  19. package/src/stories/TabBar.stories.tsx +0 -31
  20. package/src/stories/TextArea.stories.tsx +0 -23
  21. package/src/stories/TimeInput.stories.tsx +0 -37
  22. package/src/stories/Toggle.stories.tsx +0 -33
  23. package/src/stories/assets/code-brackets.svg +0 -1
  24. package/src/stories/assets/colors.svg +0 -1
  25. package/src/stories/assets/comments.svg +0 -1
  26. package/src/stories/assets/direction.svg +0 -1
  27. package/src/stories/assets/flow.svg +0 -1
  28. package/src/stories/assets/plugin.svg +0 -1
  29. package/src/stories/assets/repo.svg +0 -1
  30. package/src/stories/assets/stackalt.svg +0 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@integry/sdk",
3
- "version": "4.5.15",
3
+ "version": "4.5.16",
4
4
  "description": "Integry SDK",
5
5
  "main": "dist/umd/index.umd.js",
6
6
  "module": "dist/esm/index.csm.js",
@@ -16,8 +16,8 @@
16
16
  "test": "vitest",
17
17
  "test:watch": "vitest --watch",
18
18
  "test:coverage": "vitest --coverage",
19
- "storybook": "start-storybook -p 6006",
20
- "build-storybook": "build-storybook",
19
+ "storybook": "storybook dev -p 6006",
20
+ "build-storybook": "storybook build",
21
21
  "publish-beta": "npm publish --tag beta"
22
22
  },
23
23
  "keywords": [
@@ -43,12 +43,13 @@
43
43
  "@rollup/plugin-node-resolve": "^11.2.1",
44
44
  "@rollup/plugin-replace": "^3.0.0",
45
45
  "@size-limit/preset-big-lib": "^4.10.2",
46
- "@storybook/addon-a11y": "^6.5.12",
47
- "@storybook/addon-actions": "^6.5.12",
48
- "@storybook/addon-essentials": "^6.5.12",
49
- "@storybook/addon-links": "^6.5.12",
46
+ "@storybook/addon-a11y": "^8.5.7",
47
+ "@storybook/addon-actions": "^8.5.7",
48
+ "@storybook/addon-essentials": "^8.5.7",
49
+ "@storybook/addon-links": "^8.5.7",
50
50
  "@storybook/addon-postcss": "^2.0.0",
51
- "@storybook/preact": "^6.5.12",
51
+ "@storybook/preact": "^8.5.7",
52
+ "@storybook/preact-webpack5": "^8.5.7",
52
53
  "@storybook/preset-scss": "^1.0.3",
53
54
  "@testing-library/preact": "^2.0.1",
54
55
  "@testing-library/user-event": "^14.6.1",
@@ -1,83 +0,0 @@
1
- /* eslint-disable @typescript-eslint/no-unused-vars */
2
- /* eslint-disable import/no-extraneous-dependencies */
3
- /** @jsx h */
4
- import { h } from 'htm/preact';
5
- import { Story } from '@storybook/preact';
6
- import { Button, ButtonProps, ButtonTypes } from '@/components/Button';
7
-
8
- export default {
9
- title: 'Button',
10
- component: Button,
11
- argTypes: {
12
- label: {
13
- name: 'Label',
14
- type: { name: 'string', required: true },
15
- description: 'Button label',
16
- },
17
- type: {
18
- name: 'Type',
19
- description: 'Button type',
20
- options: ['primary', 'secondary', 'link'],
21
- control: { type: 'radio' },
22
- },
23
- size: {
24
- name: 'Size',
25
- description: 'Button size',
26
- options: ['small', 'medium', 'large'],
27
- control: { type: 'radio' },
28
- },
29
- isLoading: {
30
- name: 'Loading',
31
- description: 'Show loading state',
32
- options: [true, false],
33
- control: { type: 'radio' },
34
- },
35
- color: { name: 'Text Color', control: 'color' },
36
- backgroundColor: { name: 'Background Color', control: 'color' },
37
- onClick: { action: 'onClick' },
38
- },
39
- };
40
-
41
- const Template: Story<ButtonProps> = (args: ButtonProps) => (
42
- <Button {...args} />
43
- );
44
-
45
- export const Primary = Template.bind({});
46
-
47
- Primary.args = {
48
- type: ButtonTypes.PRIMARY,
49
- label: 'Primary Button',
50
- };
51
-
52
- export const Secondary = Template.bind({});
53
- Secondary.args = {
54
- type: ButtonTypes.SECONDARY,
55
- label: 'Secondary Button',
56
- };
57
-
58
- export const Link = Template.bind({});
59
- Link.args = {
60
- type: ButtonTypes.LINK,
61
- label: 'Link',
62
- };
63
-
64
- export const Large = Template.bind({});
65
- Large.args = {
66
- label: 'Large Button',
67
- };
68
-
69
- export const Medium = Template.bind({});
70
- Medium.args = {
71
- label: 'Medium Button',
72
- };
73
-
74
- export const Small = Template.bind({});
75
- Small.args = {
76
- label: 'Small Button',
77
- };
78
-
79
- export const Loading = Template.bind({});
80
- Loading.args = {
81
- label: 'Save',
82
- isLoading: true,
83
- };
@@ -1,41 +0,0 @@
1
- /* eslint-disable @typescript-eslint/no-unused-vars */
2
- /* eslint-disable import/no-extraneous-dependencies */
3
- /** @jsx h */
4
- import { h } from 'htm/preact';
5
- import { Story } from '@storybook/preact';
6
- import { Checkbox, CheckboxProps } from '@/components/CheckboxGroup/Checkbox';
7
-
8
- export default {
9
- title: 'Checkbox',
10
- component: Checkbox,
11
- argTypes: {
12
- isChecked: {
13
- name: 'Checked',
14
- description: 'Checked',
15
- options: [true, false],
16
- control: { type: 'radio' },
17
- },
18
- handleChange: { action: 'onClick' },
19
- },
20
- };
21
-
22
- const Template: Story<CheckboxProps> = (args: CheckboxProps) => (
23
- <Checkbox {...args} />
24
- );
25
-
26
- export const Primary = Template.bind({});
27
-
28
- Primary.args = {
29
- name: 'primary',
30
- label: 'Primary Button',
31
- value: 'primary',
32
- };
33
-
34
- export const Description = Template.bind({});
35
-
36
- Description.args = {
37
- name: 'primary',
38
- label: 'Primary Button',
39
- description: 'With description',
40
- value: 'primary',
41
- };
@@ -1,46 +0,0 @@
1
- /* eslint-disable @typescript-eslint/no-unused-vars */
2
- /* eslint-disable import/no-extraneous-dependencies */
3
- /** @jsx h */
4
- import { h } from 'htm/preact';
5
- import { Story } from '@storybook/preact';
6
- import { CheckboxGroup, CheckboxGroupProps } from '@/components/CheckboxGroup';
7
-
8
- export default {
9
- title: 'CheckboxGroup',
10
- component: CheckboxGroup,
11
- argTypes: {
12
- onChange: { action: 'onChange' },
13
- },
14
- };
15
-
16
- const Template: Story<CheckboxGroupProps> = (args: CheckboxGroupProps) => (
17
- <CheckboxGroup {...args} />
18
- );
19
-
20
- export const Primary = Template.bind({});
21
-
22
- Primary.args = {
23
- title: 'Checkbox selection',
24
- description: 'Select option/s from the following',
25
- selectedItemIndices: [0, 1],
26
- items: [
27
- {
28
- name: 'item_a',
29
- value: 'item_a',
30
- label: 'Item A',
31
- description: 'A description for item A',
32
- },
33
- {
34
- name: 'item_b',
35
- value: 'item_b',
36
- label: 'Item B',
37
- description: 'A description for item B',
38
- },
39
- {
40
- name: 'item_c',
41
- value: 'item_c',
42
- label: 'Item C',
43
- description: 'A description for item C',
44
- },
45
- ],
46
- };
@@ -1,35 +0,0 @@
1
- /* eslint-disable @typescript-eslint/no-unused-vars */
2
- /* eslint-disable import/no-extraneous-dependencies */
3
- /** @jsx h */
4
- import { h } from 'htm/preact';
5
- import { useState } from 'preact/hooks';
6
- import { Story } from '@storybook/preact';
7
-
8
- import { EditableText, EditableTextProps } from '@/components/EditableText';
9
-
10
- export default {
11
- title: 'EditableText',
12
- component: EditableText,
13
- argTypes: {
14
- value: { type: 'string' },
15
- handleChange: { action: 'onChange' },
16
- },
17
- };
18
-
19
- const Template: Story<EditableTextProps> = (args: EditableTextProps) => {
20
- const [value, setValue] = useState(args.value ?? '');
21
-
22
- return (
23
- <EditableText
24
- {...args}
25
- value={value}
26
- handleChange={(val) => setValue(val)}
27
- ></EditableText>
28
- );
29
- };
30
-
31
- export const Primary = Template.bind({});
32
-
33
- Primary.args = {
34
- value: 'This is text',
35
- };
@@ -1,48 +0,0 @@
1
- /* eslint-disable @typescript-eslint/no-unused-vars */
2
- /* eslint-disable import/no-extraneous-dependencies */
3
- /** @jsx h */
4
- import { h } from 'htm/preact';
5
- import { Story } from '@storybook/preact';
6
- import { BaseInput, BaseInputProps } from '@/components/Input/BaseInput';
7
-
8
- export default {
9
- title: 'BaseInput',
10
- component: BaseInput,
11
- argTypes: {
12
- handleChange: { action: 'onChange' },
13
- },
14
- };
15
-
16
- const Template: Story<BaseInputProps> = (args: BaseInputProps) => (
17
- <BaseInput {...args} />
18
- );
19
-
20
- export const Primary = Template.bind({});
21
-
22
- Primary.args = {
23
- value: '',
24
- placeholder: 'Placeholder',
25
- };
26
-
27
- export const WithValue = Template.bind({});
28
-
29
- WithValue.args = {
30
- value: 'I am filled',
31
- placeholder: 'Placeholder',
32
- };
33
-
34
- export const Number = Template.bind({});
35
-
36
- Number.args = {
37
- type: 'number',
38
- value: '10',
39
- placeholder: 'Placeholder',
40
- };
41
-
42
- export const Password = Template.bind({});
43
-
44
- Password.args = {
45
- type: 'password',
46
- value: '10',
47
- placeholder: 'Placeholder',
48
- };
@@ -1,28 +0,0 @@
1
- /* eslint-disable @typescript-eslint/no-unused-vars */
2
- /* eslint-disable import/no-extraneous-dependencies */
3
- /** @jsx h */
4
- import { h } from 'htm/preact';
5
- import { Story } from '@storybook/preact';
6
- import { DateInput, DateInputProps } from '@/components/Input';
7
- import { getDateFormat } from '@/utils/datetime';
8
-
9
- export default {
10
- title: 'DateInput',
11
- component: DateInput,
12
- argTypes: {
13
- onChange: { action: 'onChange' },
14
- },
15
- };
16
-
17
- const Template: Story<DateInputProps> = (args: DateInputProps) => (
18
- <DateInput {...args} />
19
- );
20
-
21
- export const Primary = Template.bind({});
22
-
23
- Primary.args = {
24
- placeholder: 'Placeholder',
25
- title: 'An input',
26
- description: 'Some description',
27
- value: getDateFormat(new Date()),
28
- };
@@ -1,24 +0,0 @@
1
- /* eslint-disable @typescript-eslint/no-unused-vars */
2
- /* eslint-disable import/no-extraneous-dependencies */
3
- /** @jsx h */
4
- import { h } from 'htm/preact';
5
- import { Story } from '@storybook/preact';
6
- import { Input, InputProps } from '@/components/Input';
7
-
8
- export default {
9
- title: 'Input',
10
- component: Input,
11
- argTypes: {
12
- value: { type: 'string' },
13
- },
14
- };
15
-
16
- const Template: Story<InputProps> = (args: InputProps) => <Input {...args} />;
17
-
18
- export const Primary = Template.bind({});
19
-
20
- Primary.args = {
21
- placeholder: 'Placeholder',
22
- title: 'An input',
23
- description: 'Some description',
24
- };
@@ -1,26 +0,0 @@
1
- /* eslint-disable @typescript-eslint/no-unused-vars */
2
- /* eslint-disable import/no-extraneous-dependencies */
3
- /** @jsx h */
4
- import { h } from 'htm/preact';
5
- import { Story } from '@storybook/preact';
6
- import { PasswordInput, PasswordInputProps } from '@/components/Input';
7
-
8
- export default {
9
- title: 'PasswordInput',
10
- component: PasswordInput,
11
- argTypes: {
12
- value: { type: 'string' },
13
- },
14
- };
15
-
16
- const Template: Story<PasswordInputProps> = (args: PasswordInputProps) => (
17
- <PasswordInput {...args} />
18
- );
19
-
20
- export const Primary = Template.bind({});
21
-
22
- Primary.args = {
23
- placeholder: 'Placeholder',
24
- title: 'A password input',
25
- description: 'Some description for this password input',
26
- };
@@ -1,211 +0,0 @@
1
- import { Meta } from '@storybook/addon-docs';
2
- import Code from './assets/code-brackets.svg';
3
- import Colors from './assets/colors.svg';
4
- import Comments from './assets/comments.svg';
5
- import Direction from './assets/direction.svg';
6
- import Flow from './assets/flow.svg';
7
- import Plugin from './assets/plugin.svg';
8
- import Repo from './assets/repo.svg';
9
- import StackAlt from './assets/stackalt.svg';
10
-
11
- <Meta title="Example/Introduction" />
12
-
13
- <style>{`
14
- .subheading {
15
- --mediumdark: '#999999';
16
- font-weight: 900;
17
- font-size: 13px;
18
- color: #999;
19
- letter-spacing: 6px;
20
- line-height: 24px;
21
- text-transform: uppercase;
22
- margin-bottom: 12px;
23
- margin-top: 40px;
24
- }
25
-
26
- .link-list {
27
- display: grid;
28
- grid-template-columns: 1fr;
29
- grid-template-rows: 1fr 1fr;
30
- row-gap: 10px;
31
- }
32
-
33
- @media (min-width: 620px) {
34
- .link-list {
35
- row-gap: 20px;
36
- column-gap: 20px;
37
- grid-template-columns: 1fr 1fr;
38
- }
39
- }
40
-
41
- @media all and (-ms-high-contrast:none) {
42
- .link-list {
43
- display: -ms-grid;
44
- -ms-grid-columns: 1fr 1fr;
45
- -ms-grid-rows: 1fr 1fr;
46
- }
47
- }
48
-
49
- .link-item {
50
- display: block;
51
- padding: 20px 30px 20px 15px;
52
- border: 1px solid #00000010;
53
- border-radius: 5px;
54
- transition: background 150ms ease-out, border 150ms ease-out, transform 150ms ease-out;
55
- color: #333333;
56
- display: flex;
57
- align-items: flex-start;
58
- }
59
-
60
- .link-item:hover {
61
- border-color: #1EA7FD50;
62
- transform: translate3d(0, -3px, 0);
63
- box-shadow: rgba(0, 0, 0, 0.08) 0 3px 10px 0;
64
- }
65
-
66
- .link-item:active {
67
- border-color: #1EA7FD;
68
- transform: translate3d(0, 0, 0);
69
- }
70
-
71
- .link-item strong {
72
- font-weight: 700;
73
- display: block;
74
- margin-bottom: 2px;
75
- }
76
-
77
- .link-item img {
78
- height: 40px;
79
- width: 40px;
80
- margin-right: 15px;
81
- flex: none;
82
- }
83
-
84
- .link-item span {
85
- font-size: 14px;
86
- line-height: 20px;
87
- }
88
-
89
- .tip {
90
- display: inline-block;
91
- border-radius: 1em;
92
- font-size: 11px;
93
- line-height: 12px;
94
- font-weight: 700;
95
- background: #E7FDD8;
96
- color: #66BF3C;
97
- padding: 4px 12px;
98
- margin-right: 10px;
99
- vertical-align: top;
100
- }
101
-
102
- .tip-wrapper {
103
- font-size: 13px;
104
- line-height: 20px;
105
- margin-top: 40px;
106
- margin-bottom: 40px;
107
- }
108
-
109
- .tip-wrapper code {
110
- font-size: 12px;
111
- display: inline-block;
112
- }
113
-
114
-
115
- `}</style>
116
-
117
- # Welcome to Storybook
118
-
119
- Storybook helps you build UI components in isolation from your app's business logic, data, and context.
120
- That makes it easy to develop hard-to-reach states. Save these UI states as **stories** to revisit during development, testing, or QA.
121
-
122
- Browse example stories now by navigating to them in the sidebar.
123
- View their code in the `src/stories` directory to learn how they work.
124
- We recommend building UIs with a [**component-driven**](https://componentdriven.org) process starting with atomic components and ending with pages.
125
-
126
- <div className="subheading">Configure</div>
127
-
128
- <div className="link-list">
129
- <a
130
- className="link-item"
131
- href="https://storybook.js.org/docs/react/addons/addon-types"
132
- target="_blank"
133
- >
134
- <img src={Plugin} alt="plugin" />
135
- <span>
136
- <strong>Presets for popular tools</strong>
137
- Easy setup for TypeScript, SCSS and more.
138
- </span>
139
- </a>
140
- <a
141
- className="link-item"
142
- href="https://storybook.js.org/docs/react/configure/webpack"
143
- target="_blank"
144
- >
145
- <img src={StackAlt} alt="Build" />
146
- <span>
147
- <strong>Build configuration</strong>
148
- How to customize webpack and Babel
149
- </span>
150
- </a>
151
- <a
152
- className="link-item"
153
- href="https://storybook.js.org/docs/react/configure/styling-and-css"
154
- target="_blank"
155
- >
156
- <img src={Colors} alt="colors" />
157
- <span>
158
- <strong>Styling</strong>
159
- How to load and configure CSS libraries
160
- </span>
161
- </a>
162
- <a
163
- className="link-item"
164
- href="https://storybook.js.org/docs/react/get-started/setup#configure-storybook-for-your-stack"
165
- target="_blank"
166
- >
167
- <img src={Flow} alt="flow" />
168
- <span>
169
- <strong>Data</strong>
170
- Providers and mocking for data libraries
171
- </span>
172
- </a>
173
- </div>
174
-
175
- <div className="subheading">Learn</div>
176
-
177
- <div className="link-list">
178
- <a className="link-item" href="https://storybook.js.org/docs" target="_blank">
179
- <img src={Repo} alt="repo" />
180
- <span>
181
- <strong>Storybook documentation</strong>
182
- Configure, customize, and extend
183
- </span>
184
- </a>
185
- <a className="link-item" href="https://storybook.js.org/tutorials/" target="_blank">
186
- <img src={Direction} alt="direction" />
187
- <span>
188
- <strong>In-depth guides</strong>
189
- Best practices from leading teams
190
- </span>
191
- </a>
192
- <a className="link-item" href="https://github.com/storybookjs/storybook" target="_blank">
193
- <img src={Code} alt="code" />
194
- <span>
195
- <strong>GitHub project</strong>
196
- View the source and add issues
197
- </span>
198
- </a>
199
- <a className="link-item" href="https://discord.gg/storybook" target="_blank">
200
- <img src={Comments} alt="comments" />
201
- <span>
202
- <strong>Discord chat</strong>
203
- Chat with maintainers and the community
204
- </span>
205
- </a>
206
- </div>
207
-
208
- <div className="tip-wrapper">
209
- <span className="tip">Tip</span>Edit the Markdown in{' '}
210
- <code>src/stories/Introduction.stories.mdx</code>
211
- </div>
@@ -1,27 +0,0 @@
1
- /* eslint-disable @typescript-eslint/no-unused-vars */
2
- /* eslint-disable import/no-extraneous-dependencies */
3
- /** @jsx h */
4
- import { h } from 'htm/preact';
5
- import { Story } from '@storybook/preact';
6
-
7
- import { Label, LabelProps } from '@/components/Label';
8
-
9
- export default {
10
- title: 'Label',
11
- component: Label,
12
- };
13
-
14
- const Template: Story<LabelProps> = (args: LabelProps) => <Label {...args} />;
15
-
16
- export const Primary = Template.bind({});
17
-
18
- Primary.args = {
19
- title: 'Title',
20
- description: 'Primary Button',
21
- };
22
-
23
- export const Secondary = Template.bind({});
24
-
25
- Secondary.args = {
26
- title: 'Title',
27
- };