@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,446 +0,0 @@
1
- import { ref as x, computed as P, openBlock as o, createElementBlock as u, createElementVNode as i, createVNode as v, unref as n, createCommentVNode as k, createBlock as B, normalizeStyle as M, withCtx as D, Fragment as A, renderList as T, normalizeClass as y, renderSlot as N, onMounted as L, mergeProps as q, toDisplayString as V } from "vue";
2
- import "dayjs";
3
- import { D as G, _ as H, B as J } from "./OcComplexCalendar.vue_vue_type_style_index_0_lang-CIQPD-6N.js";
4
- import { _ as I } from "./OcIcon-CJgBICxh.js";
5
- /* empty css */
6
- import "libphonenumber-js";
7
- /* empty css */
8
- import "v-calendar";
9
- /* empty css */
10
- import { useUploadFileProgress as K } from "./composables/uploadFileProgress.js";
11
- import { ModalCropper as Q } from "./Cropper.js";
12
- import { _ as W } from "./OcDraggable-BjhGJmpM.js";
13
- import { _ as X } from "./OcConfirmationModal-BfCrRV9r.js";
14
- import "@popperjs/core";
15
- const Y = { class: "relative min-h-[100px]" }, Z = {
16
- key: 0,
17
- class: "absolute"
18
- }, _ = { class: "w-[100px] hover:bg-oc-primary-50 cursor-pointer bg-oc-accent-1-50 text-oc-accent-1 rounded aspect-square flex items-center justify-center" }, ee = ["accept", "multiple"], te = ["onClick"], le = { class: "py-2 flex flex-col" }, ae = ["onClick"], oe = ["onClick"], ne = { class: "z-[1009] hidden group-hover:flex absolute bg-black/30 w-full h-full top-0 left-0 rounded" }, ie = {
19
- key: 0,
20
- class: "cursor-pointer m-auto drag-el"
21
- }, se = {
22
- __name: "OcSimpleMultipleUpload",
23
- props: {
24
- accept: {
25
- type: String,
26
- default: ""
27
- },
28
- uploadedImages: {
29
- type: Array,
30
- default: () => []
31
- },
32
- selectedImage: {
33
- type: Object,
34
- default: () => ({})
35
- },
36
- columnsCount: {
37
- type: Number,
38
- default: 3
39
- },
40
- inputOptions: Array,
41
- maxImages: Number
42
- },
43
- emits: [
44
- "change",
45
- "update:selectedImage",
46
- "update:uploadedImages",
47
- "onRemoveImage",
48
- "onEditImage",
49
- "delete",
50
- "onMaxFileExceed",
51
- "fileExist",
52
- "invalidFileType"
53
- ],
54
- setup(e, { emit: z }) {
55
- const d = e, m = z, b = x([]), f = x(!1), p = x(""), F = x({}), h = P(() => d.uploadedImages[p.value].fileUrl), $ = x(!1), w = x(""), U = (r) => {
56
- $.value = !0, w.value = r;
57
- }, O = x(!1), S = () => {
58
- const r = d.uploadedImages.find((a, c) => c === w.value);
59
- r.current ? m("onRemoveImage", r) : (m("delete", w.value), O.value = !0, setTimeout(() => {
60
- O.value = !1;
61
- }, 1e3)), m(
62
- "update:uploadedImages",
63
- d.uploadedImages.filter((a, c) => c !== w.value)
64
- ), $.value = !1;
65
- }, s = (r) => {
66
- const a = d.uploadedImages[p.value];
67
- a.fileUrl = r, a.fileName = Date.now(), m("onEditImage", { ...a, index: p.value }), f.value = !1, p.value = "", F.value = {};
68
- }, t = (r) => {
69
- let a = d.uploadedImages[p.value];
70
- Object.keys(r).forEach((c) => {
71
- a[c] = r[c];
72
- }), m("update:uploadedImages", d.uploadedImages);
73
- }, l = (r) => {
74
- let a = d.uploadedImages.length + r.target.files.length > d.maxImages;
75
- if (d.maxImages && a) {
76
- m("onMaxFileExceed", a);
77
- return;
78
- }
79
- m("change", r);
80
- }, E = P(
81
- () => d.maxImages == null || d.maxImages && d.uploadedImages.length < d.maxImages
82
- ), R = (r, a) => {
83
- var c;
84
- p.value = r, (c = d.inputOptions) == null || c.forEach((g) => {
85
- F.value[g] = a[g];
86
- }), b[r] = !1, f.value = !0;
87
- };
88
- return (r, a) => (o(), u("div", Y, [
89
- E.value ? (o(), u("label", Z, [
90
- i("div", _, [
91
- v(n(I), { name: "plus" })
92
- ]),
93
- O.value ? k("", !0) : (o(), u("input", {
94
- key: 0,
95
- class: "hidden",
96
- type: "file",
97
- accept: e.accept || "image/png, image/jpeg",
98
- multiple: d.maxImages !== 1,
99
- onChange: l
100
- }, null, 40, ee))
101
- ])) : k("", !0),
102
- (o(), B(n(W), {
103
- key: e.uploadedImages.length,
104
- "model-value": e.uploadedImages,
105
- filter: "filtered-el",
106
- class: "grid w-fit grid-cols-3 gap-3",
107
- style: M(`grid-template-columns: repeat(${e.columnsCount}, 1fr)`),
108
- "onUpdate:modelValue": a[0] || (a[0] = (c) => r.$emit("update:uploadedImages", c))
109
- }, {
110
- default: D(({ list: c }) => [
111
- (o(!0), u(A, null, T(c, (g, C) => (o(), u("div", {
112
- key: g.fileName,
113
- class: y(["w-[100px] group relative cursor-pointer aspect-square border rounded border-oc-accent-1-100 bg-cover bg-center", {
114
- "border-oc-primary": e.selectedImage.fileName === g.fileName,
115
- "col-start-2": C === 0 && E.value
116
- }]),
117
- style: M(`background-image: url(${g.fileUrl})`),
118
- onClick: (j) => r.$emit("update:selectedImage", g)
119
- }, [
120
- v(n(G), {
121
- modelValue: b.value[C],
122
- "onUpdate:modelValue": (j) => b.value[C] = j,
123
- placement: "bottom-end",
124
- class: "absolute top-2 right-2 z-[1010] hidden group-hover:flex"
125
- }, {
126
- menu: D(() => [
127
- N(r.$slots, "action", {
128
- item: g,
129
- removeItem: U,
130
- fileIndex: C
131
- }, () => [
132
- i("div", le, [
133
- i("div", {
134
- class: "flex p-3 cursor-pointer items-center gap-x-3",
135
- onClick: (j) => R(C, g)
136
- }, [
137
- v(n(I), {
138
- width: "16",
139
- height: "16",
140
- name: "pencil"
141
- }),
142
- a[4] || (a[4] = i("span", null, "Edit Image", -1))
143
- ], 8, ae),
144
- i("div", {
145
- class: "flex p-3 cursor-pointer items-center text-oc-error gap-x-3",
146
- onClick: () => {
147
- U(C), b.value[C] = !1;
148
- }
149
- }, [
150
- v(n(I), {
151
- width: "16",
152
- height: "16",
153
- name: "bin"
154
- }),
155
- a[5] || (a[5] = i("span", null, "Delete", -1))
156
- ], 8, oe)
157
- ])
158
- ])
159
- ]),
160
- default: D(() => [
161
- v(n(I), {
162
- name: "dots-vertical",
163
- class: "absolute right-0 cursor-pointer w-[32px] flex h-[32px] items-center justify-center text-oc-bg-light"
164
- })
165
- ]),
166
- _: 2
167
- }, 1032, ["modelValue", "onUpdate:modelValue"]),
168
- i("div", {
169
- class: y(["absolute transition-all duration-500 top-0 left-0 flex items-center justify-center w-full h-full", g.progress !== 100 ? "bg-black/[.35]" : "bg-black/0"])
170
- }, [
171
- i("div", {
172
- class: y(["h-[6px] w-[72px] bg-white transition-all rounded-full", { "on-end-loading opacity-0": g.progress === 100 }])
173
- }, [
174
- i("div", {
175
- class: "h-full bg-oc-primary rounded-full w-0 transition-all duration-500",
176
- style: M({ width: `${g.progress || 0}%` })
177
- }, null, 4)
178
- ], 2)
179
- ], 2),
180
- i("div", ne, [
181
- d.maxImages !== 1 ? (o(), u("span", ie, [
182
- v(n(I), {
183
- name: "arrows",
184
- class: "text-oc-accent-1-50"
185
- })
186
- ])) : k("", !0)
187
- ])
188
- ], 14, te))), 128))
189
- ]),
190
- _: 3
191
- }, 8, ["model-value", "style"])),
192
- f.value ? (o(), B(n(Q), {
193
- key: 1,
194
- modelValue: f.value,
195
- "onUpdate:modelValue": a[1] || (a[1] = (c) => f.value = c),
196
- img: h.value,
197
- "input-options": e.inputOptions,
198
- "input-option-values": F.value,
199
- onClose: a[2] || (a[2] = () => {
200
- f.value = !1, p.value = "";
201
- }),
202
- onChangeImage: s,
203
- "onUpdate:inputOptions": t
204
- }, null, 8, ["modelValue", "img", "input-options", "input-option-values"])) : k("", !0),
205
- v(n(X), {
206
- modelValue: $.value,
207
- "onUpdate:modelValue": a[3] || (a[3] = (c) => $.value = c),
208
- description: "Do you want to delete this image ?",
209
- onConfirm: S
210
- }, null, 8, ["modelValue"])
211
- ]));
212
- }
213
- }, re = { class: "flex flex-col gap-y-2" }, de = ["accept"], ue = { class: "input-file-uploaded flex flex-col gap-y-3" }, ce = { class: "flex items-center gap-x-3" }, me = { class: "flex flex-col items-center justify-center text-oc-text-300" }, pe = { class: "uppercase text-[8px] font-bold leading-none block" }, ge = { class: "text-oc-text-400 text-sm" }, fe = { class: "w-[100px] h-[6px] bg-oc-accent-1-50 rounded-full overflow-hidden transition-all duration-1000" }, ve = ["accept"], xe = {
214
- key: 1,
215
- class: "w-full text-oc-text-300 text-sm h-full flex-1 flex flex-col justify-center items-center my-auto min-h-[120px] transition-all duration-300 gap-2"
216
- }, be = { key: 0 }, he = { key: 1 }, ye = {
217
- key: 2,
218
- class: "text-center"
219
- }, Ie = {
220
- key: 2,
221
- class: "mt-3 flex items-center justify-center"
222
- }, ze = {
223
- __name: "OcMultipleUploadFile",
224
- props: {
225
- modelValue: {
226
- type: Array,
227
- default: () => []
228
- },
229
- accept: {
230
- type: String,
231
- default: ""
232
- },
233
- validateAcceptFileType: Boolean,
234
- /**
235
- * Maximum file size in MB
236
- */
237
- maxSize: Number,
238
- maxImages: Number,
239
- hint: String,
240
- label: String,
241
- errorMessage: String,
242
- isImageOnly: Boolean,
243
- columnsCount: Number,
244
- selectedImage: {
245
- type: Object,
246
- default: () => ({})
247
- },
248
- inputOptions: Array,
249
- isDisabled: Boolean,
250
- labelUploadArea: String,
251
- isButtonOnly: Boolean,
252
- buttonUploadProps: {
253
- type: Object,
254
- default: () => ({
255
- label: "Upload"
256
- })
257
- }
258
- },
259
- emits: [
260
- "update:modelValue",
261
- "update:selectedImage",
262
- "onEditFile",
263
- "onRemoveFile",
264
- "onExceedMaxFileSize",
265
- "onMaxFileExceed"
266
- ],
267
- setup(e, { emit: z }) {
268
- const d = z, m = e, b = x(), f = x(!1), p = x(!1), { isErrorMaxSize: F, currentFiles: h, onChangeFile: $, onDeleteFile: w } = K(
269
- m.maxSize,
270
- d,
271
- m.accept,
272
- m.validateAcceptFileType
273
- );
274
- L(() => {
275
- const s = [];
276
- m.modelValue.length > 0 && (m.modelValue.forEach((t) => {
277
- t.current && s.push({
278
- current: t.current,
279
- file: null,
280
- fileName: t.current.caption ?? "",
281
- progress: 100,
282
- fileUrl: t.current.path,
283
- totalSize: t.current.file_size ?? 0,
284
- isLoaded: !0,
285
- extension: t.current.extension ?? "png",
286
- description: t.current.description,
287
- link: t.current.link,
288
- caption: t.current.caption,
289
- caption_variant: t.current.caption_variant,
290
- lightbox: t.current.lightbox
291
- });
292
- }), h.value = s);
293
- });
294
- const U = (s) => {
295
- p.value = !0, $(s);
296
- }, O = (s) => {
297
- p.value = !1, w(s);
298
- }, S = () => {
299
- var s;
300
- (s = b.value) == null || s.click();
301
- };
302
- return (s, t) => (o(), u("div", re, [
303
- v(n(H), {
304
- label: e.label,
305
- hint: e.hint,
306
- "error-message": n(F) ? `File(s) is more than ${e.maxSize}MB` : e.errorMessage
307
- }, {
308
- hint: D(() => [
309
- N(s.$slots, "hint")
310
- ]),
311
- default: D(() => [
312
- e.isImageOnly ? (o(), B(se, {
313
- key: 0,
314
- "uploaded-images": n(h),
315
- "selected-image": e.selectedImage,
316
- "columns-count": e.columnsCount,
317
- accept: e.accept,
318
- "input-options": e.inputOptions,
319
- "max-images": e.maxImages,
320
- onChange: n($),
321
- "onUpdate:selectedImage": t[0] || (t[0] = (l) => s.$emit("update:selectedImage", l)),
322
- "onUpdate:uploadedImages": t[1] || (t[1] = (l) => {
323
- h.value = l, s.$emit("update:modelValue", l);
324
- }),
325
- onOnEditImage: t[2] || (t[2] = (l) => s.$emit("onEditFile", l)),
326
- onOnRemoveImage: t[3] || (t[3] = (l) => s.$emit("onRemoveFile", l)),
327
- onDelete: n(w),
328
- onOnMaxFileExceed: t[4] || (t[4] = (l) => s.$emit("onMaxFileExceed", l))
329
- }, {
330
- action: D((l) => [
331
- N(s.$slots, "action", {
332
- item: l.item,
333
- removeItem: l.removeItem,
334
- fileIndex: l.i
335
- })
336
- ]),
337
- _: 3
338
- }, 8, ["uploaded-images", "selected-image", "columns-count", "accept", "input-options", "max-images", "onChange", "onDelete"])) : e.isButtonOnly ? (o(), u(A, { key: 1 }, [
339
- N(s.$slots, "button", { triggerInput: S }, () => [
340
- v(n(J), q(e.buttonUploadProps, { onClick: S }), null, 16)
341
- ]),
342
- i("input", {
343
- id: "my-file",
344
- ref_key: "inputRef",
345
- ref: b,
346
- class: "hidden",
347
- type: "file",
348
- multiple: "",
349
- accept: e.accept,
350
- onChange: U
351
- }, null, 40, de)
352
- ], 64)) : (o(), u("div", {
353
- key: 2,
354
- class: y(["relative border rounded p-3 min-w-[30rem] flex flex-col", [
355
- n(F) || e.errorMessage ? "border-oc-error" : "border-oc-gray-200",
356
- {
357
- "bg-oc-bg-dark": e.isDisabled
358
- }
359
- ]])
360
- }, [
361
- i("div", ue, [
362
- (o(!0), u(A, null, T(n(h), (l, E) => (o(), u("div", {
363
- key: `${E}-${l.fileName}`,
364
- class: "flex justify-between relative items-center w-full last:mb-2"
365
- }, [
366
- i("div", ce, [
367
- i("div", me, [
368
- v(n(I), {
369
- name: "file-extension",
370
- width: "14",
371
- height: "10"
372
- }),
373
- i("span", pe, V(l.extension), 1)
374
- ]),
375
- i("span", ge, V(l == null ? void 0 : l.fileName), 1)
376
- ]),
377
- p.value ? (o(), u("div", {
378
- key: 0,
379
- class: y(["w-[100px] h-[16px] absolute right-0 flex items-center z-40", { "on-end-loading": l.progress === 100 }])
380
- }, [
381
- i("div", fe, [
382
- i("div", {
383
- style: M({ width: `${l.progress}%` }),
384
- class: "block transition-all duration-1000 h-[6px] rounded-full bg-oc-primary"
385
- }, null, 4)
386
- ])
387
- ], 2)) : k("", !0),
388
- e.isDisabled ? k("", !0) : (o(), B(n(I), {
389
- key: 1,
390
- width: "12",
391
- height: "12",
392
- name: "bin",
393
- class: y(["opacity-0 text-oc-error cursor-pointer absolute right-0", {
394
- "on-enable-delete": l.progress === 100 && p.value,
395
- "opacity-100": !p.value
396
- }]),
397
- onClick: (R) => O(E)
398
- }, null, 8, ["class", "onClick"]))
399
- ]))), 128))
400
- ]),
401
- i("label", {
402
- tabindex: "0",
403
- for: "my-file",
404
- class: y(["relative overflow-hidden rounded-sm flex-1 flex flex-col transition-all border-transparent border-dashed hover:border-oc-primary", {
405
- "!border-oc-primary": f.value && !e.isDisabled,
406
- border: !n(h).length,
407
- "cursor-pointer": !e.isDisabled
408
- }])
409
- }, [
410
- e.isDisabled ? k("", !0) : (o(), u("input", {
411
- key: 0,
412
- id: "my-file",
413
- ref_key: "inputRef",
414
- ref: b,
415
- class: "w-full h-full absolute opacity-0 cursor-pointer",
416
- type: "file",
417
- multiple: "",
418
- accept: e.accept,
419
- onDragover: t[5] || (t[5] = (l) => f.value = !0),
420
- onDragleave: t[6] || (t[6] = (l) => f.value = !1),
421
- onDrop: t[7] || (t[7] = (l) => f.value = !1),
422
- onChange: U
423
- }, null, 40, ve)),
424
- n(h).length ? e.isDisabled ? k("", !0) : (o(), u("div", Ie, t[9] || (t[9] = [
425
- i("span", { class: "text-oc-accent-1 text-sm" }, "+ Add more", -1)
426
- ]))) : (o(), u("div", xe, [
427
- v(n(I), {
428
- name: "upload",
429
- class: y(e.isDisabled ? "text-oc-accent-1-200" : "text-oc-accent-1")
430
- }, null, 8, ["class"]),
431
- e.labelUploadArea ? (o(), u("div", be, V(e.labelUploadArea), 1)) : e.isDisabled ? (o(), u("div", he, "Upload disabled")) : (o(), u("div", ye, [
432
- t[8] || (t[8] = i("div", null, "Select documents or drag here", -1)),
433
- i("div", null, "File max " + V(e.maxSize) + "MB", 1)
434
- ]))
435
- ]))
436
- ], 2)
437
- ], 2))
438
- ]),
439
- _: 3
440
- }, 8, ["label", "hint", "error-message"])
441
- ]));
442
- }
443
- };
444
- export {
445
- ze as _
446
- };
@@ -1,90 +0,0 @@
1
- import { defineComponent as f, openBlock as g, createBlock as x, unref as l, withCtx as V, createElementVNode as n, normalizeClass as r, createVNode as s } from "vue";
2
- import "dayjs";
3
- import { _ as k, B as u } from "./OcComplexCalendar.vue_vue_type_style_index_0_lang-CIQPD-6N.js";
4
- /* empty css */
5
- import "libphonenumber-js";
6
- /* empty css */
7
- import "v-calendar";
8
- /* empty css */
9
- import "./Cropper.js";
10
- import "vue-draggable-next";
11
- import "@popperjs/core";
12
- const h = ["value"], j = /* @__PURE__ */ f({
13
- __name: "OcNumberInput",
14
- props: {
15
- modelValue: {
16
- type: [String, Number],
17
- default: null
18
- },
19
- minValue: {
20
- type: Number,
21
- default: 1
22
- },
23
- label: String,
24
- errorMessage: String,
25
- isDisabled: Boolean,
26
- tooltipOptions: Object,
27
- hint: String,
28
- labelIcon: String,
29
- isRequired: Boolean,
30
- tooltipText: String,
31
- inputClass: [String, Array, Object]
32
- },
33
- emits: ["update:modelValue"],
34
- setup(e, { emit: m }) {
35
- const i = e, o = m, d = () => o("update:modelValue", Number(i.modelValue) + 1), c = () => {
36
- Number(i.modelValue) > i.minValue && o("update:modelValue", Number(i.modelValue) - 1);
37
- }, b = (t) => {
38
- t.key >= "0" && t.key <= "9" || t.key === "Backspace" || t.preventDefault();
39
- };
40
- return (t, a) => (g(), x(l(k), {
41
- label: e.label,
42
- "tooltip-options": e.tooltipOptions,
43
- "error-message": e.errorMessage,
44
- hint: e.hint,
45
- "label-icon": e.labelIcon,
46
- "is-required": e.isRequired,
47
- "tooltip-text": e.tooltipText
48
- }, {
49
- default: V(() => [
50
- n("div", {
51
- class: r(["flex justify-between gap-x-3 h-[36px] items-center border rounded px-1", [
52
- e.inputClass,
53
- e.isDisabled ? "bg-oc-bg-dark" : "",
54
- e.errorMessage ? "border-oc-error" : "border-oc-gray-200"
55
- ]])
56
- }, [
57
- s(l(u), {
58
- variant: "secondary",
59
- class: "w-[28px] shrink-0 aspect-square",
60
- size: "small",
61
- "icon-class": "shrink-0",
62
- "is-disabled": e.isDisabled,
63
- "left-icon": "minus",
64
- onClick: c
65
- }, null, 8, ["is-disabled"]),
66
- n("input", {
67
- value: e.modelValue,
68
- class: r([e.modelValue ? "font-medium" : "text-oc-text-300", "outline-none text-center max-w-[calc(100%-76px)] bg-transparent"]),
69
- placeholder: "1",
70
- onKeydown: b,
71
- onInput: a[0] || (a[0] = (p) => t.$emit("update:modelValue", p.target.value))
72
- }, null, 42, h),
73
- s(l(u), {
74
- variant: "secondary",
75
- class: "w-[28px] shrink-0 aspect-square",
76
- size: "small",
77
- "icon-class": "shrink-0",
78
- "is-disabled": e.isDisabled,
79
- "left-icon": "plus",
80
- onClick: d
81
- }, null, 8, ["is-disabled"])
82
- ], 2)
83
- ]),
84
- _: 1
85
- }, 8, ["label", "tooltip-options", "error-message", "hint", "label-icon", "is-required", "tooltip-text"]));
86
- }
87
- });
88
- export {
89
- j as _
90
- };
@@ -1,81 +0,0 @@
1
- import { defineComponent as a, openBlock as e, createElementBlock as i, createElementVNode as o, createVNode as c, unref as n, toDisplayString as s, renderSlot as l, createBlock as d, mergeProps as p, createCommentVNode as u } from "vue";
2
- import "dayjs";
3
- import { B as f } from "./OcComplexCalendar.vue_vue_type_style_index_0_lang-CIQPD-6N.js";
4
- import { _ as m } 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 x = { class: "bg-oc-bg-light py-5 px-7 gap-x-7 flex items-center" }, h = { class: "flex-1 flex gap-x-4 items-center" }, g = {
14
- key: 0,
15
- class: "w-[24px] h-[24px] min-w-[24px] flex items-center text-white justify-center rounded-full bg-oc-primary"
16
- }, y = {
17
- key: 1,
18
- class: "w-[24px] h-[24px] min-w-[24px] flex items-center justify-center border rounded-full text-oc-warning border-oc-warning"
19
- }, b = {
20
- key: 2,
21
- class: "w-[24px] h-[24px] min-w-[24px] text-oc-text-300 text-sm font-medium flex items-center justify-center border rounded-full border-oc-gray-200"
22
- }, _ = { class: "flex flex-col gap-y-1" }, w = { class: "font-medium" }, k = { class: "text-oc-text-300 text-sm" }, P = /* @__PURE__ */ a({
23
- __name: "OcOnboardingListItem",
24
- props: {
25
- title: {
26
- type: String,
27
- default: ""
28
- },
29
- description: {
30
- type: String,
31
- default: ""
32
- },
33
- buttonOptions: {
34
- type: Object,
35
- default: () => ({})
36
- },
37
- status: {
38
- type: String,
39
- default: ""
40
- },
41
- number: {
42
- type: Number,
43
- default: 1
44
- },
45
- isButtonVisible: {
46
- type: Boolean,
47
- default: !0
48
- }
49
- },
50
- setup(t) {
51
- return (r, B) => (e(), i("div", x, [
52
- o("div", h, [
53
- t.status === "completed" ? (e(), i("div", g, [
54
- c(n(m), {
55
- name: "check-2",
56
- width: "12",
57
- height: "12"
58
- })
59
- ])) : t.status === "pending" ? (e(), i("div", y, [
60
- c(n(m), {
61
- name: "time-filled",
62
- width: "18",
63
- height: "18"
64
- })
65
- ])) : (e(), i("div", b, s(t.number), 1)),
66
- o("div", _, [
67
- l(r.$slots, "default", {}, () => [
68
- o("span", w, s(t.title), 1),
69
- o("span", k, s(t.description), 1)
70
- ])
71
- ])
72
- ]),
73
- l(r.$slots, "action", {}, () => [
74
- t.isButtonVisible ? (e(), d(n(f), p({ key: 0 }, t.buttonOptions, { class: "shrink-0" }), null, 16)) : u("", !0)
75
- ])
76
- ]));
77
- }
78
- });
79
- export {
80
- P as _
81
- };