@qoretechnologies/reqore 0.36.0 → 0.36.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/__tests__/collection.test.tsx +1 -22
- package/__tests__/table.test.tsx +1 -1
- package/__tests__/tree.test.tsx +0 -18
- package/dist/components/Breadcrumbs/index.js +1 -1
- package/dist/components/Breadcrumbs/index.js.map +1 -1
- package/dist/components/Button/index.d.ts +1 -4
- package/dist/components/Button/index.d.ts.map +1 -1
- package/dist/components/Button/index.js +11 -26
- package/dist/components/Button/index.js.map +1 -1
- package/dist/components/Collection/index.d.ts +2 -2
- package/dist/components/Collection/index.d.ts.map +1 -1
- package/dist/components/Collection/index.js +10 -10
- package/dist/components/Collection/index.js.map +1 -1
- package/dist/components/Collection/item.d.ts +3 -3
- package/dist/components/Collection/item.d.ts.map +1 -1
- package/dist/components/Collection/item.js.map +1 -1
- package/dist/components/Columns/index.d.ts +1 -1
- package/dist/components/Columns/index.d.ts.map +1 -1
- package/dist/components/Comment/index.d.ts +1 -1
- package/dist/components/Comment/index.d.ts.map +1 -1
- package/dist/components/CommentFeed/index.d.ts +1 -1
- package/dist/components/CommentFeed/index.d.ts.map +1 -1
- package/dist/components/ControlGroup/index.d.ts +1 -1
- package/dist/components/ControlGroup/index.d.ts.map +1 -1
- package/dist/components/Dropdown/index.d.ts +1 -1
- package/dist/components/Dropdown/index.d.ts.map +1 -1
- package/dist/components/Dropdown/item.d.ts +2 -2
- package/dist/components/Dropdown/item.d.ts.map +1 -1
- package/dist/components/Dropdown/list.d.ts +1 -1
- package/dist/components/Dropdown/list.d.ts.map +1 -1
- package/dist/components/Effect/index.d.ts +2 -2
- package/dist/components/Effect/index.d.ts.map +1 -1
- package/dist/components/ExportModal/index.d.ts +11 -0
- package/dist/components/ExportModal/index.d.ts.map +1 -0
- package/dist/components/ExportModal/index.js +91 -0
- package/dist/components/ExportModal/index.js.map +1 -0
- package/dist/components/Header/index.d.ts +7 -7
- package/dist/components/Header/index.d.ts.map +1 -1
- package/dist/components/InputClearButton/index.d.ts +1 -0
- package/dist/components/InputClearButton/index.d.ts.map +1 -1
- package/dist/components/InternalPopover/index.js +2 -2
- package/dist/components/InternalPopover/index.js.map +1 -1
- package/dist/components/KeyValueTable/index.d.ts +7 -4
- package/dist/components/KeyValueTable/index.d.ts.map +1 -1
- package/dist/components/KeyValueTable/index.js +32 -2
- package/dist/components/KeyValueTable/index.js.map +1 -1
- package/dist/components/Layout/content.d.ts +1 -1
- package/dist/components/Layout/content.d.ts.map +1 -1
- package/dist/components/Layout/index.d.ts +1 -1
- package/dist/components/Layout/index.d.ts.map +1 -1
- package/dist/components/Menu/item.d.ts +1 -1
- package/dist/components/Menu/item.d.ts.map +1 -1
- package/dist/components/Menu/item.js +3 -3
- package/dist/components/Menu/item.js.map +1 -1
- package/dist/components/Message/index.d.ts +1 -0
- package/dist/components/Message/index.d.ts.map +1 -1
- package/dist/components/Message/index.js.map +1 -1
- package/dist/components/Modal/index.d.ts +1 -1
- package/dist/components/Modal/index.d.ts.map +1 -1
- package/dist/components/MultiSelect/index.d.ts +2 -2
- package/dist/components/MultiSelect/index.d.ts.map +1 -1
- package/dist/components/Notifications/notification.d.ts +1 -0
- package/dist/components/Notifications/notification.d.ts.map +1 -1
- package/dist/components/Notifications/notification.js +23 -16
- package/dist/components/Notifications/notification.js.map +1 -1
- package/dist/components/Paging/index.d.ts +1 -1
- package/dist/components/Paging/index.d.ts.map +1 -1
- package/dist/components/Panel/NonResponsiveActions.d.ts +1 -1
- package/dist/components/Panel/NonResponsiveActions.d.ts.map +1 -1
- package/dist/components/Panel/index.js +1 -1
- package/dist/components/Panel/index.js.map +1 -1
- package/dist/components/Panel/panel.screenshot.d.ts +1 -1
- package/dist/components/Panel/panel.screenshot.d.ts.map +1 -1
- package/dist/components/Paragraph/index.d.ts +1 -1
- package/dist/components/Paragraph/index.d.ts.map +1 -1
- package/dist/components/Popover/index.d.ts +1 -1
- package/dist/components/Popover/index.d.ts.map +1 -1
- package/dist/components/Popover/index.js +2 -0
- package/dist/components/Popover/index.js.map +1 -1
- package/dist/components/RadioGroup/index.d.ts +1 -1
- package/dist/components/RadioGroup/index.d.ts.map +1 -1
- package/dist/components/Sidebar/item.d.ts +1 -1
- package/dist/components/Sidebar/item.d.ts.map +1 -1
- package/dist/components/Spacer/index.d.ts +3 -3
- package/dist/components/Spacer/index.d.ts.map +1 -1
- package/dist/components/Spinner/index.d.ts +1 -1
- package/dist/components/Spinner/index.d.ts.map +1 -1
- package/dist/components/Table/body.d.ts +1 -1
- package/dist/components/Table/body.d.ts.map +1 -1
- package/dist/components/Table/body.js +26 -21
- package/dist/components/Table/body.js.map +1 -1
- package/dist/components/Table/cell.d.ts +3 -2
- package/dist/components/Table/cell.d.ts.map +1 -1
- package/dist/components/Table/cell.js +8 -4
- package/dist/components/Table/cell.js.map +1 -1
- package/dist/components/Table/headerCell.d.ts +1 -1
- package/dist/components/Table/headerCell.d.ts.map +1 -1
- package/dist/components/Table/helpers.d.ts +8 -6
- package/dist/components/Table/helpers.d.ts.map +1 -1
- package/dist/components/Table/helpers.js +49 -16
- package/dist/components/Table/helpers.js.map +1 -1
- package/dist/components/Table/index.d.ts +5 -4
- package/dist/components/Table/index.d.ts.map +1 -1
- package/dist/components/Table/index.js +47 -38
- package/dist/components/Table/index.js.map +1 -1
- package/dist/components/Table/row.d.ts +7 -5
- package/dist/components/Table/row.d.ts.map +1 -1
- package/dist/components/Table/row.js +38 -36
- package/dist/components/Table/row.js.map +1 -1
- package/dist/components/Table/value.d.ts +1 -1
- package/dist/components/Table/value.d.ts.map +1 -1
- package/dist/components/Tabs/content.d.ts +1 -1
- package/dist/components/Tabs/content.d.ts.map +1 -1
- package/dist/components/Tabs/index.d.ts +1 -1
- package/dist/components/Tabs/index.d.ts.map +1 -1
- package/dist/components/Tabs/list.d.ts +1 -1
- package/dist/components/Tabs/list.d.ts.map +1 -1
- package/dist/components/Tabs/list.js +1 -1
- package/dist/components/Tabs/list.js.map +1 -1
- package/dist/components/Tag/group.d.ts +1 -1
- package/dist/components/Tag/group.d.ts.map +1 -1
- package/dist/components/Tree/index.d.ts +2 -1
- package/dist/components/Tree/index.d.ts.map +1 -1
- package/dist/components/Tree/index.js +35 -31
- package/dist/components/Tree/index.js.map +1 -1
- package/dist/constants/sizes.js +5 -5
- package/dist/containers/Paging.d.ts +1 -1
- package/dist/containers/Paging.d.ts.map +1 -1
- package/dist/containers/ThemeProvider.d.ts +1 -1
- package/dist/containers/ThemeProvider.d.ts.map +1 -1
- package/dist/helpers/utils.d.ts +2 -1
- package/dist/helpers/utils.d.ts.map +1 -1
- package/dist/helpers/utils.js +20 -2
- package/dist/helpers/utils.js.map +1 -1
- package/dist/hooks/useAutoFocus.d.ts +1 -1
- package/dist/hooks/useAutoFocus.d.ts.map +1 -1
- package/dist/hooks/usePopover.d.ts +1 -0
- package/dist/hooks/usePopover.d.ts.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js.map +1 -1
- package/dist/styles.d.ts +3 -0
- package/dist/styles.d.ts.map +1 -1
- package/dist/styles.js +49 -11
- package/dist/styles.js.map +1 -1
- package/migration-storybook.log +88 -0
- package/package.json +26 -20
- package/src/components/Breadcrumbs/index.tsx +1 -1
- package/src/components/Button/index.tsx +3 -54
- package/src/components/Collection/index.tsx +18 -15
- package/src/components/Collection/item.tsx +2 -1
- package/src/components/ExportModal/index.tsx +98 -0
- package/src/components/InternalPopover/index.tsx +2 -2
- package/src/components/KeyValueTable/index.tsx +59 -11
- package/src/components/Menu/item.tsx +4 -4
- package/src/components/Message/index.tsx +1 -0
- package/src/components/Notifications/notification.tsx +14 -3
- package/src/components/Panel/index.tsx +2 -2
- package/src/components/Popover/index.tsx +3 -0
- package/src/components/Table/body.tsx +26 -20
- package/src/components/Table/cell.tsx +15 -4
- package/src/components/Table/helpers.ts +52 -21
- package/src/components/Table/index.tsx +119 -75
- package/src/components/Table/row.tsx +47 -46
- package/src/components/Tabs/list.tsx +1 -1
- package/src/components/Tree/index.tsx +82 -75
- package/src/constants/sizes.ts +5 -5
- package/src/helpers/utils.ts +10 -2
- package/src/hooks/useAutoFocus.ts +1 -1
- package/src/index.tsx +1 -1
- package/src/mock/tableData.ts +12 -0
- package/src/stories/Breadcrumbs/Breadcrumbs.stories.tsx +11 -23
- package/src/stories/Button/Button.stories.tsx +83 -47
- package/src/stories/Checkbox/Checkbox.stories.tsx +19 -9
- package/src/stories/Collection/Collection.stories.tsx +195 -171
- package/src/stories/Columns/Columns.stories.tsx +38 -24
- package/src/stories/Comment/Comment.stories.tsx +15 -6
- package/src/stories/ControlGroup/ControlGroup.stories.tsx +102 -48
- package/src/stories/Drawer/Drawer.stories.tsx +52 -17
- package/src/stories/Dropdown/Dropdown.stories.tsx +184 -152
- package/src/stories/ExportModal/ExportModal.stories.tsx +18 -0
- package/src/stories/Header/Header.stories.tsx +65 -31
- package/src/stories/Icon/Icon.stories.tsx +139 -133
- package/src/stories/Input/Input.stories.tsx +68 -31
- package/src/stories/KeyValueTable/KeyValueTable.stories.tsx +183 -117
- package/src/stories/Menu/Menu.stories.tsx +56 -20
- package/src/stories/Message/Message.stories.tsx +96 -37
- package/src/stories/Modal/Modal.stories.tsx +28 -8
- package/src/stories/MultiSelect/MultiSelect.stories.tsx +66 -35
- package/src/stories/Navbar/Navbar.stories.tsx +15 -5
- package/src/stories/Notifications/Interactive.stories.tsx +40 -28
- package/src/stories/Notifications/Notification.stories.tsx +55 -41
- package/src/stories/Notifications/Notifications.stories.tsx +45 -29
- package/src/stories/Paging/Paging.stories.tsx +206 -177
- package/src/stories/Panel/Panel.stories.tsx +238 -168
- package/src/stories/Paragraph/Paragraph.stories.tsx +66 -31
- package/src/stories/Popover/Popover.stories.tsx +62 -40
- package/src/stories/RadioGroup/RadioGroup.stories.tsx +41 -19
- package/src/stories/Sidebar/Sidebar.stories.tsx +29 -10
- package/src/stories/Spacer/Spacer.stories.tsx +13 -5
- package/src/stories/Spinner/Spinner.stories.tsx +26 -12
- package/src/stories/Table/Table.stories.tsx +200 -144
- package/src/stories/Table/Tests.stories.tsx +9 -0
- package/src/stories/Tabs/Tabs.stories.tsx +82 -46
- package/src/stories/Tag/Tag.stories.tsx +56 -37
- package/src/stories/Tag/TagGroup.stories.tsx +297 -0
- package/src/stories/TextArea/TextArea.stories.tsx +82 -40
- package/src/stories/Tree/Tree.stories.tsx +84 -22
- package/src/stories/utils.ts +22 -1
- package/src/styles.ts +55 -2
- package/tests.json +1 -1
|
@@ -1,16 +1,20 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { IReqoreHeadingProps } from '../../components/Header';
|
|
1
|
+
import { StoryFn, StoryObj } from '@storybook/react';
|
|
3
2
|
import { ReqoreControlGroup, ReqoreHeading } from '../../index';
|
|
3
|
+
import { StoryMeta } from '../utils';
|
|
4
4
|
import { IntentArg } from '../utils/args';
|
|
5
5
|
|
|
6
|
-
|
|
6
|
+
const meta = {
|
|
7
7
|
title: 'Other/Heading/Stories',
|
|
8
|
+
component: ReqoreHeading,
|
|
8
9
|
argTypes: {
|
|
9
10
|
...IntentArg,
|
|
10
11
|
},
|
|
11
|
-
} as
|
|
12
|
+
} as StoryMeta<typeof ReqoreHeading>;
|
|
12
13
|
|
|
13
|
-
|
|
14
|
+
export default meta;
|
|
15
|
+
type Story = StoryObj<typeof meta>;
|
|
16
|
+
|
|
17
|
+
const Template: StoryFn<typeof ReqoreHeading> = (args) => {
|
|
14
18
|
return (
|
|
15
19
|
<ReqoreControlGroup gapSize='big' vertical>
|
|
16
20
|
<ReqoreHeading size={1} {...args}>
|
|
@@ -38,37 +42,67 @@ const Template: Story<IReqoreHeadingProps> = (args) => {
|
|
|
38
42
|
);
|
|
39
43
|
};
|
|
40
44
|
|
|
41
|
-
export const Basic =
|
|
42
|
-
|
|
43
|
-
Success.args = {
|
|
44
|
-
intent: 'success',
|
|
45
|
+
export const Basic: Story = {
|
|
46
|
+
render: Template,
|
|
45
47
|
};
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
48
|
+
|
|
49
|
+
export const Success: Story = {
|
|
50
|
+
render: Template,
|
|
51
|
+
|
|
52
|
+
args: {
|
|
53
|
+
intent: 'success',
|
|
54
|
+
},
|
|
49
55
|
};
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
56
|
+
|
|
57
|
+
export const Danger: Story = {
|
|
58
|
+
render: Template,
|
|
59
|
+
|
|
60
|
+
args: {
|
|
61
|
+
intent: 'danger',
|
|
62
|
+
},
|
|
63
|
+
};
|
|
64
|
+
|
|
65
|
+
export const Warning: Story = {
|
|
66
|
+
render: Template,
|
|
67
|
+
|
|
68
|
+
args: {
|
|
69
|
+
intent: 'warning',
|
|
70
|
+
},
|
|
53
71
|
};
|
|
54
|
-
|
|
55
|
-
Info
|
|
56
|
-
|
|
72
|
+
|
|
73
|
+
export const Info: Story = {
|
|
74
|
+
render: Template,
|
|
75
|
+
|
|
76
|
+
args: {
|
|
77
|
+
intent: 'info',
|
|
78
|
+
},
|
|
57
79
|
};
|
|
58
|
-
|
|
59
|
-
Pending
|
|
60
|
-
|
|
80
|
+
|
|
81
|
+
export const Pending: Story = {
|
|
82
|
+
render: Template,
|
|
83
|
+
|
|
84
|
+
args: {
|
|
85
|
+
intent: 'pending',
|
|
86
|
+
},
|
|
61
87
|
};
|
|
62
|
-
|
|
63
|
-
Muted
|
|
64
|
-
|
|
88
|
+
|
|
89
|
+
export const Muted: Story = {
|
|
90
|
+
render: Template,
|
|
91
|
+
|
|
92
|
+
args: {
|
|
93
|
+
intent: 'muted',
|
|
94
|
+
},
|
|
65
95
|
};
|
|
66
|
-
|
|
67
|
-
Effect
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
96
|
+
|
|
97
|
+
export const Effect: Story = {
|
|
98
|
+
render: Template,
|
|
99
|
+
|
|
100
|
+
args: {
|
|
101
|
+
effect: {
|
|
102
|
+
gradient: { colors: { 0: '#5e0acc', 100: '#c008c0' } },
|
|
103
|
+
spaced: 4,
|
|
104
|
+
weight: 'bold',
|
|
105
|
+
uppercase: true,
|
|
106
|
+
},
|
|
73
107
|
},
|
|
74
108
|
};
|
|
@@ -1,143 +1,149 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { IReqoreIconProps } from '../../components/Icon';
|
|
1
|
+
import { StoryObj } from '@storybook/react';
|
|
3
2
|
import { ReqoreIcon, ReqorePanel } from '../../index';
|
|
3
|
+
import { StoryMeta } from '../utils';
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
const meta = {
|
|
6
6
|
title: 'Other/Icon/Stories',
|
|
7
|
-
|
|
7
|
+
component: ReqoreIcon,
|
|
8
|
+
} as StoryMeta<typeof ReqoreIcon>;
|
|
8
9
|
|
|
9
|
-
export
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
<
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
icon='
|
|
20
|
-
size='
|
|
21
|
-
color='#
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
/>
|
|
69
|
-
<ReqoreIcon
|
|
70
|
-
image='https://avatars.githubusercontent.com/u/44835090?s=400&u=371120ce0755102d2e432f11ad9aa0378c871b45&v=4'
|
|
71
|
-
size='40px'
|
|
72
|
-
rounded
|
|
73
|
-
margin='both'
|
|
74
|
-
/>
|
|
75
|
-
<ReqoreIcon
|
|
76
|
-
image='https://avatars.githubusercontent.com/u/44835090?s=400&u=371120ce0755102d2e432f11ad9aa0378c871b45&v=4'
|
|
77
|
-
size='30px'
|
|
78
|
-
effect={{ sepia: true }}
|
|
79
|
-
margin='both'
|
|
80
|
-
/>
|
|
81
|
-
<ReqoreIcon
|
|
82
|
-
image='https://avatars.githubusercontent.com/u/44835090?s=400&u=371120ce0755102d2e432f11ad9aa0378c871b45&v=4'
|
|
83
|
-
size='40px'
|
|
84
|
-
effect={{ grayscale: true }}
|
|
85
|
-
margin='both'
|
|
86
|
-
/>
|
|
87
|
-
<ReqoreIcon
|
|
88
|
-
image='https://avatars.githubusercontent.com/u/44835090?s=400&u=371120ce0755102d2e432f11ad9aa0378c871b45&v=4'
|
|
89
|
-
size='70px'
|
|
90
|
-
effect={{ blur: 1 }}
|
|
91
|
-
margin='both'
|
|
92
|
-
/>
|
|
93
|
-
<ReqoreIcon
|
|
94
|
-
image='https://avatars.githubusercontent.com/u/44835090?s=400&u=371120ce0755102d2e432f11ad9aa0378c871b45&v=4'
|
|
95
|
-
size='40px'
|
|
96
|
-
effect={{ contrast: 150 }}
|
|
97
|
-
margin='both'
|
|
98
|
-
/>
|
|
99
|
-
<ReqoreIcon
|
|
100
|
-
image='https://avatars.githubusercontent.com/u/44835090?s=400&u=371120ce0755102d2e432f11ad9aa0378c871b45&v=4'
|
|
101
|
-
size='40px'
|
|
102
|
-
effect={{ invert: true }}
|
|
103
|
-
margin='both'
|
|
104
|
-
/>
|
|
105
|
-
<ReqoreIcon
|
|
106
|
-
image='https://avatars.githubusercontent.com/u/44835090?s=400&u=371120ce0755102d2e432f11ad9aa0378c871b45&v=4'
|
|
107
|
-
size='40px'
|
|
108
|
-
effect={{ opacity: 0.5 }}
|
|
109
|
-
margin='both'
|
|
110
|
-
/>
|
|
111
|
-
<ReqoreIcon
|
|
112
|
-
image='https://avatars.githubusercontent.com/u/44835090?s=400&u=371120ce0755102d2e432f11ad9aa0378c871b45&v=4'
|
|
113
|
-
size='40px'
|
|
114
|
-
effect={{ saturate: 150 }}
|
|
115
|
-
margin='both'
|
|
116
|
-
/>
|
|
117
|
-
</ReqorePanel>
|
|
118
|
-
<br />
|
|
119
|
-
<ReqorePanel label='Margined' flat minimal>
|
|
120
|
-
<ReqoreIcon icon='AccountCircleLine' />
|
|
121
|
-
No Margin
|
|
122
|
-
<div>
|
|
123
|
-
<ReqoreIcon icon='4KFill' margin='right' />
|
|
124
|
-
Right Margin
|
|
125
|
-
</div>
|
|
126
|
-
<div>
|
|
127
|
-
Left Margin
|
|
10
|
+
export default meta;
|
|
11
|
+
type Story = StoryObj<typeof meta>;
|
|
12
|
+
|
|
13
|
+
export const Basic: Story = {
|
|
14
|
+
render: () => {
|
|
15
|
+
return (
|
|
16
|
+
<>
|
|
17
|
+
<ReqorePanel label='Basic' flat minimal>
|
|
18
|
+
<ReqoreIcon icon='AccountCircleLine' size='12px' margin='both' />
|
|
19
|
+
<ReqoreIcon icon='4KFill' size='14px' margin='both' />
|
|
20
|
+
<ReqoreIcon icon='ArrowLeftCircleFill' intent='success' margin='both' />
|
|
21
|
+
<ReqoreIcon icon='HotelFill' size='18px' margin='both' />
|
|
22
|
+
<ReqoreIcon icon='SignalTowerFill' size='20px' color='#ff0000' margin='both' />
|
|
23
|
+
<ReqoreIcon
|
|
24
|
+
icon='SignalTowerFill'
|
|
25
|
+
size='20px'
|
|
26
|
+
color='#291133'
|
|
27
|
+
effect={{ sepia: true }}
|
|
28
|
+
margin='both'
|
|
29
|
+
tooltip={{ content: 'I have a tooltip', openOnMount: true }}
|
|
30
|
+
/>
|
|
31
|
+
<ReqoreIcon
|
|
32
|
+
icon='SignalTowerFill'
|
|
33
|
+
size='20px'
|
|
34
|
+
color='#0c7052'
|
|
35
|
+
effect={{ blur: 1 }}
|
|
36
|
+
margin='both'
|
|
37
|
+
/>
|
|
38
|
+
<ReqoreIcon
|
|
39
|
+
icon='SignalTowerFill'
|
|
40
|
+
size='20px'
|
|
41
|
+
color='#700c57'
|
|
42
|
+
effect={{ contrast: 150 }}
|
|
43
|
+
margin='both'
|
|
44
|
+
/>
|
|
45
|
+
<ReqoreIcon
|
|
46
|
+
icon='SignalTowerFill'
|
|
47
|
+
size='20px'
|
|
48
|
+
color='#d5be0f'
|
|
49
|
+
effect={{ grayscale: true }}
|
|
50
|
+
margin='both'
|
|
51
|
+
/>
|
|
52
|
+
<ReqoreIcon
|
|
53
|
+
icon='SignalTowerFill'
|
|
54
|
+
size='20px'
|
|
55
|
+
color='#0f5bd5'
|
|
56
|
+
effect={{ invert: true }}
|
|
57
|
+
margin='both'
|
|
58
|
+
/>
|
|
59
|
+
<ReqoreIcon
|
|
60
|
+
icon='SignalTowerFill'
|
|
61
|
+
size='20px'
|
|
62
|
+
color='#ffffff'
|
|
63
|
+
effect={{ opacity: 0.5 }}
|
|
64
|
+
margin='both'
|
|
65
|
+
/>
|
|
66
|
+
</ReqorePanel>
|
|
67
|
+
<br />
|
|
68
|
+
<ReqorePanel label='Image' flat minimal>
|
|
128
69
|
<ReqoreIcon
|
|
129
70
|
image='https://avatars.githubusercontent.com/u/44835090?s=400&u=371120ce0755102d2e432f11ad9aa0378c871b45&v=4'
|
|
130
71
|
size='20px'
|
|
72
|
+
margin='both'
|
|
73
|
+
/>
|
|
74
|
+
<ReqoreIcon
|
|
75
|
+
image='https://avatars.githubusercontent.com/u/44835090?s=400&u=371120ce0755102d2e432f11ad9aa0378c871b45&v=4'
|
|
76
|
+
size='40px'
|
|
131
77
|
rounded
|
|
132
|
-
margin='
|
|
78
|
+
margin='both'
|
|
79
|
+
/>
|
|
80
|
+
<ReqoreIcon
|
|
81
|
+
image='https://avatars.githubusercontent.com/u/44835090?s=400&u=371120ce0755102d2e432f11ad9aa0378c871b45&v=4'
|
|
82
|
+
size='30px'
|
|
83
|
+
effect={{ sepia: true }}
|
|
84
|
+
margin='both'
|
|
85
|
+
/>
|
|
86
|
+
<ReqoreIcon
|
|
87
|
+
image='https://avatars.githubusercontent.com/u/44835090?s=400&u=371120ce0755102d2e432f11ad9aa0378c871b45&v=4'
|
|
88
|
+
size='40px'
|
|
89
|
+
effect={{ grayscale: true }}
|
|
90
|
+
margin='both'
|
|
91
|
+
/>
|
|
92
|
+
<ReqoreIcon
|
|
93
|
+
image='https://avatars.githubusercontent.com/u/44835090?s=400&u=371120ce0755102d2e432f11ad9aa0378c871b45&v=4'
|
|
94
|
+
size='70px'
|
|
95
|
+
effect={{ blur: 1 }}
|
|
96
|
+
margin='both'
|
|
97
|
+
/>
|
|
98
|
+
<ReqoreIcon
|
|
99
|
+
image='https://avatars.githubusercontent.com/u/44835090?s=400&u=371120ce0755102d2e432f11ad9aa0378c871b45&v=4'
|
|
100
|
+
size='40px'
|
|
101
|
+
effect={{ contrast: 150 }}
|
|
102
|
+
margin='both'
|
|
103
|
+
/>
|
|
104
|
+
<ReqoreIcon
|
|
105
|
+
image='https://avatars.githubusercontent.com/u/44835090?s=400&u=371120ce0755102d2e432f11ad9aa0378c871b45&v=4'
|
|
106
|
+
size='40px'
|
|
107
|
+
effect={{ invert: true }}
|
|
108
|
+
margin='both'
|
|
109
|
+
/>
|
|
110
|
+
<ReqoreIcon
|
|
111
|
+
image='https://avatars.githubusercontent.com/u/44835090?s=400&u=371120ce0755102d2e432f11ad9aa0378c871b45&v=4'
|
|
112
|
+
size='40px'
|
|
113
|
+
effect={{ opacity: 0.5 }}
|
|
114
|
+
margin='both'
|
|
115
|
+
/>
|
|
116
|
+
<ReqoreIcon
|
|
117
|
+
image='https://avatars.githubusercontent.com/u/44835090?s=400&u=371120ce0755102d2e432f11ad9aa0378c871b45&v=4'
|
|
118
|
+
size='40px'
|
|
119
|
+
effect={{ saturate: 150 }}
|
|
120
|
+
margin='both'
|
|
133
121
|
/>
|
|
134
|
-
</
|
|
135
|
-
<
|
|
136
|
-
|
|
137
|
-
<ReqoreIcon icon='
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
122
|
+
</ReqorePanel>
|
|
123
|
+
<br />
|
|
124
|
+
<ReqorePanel label='Margined' flat minimal>
|
|
125
|
+
<ReqoreIcon icon='AccountCircleLine' />
|
|
126
|
+
No Margin
|
|
127
|
+
<div>
|
|
128
|
+
<ReqoreIcon icon='4KFill' margin='right' />
|
|
129
|
+
Right Margin
|
|
130
|
+
</div>
|
|
131
|
+
<div>
|
|
132
|
+
Left Margin
|
|
133
|
+
<ReqoreIcon
|
|
134
|
+
image='https://avatars.githubusercontent.com/u/44835090?s=400&u=371120ce0755102d2e432f11ad9aa0378c871b45&v=4'
|
|
135
|
+
size='20px'
|
|
136
|
+
rounded
|
|
137
|
+
margin='left'
|
|
138
|
+
/>
|
|
139
|
+
</div>
|
|
140
|
+
<div>
|
|
141
|
+
Both
|
|
142
|
+
<ReqoreIcon icon='HotelFill' margin='both' />
|
|
143
|
+
Sides
|
|
144
|
+
</div>
|
|
145
|
+
</ReqorePanel>
|
|
146
|
+
</>
|
|
147
|
+
);
|
|
148
|
+
},
|
|
143
149
|
};
|
|
@@ -1,20 +1,28 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { StoryFn, StoryObj } from '@storybook/react';
|
|
2
2
|
import { useState } from 'react';
|
|
3
3
|
import ReqoreInput, { IReqoreInputProps } from '../../components/Input';
|
|
4
4
|
import { ReqoreControlGroup } from '../../index';
|
|
5
|
+
import { StoryMeta } from '../utils';
|
|
5
6
|
import { FlatArg, IconArg, MinimalArg, SizeArg } from '../utils/args';
|
|
6
7
|
|
|
7
|
-
|
|
8
|
+
const meta = {
|
|
8
9
|
title: 'Form/Input/Stories',
|
|
10
|
+
component: ReqoreInput,
|
|
9
11
|
argTypes: {
|
|
10
12
|
...MinimalArg,
|
|
11
13
|
...FlatArg,
|
|
12
14
|
...SizeArg,
|
|
13
|
-
...IconArg('icon', 'Icon'
|
|
15
|
+
...IconArg('icon', 'Icon'),
|
|
14
16
|
},
|
|
15
|
-
|
|
17
|
+
args: {
|
|
18
|
+
icon: 'SearchLine',
|
|
19
|
+
},
|
|
20
|
+
} as StoryMeta<typeof ReqoreInput>;
|
|
21
|
+
|
|
22
|
+
export default meta;
|
|
23
|
+
type Story = StoryObj<typeof meta>;
|
|
16
24
|
|
|
17
|
-
const Template:
|
|
25
|
+
const Template: StoryFn<typeof ReqoreInput> = (args: IReqoreInputProps) => {
|
|
18
26
|
const [value, setValue] = useState('Input value');
|
|
19
27
|
|
|
20
28
|
const handleValueChange = (e: React.ChangeEvent<HTMLInputElement>) => {
|
|
@@ -133,39 +141,68 @@ const Template: Story<IReqoreInputProps> = (args: IReqoreInputProps) => {
|
|
|
133
141
|
);
|
|
134
142
|
};
|
|
135
143
|
|
|
136
|
-
export const Basic =
|
|
137
|
-
|
|
138
|
-
Info.args = {
|
|
139
|
-
intent: 'info',
|
|
144
|
+
export const Basic: Story = {
|
|
145
|
+
render: Template,
|
|
140
146
|
};
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
147
|
+
|
|
148
|
+
export const Info: Story = {
|
|
149
|
+
render: Template,
|
|
150
|
+
|
|
151
|
+
args: {
|
|
152
|
+
intent: 'info',
|
|
153
|
+
},
|
|
144
154
|
};
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
155
|
+
|
|
156
|
+
export const Success: Story = {
|
|
157
|
+
render: Template,
|
|
158
|
+
|
|
159
|
+
args: {
|
|
160
|
+
intent: 'success',
|
|
161
|
+
},
|
|
162
|
+
};
|
|
163
|
+
|
|
164
|
+
export const Warning: Story = {
|
|
165
|
+
render: Template,
|
|
166
|
+
|
|
167
|
+
args: {
|
|
168
|
+
intent: 'warning',
|
|
169
|
+
},
|
|
148
170
|
};
|
|
149
|
-
|
|
150
|
-
Danger
|
|
151
|
-
|
|
171
|
+
|
|
172
|
+
export const Danger: Story = {
|
|
173
|
+
render: Template,
|
|
174
|
+
|
|
175
|
+
args: {
|
|
176
|
+
intent: 'danger',
|
|
177
|
+
},
|
|
152
178
|
};
|
|
153
|
-
|
|
154
|
-
Pending
|
|
155
|
-
|
|
179
|
+
|
|
180
|
+
export const Pending: Story = {
|
|
181
|
+
render: Template,
|
|
182
|
+
|
|
183
|
+
args: {
|
|
184
|
+
intent: 'pending',
|
|
185
|
+
},
|
|
156
186
|
};
|
|
157
|
-
|
|
158
|
-
Muted
|
|
159
|
-
|
|
187
|
+
|
|
188
|
+
export const Muted: Story = {
|
|
189
|
+
render: Template,
|
|
190
|
+
|
|
191
|
+
args: {
|
|
192
|
+
intent: 'muted',
|
|
193
|
+
},
|
|
160
194
|
};
|
|
161
195
|
|
|
162
|
-
export const Effect =
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
196
|
+
export const Effect: Story = {
|
|
197
|
+
render: Template,
|
|
198
|
+
|
|
199
|
+
args: {
|
|
200
|
+
effect: {
|
|
201
|
+
gradient: {
|
|
202
|
+
colors: {
|
|
203
|
+
0: '#56345e',
|
|
204
|
+
100: 'transparent',
|
|
205
|
+
},
|
|
169
206
|
},
|
|
170
207
|
},
|
|
171
208
|
},
|