@orchidui/core 0.4.0 → 0.6.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 (155) hide show
  1. package/dist/DataDisplay/CustomerCard/OcCustomerCard.js +1 -1
  2. package/dist/DataDisplay/FloatContent/OcFloatContent.js +1 -1
  3. package/dist/DataDisplay/InfoCard/OcInfoCard.js +1 -1
  4. package/dist/DataDisplay/ListDetail/OcListDetail.js +1 -1
  5. package/dist/DataDisplay/ListItem/OcListItem.js +3 -3
  6. package/dist/DataDisplay/OnboardingListItem/OcOnboardingListItem.js +1 -1
  7. package/dist/DataDisplay/Overview/OcOverview.js +4 -5
  8. package/dist/DataDisplay/Pagination/OcPagination.js +1 -1
  9. package/dist/DataDisplay/Table/OcTable.js +4 -4
  10. package/dist/DataDisplay/TransferSummary/OcTransferSummary.js +1 -1
  11. package/dist/DataTable/utils/editColumnsUtils.js +29 -0
  12. package/dist/Disclosure/Accordion/OcAccordion.js +1 -1
  13. package/dist/Disclosure/OnboardingAccordion/OnboardingAccordion.js +1 -1
  14. package/dist/Disclosure/Steps/OcSteps.js +3 -3
  15. package/dist/Disclosure/Tabs/Tabs.js +1 -1
  16. package/dist/Disclosure/Variants/OcVariants.js +1 -1
  17. package/dist/Elements/AdditionalContent/OcAdditionalContent.js +2 -2
  18. package/dist/Elements/AuthenticationOption/AuthenticationOption.js +2 -2
  19. package/dist/Elements/Box/OcBox.js +2 -2
  20. package/dist/Elements/EmptyPage/OcEmptyPage.js +1 -1
  21. package/dist/Elements/FeatureOverviewCard/OcFeatureOverviewCard.js +1 -1
  22. package/dist/Elements/Header/OcHeader.js +3 -3
  23. package/dist/Elements/PageTitle/OcPageTitle.js +3 -4
  24. package/dist/Elements/SandboxBanner/OcSandboxBanner.js +1 -1
  25. package/dist/Elements/Sidebar/OcSidebar.js +1 -1
  26. package/dist/Elements/Skeleton/OcSkeleton.js +1 -1
  27. package/dist/Elements/SubSidebar/OcSubSidebar.js +1 -1
  28. package/dist/Elements/VerificationOption/OcVerificationOption.js +2 -2
  29. package/dist/Feedback/Banner/OcBanner.js +1 -1
  30. package/dist/Feedback/Chip/OcChip.js +2 -2
  31. package/dist/Feedback/ShareIcon/OcShareIcon.js +2 -2
  32. package/dist/Feedback/Snackbar/OcSnackbar.js +1 -1
  33. package/dist/Form/BaseInput/OcBaseInput.js +1 -1
  34. package/dist/Form/Button/OcButton.js +1 -1
  35. package/dist/Form/Calendar/OcCalendar.js +2 -2
  36. package/dist/Form/CardInput/OcCardInput.js +1 -1
  37. package/dist/Form/Checkbox/OcCheckbox.js +1 -1
  38. package/dist/Form/CheckboxesGroup/OcCheckboxesGroup.js +1 -1
  39. package/dist/Form/Criteria/OcCriteria.js +1 -1
  40. package/dist/Form/Cropper/OcCropper.js +1 -1
  41. package/dist/Form/DatePicker/OcDatePicker.js +1 -1
  42. package/dist/Form/EmojiPicker/OcEmojiPicker.js +2 -2
  43. package/dist/Form/Input/OcInput.js +3 -4
  44. package/dist/Form/LinkInput/OcLinkInput.js +1 -1
  45. package/dist/Form/MultipleUploadFile/OcMultipleUploadFile.js +1 -1
  46. package/dist/Form/NumberInput/OcNumberInput.js +1 -1
  47. package/dist/Form/PhoneInput/OcPhoneInput.js +1 -1
  48. package/dist/Form/Radio/OcRadio.js +1 -1
  49. package/dist/Form/RadioGroup/OcRadioGroup.js +1 -1
  50. package/dist/Form/RangeInput/OcRangeInput.js +1 -1
  51. package/dist/Form/SectionItem/OcSectionItem.js +2 -2
  52. package/dist/Form/Select/OcSelect.js +4 -5
  53. package/dist/Form/SelectOptions/OcSelectOptions.js +2 -2
  54. package/dist/Form/SingleFileUpload/OcSingleFileUpload.js +1 -1
  55. package/dist/Form/Slider/OcSlider.js +1 -1
  56. package/dist/Form/TextArea/OcTextArea.js +2 -2
  57. package/dist/Form/Toggle/OcToggle.js +1 -1
  58. package/dist/Form/index.js +24 -47
  59. package/dist/FormBuilder/OcFormBuilder.js +1 -1
  60. package/dist/{OcComplexCalendar-x-_kg9Yk.js → OcComplexCalendar-Boa7mNFU.js} +18 -25
  61. package/dist/OcComplexDatePicker-BydI4VSR.js +93 -0
  62. package/dist/{OcCropper-31Y_S1Ne.js → OcCropper-7E2i6ayU.js} +38 -49
  63. package/dist/OcDataTable-CsCGrRx7.js +561 -0
  64. package/dist/{OcDraggable-BjhGJmpM.js → OcDraggable-CA_BCbpl.js} +7 -8
  65. package/dist/{Draggable.js → OcDraggableList-BUu5SgoA.js} +40 -50
  66. package/dist/{OcEmojiPicker-BXm-_OGK.js → OcEmojiPicker-DYYK7OB3.js} +28 -38
  67. package/dist/OcFilterForm-7ehuJUMp.js +83 -0
  68. package/dist/OcFilterSearch-B4AZsLBn.js +69 -0
  69. package/dist/OcFilterSearchFor-DfwJG-5N.js +67 -0
  70. package/dist/OcModalCropper-Z4jlnFc5.js +46 -0
  71. package/dist/{OcSkeleton-BdPTmGh0.js → OcSkeleton-CvdpGSQR.js} +2 -3
  72. package/dist/{OcSlider-Bsi-ckbP.js → OcSlider-DW9x8eas.js} +10 -11
  73. package/dist/{OcTimePicker-B61MCi0D.js → OcTimePicker-D9fPU8_m.js} +22 -33
  74. package/dist/{OcTimePopup-zQFKCZLk.js → OcTimePopup-CXGhaOev.js} +2 -3
  75. package/dist/{OcToggle-C0wTjM_Y.js → OcToggle-bIJaLDMZ.js} +5 -6
  76. package/dist/Overlay/ConfirmationModal/OcConfirmationModal.js +1 -1
  77. package/dist/Overlay/CopyTooltip/OcCopyTooltip.js +1 -1
  78. package/dist/Overlay/Dropdown/OcDropdown.js +3 -4
  79. package/dist/Overlay/Modal/OcModal.js +3 -4
  80. package/dist/Overlay/SupportMenu/OcSupportMenu.js +1 -1
  81. package/dist/Overlay/Tooltip/OcTooltip.js +2 -2
  82. package/dist/Overlay/Whitelist/OcWhiteList.js +2 -2
  83. package/dist/SubPlanCard-DHj4RHJZ.js +81 -0
  84. package/dist/ThumbnailSection-CJBS0QXp.js +41 -0
  85. package/dist/ThumbnailTheme-hey6se0g.js +119 -0
  86. package/dist/index-DyVteXE3.js +10028 -0
  87. package/dist/index.js +129 -175
  88. package/dist/style.css +1 -1
  89. package/package.json +1 -16
  90. package/dist/Calendar.js +0 -103
  91. package/dist/Cropper.js +0 -6
  92. package/dist/DatePicker-D3w435Ml.js +0 -263
  93. package/dist/EmojiPicker.js +0 -4
  94. package/dist/Form/TimePicker/OcTimePicker.js +0 -6
  95. package/dist/OcAccordion-DdkNsXvN.js +0 -101
  96. package/dist/OcAccountSetup-BXDjf48o.js +0 -324
  97. package/dist/OcAdditionalContent-BMSysCXu.js +0 -612
  98. package/dist/OcAuthenticationOption.vue_vue_type_script_setup_true_lang-w5Y0ymGN.js +0 -43
  99. package/dist/OcBanner-Cg2WJV6e.js +0 -108
  100. package/dist/OcBox.vue_vue_type_script_setup_true_lang-aB397QRg.js +0 -43
  101. package/dist/OcCardInput-BFE4Xu-S.js +0 -75
  102. package/dist/OcCheckboxesGroup-CLbquUO2.js +0 -94
  103. package/dist/OcChip-B1hm2Qni.js +0 -144
  104. package/dist/OcComplexCalendar.vue_vue_type_style_index_0_lang-CIQPD-6N.js +0 -1006
  105. package/dist/OcConfirmationModal-BfCrRV9r.js +0 -179
  106. package/dist/OcCopyTooltip.vue_vue_type_script_setup_true_lang-S2RAfV_g.js +0 -65
  107. package/dist/OcCriteria-CpIohheZ.js +0 -42
  108. package/dist/OcCustomerCard-DbDOBO03.js +0 -160
  109. package/dist/OcDropdownItem-DAElmzEu.js +0 -57
  110. package/dist/OcEmptyPage-CTwgMzRp.js +0 -155
  111. package/dist/OcExpadingTable.vue_vue_type_script_setup_true_lang-B4HOMDBK.js +0 -815
  112. package/dist/OcFeatureOverviewCard-RVyrWLVW.js +0 -71
  113. package/dist/OcFloatContent-BIKQOxSw.js +0 -142
  114. package/dist/OcFormBuilder-CRXWtt8I.js +0 -177
  115. package/dist/OcGroupOptions-ChGJvTXl.js +0 -16
  116. package/dist/OcInfoCard-DpYUZOMZ.js +0 -81
  117. package/dist/OcInput-tcRxG3Y2.js +0 -227
  118. package/dist/OcInputOption-CncASfNt.js +0 -160
  119. package/dist/OcLinkInput-C2ixk-gk.js +0 -143
  120. package/dist/OcListDetail-6XeME6ko.js +0 -76
  121. package/dist/OcListUrl.vue_vue_type_script_setup_true_lang-7zZdFM8K.js +0 -750
  122. package/dist/OcModal-DdD5VFEN.js +0 -187
  123. package/dist/OcModalCropper-D2OI2iun.js +0 -56
  124. package/dist/OcModalPage-BLVa-kcB.js +0 -86
  125. package/dist/OcMultipleUploadFile-B8Wl9Fuq.js +0 -446
  126. package/dist/OcNumberInput.vue_vue_type_script_setup_true_lang-C4EXUIUe.js +0 -90
  127. package/dist/OcOnboardingListItem.vue_vue_type_script_setup_true_lang-Cr80xmnz.js +0 -81
  128. package/dist/OcOption-DK2FBGq7.js +0 -485
  129. package/dist/OcOverviewIcon-D702Ujka.js +0 -55
  130. package/dist/OcOverviewItem-DNr5tWnt.js +0 -186
  131. package/dist/OcPageTitleRight-DMtJ1qmZ.js +0 -243
  132. package/dist/OcPaginationNumber-IKPorX26.js +0 -172
  133. package/dist/OcPaymentTab-Cna1IAhO.js +0 -170
  134. package/dist/OcPhoneInput-AC6BgQhN.js +0 -432
  135. package/dist/OcPrimaryActions-D5IprKsQ.js +0 -222
  136. package/dist/OcRadio-CRYfNwV9.js +0 -107
  137. package/dist/OcRadioGroup-DgfdWJos.js +0 -76
  138. package/dist/OcRangeInput-C-hoHFhr.js +0 -103
  139. package/dist/OcSandboxBanner.vue_vue_type_script_setup_true_lang-BD0k_8xa.js +0 -37
  140. package/dist/OcSectionItem-BFgxO3se.js +0 -84
  141. package/dist/OcSelectOptions-BQlG_EUA.js +0 -148
  142. package/dist/OcShareIcon-BB-NPq0r.js +0 -53
  143. package/dist/OcSingleFileUpload-B8-e1H5t.js +0 -464
  144. package/dist/OcSnackbar-CKxY1-ej.js +0 -196
  145. package/dist/OcSteps.vue_vue_type_script_setup_true_lang-CXGy8ma_.js +0 -87
  146. package/dist/OcSubSidebar.vue_vue_type_script_setup_true_lang-CNxgU07N.js +0 -60
  147. package/dist/OcSupportMenu.vue_vue_type_script_setup_true_lang-DrjZsWti.js +0 -114
  148. package/dist/OcTabToSelect-BHAz1Niv.js +0 -183
  149. package/dist/OcTextArea-BpV1Bnj_.js +0 -78
  150. package/dist/OcTransferSummary-Bk2GXhrT.js +0 -67
  151. package/dist/OcVariant.vue_vue_type_script_setup_true_lang-CY_82DLc.js +0 -99
  152. package/dist/OcVerificationOption.vue_vue_type_script_setup_true_lang-ChqvNoDe.js +0 -59
  153. package/dist/OcWhiteList.vue_vue_type_script_setup_true_lang-DI9pYU3w.js +0 -64
  154. package/dist/OnboardingAccordion.vue_vue_type_script_setup_true_lang-B0Z7ETmj.js +0 -113
  155. package/dist/StoreDesign.js +0 -240
@@ -1,263 +0,0 @@
1
- import { ref as b, computed as S, openBlock as f, createBlock as V, unref as c, withCtx as p, renderSlot as R, createCommentVNode as k, createElementVNode as i, createElementBlock as F, Fragment as A, createVNode as x, toDisplayString as E, normalizeClass as M, withKeys as B, withModifiers as U } from "vue";
2
- import d from "dayjs";
3
- import { c as j, D as K, b as O, _ as P } from "./OcComplexCalendar.vue_vue_type_style_index_0_lang-CIQPD-6N.js";
4
- import { _ as $ } from "./OcIcon-CJgBICxh.js";
5
- /* empty css */
6
- import { _ as T } from "./OcInput-tcRxG3Y2.js";
7
- import "libphonenumber-js";
8
- /* empty css */
9
- import { _ as L } from "./OcComplexCalendar-x-_kg9Yk.js";
10
- /* empty css */
11
- import "./Cropper.js";
12
- import "vue-draggable-next";
13
- import "@popperjs/core";
14
- const z = { class: "flex flex-col gap-y-2 w-full" }, G = { class: "flex w-full" }, H = {
15
- key: 0,
16
- class: "text-sm text-oc-error flex items-center"
17
- }, J = {
18
- key: 1,
19
- class: "flex flex-wrap cursor-pointer"
20
- }, Q = { class: "flex items-center gap-x-3" }, W = ["value"], X = { class: "flex items-center gap-x-3" }, Z = ["value"], fe = {
21
- __name: "DatePicker",
22
- props: {
23
- modelValue: {
24
- type: [String, Date, Number, Array]
25
- },
26
- type: {
27
- type: String,
28
- default: "default",
29
- validator: (e) => ["default", "range"].includes(e)
30
- },
31
- disabledDate: {
32
- type: Function,
33
- default: () => !1
34
- },
35
- minDate: {
36
- type: [String, Date, Number],
37
- default: null
38
- },
39
- maxDate: {
40
- type: [String, Date, Number],
41
- default: null
42
- },
43
- dateFormat: {
44
- type: String,
45
- default: "YYYY-MM-DD"
46
- },
47
- disabled: {
48
- type: Boolean,
49
- default: !1
50
- },
51
- errorMessage: {
52
- type: String,
53
- default: ""
54
- },
55
- label: {
56
- type: String,
57
- default: ""
58
- },
59
- hint: {
60
- type: String,
61
- default: ""
62
- },
63
- placeholder: {
64
- type: String,
65
- default: "YYYY-MM-DD"
66
- },
67
- isSplitInput: {
68
- type: Boolean,
69
- default: !0
70
- },
71
- minLabel: {
72
- type: String,
73
- default: "From"
74
- },
75
- maxLabel: {
76
- type: String,
77
- default: "To"
78
- },
79
- isRequired: {
80
- type: Boolean,
81
- default: !1
82
- },
83
- isIndefinite: {
84
- type: Boolean,
85
- default: !1
86
- },
87
- disabledRange: {
88
- type: Object,
89
- default: () => ({
90
- start: null,
91
- end: null
92
- })
93
- },
94
- countCalendars: {
95
- type: Number,
96
- default: 2
97
- },
98
- shortcuts: {
99
- type: Array,
100
- default: () => []
101
- }
102
- },
103
- emits: ["update:modelValue", "resetCalendar", "error"],
104
- setup(e, { emit: Y }) {
105
- d.extend(j);
106
- const s = Y, t = e, m = b(!1), w = b(!1), y = b(!1), r = b([]), v = S(() => t.type === "range"), o = S(() => v.value ? t.modelValue && t.modelValue[0] ? [
107
- d(t.modelValue[0], t.dateFormat),
108
- d(t.modelValue[1], t.dateFormat)
109
- ] : ["", ""] : t.modelValue ? d(t.modelValue, t.dateFormat) : ""), h = (a) => {
110
- t.type === "range" ? s(
111
- "update:modelValue",
112
- a ? [
113
- d(a.start).format(t.dateFormat),
114
- d(a.end).format(t.dateFormat)
115
- ] : []
116
- ) : s("update:modelValue", d(a).format(t.dateFormat)), m.value = !1;
117
- }, D = () => {
118
- s("resetCalendar"), s("update:modelValue", v.value ? [] : null), m.value = !1;
119
- }, q = (a) => {
120
- const l = d(a);
121
- return ((u) => u.get("month") === d().get("month"))(l);
122
- }, N = (a) => {
123
- w.value = a, s("update:modelValue", a ? "Indefinite" : null);
124
- }, I = (a, l) => {
125
- var u;
126
- const n = d(a, t.dateFormat, !0);
127
- r.value[l] = n.format(t.dateFormat), r.value[l ? 0 : 1] = ((u = t.modelValue) == null ? void 0 : u[l ? 0 : 1]) || d().format(t.dateFormat);
128
- }, g = () => {
129
- if (r.value.length) {
130
- if (y.value = !1, r.value.some((a) => !d(a, t.dateFormat).isValid())) {
131
- y.value = !0, r.value = [];
132
- return;
133
- }
134
- t.maxDate && (r.value = r.value.map(
135
- (a) => d(a, t.dateFormat).isSameOrBefore(d(t.maxDate)) ? a : d(t.maxDate).format(t.dateFormat)
136
- )), s("update:modelValue", r.value), r.value = [];
137
- }
138
- };
139
- return (a, l) => (f(), V(c(K), {
140
- modelValue: m.value,
141
- "onUpdate:modelValue": l[3] || (l[3] = (n) => m.value = n),
142
- "is-disabled": e.disabled,
143
- placement: "bottom-start",
144
- distance: 10,
145
- class: "w-full"
146
- }, {
147
- menu: p(({ isPopoverOpen: n }) => [
148
- R(a.$slots, "menu", {
149
- isPopoverOpen: n,
150
- updateCalendar: h,
151
- resetCalendar: D
152
- }, () => {
153
- var u, C;
154
- return [
155
- v.value ? (f(), V(L, {
156
- key: 0,
157
- "model-value": {
158
- start: (u = e.modelValue) == null ? void 0 : u[0],
159
- end: (C = e.modelValue) == null ? void 0 : C[1]
160
- },
161
- shortcuts: e.shortcuts,
162
- "count-calendars": e.countCalendars,
163
- "is-range": "",
164
- "with-footer": !1,
165
- "min-date": e.minDate,
166
- "max-date": e.maxDate,
167
- masks: { modelValue: e.dateFormat },
168
- "onUpdate:modelValue": h
169
- }, null, 8, ["model-value", "shortcuts", "count-calendars", "min-date", "max-date", "masks"])) : !e.disabled && n ? (f(), V(c(O), {
170
- key: 1,
171
- "model-value": o.value ? o.value.toDate() : /* @__PURE__ */ new Date(),
172
- "disabled-date": w.value ? q : e.disabledDate,
173
- "max-date": e.maxDate,
174
- "min-date": e.minDate,
175
- "is-indefinite": e.isIndefinite,
176
- position: "inline",
177
- type: e.type,
178
- "onUpdate:modelValue": h,
179
- "onUpdate:isIndefinite": N,
180
- onResetCalendar: D
181
- }, null, 8, ["model-value", "disabled-date", "max-date", "min-date", "is-indefinite", "type"])) : k("", !0)
182
- ];
183
- })
184
- ]),
185
- default: p(() => [
186
- i("div", z, [
187
- !e.isSplitInput || !v.value ? (f(), F(A, { key: 0 }, [
188
- i("div", G, [
189
- x(c(T), {
190
- "model-value": v.value ? e.modelValue && e.modelValue[0] ? `${o.value[0].format(e.dateFormat)} - ${o.value[1].format(e.dateFormat)}` : "" : e.modelValue === "Indefinite" ? "Indefinite" : e.modelValue ? o.value.format(e.dateFormat) : "",
191
- icon: "calendar",
192
- label: e.label,
193
- hint: e.hint,
194
- "is-required": e.isRequired,
195
- disabled: e.disabled,
196
- placeholder: e.placeholder
197
- }, null, 8, ["model-value", "label", "hint", "is-required", "disabled", "placeholder"])
198
- ]),
199
- e.errorMessage ? (f(), F("div", H, E(e.errorMessage), 1)) : k("", !0)
200
- ], 64)) : (f(), F("div", J, [
201
- x(c(P), {
202
- "error-message": y.value ? `Invalid Date. Try this format (${e.dateFormat})` : e.errorMessage,
203
- hint: e.hint,
204
- "is-required": e.isRequired,
205
- label: e.label
206
- }, {
207
- default: p(() => [
208
- i("div", {
209
- class: M(["rounded justify-between border flex items-center gap-3 h-[36px] px-3", [
210
- e.errorMessage || y.value ? "border-oc-error shadow-oc-error" : "border-oc-gray-200 shadow-oc-gray-200",
211
- e.disabled ? "pointer-events-none bg-oc-bg-dark" : "bg-white",
212
- {
213
- "shadow-[0_0_0_2px]": m.value && !e.disabled
214
- }
215
- ]]),
216
- onClick: l[2] || (l[2] = (n) => m.value ? n.stopPropagation : null)
217
- }, [
218
- i("div", Q, [
219
- x(c($), {
220
- name: "calendar",
221
- class: "text-oc-text-400"
222
- }),
223
- i("input", {
224
- placeholder: "Start date",
225
- value: o.value[0] ? o.value[0].format(e.dateFormat) : "",
226
- class: "text-center bg-transparent outline-0 w-full placeholder:text-oc-text-300",
227
- onInput: l[0] || (l[0] = (n) => I(n.target.value, 0)),
228
- onKeydown: B(g, ["enter"]),
229
- onBlur: g
230
- }, null, 40, W)
231
- ]),
232
- l[4] || (l[4] = i("span", { class: "text-oc-text-400" }, "To", -1)),
233
- i("div", X, [
234
- i("input", {
235
- placeholder: "End date",
236
- value: o.value[1] ? o.value[1].format(e.dateFormat) : "",
237
- class: "text-center bg-transparent outline-0 w-full placeholder:text-oc-text-300",
238
- onInput: l[1] || (l[1] = (n) => I(n.target.value, 1)),
239
- onKeydown: B(g, ["enter"]),
240
- onBlur: g
241
- }, null, 40, Z),
242
- x(c($), {
243
- class: M([o.value.every(Boolean) ? "opacity-100" : "opacity-0", "text-oc-text-400"]),
244
- width: "16",
245
- height: "16",
246
- name: "filled-x-circle",
247
- onClick: U(D, ["stop"])
248
- }, null, 8, ["class"])
249
- ])
250
- ], 2)
251
- ]),
252
- _: 1
253
- }, 8, ["error-message", "hint", "is-required", "label"])
254
- ]))
255
- ])
256
- ]),
257
- _: 3
258
- }, 8, ["modelValue", "is-disabled"]));
259
- }
260
- };
261
- export {
262
- fe as _
263
- };
@@ -1,4 +0,0 @@
1
- import { O as e } from "./OcEmojiPicker-BXm-_OGK.js";
2
- export {
3
- e as EmojiPicker
4
- };
@@ -1,6 +0,0 @@
1
- import { default as r } from "../../OcTimePopup-zQFKCZLk.js";
2
- import { _ as p } from "../../OcTimePicker-B61MCi0D.js";
3
- export {
4
- p as TimePicker,
5
- r as TimePopup
6
- };
@@ -1,101 +0,0 @@
1
- import { ref as u, watch as b, onUpdated as y, openBlock as l, createElementBlock as x, normalizeClass as a, createElementVNode as n, renderSlot as s, createTextVNode as c, toDisplayString as m, createBlock as p, unref as f, createCommentVNode as h, nextTick as g } from "vue";
2
- import "dayjs";
3
- import "./OcComplexCalendar.vue_vue_type_style_index_0_lang-CIQPD-6N.js";
4
- import { _ as E } from "./OcIcon-CJgBICxh.js";
5
- /* empty css */
6
- import "libphonenumber-js";
7
- /* empty css */
8
- import "v-calendar";
9
- /* empty css */
10
- import "./Cropper.js";
11
- import "vue-draggable-next";
12
- import "@popperjs/core";
13
- const I = {
14
- __name: "OcAccordion",
15
- props: {
16
- header: {
17
- type: String,
18
- default: ""
19
- },
20
- headerStyle: {
21
- type: String,
22
- default: ""
23
- },
24
- body: {
25
- type: String,
26
- default: ""
27
- },
28
- bodyStyle: {
29
- type: String,
30
- default: ""
31
- },
32
- icon: {
33
- type: String,
34
- default: "chevron-down"
35
- },
36
- showIcon: {
37
- type: Boolean,
38
- default: !0
39
- },
40
- isAnimated: {
41
- type: Boolean,
42
- default: !0
43
- },
44
- isExpandable: {
45
- type: Boolean,
46
- default: !1
47
- },
48
- isDisabled: {
49
- type: Boolean,
50
- default: !1
51
- }
52
- },
53
- emits: {
54
- "update:isExpandable": []
55
- },
56
- setup(e) {
57
- const i = u(), o = e, r = async (t) => {
58
- await g(), i.value && (i.value.style.maxHeight = t ? "max-content" : "0");
59
- };
60
- return b(() => o.isExpandable, r), y(() => {
61
- r(o.isExpandable);
62
- }), (t, d) => (l(), x("div", {
63
- class: a(e.isDisabled && "opacity-60")
64
- }, [
65
- n("div", null, [
66
- n("div", {
67
- class: a(["border-oc-accent-1-50 py-3 text-sm border z-10 justify-between px-4 gap-x-3 flex hover:border-oc-gray-200 items-center w-full text-oc-text", [
68
- e.isExpandable ? "rounded-t border-oc-gray-200" : "rounded border-transparent",
69
- e.headerStyle
70
- ]]),
71
- onClick: d[0] || (d[0] = (v) => o.isDisabled ? null : t.$emit("update:isExpandable", !o.isExpandable))
72
- }, [
73
- s(t.$slots, "header", {}, () => [
74
- c(m(e.header), 1)
75
- ]),
76
- e.showIcon ? (l(), p(f(E), {
77
- key: 0,
78
- name: e.icon,
79
- class: a(["text-oc-text-400 w-4 h-4 shrink-0", [e.isExpandable && "-rotate-180", e.isAnimated && "transition-all duration-300"]])
80
- }, null, 8, ["name", "class"])) : h("", !0)
81
- ], 2),
82
- n("div", {
83
- ref_key: "upcomingAccordion",
84
- ref: i,
85
- class: a(["max-h-0", [e.isAnimated && "transition-all duration-300", !e.isExpandable && "overflow-hidden"]])
86
- }, [
87
- n("div", {
88
- class: a(["text-oc-text text-sm p-4 rounded-b z-0 border-x border-b", [e.isExpandable ? "border-oc-gray-200" : " border-transparent", e.bodyStyle]])
89
- }, [
90
- s(t.$slots, "body", {}, () => [
91
- c(m(e.body), 1)
92
- ])
93
- ], 2)
94
- ], 2)
95
- ])
96
- ], 2));
97
- }
98
- };
99
- export {
100
- I as _
101
- };