@onereach/ui-components 4.4.3 → 4.4.4-beta.2722.0

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 (124) hide show
  1. package/dist/bundled/v2/components/index.d.ts +2 -0
  2. package/dist/bundled/v2/components/index.js +6 -4
  3. package/dist/bundled/v2/index.js +7 -5
  4. package/dist/bundled/v3/OrCombinedInput.vue_vue_type_script_lang-cb7a88f3.js +66 -0
  5. package/dist/bundled/v3/components/OrCombinedInputV3/OrCombinedInput.js +11 -66
  6. package/dist/bundled/v3/components/OrCombinedInputV3/index.js +1 -1
  7. package/dist/bundled/v3/components/index.d.ts +2 -0
  8. package/dist/bundled/v3/components/index.js +5 -3
  9. package/dist/bundled/v3/index.js +11 -8
  10. package/dist/esm/v2/OrCombinedInput-5994d9fc.js +158 -0
  11. package/dist/esm/v2/components/index.d.ts +2 -0
  12. package/dist/esm/v2/components/index.js +4 -3
  13. package/dist/esm/v2/components/or-combined-input-v3/index.js +6 -158
  14. package/dist/esm/v2/index.js +4 -3
  15. package/dist/esm/v3/OrCombinedInput-14c23a04.js +129 -0
  16. package/dist/esm/v3/components/index.d.ts +2 -0
  17. package/dist/esm/v3/components/index.js +3 -2
  18. package/dist/esm/v3/components/or-combined-input-v3/index.js +6 -129
  19. package/dist/esm/v3/index.js +3 -2
  20. package/package.json +2 -3
  21. package/src/components/index.ts +2 -0
  22. package/src/components/or-button/OrButton.stories.ts +8 -0
  23. package/src/components/or-bottom-sheet-v3/OrBottomSheet.docs.mdx +0 -7
  24. package/src/components/or-bottom-sheet-v3/OrBottomSheet.stories3.ts +0 -110
  25. package/src/components/or-button-v3/OrButton.docs.mdx +0 -14
  26. package/src/components/or-button-v3/OrButton.stories3.ts +0 -130
  27. package/src/components/or-card-collection-v3/OrCardCollection.docs.mdx +0 -7
  28. package/src/components/or-card-collection-v3/OrCardCollection.stories3.ts +0 -378
  29. package/src/components/or-card-v3/OrCard.docs.mdx +0 -10
  30. package/src/components/or-card-v3/OrCard.stories3.ts +0 -74
  31. package/src/components/or-checkbox-group-v3/OrCheckboxGroup.docs.mdx +0 -7
  32. package/src/components/or-checkbox-group-v3/OrCheckboxGroup.stories3.ts +0 -399
  33. package/src/components/or-checkbox-tree-v3/OrCheckboxTree.docs.mdx +0 -7
  34. package/src/components/or-checkbox-tree-v3/OrCheckboxTree.stories3.ts +0 -112
  35. package/src/components/or-checkbox-v3/OrCheckbox.docs.mdx +0 -12
  36. package/src/components/or-checkbox-v3/OrCheckbox.stories3.ts +0 -155
  37. package/src/components/or-combined-input-v3/OrCombinedInput.docs.mdx +0 -7
  38. package/src/components/or-combined-input-v3/OrCombinedInput.stories3.ts +0 -201
  39. package/src/components/or-confirm-v3/OrConfirm.docs.mdx +0 -16
  40. package/src/components/or-confirm-v3/OrConfirm.stories3.ts +0 -252
  41. package/src/components/or-date-picker-v3/OrDatePicker.docs.mdx +0 -7
  42. package/src/components/or-date-picker-v3/OrDatePicker.stories3.ts +0 -174
  43. package/src/components/or-date-time-picker-v3/OrDateTimePicker.docs.mdx +0 -7
  44. package/src/components/or-date-time-picker-v3/OrDateTimePicker.stories3.ts +0 -183
  45. package/src/components/or-empty-state-v3/OrEmptyState.stories3.ts +0 -87
  46. package/src/components/or-error-tag-v3/OrErrorTag.docs.mdx +0 -8
  47. package/src/components/or-error-tag-v3/OrErrorTag.stories3.ts +0 -56
  48. package/src/components/or-expansion-panel-v3/OrExpansionPanel.docs.mdx +0 -7
  49. package/src/components/or-expansion-panel-v3/OrExpansionPanel.stories3.ts +0 -137
  50. package/src/components/or-fab-v3/OrFab.docs.mdx +0 -7
  51. package/src/components/or-fab-v3/OrFab.stories3.ts +0 -81
  52. package/src/components/or-form-group-v3/OrFormGroup.stories3.ts +0 -114
  53. package/src/components/or-icon-button-v3/OrIconButton.docs.mdx +0 -14
  54. package/src/components/or-icon-button-v3/OrIconButton.stories3.ts +0 -105
  55. package/src/components/or-icon-v3/OrIcon.docs.mdx +0 -12
  56. package/src/components/or-icon-v3/OrIcon.stories3.ts +0 -53
  57. package/src/components/or-inline-input-v3/OrInlineInput.docs.mdx +0 -7
  58. package/src/components/or-inline-input-v3/OrInlineInput.stories3.ts +0 -137
  59. package/src/components/or-inline-textarea-v3/OrInlineTextarea.docs.mdx +0 -7
  60. package/src/components/or-inline-textarea-v3/OrInlineTextarea.stories3.ts +0 -126
  61. package/src/components/or-input-v3/OrInput.docs.mdx +0 -16
  62. package/src/components/or-input-v3/OrInput.stories3.ts +0 -222
  63. package/src/components/or-link-v3/OrLink.docs.mdx +0 -7
  64. package/src/components/or-link-v3/OrLink.stories3.ts +0 -163
  65. package/src/components/or-loader-v3/OrLoader.docs.mdx +0 -14
  66. package/src/components/or-loader-v3/OrLoader.stories3.ts +0 -86
  67. package/src/components/or-menu-item-v3/OrMenuItem.docs.mdx +0 -7
  68. package/src/components/or-menu-item-v3/OrMenuItem.stories3.ts +0 -90
  69. package/src/components/or-menu-v3/OrMenu.docs.mdx +0 -7
  70. package/src/components/or-menu-v3/OrMenu.stories3.ts +0 -167
  71. package/src/components/or-modal-v3/OrModal.docs.mdx +0 -10
  72. package/src/components/or-modal-v3/OrModal.stories3.ts +0 -278
  73. package/src/components/or-notification-v3/OrNotification.docs.mdx +0 -7
  74. package/src/components/or-notification-v3/OrNotification.stories3.ts +0 -122
  75. package/src/components/or-overlay-v3/OrOverlay.docs.mdx +0 -11
  76. package/src/components/or-overlay-v3/OrOverlay.stories3.ts +0 -61
  77. package/src/components/or-pagination-v3/OrPagination.docs.mdx +0 -7
  78. package/src/components/or-pagination-v3/OrPagination.stories3.ts +0 -81
  79. package/src/components/or-popover-v3/OrPopover.docs.mdx +0 -11
  80. package/src/components/or-popover-v3/OrPopover.stories3.ts +0 -115
  81. package/src/components/or-progress-v3/OrProgress.docs.mdx +0 -12
  82. package/src/components/or-progress-v3/OrProgress.stories3.ts +0 -220
  83. package/src/components/or-radio-group-v3/OrRadioGroup.stories3.ts +0 -81
  84. package/src/components/or-radio-v3/OrRadio.docs.mdx +0 -11
  85. package/src/components/or-radio-v3/OrRadio.stories3.ts +0 -151
  86. package/src/components/or-search-v3/OrSearch.docs.mdx +0 -16
  87. package/src/components/or-search-v3/OrSearch.stories3.ts +0 -126
  88. package/src/components/or-segmented-control-v3/OrSegmentedControl.docs.mdx +0 -7
  89. package/src/components/or-segmented-control-v3/OrSegmentedControl.stories3.ts +0 -100
  90. package/src/components/or-select-v3/OrSelect.docs.mdx +0 -17
  91. package/src/components/or-select-v3/OrSelect.stories3.ts +0 -508
  92. package/src/components/or-sidebar-v3/OrSidebar.docs.mdx +0 -13
  93. package/src/components/or-sidebar-v3/OrSidebar.stories3.ts +0 -415
  94. package/src/components/or-skeleton-v3/OrSkeleton.docs.mdx +0 -14
  95. package/src/components/or-skeleton-v3/OrSkeleton.stories3.ts +0 -144
  96. package/src/components/or-skeleton-v3/or-skeleton-circle-v3/OrSkeletonCircle.docs.mdx +0 -7
  97. package/src/components/or-skeleton-v3/or-skeleton-circle-v3/OrSkeletonCircle.stories3.ts +0 -59
  98. package/src/components/or-skeleton-v3/or-skeleton-rect-v3/OrSkeletonRect.docs.mdx +0 -6
  99. package/src/components/or-skeleton-v3/or-skeleton-rect-v3/OrSkeletonRect.stories3.ts +0 -80
  100. package/src/components/or-skeleton-v3/or-skeleton-text-v3/OrSkeletonText.docs.mdx +0 -7
  101. package/src/components/or-skeleton-v3/or-skeleton-text-v3/OrSkeletonText.stories3.ts +0 -88
  102. package/src/components/or-switch-v3/OrSwitch.docs.mdx +0 -7
  103. package/src/components/or-switch-v3/OrSwitch.stories3.ts +0 -155
  104. package/src/components/or-tab-v3/OrTab.docs.mdx +0 -7
  105. package/src/components/or-tab-v3/OrTab.stories3.ts +0 -74
  106. package/src/components/or-tabs-v3/OrTabs.docs.mdx +0 -7
  107. package/src/components/or-tabs-v3/OrTabs.stories3.ts +0 -140
  108. package/src/components/or-tag-v3/OrTag.docs.mdx +0 -13
  109. package/src/components/or-tag-v3/OrTag.stories3.ts +0 -213
  110. package/src/components/or-tags-v3/OrTags.docs.mdx +0 -7
  111. package/src/components/or-tags-v3/OrTags.stories3.ts +0 -101
  112. package/src/components/or-teleport-v3/OrTeleport.docs.mdx +0 -7
  113. package/src/components/or-teleport-v3/OrTeleport.stories3.ts +0 -60
  114. package/src/components/or-text-v3/OrText.docs.mdx +0 -7
  115. package/src/components/or-text-v3/OrText.stories3.ts +0 -124
  116. package/src/components/or-textarea-v3/OrTextarea.docs.mdx +0 -14
  117. package/src/components/or-textarea-v3/OrTextarea.stories3.ts +0 -164
  118. package/src/components/or-time-picker-v3/OrTimePicker.docs.mdx +0 -7
  119. package/src/components/or-time-picker-v3/OrTimePicker.stories3.ts +0 -170
  120. package/src/components/or-toast-v3/OrToast.stories3.ts +0 -67
  121. package/src/components/or-toast-v3/or-toast-container-v3/OrToastContainer.docs.mdx +0 -123
  122. package/src/components/or-toast-v3/or-toast-container-v3/OrToastContainer.stories3.ts +0 -119
  123. package/src/components/or-tooltip-v3/OrTooltip.docs.mdx +0 -10
  124. package/src/components/or-tooltip-v3/OrTooltip.stories3.ts +0 -84
@@ -1,183 +0,0 @@
1
- import { action } from '@storybook/addon-actions';
2
- import { Meta, StoryFn } from '@storybook/vue3';
3
- import * as Faker from 'faker';
4
- import { ref, watch } from 'vue-demi';
5
- import { OrIconV3 as OrIcon } from '../or-icon-v3';
6
- import OrDateTimePickerDocs from './OrDateTimePicker.docs.mdx';
7
- import OrDateTimePicker from './OrDateTimePicker.vue';
8
- import { DateTimePickerSize } from './props';
9
-
10
- export default {
11
- title: 'Components/Date & Time Picker',
12
- component: OrDateTimePicker,
13
-
14
- argTypes: {
15
- // Slots
16
- addon: {
17
- type: {
18
- name: 'string',
19
- required: false,
20
- },
21
-
22
- control: { type: 'text' },
23
- },
24
-
25
- // Props
26
- modelValue: {
27
- control: { type: 'text' },
28
- },
29
-
30
- yearFilter: {
31
- table: { disable: true },
32
- },
33
-
34
- monthFilter: {
35
- table: { disable: true },
36
- },
37
-
38
- dateFilter: {
39
- table: { disable: true },
40
- },
41
-
42
- hoursFilter: {
43
- table: { disable: true },
44
- },
45
-
46
- minutesFilter: {
47
- table: { disable: true },
48
- },
49
-
50
- size: {
51
- control: { type: 'select' },
52
- options: Object.values(DateTimePickerSize),
53
- },
54
-
55
- label: {
56
- control: { type: 'text' },
57
- },
58
-
59
- hint: {
60
- control: { type: 'text' },
61
- },
62
-
63
- error: {
64
- control: { type: 'text' },
65
- },
66
-
67
- required: {
68
- control: { type: 'boolean' },
69
- },
70
-
71
- readonly: {
72
- control: { type: 'boolean' },
73
- },
74
-
75
- disabled: {
76
- control: { type: 'boolean' },
77
- },
78
-
79
- disableDefaultStyles: {
80
- control: { type: 'boolean' },
81
- },
82
-
83
- // Events
84
- 'update:modelValue': {
85
- table: { disable: true },
86
- },
87
-
88
- input: {
89
- table: { disable: true },
90
- },
91
-
92
- keydown: {
93
- table: { disable: true },
94
- },
95
-
96
- keyup: {
97
- table: { disable: true },
98
- },
99
-
100
- focus: {
101
- table: { disable: true },
102
- },
103
-
104
- blur: {
105
- table: { disable: true },
106
- },
107
- },
108
-
109
- parameters: {
110
- docs: {
111
- page: OrDateTimePickerDocs,
112
- },
113
-
114
- design: {
115
- type: 'figma',
116
- url: 'https://www.figma.com/file/o7DdkaznUW2PtX4wiSuhhQ/Core?node-id=4063%3A40967&t=H1iGW8hg2dduEfyc-4',
117
- },
118
- },
119
- } as Meta<typeof OrDateTimePicker>;
120
-
121
- const Template: StoryFn<typeof OrDateTimePicker> = (args) => ({
122
- components: {
123
- OrIcon,
124
- OrDateTimePicker,
125
- },
126
-
127
- setup() {
128
- // State
129
- const model = ref<Date>();
130
-
131
- // Effects
132
- watch(model, (value) => {
133
- console.debug(value);
134
- });
135
-
136
- return {
137
- args,
138
- model,
139
- onUpdateModelValue: action('update:modelValue'),
140
- onKeydown: action('keydown'),
141
- onKeyup: action('keyup'),
142
- onFocus: action('focus'),
143
- onBlur: action('blur'),
144
- };
145
- },
146
-
147
- template: `
148
- <OrDateTimePicker
149
- v-model="model"
150
- v-bind="args"
151
- @update:modelValue="onUpdateModelValue"
152
- @keydown="onKeydown"
153
- @keyup="onKeyup"
154
- @focus="onFocus"
155
- @blur="onBlur"
156
- >
157
- <template #addon>
158
- ${args.addon}
159
- </template>
160
- </OrDateTimePicker>
161
- `,
162
- });
163
-
164
- export const Default = Template.bind({});
165
-
166
- Default.args = {
167
- // Slots
168
- addon: '<OrIcon icon="info" />',
169
-
170
- // Props
171
- label: 'Label',
172
- hint: Faker.lorem.sentence(20),
173
- };
174
-
175
- export const WithFilter = Template.bind({});
176
-
177
- WithFilter.args = {
178
- ...Default.args,
179
-
180
- // Props
181
- dateFilter: (value: Date) => ![0, 6].includes(value.getUTCDay()),
182
- hoursFilter: (value: Date) => value.getUTCHours() >= 9 && value.getUTCHours() <= 18,
183
- };
@@ -1,87 +0,0 @@
1
- import { Meta, StoryFn } from '@storybook/vue3';
2
- import OrEmptyState from './OrEmptyState.vue';
3
- import successPng from '../../assets/success.png';
4
- import { EmptyStateSize } from './props';
5
-
6
- export default {
7
- title: 'Components/Empty State',
8
- component: OrEmptyState,
9
- argTypes: {
10
- size: {
11
- control: {
12
- type: 'inline-radio',
13
- labels: {
14
- [EmptyStateSize.M]: 'Medium',
15
- [EmptyStateSize.L]: 'Large',
16
- },
17
- },
18
- options: Object.values(EmptyStateSize),
19
- },
20
- },
21
- parameters: {
22
- layout: 'centered',
23
- },
24
- } as Meta<typeof OrEmptyState>
25
-
26
- const Template: StoryFn<typeof OrEmptyState> = (args) => ({
27
- components: { OrEmptyState },
28
- setup() {
29
- return { args };
30
- },
31
- template: `
32
- <OrEmptyState v-bind="args"/>
33
- `,
34
- });
35
-
36
- export const Default = Template.bind({});
37
- Default.args = {
38
- heading: 'No aliens detected',
39
- text: 'Invite some aliens to your planet.'
40
- };
41
- Default.parameters = {
42
- layout: 'fullscreen',
43
- };
44
- Default.decorators = [
45
- () => ({
46
- template: `
47
- <div class="
48
- demo-wrapper w-full min-h-[200px] h-screen box-border relative
49
- gap-sm p-md bg-surface-variant
50
- flex flex-col
51
- text-body-2-regular">
52
- <div>
53
- Note: This frame is added for demo purpose.<br>
54
- The OrEmptyState component is transparent and has <code>width:100%</code> and <code>flex-grow:1</code> attributes.<br>
55
- It is recommended to put it inside a column flex container or a row flex container that wraps.
56
- </div>
57
- <div class="demo-container grow bg-background dark:bg-background-dark flex flex-col"><story /></div>
58
- </div>
59
- `
60
- })
61
- ];
62
-
63
- export const ImageIcon = Template.bind({});
64
- ImageIcon.args = {
65
- heading: 'Planet populated',
66
- text: 'So many aliens on this planet!',
67
- imageSrc: successPng,
68
- };
69
-
70
- export const LargeSize = Template.bind({});
71
- LargeSize.args = {
72
- ...ImageIcon.args,
73
- size: EmptyStateSize.L,
74
- };
75
-
76
- export const ExtraContentInSlot: StoryFn<typeof OrEmptyState> = (args) => ({
77
- components: { OrEmptyState },
78
- setup() {
79
- return { args };
80
- },
81
- template: `
82
- <OrEmptyState v-bind="args" heading="Alien not found" text="Pass formatted content via a default slot.">
83
- Alien named <b>Garry</b> not found.<br>
84
- The text in the slot is by default formatted as a component's text prop.
85
- </OrEmptyState>
86
- `,
87
- });
@@ -1,8 +0,0 @@
1
- import { DocsPage } from '@storybook/addon-docs';
2
-
3
- ```ts
4
- import { OrErrorTagV3 as OrErrorTag } from '@onereach/ui-components';
5
- ```
6
-
7
-
8
- <DocsPage />
@@ -1,56 +0,0 @@
1
- import { Meta, StoryFn } from '@storybook/vue3';
2
- import OrErrorTagDocs from './OrErrorTag.docs.mdx';
3
- import OrErrorTag from './OrErrorTag.vue';
4
-
5
- export default {
6
- title: 'Components/Tag/Error Tag',
7
- component: OrErrorTag,
8
-
9
- argTypes: {
10
- // Slots
11
- default: {
12
- type: {
13
- name: 'string',
14
- required: true,
15
- },
16
-
17
- control: { type: 'text' },
18
- },
19
- },
20
-
21
- parameters: {
22
- layout: 'centered',
23
-
24
- docs: {
25
- page: OrErrorTagDocs,
26
- },
27
-
28
- design: {
29
- type: 'figma',
30
- url: 'https://www.figma.com/file/o7DdkaznUW2PtX4wiSuhhQ/Core?node-id=202%3A14',
31
- },
32
- },
33
- } as Meta<typeof OrErrorTag>;
34
-
35
- const Template: StoryFn<typeof OrErrorTag> = (args) => ({
36
- components: {
37
- OrErrorTag,
38
- },
39
-
40
- setup() {
41
- return { args };
42
- },
43
-
44
- template: `
45
- <OrErrorTag v-bind="args">
46
- ${args.default}
47
- </OrErrorTag>
48
- `,
49
- });
50
-
51
- export const ErrorTag = Template.bind({});
52
-
53
- ErrorTag.args = {
54
- // Slots
55
- default: 'Error',
56
- };
@@ -1,7 +0,0 @@
1
- import { DocsPage } from '@storybook/addon-docs';
2
-
3
- ```ts
4
- import { OrExpansionPanelV3 as OrExpansionPanel } from '@onereach/ui-components';
5
- ```
6
-
7
- <DocsPage />
@@ -1,137 +0,0 @@
1
- import { Meta, StoryFn } from '@storybook/vue3';
2
- import { action } from '@storybook/addon-actions';
3
-
4
- import { OrIconV3 as OrIcon } from '../or-icon-v3';
5
- import { OrIconButtonV3 as OrIconButton } from '../or-icon-button-v3';
6
- import { OrTagV3 as OrTag } from '../or-tag-v3';
7
- import OrExpansionPanelDocs from './OrExpansionPanel.docs.mdx';
8
- import OrExpansionPanel from './OrExpansionPanel.vue';
9
- import { ExpansionPanelColor, ExpansionPanelVariant } from './props';
10
- import * as Faker from 'faker';
11
-
12
- export default {
13
- title: 'Components/Expansion Panel',
14
- component: OrExpansionPanel,
15
-
16
- argTypes: {
17
- // Slots
18
- default: {
19
- type: {
20
- name: 'string',
21
- required: true,
22
- },
23
-
24
- control: { type: 'text' },
25
- },
26
-
27
- addon: {
28
- type: {
29
- name: 'string',
30
- required: false,
31
- },
32
-
33
- control: { type: 'text' },
34
- },
35
-
36
- // Props
37
- label: {
38
- control: { type: 'text' },
39
- },
40
-
41
- variant: {
42
- control: { type: 'select' },
43
- options: Object.values(ExpansionPanelVariant),
44
- },
45
-
46
- color: {
47
- control: { type: 'select' },
48
- options: Object.values(ExpansionPanelColor),
49
- },
50
-
51
- disabled: {
52
- control: { type: 'boolean' },
53
- },
54
- },
55
-
56
- parameters: {
57
- docs: {
58
- page: OrExpansionPanelDocs,
59
- },
60
-
61
- design: {
62
- type: 'figma',
63
- url: 'https://www.figma.com/file/o7DdkaznUW2PtX4wiSuhhQ/Core?node-id=202%3A19&t=a2KFznTzma8aZ816-1',
64
- },
65
- },
66
- } as Meta<typeof OrExpansionPanel>;
67
-
68
- const Template: StoryFn<typeof OrExpansionPanel> = (args) => ({
69
- components: {
70
- OrExpansionPanel,
71
- OrIcon,
72
- OrIconButton,
73
- OrTag,
74
- },
75
-
76
- setup() {
77
- return {
78
- args,
79
- handleOpen: action('open'),
80
- handleClose: action('close'),
81
- };
82
- },
83
-
84
- template: `
85
- <OrExpansionPanel
86
- v-bind="args"
87
- @open="handleOpen"
88
- @close="handleClose"
89
- >
90
- ${args.default}
91
-
92
- <template #addon>
93
- ${args.addon}
94
- </template>
95
- </OrExpansionPanel>
96
- `,
97
- });
98
-
99
- export const Default = Template.bind({});
100
-
101
- Default.args = {
102
- // Slots
103
- default: Faker.lorem.paragraphs(3),
104
- addon: '<OrIcon icon="drag_indicator" />',
105
-
106
- // Props
107
- label: 'Expansion Panel',
108
- };
109
-
110
- export const CardVariant = Template.bind({});
111
-
112
- CardVariant.args = {
113
- // Slots
114
- default: Faker.lorem.paragraphs(3),
115
- addon: '<OrIconButton icon="delete" />',
116
-
117
- // Props
118
- label: 'Card Expansion Panel',
119
- variant: ExpansionPanelVariant.Card,
120
- };
121
-
122
- export const WithLongLabelAndTags = Template.bind({});
123
-
124
- WithLongLabelAndTags.args = {
125
- // Slots
126
- default: Faker.lorem.paragraphs(3),
127
- addon: `
128
- <div class="flex flex-row gap-sm">
129
- <OrTag>${Faker.lorem.word()}</OrTag>
130
- <OrTag>${Faker.lorem.word()}</OrTag>
131
- <OrTag>${Faker.lorem.word()}</OrTag>
132
- </div>
133
- `,
134
-
135
- // Props
136
- label: Faker.lorem.sentence(35),
137
- };
@@ -1,7 +0,0 @@
1
- import { DocsPage } from '@storybook/addon-docs';
2
-
3
- ```ts
4
- import { OrFabV3 as OrFab } from '@onereach/ui-components';
5
- ```
6
-
7
- <DocsPage />
@@ -1,81 +0,0 @@
1
- import { Meta, StoryFn } from '@storybook/vue3';
2
- import { action } from '@storybook/addon-actions';
3
- import { OrIconV3 as OrIcon } from '../or-icon-v3';
4
- import OrFabDocs from './OrFab.docs.mdx';
5
- import OrFab from './OrFab.vue';
6
- import { FabColor } from './props';
7
-
8
- export default {
9
- title: 'Components/Buttons/FAB',
10
- component: OrFab,
11
-
12
- argTypes: {
13
- // Props
14
- icon: {
15
- control: { type: 'text' },
16
- },
17
-
18
- color: {
19
- control: { type: 'select' },
20
- options: Object.values(FabColor),
21
- },
22
-
23
- disabled: {
24
- control: { type: 'boolean' },
25
- },
26
- },
27
-
28
- parameters: {
29
- docs: {
30
- page: OrFabDocs,
31
- },
32
-
33
- design: {
34
- type: 'figma',
35
- url: 'https://www.figma.com/file/o7DdkaznUW2PtX4wiSuhhQ/Core?node-id=202%3A9',
36
- },
37
- },
38
- } as Meta<typeof OrFab>;
39
-
40
- const Template: StoryFn<typeof OrFab> = (args) => ({
41
- components: {
42
- OrFab,
43
- OrIcon,
44
- },
45
-
46
- setup() {
47
- return {
48
- args,
49
- handleClick: action('click'),
50
- handleFocus: action('focus'),
51
- handleBlur: action('blur'),
52
- handleMouseover: action('mouseover'),
53
- handleMouseout: action('moouseout'),
54
- handleMousemove: action('moousemove'),
55
- handleMouseenter: action('mouseenter'),
56
- handleMouseleave: action('museleave'),
57
- };
58
- },
59
-
60
- template: `
61
- <OrFab
62
- v-bind="args"
63
- @click="handleClick"
64
- @focus="handleFocus"
65
- @blur="handleBlur"
66
- @mouseover="handleMouseover"
67
- @mouseout="handleMouseout"
68
- @mousemove="handleMousemove"
69
- @mouseenter="handleMouseenter"
70
- @mouseleave="handleMouseleave"
71
- class="test-class"
72
- />
73
- `,
74
- });
75
-
76
- export const Default = Template.bind({});
77
-
78
- Default.args = {
79
- // Props
80
- icon: 'add',
81
- };
@@ -1,114 +0,0 @@
1
- import OrFormGroup from './OrFormGroup.vue';
2
- import { ref } from 'vue-demi';
3
- import { Meta, StoryFn } from '@storybook/vue3';
4
- import { OrRadioV3 as OrRadio } from '../or-radio-v3';
5
- import { OrCheckboxV3 as OrCheckbox } from '../or-checkbox-v3';
6
- import { OrSwitchV3 as OrSwitch } from '../or-switch-v3';
7
- import { FormGroupDirection } from './props';
8
- export default {
9
- title: 'Components/Forms/Group',
10
- component: OrFormGroup,
11
- argTypes: {
12
- // Props
13
- label: {
14
- control: { type: 'text' },
15
- },
16
- error: {
17
- control: { type: 'text' },
18
- },
19
- hint: {
20
- control: { type: 'text' },
21
- },
22
- direction: {
23
- control: { type: 'select' },
24
- options: Object.values(FormGroupDirection),
25
- },
26
- },
27
- } as Meta<typeof OrFormGroup>;
28
-
29
- const RadioTemplate: StoryFn<typeof OrFormGroup> = (args) => ({
30
- components: {
31
- OrFormGroup,
32
- OrRadio,
33
- },
34
- setup() {
35
- const modelValue = ref('');
36
- return {
37
- args,
38
- modelValue,
39
- };
40
- },
41
- template: `
42
- <OrFormGroup
43
- v-bind="args"
44
- >
45
- <OrRadio :label="'Option 1'" value="1" v-model="modelValue"/>
46
- <OrRadio :label="'Option 2'" value="3" v-model="modelValue"/>
47
- <OrRadio :label="'Option 3'" value="4" v-model="modelValue"/>
48
- </OrFormGroup>
49
- `,
50
- });
51
-
52
- export const RadioGroup = RadioTemplate.bind({});
53
- RadioGroup.args = {
54
- label: 'Radio Group',
55
- hint: 'This is a hint',
56
- };
57
-
58
- const CheckboxTemplate: StoryFn<typeof OrFormGroup> = (args) => ({
59
- components: {
60
- OrFormGroup,
61
- OrCheckbox,
62
- },
63
- setup() {
64
- const modelValue = ref([]);
65
- return {
66
- args,
67
- modelValue,
68
- };
69
- },
70
- template: `
71
- <OrFormGroup
72
- v-bind="args"
73
- >
74
- <OrCheckbox :label="'Option 1'" value="1" v-model="modelValue"/>
75
- <OrCheckbox :label="'Option 2'" value="3" v-model="modelValue"/>
76
- <OrCheckbox :label="'Option 3'" value="4" v-model="modelValue"/>
77
- </OrFormGroup>
78
- `,
79
- });
80
-
81
- export const CheckboxGroup = CheckboxTemplate.bind({});
82
- CheckboxGroup.args = {
83
- label: 'Checkbox Group',
84
- hint: 'This is a hint',
85
- };
86
-
87
- const SwitchTemplate: StoryFn<typeof OrFormGroup> = (args) => ({
88
- components: {
89
- OrFormGroup,
90
- OrSwitch,
91
- },
92
- setup() {
93
- const modelValue = ref([]);
94
- return {
95
- args,
96
- modelValue,
97
- };
98
- },
99
- template: `
100
- <OrFormGroup
101
- v-bind="args"
102
- >
103
- <OrSwitch :label="'Option 1'" value="1" v-model="modelValue"/>
104
- <OrSwitch :label="'Option 2'" value="3" v-model="modelValue"/>
105
- <OrSwitch :label="'Option 3'" value="4" v-model="modelValue"/>
106
- </OrFormGroup>
107
- `,
108
- });
109
-
110
- export const SwitchGroup = SwitchTemplate.bind({});
111
- SwitchGroup.args = {
112
- label: 'Switch Group',
113
- hint: 'This is a hint',
114
- };
@@ -1,14 +0,0 @@
1
- import { DocsPage } from '@storybook/addon-docs';
2
-
3
- ```ts
4
- import { OrIconButtonV3 as OrIconButton } from '@onereach/ui-components';
5
- ```
6
-
7
- <DocsPage />
8
-
9
- ## Migration Guide from V1
10
- - removed property `type`
11
- - property `htmlButtonType` renamed to `type`
12
- - removed properties `color`, `iconColor`, `bgColor`, and `size`
13
- - property `isDisabled` renamed to `disabled`
14
- - removed property `isLoading`