@qoretechnologies/reqore 0.30.6 → 0.30.7

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 (232) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +2 -44
  3. package/__tests__/collection.test.tsx +1 -1
  4. package/__tests__/{control_group.text.tsx → control_group.test.tsx} +4 -2
  5. package/__tests__/modal.test.tsx +74 -2
  6. package/__tests__/panel.test.tsx +96 -24
  7. package/__tests__/popover.test.tsx +24 -2
  8. package/__tests__/tabs.test.tsx +75 -0
  9. package/dist/components/Button/index.d.ts +7 -2
  10. package/dist/components/Button/index.d.ts.map +1 -1
  11. package/dist/components/Button/index.js +30 -20
  12. package/dist/components/Button/index.js.map +1 -1
  13. package/dist/components/Checkbox/index.d.ts.map +1 -1
  14. package/dist/components/Checkbox/index.js +6 -3
  15. package/dist/components/Checkbox/index.js.map +1 -1
  16. package/dist/components/Collection/index.d.ts +7 -2
  17. package/dist/components/Collection/index.d.ts.map +1 -1
  18. package/dist/components/Collection/index.js +57 -53
  19. package/dist/components/Collection/index.js.map +1 -1
  20. package/dist/components/Collection/item.d.ts +5 -5
  21. package/dist/components/Collection/item.d.ts.map +1 -1
  22. package/dist/components/Collection/item.js +15 -4
  23. package/dist/components/Collection/item.js.map +1 -1
  24. package/dist/components/Columns/column.d.ts.map +1 -1
  25. package/dist/components/Columns/column.js +1 -1
  26. package/dist/components/Columns/column.js.map +1 -1
  27. package/dist/components/ControlGroup/index.d.ts +21 -4
  28. package/dist/components/ControlGroup/index.d.ts.map +1 -1
  29. package/dist/components/ControlGroup/index.js +250 -55
  30. package/dist/components/ControlGroup/index.js.map +1 -1
  31. package/dist/components/Drawer/index.d.ts +3 -3
  32. package/dist/components/Drawer/index.d.ts.map +1 -1
  33. package/dist/components/Drawer/index.js +27 -16
  34. package/dist/components/Drawer/index.js.map +1 -1
  35. package/dist/components/Dropdown/index.d.ts +1 -0
  36. package/dist/components/Dropdown/index.d.ts.map +1 -1
  37. package/dist/components/Dropdown/index.js +2 -2
  38. package/dist/components/Dropdown/index.js.map +1 -1
  39. package/dist/components/Dropdown/list.d.ts +3 -3
  40. package/dist/components/Dropdown/list.d.ts.map +1 -1
  41. package/dist/components/Effect/index.d.ts +10 -10
  42. package/dist/components/Effect/index.d.ts.map +1 -1
  43. package/dist/components/Effect/index.js +7 -6
  44. package/dist/components/Effect/index.js.map +1 -1
  45. package/dist/components/Icon/index.d.ts +5 -6
  46. package/dist/components/Icon/index.d.ts.map +1 -1
  47. package/dist/components/Icon/index.js +14 -7
  48. package/dist/components/Icon/index.js.map +1 -1
  49. package/dist/components/Input/index.d.ts +2 -0
  50. package/dist/components/Input/index.d.ts.map +1 -1
  51. package/dist/components/Input/index.js +10 -4
  52. package/dist/components/Input/index.js.map +1 -1
  53. package/dist/components/InternalPopover/index.d.ts.map +1 -1
  54. package/dist/components/InternalPopover/index.js +12 -10
  55. package/dist/components/InternalPopover/index.js.map +1 -1
  56. package/dist/components/Menu/index.d.ts.map +1 -1
  57. package/dist/components/Menu/index.js +1 -1
  58. package/dist/components/Menu/index.js.map +1 -1
  59. package/dist/components/Message/index.d.ts +2 -0
  60. package/dist/components/Message/index.d.ts.map +1 -1
  61. package/dist/components/Message/index.js +2 -2
  62. package/dist/components/Message/index.js.map +1 -1
  63. package/dist/components/MultiSelect/index.d.ts +2 -2
  64. package/dist/components/MultiSelect/index.d.ts.map +1 -1
  65. package/dist/components/MultiSelect/index.js +10 -10
  66. package/dist/components/MultiSelect/index.js.map +1 -1
  67. package/dist/components/Notifications/index.d.ts +1 -1
  68. package/dist/components/Notifications/index.d.ts.map +1 -1
  69. package/dist/components/Notifications/notification.d.ts +1 -1
  70. package/dist/components/Notifications/notification.d.ts.map +1 -1
  71. package/dist/components/Panel/index.d.ts +13 -6
  72. package/dist/components/Panel/index.d.ts.map +1 -1
  73. package/dist/components/Panel/index.js +78 -44
  74. package/dist/components/Panel/index.js.map +1 -1
  75. package/dist/components/Popover/index.d.ts +1 -2
  76. package/dist/components/Popover/index.d.ts.map +1 -1
  77. package/dist/components/Popover/index.js +2 -2
  78. package/dist/components/Popover/index.js.map +1 -1
  79. package/dist/components/Spacer/index.d.ts +2 -0
  80. package/dist/components/Spacer/index.d.ts.map +1 -1
  81. package/dist/components/Spacer/index.js +29 -7
  82. package/dist/components/Spacer/index.js.map +1 -1
  83. package/dist/components/Table/header.js +2 -2
  84. package/dist/components/Table/header.js.map +1 -1
  85. package/dist/components/Table/headerCell.js +2 -2
  86. package/dist/components/Table/headerCell.js.map +1 -1
  87. package/dist/components/Table/helpers.d.ts +3 -2
  88. package/dist/components/Table/helpers.d.ts.map +1 -1
  89. package/dist/components/Table/helpers.js +6 -3
  90. package/dist/components/Table/helpers.js.map +1 -1
  91. package/dist/components/Table/index.d.ts +4 -3
  92. package/dist/components/Table/index.d.ts.map +1 -1
  93. package/dist/components/Table/index.js.map +1 -1
  94. package/dist/components/Table/row.d.ts +0 -5
  95. package/dist/components/Table/row.d.ts.map +1 -1
  96. package/dist/components/Table/row.js +3 -7
  97. package/dist/components/Table/row.js.map +1 -1
  98. package/dist/components/Tabs/content.d.ts +3 -1
  99. package/dist/components/Tabs/content.d.ts.map +1 -1
  100. package/dist/components/Tabs/content.js +8 -3
  101. package/dist/components/Tabs/content.js.map +1 -1
  102. package/dist/components/Tabs/index.d.ts +4 -1
  103. package/dist/components/Tabs/index.d.ts.map +1 -1
  104. package/dist/components/Tabs/index.js +12 -4
  105. package/dist/components/Tabs/index.js.map +1 -1
  106. package/dist/components/Tabs/item.d.ts +1 -0
  107. package/dist/components/Tabs/item.d.ts.map +1 -1
  108. package/dist/components/Tabs/item.js +7 -7
  109. package/dist/components/Tabs/item.js.map +1 -1
  110. package/dist/components/Tabs/list.d.ts +1 -1
  111. package/dist/components/Tabs/list.d.ts.map +1 -1
  112. package/dist/components/Tabs/list.js +7 -6
  113. package/dist/components/Tabs/list.js.map +1 -1
  114. package/dist/components/Tag/group.d.ts +2 -2
  115. package/dist/components/Tag/group.d.ts.map +1 -1
  116. package/dist/components/Tag/group.js +7 -8
  117. package/dist/components/Tag/group.js.map +1 -1
  118. package/dist/components/Tag/index.d.ts +6 -2
  119. package/dist/components/Tag/index.d.ts.map +1 -1
  120. package/dist/components/Tag/index.js +24 -12
  121. package/dist/components/Tag/index.js.map +1 -1
  122. package/dist/components/Tree/index.js +1 -1
  123. package/dist/components/Tree/index.js.map +1 -1
  124. package/dist/constants/animations.js +1 -1
  125. package/dist/constants/sizes.d.ts +2 -2
  126. package/dist/constants/sizes.d.ts.map +1 -1
  127. package/dist/constants/sizes.js +10 -10
  128. package/dist/constants/sizes.js.map +1 -1
  129. package/dist/constants/theme.d.ts +1 -1
  130. package/dist/constants/theme.d.ts.map +1 -1
  131. package/dist/containers/PopoverProvider.d.ts.map +1 -1
  132. package/dist/containers/PopoverProvider.js +10 -8
  133. package/dist/containers/PopoverProvider.js.map +1 -1
  134. package/dist/containers/ReqoreProvider.d.ts.map +1 -1
  135. package/dist/containers/ReqoreProvider.js +4 -2
  136. package/dist/containers/ReqoreProvider.js.map +1 -1
  137. package/dist/containers/UIProvider.d.ts +7 -0
  138. package/dist/containers/UIProvider.d.ts.map +1 -1
  139. package/dist/containers/UIProvider.js.map +1 -1
  140. package/dist/context/ReqoreContext.d.ts +2 -0
  141. package/dist/context/ReqoreContext.d.ts.map +1 -1
  142. package/dist/context/ReqoreContext.js.map +1 -1
  143. package/dist/helpers/colors.d.ts +1 -1
  144. package/dist/helpers/colors.d.ts.map +1 -1
  145. package/dist/helpers/colors.js +6 -2
  146. package/dist/helpers/colors.js.map +1 -1
  147. package/dist/helpers/utils.d.ts +3 -0
  148. package/dist/helpers/utils.d.ts.map +1 -1
  149. package/dist/helpers/utils.js +17 -2
  150. package/dist/helpers/utils.js.map +1 -1
  151. package/dist/hooks/useLatestZIndex.js +2 -2
  152. package/dist/hooks/useLatestZIndex.js.map +1 -1
  153. package/dist/hooks/usePopover.d.ts +1 -0
  154. package/dist/hooks/usePopover.d.ts.map +1 -1
  155. package/dist/hooks/usePopover.js +8 -6
  156. package/dist/hooks/usePopover.js.map +1 -1
  157. package/dist/styles.d.ts +1 -0
  158. package/dist/styles.d.ts.map +1 -1
  159. package/dist/styles.js +6 -5
  160. package/dist/styles.js.map +1 -1
  161. package/dist/types/global.d.ts +27 -1
  162. package/dist/types/global.d.ts.map +1 -1
  163. package/dist/types/icons.d.ts +1 -1
  164. package/dist/types/icons.d.ts.map +1 -1
  165. package/package.json +1 -1
  166. package/src/components/Button/index.tsx +79 -34
  167. package/src/components/Checkbox/index.tsx +3 -2
  168. package/src/components/Collection/index.tsx +93 -60
  169. package/src/components/Collection/item.tsx +29 -9
  170. package/src/components/Columns/column.tsx +1 -0
  171. package/src/components/ControlGroup/index.tsx +449 -104
  172. package/src/components/Drawer/index.tsx +28 -27
  173. package/src/components/Dropdown/index.tsx +3 -1
  174. package/src/components/Effect/index.tsx +22 -14
  175. package/src/components/Icon/index.tsx +81 -62
  176. package/src/components/Input/index.tsx +8 -3
  177. package/src/components/InternalPopover/index.tsx +131 -126
  178. package/src/components/Menu/index.tsx +7 -1
  179. package/src/components/Message/index.tsx +9 -1
  180. package/src/components/MultiSelect/index.tsx +180 -188
  181. package/src/components/Panel/index.tsx +227 -100
  182. package/src/components/Popover/index.tsx +1 -3
  183. package/src/components/Spacer/index.tsx +63 -14
  184. package/src/components/Table/header.tsx +2 -2
  185. package/src/components/Table/headerCell.tsx +2 -2
  186. package/src/components/Table/helpers.ts +12 -6
  187. package/src/components/Table/index.tsx +1 -0
  188. package/src/components/Table/row.tsx +2 -7
  189. package/src/components/Tabs/content.tsx +11 -3
  190. package/src/components/Tabs/index.tsx +14 -3
  191. package/src/components/Tabs/item.tsx +28 -5
  192. package/src/components/Tabs/list.tsx +7 -3
  193. package/src/components/Tag/group.tsx +6 -12
  194. package/src/components/Tag/index.tsx +69 -35
  195. package/src/components/Tree/index.tsx +1 -1
  196. package/src/constants/animations.ts +1 -1
  197. package/src/constants/sizes.ts +10 -10
  198. package/src/containers/PopoverProvider.tsx +11 -8
  199. package/src/containers/ReqoreProvider.tsx +40 -35
  200. package/src/containers/UIProvider.tsx +7 -0
  201. package/src/context/ReqoreContext.tsx +2 -0
  202. package/src/helpers/colors.ts +8 -2
  203. package/src/helpers/utils.ts +18 -0
  204. package/src/hooks/useLatestZIndex.ts +2 -2
  205. package/src/hooks/usePopover.tsx +9 -6
  206. package/src/mock/collectionData.tsx +33 -2
  207. package/src/stories/Button/Button.stories.tsx +72 -7
  208. package/src/stories/Checkbox/Checkbox.stories.tsx +6 -3
  209. package/src/stories/Collection/Collection.stories.tsx +18 -2
  210. package/src/stories/ControlGroup/ControlGroup.stories.tsx +282 -33
  211. package/src/stories/Drawer/Drawer.stories.tsx +70 -3
  212. package/src/stories/Dropdown/Dropdown.stories.tsx +13 -3
  213. package/src/stories/Icon/Icon.stories.tsx +1 -0
  214. package/src/stories/Input/Input.stories.tsx +5 -3
  215. package/src/stories/Menu/Menu.stories.tsx +2 -0
  216. package/src/stories/Message/Message.stories.tsx +7 -0
  217. package/src/stories/Panel/Panel.stories.tsx +147 -13
  218. package/src/stories/Popover/Popover.stories.tsx +88 -82
  219. package/src/stories/Tabs/Tabs.stories.tsx +33 -15
  220. package/src/stories/Tag/Tag.stories.tsx +23 -3
  221. package/src/stories/TextArea/TextArea.stories.tsx +3 -3
  222. package/src/styles.ts +6 -0
  223. package/src/types/global.ts +28 -0
  224. package/tests.json +1 -1
  225. package/CODE_OF_CONDUCT.md +0 -105
  226. package/CONTRIBUTING.MD +0 -78
  227. package/SECURITY.md +0 -5
  228. package/public/logo-dark.png +0 -0
  229. package/public/logo.png +0 -0
  230. package/public/q-symbol.png +0 -0
  231. package/public/qoreLogo-dark.png +0 -0
  232. package/public/qoreLogo.png +0 -0
@@ -159,11 +159,21 @@ const Template: Story<IReqoreDropdownProps> = (args: IReqoreDropdownProps) => {
159
159
 
160
160
  return (
161
161
  <>
162
- <ReqoreControlGroup>
162
+ <ReqoreControlGroup wrap>
163
163
  <ReqoreDropdown label='Default Dropdown' {...args} />
164
164
  <ReqoreDropdown label='Disabled if empty' {...args} items={[]} />
165
- <ReqoreDropdown icon='SunCloudyLine' label='Custom icon' {...args} />
166
- <ReqoreDropdown rightIcon='SunCloudyLine' caretPosition='right' {...args}>
165
+ <ReqoreDropdown
166
+ icon='SunCloudyLine'
167
+ label='Custom icon'
168
+ {...args}
169
+ leftIconColor='warning:lighten:2'
170
+ />
171
+ <ReqoreDropdown
172
+ rightIcon='SunCloudyLine'
173
+ caretPosition='right'
174
+ {...args}
175
+ iconColor='success:lighten:2'
176
+ >
167
177
  Custom icon with caret on right
168
178
  </ReqoreDropdown>
169
179
  <ReqoreDropdown
@@ -21,6 +21,7 @@ export const Icon: Story<IReqoreIconProps> = () => {
21
21
  color='#291133'
22
22
  effect={{ sepia: true }}
23
23
  margin='both'
24
+ tooltip={{ content: 'I have a tooltip', openOnMount: true }}
24
25
  />
25
26
  <ReqoreIcon
26
27
  icon='SignalTowerFill'
@@ -2,13 +2,14 @@ import { Meta, Story } from '@storybook/react/types-6-0';
2
2
  import { useState } from 'react';
3
3
  import ReqoreInput, { IReqoreInputProps } from '../../components/Input';
4
4
  import { ReqoreControlGroup } from '../../index';
5
- import { FlatArg, IconArg, MinimalArg } from '../utils/args';
5
+ import { FlatArg, IconArg, MinimalArg, SizeArg } from '../utils/args';
6
6
 
7
7
  export default {
8
8
  title: 'Components/Input',
9
9
  argTypes: {
10
10
  ...MinimalArg,
11
11
  ...FlatArg,
12
+ ...SizeArg,
12
13
  ...IconArg('icon', 'Icon', 'SearchLine'),
13
14
  },
14
15
  } as Meta<IReqoreInputProps>;
@@ -26,7 +27,7 @@ const Template: Story<IReqoreInputProps> = (args: IReqoreInputProps) => {
26
27
 
27
28
  return (
28
29
  <>
29
- <ReqoreControlGroup>
30
+ <ReqoreControlGroup wrap>
30
31
  <ReqoreInput {...args} placeholder='Reqore Input' onChange={handleValueChange} />
31
32
  <ReqoreInput {...args} placeholder='Minimal Input' minimal onChange={handleValueChange} />
32
33
  <ReqoreInput
@@ -38,6 +39,7 @@ const Template: Story<IReqoreInputProps> = (args: IReqoreInputProps) => {
38
39
  />
39
40
  <ReqoreInput
40
41
  {...args}
42
+ iconColor='pending:lighten:2'
41
43
  placeholder='Clearable Input'
42
44
  onClearClick={handleValueClear}
43
45
  onChange={handleValueChange}
@@ -51,7 +53,7 @@ const Template: Story<IReqoreInputProps> = (args: IReqoreInputProps) => {
51
53
  />
52
54
  </ReqoreControlGroup>
53
55
  <br />
54
- <ReqoreControlGroup>
56
+ <ReqoreControlGroup wrap>
55
57
  <ReqoreInput
56
58
  {...args}
57
59
  placeholder='Reqore Input'
@@ -118,6 +118,7 @@ const Template: Story<IReqoreMenuProps> = (args) => {
118
118
  {
119
119
  icon: 'EmotionUnhappyLine',
120
120
  rightIcon: 'Scissors2Fill',
121
+ leftIconColor: 'danger:lighten',
121
122
  wrap: args.wrapText,
122
123
  flat: args.flat,
123
124
  } as IReqoreMenuItemProps
@@ -148,6 +149,7 @@ const Template: Story<IReqoreMenuProps> = (args) => {
148
149
  </ReqoreMenu>
149
150
  }
150
151
  isReqoreComponent
152
+ noWrapper
151
153
  handler='click'
152
154
  placement='right'
153
155
  >
@@ -52,6 +52,13 @@ Minimal.args = {
52
52
  intent: 'danger',
53
53
  };
54
54
 
55
+ export const WithIconColor: Story<IReqoreMessageProps> = Template.bind({});
56
+ WithIconColor.args = {
57
+ minimal: true,
58
+ intent: 'success',
59
+ iconColor: '#00fd9f',
60
+ };
61
+
55
62
  export const Opaque: Story<IReqoreMessageProps> = Template.bind({});
56
63
  Opaque.args = {
57
64
  opaque: true,
@@ -1,8 +1,9 @@
1
1
  import { Meta, Story } from '@storybook/react/types-6-0';
2
2
  import { noop } from 'lodash';
3
3
  import ReqoreInput, { IReqoreInputProps } from '../../components/Input';
4
- import { IReqorePanelProps, ReqorePanel } from '../../components/Panel';
5
- import { FlatArg, IconArg, IntentArg, argManager } from '../utils/args';
4
+ import { IReqorePanelAction, IReqorePanelProps, ReqorePanel } from '../../components/Panel';
5
+ import { ReqoreVerticalSpacer } from '../../components/Spacer';
6
+ import { FlatArg, IconArg, IntentArg, SizeArg, argManager } from '../utils/args';
6
7
 
7
8
  const { createArg } = argManager<IReqorePanelProps>();
8
9
 
@@ -11,6 +12,7 @@ export default {
11
12
  argTypes: {
12
13
  ...IntentArg,
13
14
  ...FlatArg,
15
+ ...SizeArg,
14
16
  ...createArg('padded', {
15
17
  type: 'boolean',
16
18
  defaultValue: true,
@@ -48,8 +50,8 @@ export default {
48
50
  description: 'The opacity of the panel',
49
51
  }),
50
52
  ...createArg('headerSize', {
51
- type: 'number',
52
- defaultValue: 4,
53
+ type: 'string',
54
+ defaultValue: undefined,
53
55
  name: 'Header Size',
54
56
  description: 'The size of the header',
55
57
  }),
@@ -64,9 +66,64 @@ export default {
64
66
  } as Meta<IReqorePanelProps>;
65
67
 
66
68
  const Template: Story<IReqorePanelProps> = (args: IReqorePanelProps) => {
69
+ if (args.fluid) {
70
+ const actions: IReqorePanelAction[] = [
71
+ {
72
+ icon: 'GiftFill',
73
+ label: 'Visible',
74
+ responsive: false,
75
+ },
76
+ {
77
+ label: 'Hidden when small',
78
+ icon: 'EyeCloseLine',
79
+ },
80
+ {
81
+ label: 'Hidden when small',
82
+ icon: 'EyeCloseLine',
83
+ },
84
+ {
85
+ label: 'Hidden when small',
86
+ icon: 'EyeCloseLine',
87
+ },
88
+ {
89
+ label: 'Hidden when small',
90
+ icon: 'EyeCloseLine',
91
+ },
92
+ ];
93
+
94
+ return (
95
+ <>
96
+ <ReqorePanel
97
+ {...args}
98
+ badge='Fluid'
99
+ actions={actions}
100
+ bottomActions={[
101
+ ...actions,
102
+ ...actions.map((action) => ({ ...action, position: 'right' })),
103
+ ]}
104
+ >
105
+ This is a fluid panel
106
+ </ReqorePanel>
107
+ <ReqoreVerticalSpacer height={10} />
108
+ <ReqorePanel
109
+ {...args}
110
+ style={{ width: 400 }}
111
+ fluid={false}
112
+ badge='Not Fluid'
113
+ actions={actions}
114
+ bottomActions={[
115
+ ...actions,
116
+ ...actions.map((action) => ({ ...action, position: 'right' })),
117
+ ]}
118
+ >
119
+ This is not a fluid panel
120
+ </ReqorePanel>
121
+ </>
122
+ );
123
+ }
124
+
67
125
  return (
68
126
  <ReqorePanel
69
- {...args}
70
127
  badge={[
71
128
  10,
72
129
  0,
@@ -85,11 +142,26 @@ const Template: Story<IReqorePanelProps> = (args: IReqorePanelProps) => {
85
142
  },
86
143
  ]}
87
144
  actions={[
88
- { label: 'Test', icon: '24HoursFill', intent: 'info' },
89
- [
90
- { label: 'Stacked Action 1', icon: 'BallPenLine', intent: 'warning' },
91
- { icon: 'CopperCoinFill', intent: 'danger' },
92
- ],
145
+ {
146
+ responsive: false,
147
+ group: [
148
+ {
149
+ label: 'Non responsive',
150
+ icon: '24HoursFill',
151
+ customTheme: { main: '#eb0e8c' },
152
+ },
153
+ {
154
+ icon: 'FullscreenExitLine',
155
+ customTheme: { main: '#a40a62' },
156
+ },
157
+ ],
158
+ },
159
+ {
160
+ group: [
161
+ { label: 'Stacked Action 1', icon: 'BallPenLine', intent: 'warning' },
162
+ { icon: 'CopperCoinFill', intent: 'danger' },
163
+ ],
164
+ },
93
165
  {
94
166
  as: ReqoreInput,
95
167
  props: {
@@ -108,7 +180,14 @@ const Template: Story<IReqorePanelProps> = (args: IReqorePanelProps) => {
108
180
  },
109
181
  ]}
110
182
  bottomActions={[
111
- { label: 'Test', icon: '24HoursFill', position: 'left' },
183
+ {
184
+ position: 'left',
185
+ intent: 'success',
186
+ group: [
187
+ { label: 'Test 1', icon: '24HoursFill' },
188
+ { label: 'Test 2', icon: '24HoursFill' },
189
+ ],
190
+ },
112
191
  {
113
192
  label: 'More actions',
114
193
  position: 'right',
@@ -118,6 +197,7 @@ const Template: Story<IReqorePanelProps> = (args: IReqorePanelProps) => {
118
197
  ],
119
198
  },
120
199
  ]}
200
+ {...args}
121
201
  >
122
202
  Shadowlands has mechanisms put in place for allowing players to catch up on Renown, the system
123
203
  of gaining favor and unlocking rewards, Campaign chapters, and soulbinds within your Covenant.
@@ -157,9 +237,33 @@ export const Flat = Template.bind({});
157
237
  Flat.args = {
158
238
  flat: true,
159
239
  };
160
- export const NoLabel: Story<IReqorePanelProps> = Template.bind({});
161
- NoLabel.args = {
240
+ export const NoBars: Story<IReqorePanelProps> = Template.bind({});
241
+ NoBars.args = {
162
242
  label: undefined,
243
+ badge: undefined,
244
+ icon: undefined,
245
+ actions: [
246
+ { label: 'test', show: false },
247
+ {
248
+ show: false,
249
+ group: [
250
+ { label: 'test 2', show: true },
251
+ { label: 'test 3', show: true },
252
+ ],
253
+ },
254
+ ],
255
+ bottomActions: [
256
+ { label: 'test', show: false, position: 'left' },
257
+ {
258
+ position: 'right',
259
+ show: false,
260
+ group: [
261
+ { label: 'test 2', show: true },
262
+ { label: 'test 3', show: true },
263
+ ],
264
+ },
265
+ ],
266
+ collapsible: false,
163
267
  };
164
268
 
165
269
  export const Transparent: Story<IReqorePanelProps> = Template.bind({});
@@ -167,14 +271,44 @@ Transparent.args = {
167
271
  transparent: true,
168
272
  };
169
273
 
274
+ export const Intent: Story<IReqorePanelProps> = Template.bind({});
275
+ Intent.args = {
276
+ intent: 'success',
277
+ iconColor: 'success:lighten:2',
278
+ transparent: true,
279
+ flat: true,
280
+ };
281
+
170
282
  export const Minimal: Story<IReqorePanelProps> = Template.bind({});
171
283
  Minimal.args = {
172
284
  minimal: true,
173
285
  flat: true,
174
286
  };
175
287
 
288
+ export const TransparentFlat: Story<IReqorePanelProps> = Template.bind({});
289
+ TransparentFlat.args = {
290
+ transparent: true,
291
+ flat: true,
292
+ };
293
+
294
+ export const Fluid: Story<IReqorePanelProps> = Template.bind({});
295
+ Fluid.args = {
296
+ fluid: true,
297
+ };
298
+
299
+ export const Size: Story<IReqorePanelProps> = Template.bind({});
300
+ Size.args = {
301
+ size: 'small',
302
+ };
303
+
304
+ export const ContentSize: Story<IReqorePanelProps> = Template.bind({});
305
+ ContentSize.args = {
306
+ contentSize: 'big',
307
+ };
308
+
176
309
  export const WithEffect: Story<IReqorePanelProps> = Template.bind({});
177
310
  WithEffect.args = {
311
+ iconColor: 'info:lighten:2',
178
312
  minimal: true,
179
313
  contentEffect: {
180
314
  gradient: {
@@ -8,9 +8,9 @@ import {
8
8
  ReqoreMessage,
9
9
  ReqorePanel,
10
10
  ReqorePopover,
11
- ReqoreSpacer,
11
+ ReqoreSpacer
12
12
  } from '../../index';
13
- import { FlatArg, argManager } from '../utils/args';
13
+ import { argManager, FlatArg } from '../utils/args';
14
14
 
15
15
  const { createArg } = argManager<IReqorePopoverProps>();
16
16
 
@@ -56,7 +56,7 @@ export default {
56
56
 
57
57
  const HoverButton = (args: any) => {
58
58
  return (
59
- <ReqorePopover component={ReqoreButton} isReqoreComponent {...args}>
59
+ <ReqorePopover component={ReqoreButton} isReqoreComponent {...args} fixed>
60
60
  Hover popover
61
61
  </ReqorePopover>
62
62
  );
@@ -106,100 +106,105 @@ const HoverStayButton = (args: any) => {
106
106
 
107
107
  const Template: Story<IReqorePopoverProps> = (args: IReqorePopoverProps) => {
108
108
  return (
109
- <ReqoreControlGroup vertical gapSize='huge'>
110
- <HoverButton {...args} />
111
- <ClickButton {...args} />
112
- <DelayButton {...args} />
113
- <HoverStayButton {...args} />
114
- {typeof args.content === 'string' && (
115
- <>
116
- <ReqoreSpacer height={100} />
117
- <ReqorePopover
118
- {...args}
119
- component={ReqoreButton}
120
- isReqoreComponent
121
- openOnMount
122
- title='I opened on my own'
123
- icon='CactusFill'
124
- intent='success'
125
- placement='top'
126
- >
127
- Full popover
128
- </ReqorePopover>
129
- <ReqoreControlGroup>
130
- <ReqoreSpacer width={350} />
109
+ <>
110
+ <ReqoreControlGroup vertical gapSize='huge' horizontalAlign='flex-start'>
111
+ <HoverButton {...args} />
112
+ <ClickButton {...args} />
113
+ <DelayButton {...args} />
114
+ <HoverStayButton {...args} />
115
+ {typeof args.content === 'string' && (
116
+ <>
117
+ <ReqoreSpacer height={100} />
131
118
  <ReqorePopover
132
119
  {...args}
133
120
  component={ReqoreButton}
134
121
  isReqoreComponent
135
122
  openOnMount
136
- intent='info'
137
- minimal
138
- placement='left'
123
+ title='I opened on my own'
124
+ icon='CactusFill'
125
+ intent='success'
126
+ placement='top'
139
127
  >
140
- Minimal popover
128
+ Full popover
141
129
  </ReqorePopover>
142
- </ReqoreControlGroup>
143
- <ReqorePopover
144
- {...args}
145
- component={ReqoreButton}
146
- isReqoreComponent
147
- openOnMount
148
- icon='CactusFill'
149
- effect={{
150
- gradient: {
151
- colors: {
152
- 0: 'warning',
153
- 100: 'warning:darken:2',
130
+ <ReqoreControlGroup>
131
+ <ReqoreSpacer width={190} />
132
+ <ReqorePopover
133
+ {...args}
134
+ component={ReqoreButton}
135
+ isReqoreComponent
136
+ openOnMount
137
+ intent='info'
138
+ minimal
139
+ placement='left'
140
+ >
141
+ Minimal popover
142
+ </ReqorePopover>
143
+ </ReqoreControlGroup>
144
+ <ReqorePopover
145
+ {...args}
146
+ component={ReqoreButton}
147
+ isReqoreComponent
148
+ openOnMount
149
+ icon='CactusFill'
150
+ effect={{
151
+ gradient: {
152
+ colors: {
153
+ 0: 'warning',
154
+ 100: 'warning:darken:2',
155
+ },
154
156
  },
155
- },
156
- spaced: 2,
157
- uppercase: true,
158
- weight: 'thick',
159
- }}
160
- placement='right'
161
- >
162
- Effect popover
163
- </ReqorePopover>
157
+ spaced: 2,
158
+ uppercase: true,
159
+ weight: 'thick',
160
+ }}
161
+ placement='right'
162
+ >
163
+ Effect popover
164
+ </ReqorePopover>
165
+ <ReqorePopover
166
+ {...args}
167
+ component={ReqoreButton}
168
+ isReqoreComponent
169
+ openOnMount
170
+ transparent
171
+ placement='right'
172
+ >
173
+ Transparent popover
174
+ </ReqorePopover>
175
+ </>
176
+ )}
177
+ <ReqorePopover
178
+ {...args}
179
+ component={ReqoreButton}
180
+ isReqoreComponent
181
+ openOnMount
182
+ placement='right'
183
+ >
184
+ Auto open popover
185
+ </ReqorePopover>
186
+ <ReqorePanel label='This is a test' flat>
164
187
  <ReqorePopover
165
188
  {...args}
166
189
  component={ReqoreButton}
167
190
  isReqoreComponent
168
191
  openOnMount
169
- transparent
170
- placement='right'
192
+ placement='bottom'
193
+ title="I'm a title"
194
+ content={
195
+ <ReqorePanel label='This is a test' flat>
196
+ <ReqoreMessage flat>
197
+ In to am attended desirous raptures declared diverted confined at. Collected
198
+ instantly remaining up certainly to necessary as. Over walk dull into
199
+ </ReqoreMessage>
200
+ </ReqorePanel>
201
+ }
171
202
  >
172
- Transparent popover
203
+ With Custom Content inside a panel
173
204
  </ReqorePopover>
174
- </>
175
- )}
176
- <ReqorePopover
177
- {...args}
178
- component={ReqoreButton}
179
- isReqoreComponent
180
- openOnMount
181
- placement='right'
182
- >
183
- Auto open popover
184
- </ReqorePopover>
185
- <ReqorePopover
186
- {...args}
187
- component={ReqoreButton}
188
- isReqoreComponent
189
- openOnMount
190
- placement='bottom'
191
- content={
192
- <ReqorePanel label='This is a test' flat>
193
- <ReqoreMessage flat>
194
- In to am attended desirous raptures declared diverted confined at. Collected instantly
195
- remaining up certainly to necessary as. Over walk dull into
196
- </ReqoreMessage>
197
- </ReqorePanel>
198
- }
199
- >
200
- With Custom Content
201
- </ReqorePopover>
202
- </ReqoreControlGroup>
205
+ </ReqorePanel>
206
+ </ReqoreControlGroup>
207
+ </>
203
208
  );
204
209
  };
205
210
 
@@ -210,6 +215,7 @@ NotFlat.args = {
210
215
  };
211
216
  export const CustomContent = Template.bind({});
212
217
  CustomContent.args = {
218
+ noWrapper: true,
213
219
  content: (
214
220
  <ReqorePanel label='This is a test' flat>
215
221
  <ReqoreMessage flat>
@@ -1,7 +1,8 @@
1
1
  import { Meta, Story } from '@storybook/react/types-6-0';
2
2
  import { IReqoreTabsProps } from '../../components/Tabs';
3
- import { ReqoreTabs, ReqoreTabsContent } from '../../index';
4
- import { argManager, IntentArg, SizeArg } from '../utils/args';
3
+ import { TReqoreTabsContentPadding } from '../../components/Tabs/content';
4
+ import { ReqoreH3, ReqoreTabs, ReqoreTabsContent } from '../../index';
5
+ import { IntentArg, SizeArg, argManager } from '../utils/args';
5
6
 
6
7
  const tabs = [
7
8
  {
@@ -30,6 +31,7 @@ const tabs = [
30
31
  id: 3,
31
32
  icon: 'FileSettingsLine',
32
33
  tooltip: 'Click to go to page 3!',
34
+ iconColor: 'info:lighten:3',
33
35
  },
34
36
  {
35
37
  id: 'tab4',
@@ -98,7 +100,7 @@ const tabs = [
98
100
  },
99
101
  ] as IReqoreTabsProps['tabs'];
100
102
 
101
- const { createArg } = argManager<IReqoreTabsProps>();
103
+ const { createArg } = argManager<IReqoreTabsProps & { tabPadding: TReqoreTabsContentPadding }>();
102
104
 
103
105
  export default {
104
106
  title: 'Components/Tabs',
@@ -136,25 +138,25 @@ export default {
136
138
  description: 'If the tabs should be vertical',
137
139
  }),
138
140
  },
139
- } as Meta<IReqoreTabsProps>;
141
+ } as Meta<IReqoreTabsProps & { tabPadding: TReqoreTabsContentPadding }>;
140
142
 
141
- const Template: Story<IReqoreTabsProps> = (args) => {
143
+ const Template: Story<IReqoreTabsProps & { tabPadding: TReqoreTabsContentPadding }> = (args) => {
142
144
  return (
143
145
  <ReqoreTabs {...args} tabs={tabs}>
144
146
  <ReqoreTabsContent tabId='tab1'>
145
- <h3>Tab 1</h3>
147
+ <ReqoreH3>Tab 1</ReqoreH3>
146
148
  </ReqoreTabsContent>
147
149
  <ReqoreTabsContent tabId='tab2'>
148
- <h3>Tab 2</h3>
150
+ <ReqoreH3>Tab 2</ReqoreH3>
149
151
  </ReqoreTabsContent>
150
- <ReqoreTabsContent tabId={3}>
151
- <h3>Tab 3</h3>
152
+ <ReqoreTabsContent tabId={3} padded='vertical'>
153
+ <ReqoreH3>Tab 3</ReqoreH3>
152
154
  </ReqoreTabsContent>
153
155
  <ReqoreTabsContent tabId='tab4'>
154
- <h3>Tab 4</h3>
156
+ <ReqoreH3>Tab 4</ReqoreH3>
155
157
  </ReqoreTabsContent>
156
158
  <ReqoreTabsContent tabId='tab5'>
157
- <h3>Tab 5</h3>
159
+ <ReqoreH3>Tab 5</ReqoreH3>
158
160
  </ReqoreTabsContent>
159
161
  <ReqoreTabsContent tabId='tab6'>
160
162
  Lorem ipsum dolor sit amet, consectetur adipiscing elit. Curabitur vitae nisi ligula. Proin
@@ -215,13 +217,13 @@ const Template: Story<IReqoreTabsProps> = (args) => {
215
217
  Praesent vitae bibendum mauris, eu blandit dui.
216
218
  </ReqoreTabsContent>
217
219
  <ReqoreTabsContent tabId='tab7'>
218
- <h3>Tab 7</h3>
220
+ <ReqoreH3>Tab 7</ReqoreH3>
219
221
  </ReqoreTabsContent>
220
222
  <ReqoreTabsContent tabId='tab8'>
221
- <h3>Tab 8</h3>
223
+ <ReqoreH3>Tab 8</ReqoreH3>
222
224
  </ReqoreTabsContent>
223
225
  <ReqoreTabsContent tabId='tab9'>
224
- <h3>Tab 9</h3>
226
+ <ReqoreH3>Tab 9</ReqoreH3>
225
227
  </ReqoreTabsContent>
226
228
  </ReqoreTabs>
227
229
  );
@@ -236,6 +238,7 @@ Fill.args = {
236
238
  export const CustomActiveIntent = Template.bind({});
237
239
  CustomActiveIntent.args = {
238
240
  activeTabIntent: 'warning',
241
+ activeTab: 'tab8',
239
242
  };
240
243
 
241
244
  export const NotFlat = Template.bind({});
@@ -243,12 +246,23 @@ NotFlat.args = {
243
246
  flat: false,
244
247
  };
245
248
 
249
+ export const NoTabsPadding = Template.bind({});
250
+ NoTabsPadding.args = {
251
+ padded: false,
252
+ };
253
+
246
254
  export const Vertical = Template.bind({});
247
255
  Vertical.args = {
248
256
  vertical: true,
249
257
  fillParent: true,
250
258
  };
251
259
 
260
+ export const VerticalNoTabsPadding = Template.bind({});
261
+ VerticalNoTabsPadding.args = {
262
+ padded: false,
263
+ vertical: true,
264
+ };
265
+
252
266
  export const VerticalWithWrapping = Template.bind({});
253
267
  VerticalWithWrapping.args = {
254
268
  vertical: true,
@@ -259,7 +273,11 @@ VerticalWithWrapping.args = {
259
273
  export const VerticalCustomWidth = Template.bind({});
260
274
  VerticalCustomWidth.args = {
261
275
  vertical: true,
262
- fill: true,
263
276
  fillParent: true,
264
277
  width: '300px',
265
278
  };
279
+
280
+ export const CustomTabsPadding = Template.bind({});
281
+ CustomTabsPadding.args = {
282
+ tabsPadding: 'none',
283
+ };