@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,130 +1,7 @@
1
- import { defineComponent, ref, computed } from 'vue-demi';
2
- import { s as script$1 } from '../../OrError-c01d0c29.js';
3
- import { s as script$2 } from '../../OrHint-06ab89d7.js';
4
- import { s as script$3 } from '../../OrLabel-4da56db0.js';
5
- import { I as InputBoxSize } from '../../OrInputBox-ba40bbdf.js';
1
+ export { s as OrCombinedInputV3 } from '../../OrCombinedInput-14c23a04.js';
6
2
  export { I as CombinedInputSize } from '../../OrInputBox-ba40bbdf.js';
7
- import { resolveComponent, openBlock, createElementBlock, normalizeClass, createBlock, withCtx, renderSlot, createTextVNode, toDisplayString, createCommentVNode, createElementVNode, withDirectives, vShow, createVNode } from 'vue';
8
-
9
- const CombinedInputRoot = [
10
- // Layout
11
- 'layout-column',
12
- // Spacing
13
- 'gap-xs'];
14
- const CombinedInputControlGroup = [
15
- // Layout
16
- 'layout-row',
17
- // Box
18
- 'w-full',
19
- // Shape (.or-input-box-v3)
20
- '[&_.or-input-box-v3]:first-child:rounded-r-0', '[&_.or-input-box-v3]:intermediate-child:rounded-0', '[&_.or-input-box-v3]:last-child:rounded-l-0',
21
- // Spacing (.or-input-box-v3)
22
- '[&_.or-input-box-v3]:first-child:mr-[-1px]', '[&_.or-input-box-v3]:intermediate-child:border-x-0', '[&_.or-input-box-v3]:last-child:ml-[-1px]'];
23
-
24
- var script = defineComponent({
25
- name: 'OrCombinedInput',
26
- components: {
27
- OrError: script$1,
28
- OrHint: script$2,
29
- OrLabel: script$3
30
- },
31
- props: {
32
- size: {
33
- type: String,
34
- default: InputBoxSize.M
35
- },
36
- label: {
37
- type: String,
38
- default: undefined
39
- },
40
- hint: {
41
- type: String,
42
- default: undefined
43
- },
44
- error: {
45
- type: [String, Boolean],
46
- default: undefined
47
- },
48
- required: {
49
- type: Boolean,
50
- default: false
51
- },
52
- readonly: {
53
- type: Boolean,
54
- default: false
55
- },
56
- disabled: {
57
- type: Boolean,
58
- default: false
59
- },
60
- disableDefaultStyles: {
61
- type: Boolean,
62
- default: false
63
- }
64
- },
65
- setup() {
66
- // Refs
67
- const root = ref();
68
- // Styles
69
- const rootStyles = computed(() => ['or-combined-input-v3', ...CombinedInputRoot]);
70
- const controlGroup = computed(() => [...CombinedInputControlGroup]);
71
- return {
72
- root,
73
- rootStyles,
74
- controlGroup
75
- };
76
- }
77
- });
78
-
79
- const _hoisted_1 = {
80
- class: /*#__PURE__*/normalizeClass(['contents'])
81
- };
82
- const _hoisted_2 = {
83
- class: /*#__PURE__*/normalizeClass(['contents'])
84
- };
85
- function render(_ctx, _cache, $props, $setup, $data, $options) {
86
- const _component_OrLabel = resolveComponent("OrLabel");
87
- const _component_OrHint = resolveComponent("OrHint");
88
- const _component_OrError = resolveComponent("OrError");
89
- return openBlock(), createElementBlock("div", {
90
- ref: "root",
91
- class: normalizeClass(_ctx.rootStyles)
92
- }, [_ctx.label ? (openBlock(), createBlock(_component_OrLabel, {
93
- key: 0,
94
- variant: 'input',
95
- required: _ctx.required,
96
- disabled: _ctx.disabled
97
- }, {
98
- addon: withCtx(() => [renderSlot(_ctx.$slots, "addon")]),
99
- default: withCtx(() => [createTextVNode(toDisplayString(_ctx.label) + " ", 1 /* TEXT */)]),
100
-
101
- _: 3 /* FORWARDED */
102
- }, 8 /* PROPS */, ["required", "disabled"])) : createCommentVNode("v-if", true), createElementVNode("div", {
103
- class: normalizeClass(_ctx.controlGroup)
104
- }, [renderSlot(_ctx.$slots, "default", {
105
- size: _ctx.size,
106
- error: !!_ctx.error,
107
- required: _ctx.required,
108
- readonly: _ctx.readonly,
109
- disabled: _ctx.disabled,
110
- disableDefaultStyles: _ctx.disableDefaultStyles
111
- })], 2 /* CLASS */), withDirectives(createElementVNode("div", _hoisted_1, [_ctx.hint ? (openBlock(), createBlock(_component_OrHint, {
112
- key: 0,
113
- disabled: _ctx.disabled
114
- }, {
115
- default: withCtx(() => [createTextVNode(toDisplayString(_ctx.hint), 1 /* TEXT */)]),
116
-
117
- _: 1 /* STABLE */
118
- }, 8 /* PROPS */, ["disabled"])) : createCommentVNode("v-if", true)], 512 /* NEED_PATCH */), [[vShow, !_ctx.error]]), withDirectives(createElementVNode("div", _hoisted_2, [createVNode(_component_OrError, {
119
- disabled: _ctx.disabled
120
- }, {
121
- default: withCtx(() => [createTextVNode(toDisplayString(_ctx.error), 1 /* TEXT */)]),
122
-
123
- _: 1 /* STABLE */
124
- }, 8 /* PROPS */, ["disabled"])], 512 /* NEED_PATCH */), [[vShow, typeof _ctx.error === 'string']])], 2 /* CLASS */);
125
- }
126
-
127
- script.render = render;
128
- script.__file = "src/components/or-combined-input-v3/OrCombinedInput.vue";
129
-
130
- export { script as OrCombinedInputV3 };
3
+ import 'vue-demi';
4
+ import '../../OrError-c01d0c29.js';
5
+ import 'vue';
6
+ import '../../OrHint-06ab89d7.js';
7
+ import '../../OrLabel-4da56db0.js';
@@ -20,10 +20,11 @@ export { s as OrChips } from './OrChips-544a35b3.js';
20
20
  export { s as OrCode, O as OrCodeLanguages } from './OrCode-48281fc0.js';
21
21
  export { s as OrCollapse } from './OrCollapse-2b31de04.js';
22
22
  export { s as OrColorPicker, h as amber, n as black, b as blue, m as blueGrey, k as brown, c as cyan, j as deepOrange, d as deepPurple, g as green, i as indigo, l as lightBlue, e as lightGreen, f as lime, o as orange, p as pink, a as purple, r as red, t as teal, w as white, y as yellow } from './OrColorPicker-ffaaf14f.js';
23
+ export { s as OrCombinedInputV3 } from './OrCombinedInput-14c23a04.js';
24
+ export { I as CombinedInputSize, I as DatePickerSize, I as DateTimePickerSize, I as InputBoxSize, a as InputBoxVariant, I as InputSize, s as OrInputBoxV3, I as SearchSize, I as SelectSize, I as TextareaSize, I as TimePickerSize } from './OrInputBox-ba40bbdf.js';
23
25
  export { s as OrConfirm } from './OrConfirm-410da5b4.js';
24
26
  export { C as ConfirmType, s as OrConfirmV3 } from './OrConfirm-fe8617ac.js';
25
27
  export { s as OrDatePickerV3 } from './OrDatePicker-759653a5.js';
26
- export { I as DatePickerSize, I as DateTimePickerSize, I as InputBoxSize, a as InputBoxVariant, I as InputSize, s as OrInputBoxV3, I as SearchSize, I as SelectSize, I as TextareaSize, I as TimePickerSize } from './OrInputBox-ba40bbdf.js';
27
28
  export { D as DEFAULT_TEXT, s as OrDateTimePicker, a as OrDateTimePickerItemTypes, O as OrDateTimePickerTypes } from './OrDateTimePicker-2af19719.js';
28
29
  export { s as OrDateTimePickerV3 } from './OrDateTimePicker-4768a411.js';
29
30
  export { E as EmptyStateSize, s as OrEmptyStateV3 } from './OrEmptyState-5349a1f9.js';
@@ -33,6 +34,7 @@ export { s as OrErrorV3 } from './OrError-c01d0c29.js';
33
34
  export { a as ExpansionPanelColor, E as ExpansionPanelVariant, s as OrExpansionPanelV3 } from './OrExpansionPanel-c016d8fa.js';
34
35
  export { F as FabColor, s as OrFabV3 } from './OrFab-83cd7ed7.js';
35
36
  export { s as OrFloating, a as OrFloatingHideStrategy, O as OrFloatingPlacements } from './OrFloating-291c7653.js';
37
+ export { F as FormGroupDirection, s as OrFormGroupV3 } from './OrFormGroup-9f581536.js';
36
38
  export { s as OrHint } from './OrHint-1414c530.js';
37
39
  export { s as OrHintV3 } from './OrHint-06ab89d7.js';
38
40
  export { s as OrIcon, O as OrIconColors, a as OrIconType } from './OrIcon-b566a871.js';
@@ -127,7 +129,6 @@ import './style-inject.es-4c6f2515.js';
127
129
  import '@vueuse/core';
128
130
  import '@splidejs/splide';
129
131
  import '@splidejs/splide/dist/css/splide.min.css';
130
- import './OrFormGroup-9f581536.js';
131
132
  import '@codemirror/state';
132
133
  import '@codemirror/view';
133
134
  import '@codemirror/commands';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@onereach/ui-components",
3
- "version": "4.4.3",
3
+ "version": "4.4.4-beta.2722.0",
4
4
  "description": "Vue components library for v2/3",
5
5
  "sideEffects": false,
6
6
  "main": "./dist/auto/index.js",
@@ -153,6 +153,5 @@
153
153
  "default": "./dist/bundled/v3/components/*/index.js"
154
154
  },
155
155
  "./package.json": "./package.json"
156
- },
157
- "gitHead": "6a8baaffe1aa9419770937c168b8ed3f63df3b37"
156
+ }
158
157
  }
@@ -17,6 +17,7 @@ export * from './or-chips';
17
17
  export * from './or-code';
18
18
  export * from './or-collapse';
19
19
  export * from './or-color-picker';
20
+ export * from './or-combined-input-v3';
20
21
  export * from './or-confirm';
21
22
  export * from './or-confirm-v3';
22
23
  export * from './or-date-picker-v3';
@@ -29,6 +30,7 @@ export * from './or-error-v3';
29
30
  export * from './or-expansion-panel-v3';
30
31
  export * from './or-fab-v3';
31
32
  export * from './or-floating';
33
+ export * from './or-form-group-v3';
32
34
  export * from './or-hint';
33
35
  export * from './or-hint-v3';
34
36
  export * from './or-icon';
@@ -45,6 +45,8 @@ const defaultMixin = (argTypes: ArgTypes) => ({
45
45
  });
46
46
 
47
47
  const Template: Story = (_args, { argTypes }) => ({
48
+ // eslint-disable-next-line @typescript-eslint/ban-ts-comment
49
+ // @ts-ignore
48
50
  mixins: [defaultMixin(argTypes)],
49
51
  template: `
50
52
  <or-button
@@ -59,6 +61,8 @@ const Template: Story = (_args, { argTypes }) => ({
59
61
  });
60
62
 
61
63
  const TemplateSlotPrepend: Story = (_args, { argTypes }) => ({
64
+ // eslint-disable-next-line @typescript-eslint/ban-ts-comment
65
+ // @ts-ignore
62
66
  mixins: [defaultMixin(argTypes)],
63
67
  template: `
64
68
  <or-button
@@ -74,6 +78,8 @@ const TemplateSlotPrepend: Story = (_args, { argTypes }) => ({
74
78
  });
75
79
 
76
80
  const TemplateSlotAppend: Story = (_args, { argTypes }) => ({
81
+ // eslint-disable-next-line @typescript-eslint/ban-ts-comment
82
+ // @ts-ignore
77
83
  mixins: [defaultMixin(argTypes)],
78
84
  template: `
79
85
  <or-button
@@ -89,6 +95,8 @@ const TemplateSlotAppend: Story = (_args, { argTypes }) => ({
89
95
  });
90
96
 
91
97
  const TemplateIcon: Story = (_args, { argTypes }) => ({
98
+ // eslint-disable-next-line @typescript-eslint/ban-ts-comment
99
+ // @ts-ignore
92
100
  mixins: [defaultMixin(argTypes)],
93
101
  template: `
94
102
  <div style="padding: 50px; margin: 0 auto; width: fit-content;">
@@ -1,7 +0,0 @@
1
- import { DocsPage } from '@storybook/addon-docs';
2
-
3
- ```ts
4
- import { OrBottomSheetV3 as OrBottomSheet } from '@onereach/ui-components';
5
- ```
6
-
7
- <DocsPage />
@@ -1,110 +0,0 @@
1
- import { action } from '@storybook/addon-actions';
2
- import { Meta, StoryFn } from '@storybook/vue3';
3
- import { ref } from 'vue-demi';
4
- import { OrButtonV3 as OrButton } from '../or-button-v3';
5
- import { OrMenuItemV3 as OrMenuItem } from '../or-menu-item-v3';
6
- import OrBottomSheetDocs from './OrBottomSheet.docs.mdx';
7
- import OrBottomSheet from './OrBottomSheet.vue';
8
- import { BottomSheetVariant } from './props';
9
-
10
- export default {
11
- title: 'Components/Bottom Sheet',
12
- component: OrBottomSheet,
13
-
14
- argTypes: {
15
- // Slots
16
- header: {
17
- type: {
18
- name: 'string',
19
- required: false,
20
- },
21
-
22
- control: { type: 'text' },
23
- },
24
-
25
- default: {
26
- type: {
27
- name: 'string',
28
- required: true,
29
- },
30
-
31
- control: { type: 'text' },
32
- },
33
-
34
- // Props
35
- variant: {
36
- control: { type: 'select' },
37
- options: Object.values(BottomSheetVariant),
38
- },
39
-
40
- // Events
41
- 'update:state': {
42
- table: { disable: true },
43
- },
44
- },
45
-
46
- parameters: {
47
- layout: 'centered',
48
-
49
- docs: {
50
- page: OrBottomSheetDocs,
51
- },
52
-
53
- design: {
54
- type: 'figma',
55
- url: 'https://www.figma.com/file/o7DdkaznUW2PtX4wiSuhhQ/Core?node-id=2793%3A15600',
56
- },
57
- },
58
- } as Meta<typeof OrBottomSheet>;
59
-
60
- const Template: StoryFn<typeof OrBottomSheet> = (args) => ({
61
- components: {
62
- OrBottomSheet,
63
- OrButton,
64
- OrMenuItem,
65
- },
66
-
67
- setup() {
68
- // Refs
69
- const bottomSheet = ref<InstanceType<typeof OrBottomSheet>>();
70
-
71
- return {
72
- args,
73
- bottomSheet,
74
- onUpdateState: action('update:state'),
75
- };
76
- },
77
-
78
- template: `
79
- <div class="contents">
80
- <OrButton @click="bottomSheet.open()">Open</OrButton>
81
-
82
- <OrBottomSheet
83
- ref="bottomSheet"
84
- v-bind="args"
85
- @update:state="onUpdateState"
86
- >
87
- <template #header>
88
- ${args.header}
89
- </template>
90
-
91
- ${args.default}
92
- </OrBottomSheet>
93
- </div>
94
- `,
95
- });
96
-
97
- export const BottomSheet = Template.bind({});
98
-
99
- BottomSheet.args = {
100
- // Slots
101
- header: 'Title',
102
-
103
- default: `
104
- <OrMenuItem>Item 1</OrMenuItem>
105
- <OrMenuItem>Item 2</OrMenuItem>
106
- <OrMenuItem>Item 3</OrMenuItem>
107
- <OrMenuItem>Item 4</OrMenuItem>
108
- <OrMenuItem>Item 5</OrMenuItem>
109
- `,
110
- };
@@ -1,14 +0,0 @@
1
- import { DocsPage } from '@storybook/addon-docs';
2
-
3
- ```ts
4
- import { OrButtonV3 as OrButton } from '@onereach/ui-components';
5
- ```
6
-
7
- <DocsPage />
8
-
9
- ## Migration Guide from V1
10
- - property `type` renamed to `variant`
11
- - property `htmlButtonType` renamed to `type`
12
- - property `isDisabled` renamed to `disabled`
13
- - property `isLoading` renamed to `loading`
14
- - removed properties `content`, `size`, `icon`, `iconPosition`, and `loadingType`
@@ -1,130 +0,0 @@
1
- import { action } from '@storybook/addon-actions';
2
- import { Meta, StoryFn } from '@storybook/vue3';
3
- import { OrIconV3 as OrIcon } from '../or-icon-v3';
4
- import OrButtonDocs from './OrButton.docs.mdx';
5
- import OrButton from './OrButton.vue';
6
- import { ButtonColor, ButtonType, ButtonVariant } from './props';
7
-
8
- export default {
9
- title: 'Components/Buttons/Button',
10
- component: OrButton,
11
-
12
- argTypes: {
13
- // Slots
14
- default: {
15
- type: {
16
- name: 'string',
17
- required: true,
18
- },
19
-
20
- control: { type: 'text' },
21
- },
22
-
23
- // Props
24
- type: {
25
- control: { type: 'select' },
26
- options: Object.values(ButtonType),
27
- },
28
-
29
- variant: {
30
- control: { type: 'select' },
31
- options: Object.values(ButtonVariant),
32
- },
33
-
34
- color: {
35
- control: { type: 'select' },
36
- options: Object.values(ButtonColor),
37
- },
38
-
39
- activated: {
40
- table: { disable: true },
41
- },
42
-
43
- disabled: {
44
- control: { type: 'boolean' },
45
- },
46
-
47
- loading: {
48
- control: { type: 'boolean' },
49
- },
50
-
51
- loadingText: {
52
- control: { type: 'text' },
53
- },
54
- },
55
-
56
- parameters: {
57
- layout: 'centered',
58
-
59
- docs: {
60
- page: OrButtonDocs,
61
- },
62
-
63
- design: {
64
- type: 'figma',
65
- url: 'https://www.figma.com/file/o7DdkaznUW2PtX4wiSuhhQ/Core?node-id=202%3A9',
66
- },
67
- },
68
- } as Meta<typeof OrButton>;
69
-
70
- const Template: StoryFn<typeof OrButton> = (args) => ({
71
- components: {
72
- OrButton,
73
- OrIcon,
74
- },
75
-
76
- setup() {
77
- return {
78
- args,
79
- handleClick: action('click'),
80
- handleFocus: action('focus'),
81
- handleBlur: action('blur'),
82
- handleMouseover: action('mouseover'),
83
- handleMouseout: action('moouseout'),
84
- handleMousemove: action('moousemove'),
85
- handleMouseenter: action('mouseenter'),
86
- handleMouseleave: action('museleave'),
87
- };
88
- },
89
-
90
- template: `
91
- <OrButton
92
- v-bind="args"
93
- @click="handleClick"
94
- @focus="handleFocus"
95
- @blur="handleBlur"
96
- @mouseover="handleMouseover"
97
- @mouseout="handleMouseout"
98
- @mousemove="handleMousemove"
99
- @mouseenter="handleMouseenter"
100
- @mouseleave="handleMouseleave"
101
- class="test-class"
102
- >
103
- ${args.default}
104
- </OrButton>
105
- `,
106
- });
107
-
108
- export const Default = Template.bind({});
109
-
110
- Default.args = {
111
- // Slots
112
- default: 'Button',
113
- };
114
-
115
- export const WithIcons = Template.bind({});
116
-
117
- WithIcons.args = {
118
- // Slots
119
- default: '<OrIcon icon="photo" /> Button',
120
- };
121
-
122
- export const Link = Template.bind({});
123
-
124
- Link.args = {
125
- // Slots
126
- default: 'Link <OrIcon icon="arrow_drop_down" />',
127
-
128
- // Props
129
- variant: ButtonVariant.Link,
130
- };
@@ -1,7 +0,0 @@
1
- import { DocsPage } from '@storybook/addon-docs';
2
-
3
- <DocsPage />
4
-
5
- ## Migration Guide from V1
6
-
7
- Component refactored completely, see new stories and code snippets