@orchidui/core 1.21.1-18 → 1.21.1-19

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 (83) 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 +1 -1
  6. package/dist/DataDisplay/NewTable/OcNewTable.js +1 -1
  7. package/dist/DataDisplay/OnboardingListItem/OcOnboardingListItem.js +1 -1
  8. package/dist/DataDisplay/Overview/OcOverview.js +1 -1
  9. package/dist/DataDisplay/Pagination/OcPagination.js +1 -1
  10. package/dist/DataDisplay/Table/OcTable.js +1 -1
  11. package/dist/DataDisplay/TransferSummary/OcTransferSummary.js +1 -1
  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 +1 -1
  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 +1 -1
  18. package/dist/Elements/AuthenticationOption/AuthenticationOption.js +1 -1
  19. package/dist/Elements/Box/OcBox.js +1 -1
  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 +1 -1
  23. package/dist/Elements/PageTitle/OcPageTitle.js +1 -1
  24. package/dist/Elements/SandboxBanner/OcSandboxBanner.js +1 -1
  25. package/dist/Elements/Sidebar/OcSidebar.js +2 -2
  26. package/dist/Elements/SubSidebar/OcSubSidebar.js +1 -1
  27. package/dist/Elements/TopBanner/OcTopBanner.js +1 -1
  28. package/dist/Elements/VerificationOption/OcVerificationOption.js +1 -1
  29. package/dist/Feedback/Banner/OcBanner.js +1 -1
  30. package/dist/Feedback/Chip/OcChip.js +1 -1
  31. package/dist/Feedback/ShareIcon/OcShareIcon.js +1 -1
  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 +1 -1
  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 +1 -1
  43. package/dist/Form/Input/OcInput.js +1 -1
  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 +1 -1
  52. package/dist/Form/Select/OcSelect.js +1 -1
  53. package/dist/Form/SelectOptions/OcSelectOptions.js +1 -1
  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 +1 -1
  57. package/dist/Form/index.js +1 -1
  58. package/dist/FormBuilder/OcFormBuilder.js +1 -1
  59. package/dist/{OcAccountSetupProgress-DPW3WzMx.js → OcAccountSetupProgress-DKtEhLsr.js} +1 -1
  60. package/dist/{OcComplexCalendar-B_NOGCdu.js → OcComplexCalendar-BwFte9iD.js} +1 -1
  61. package/dist/{OcComplexDatePicker-6bFucWVd.js → OcComplexDatePicker-CSspopV-.js} +1 -1
  62. package/dist/{OcCropper-DF4Ig9lc.js → OcCropper-BHMQxTS_.js} +1 -1
  63. package/dist/{OcDataTable-Dskcff1R.js → OcDataTable-DaE3k78o.js} +180 -183
  64. package/dist/{OcDraggableList-DamXY5L9.js → OcDraggableList-H7KmSFYw.js} +1 -1
  65. package/dist/{OcEmojiPicker-CeXqGPa8.js → OcEmojiPicker-CQpW2nAF.js} +1 -1
  66. package/dist/{OcFilterForm-DfbP9FSc.js → OcFilterForm-CkjN35mK.js} +1 -1
  67. package/dist/{OcFilterSearch-C7fSagcx.js → OcFilterSearch-GGiF9lC5.js} +1 -1
  68. package/dist/{OcFilterSearchFor-ChXphb15.js → OcFilterSearchFor-DeXI2S4s.js} +1 -1
  69. package/dist/{OcModalCropper-BSKNNeGR.js → OcModalCropper-BjiaUvDo.js} +2 -2
  70. package/dist/{OcTimePicker-_EabmAwr.js → OcTimePicker-CKjJgu1S.js} +1 -1
  71. package/dist/Overlay/ConfirmationModal/OcConfirmationModal.js +1 -1
  72. package/dist/Overlay/CopyTooltip/OcCopyTooltip.js +1 -1
  73. package/dist/Overlay/Dropdown/OcDropdown.js +1 -1
  74. package/dist/Overlay/Modal/OcModal.js +1 -1
  75. package/dist/Overlay/SupportMenu/OcSupportMenu.js +1 -1
  76. package/dist/Overlay/Tooltip/OcTooltip.js +1 -1
  77. package/dist/Overlay/Whitelist/OcWhiteList.js +1 -1
  78. package/dist/{SubPlanCard-BOynReDA.js → SubPlanCard-DT1lK_eZ.js} +1 -1
  79. package/dist/{ThumbnailSection-Dhyk0Ojd.js → ThumbnailSection-SOglxqye.js} +1 -1
  80. package/dist/{ThumbnailTheme-BDO_3w75.js → ThumbnailTheme-DuHOPsel.js} +1 -1
  81. package/dist/{index-Dj4H9HZ7.js → index-Dyx5BWEX.js} +8 -8
  82. package/dist/index.js +1 -1
  83. package/package.json +1 -1
@@ -1,19 +1,19 @@
1
- import { ref as w, onMounted as Ke, createBlock as L, openBlock as r, unref as i, withCtx as S, createVNode as j, createElementVNode as q, createElementBlock as h, createCommentVNode as f, mergeProps as Pe, Fragment as re, renderList as de, normalizeClass as ve, toDisplayString as Ae, computed as $, watch as ne, nextTick as dl, renderSlot as A, resolveDynamicComponent as vl, createSlots as cl, normalizeProps as Le, guardReactiveProps as je } from "vue";
2
- import { aA as Ie, B as Ne, C as ml, D as pl, L as fl, $ as yl, aL as gl, aM as bl, aN as kl, I as hl, J as Be, j as xl } from "./index-Dj4H9HZ7.js";
3
- import { useDataTable as wl } from "./DataTable/useDataTable.js";
4
- import { VueDraggableNext as Ue } from "vue-draggable-next";
5
- import { getFromLocalStorage as qe, formatHeadersFromLocalStorage as Qe, formatHeadersToLocalStorage as Sl, setInLocalStorage as $l } from "./DataTable/utils/editColumnsUtils.js";
6
- import { _ as Te } from "./OcIcon-CxreweI4.js";
7
- import { formatFilterDisplay as Fl, clearAllFilters as Ol } from "./DataTable/utils/filterUtils.js";
8
- import { formatCustomItemsPerPageOptions as Vl, getItemsPerPageOptions as Dl } from "./DataTable/utils/paginationUtils.js";
1
+ import { ref as $, onMounted as Te, createBlock as L, openBlock as r, unref as u, withCtx as w, createVNode as j, createElementVNode as q, createElementBlock as h, createCommentVNode as y, mergeProps as Ce, Fragment as re, renderList as de, normalizeClass as ve, toDisplayString as Pe, computed as S, watch as ne, nextTick as nl, renderSlot as A, resolveDynamicComponent as dl, createSlots as vl, normalizeProps as Ae, guardReactiveProps as Le } from "vue";
2
+ import { aA as Ke, B as Ie, C as cl, D as ml, L as pl, $ as fl, aL as yl, aM as gl, aN as bl, I as kl, J as je, j as hl } from "./index-Dyx5BWEX.js";
3
+ import { useDataTable as xl } from "./DataTable/useDataTable.js";
4
+ import { VueDraggableNext as Be } from "vue-draggable-next";
5
+ import { getFromLocalStorage as Ne, formatHeadersFromLocalStorage as qe, formatHeadersToLocalStorage as wl, setInLocalStorage as Sl } from "./DataTable/utils/editColumnsUtils.js";
6
+ import { _ as Ue } from "./OcIcon-CxreweI4.js";
7
+ import { formatFilterDisplay as $l, clearAllFilters as Fl } from "./DataTable/utils/filterUtils.js";
8
+ import { formatCustomItemsPerPageOptions as Ol, getItemsPerPageOptions as Vl } from "./DataTable/utils/paginationUtils.js";
9
9
  import "dayjs";
10
- const El = { class: "p-5 gap-y-4 text-sm flex w-[250px] flex-col" }, Cl = {
10
+ const Dl = { class: "p-5 gap-y-4 text-sm flex w-[250px] flex-col" }, El = {
11
11
  key: 0,
12
12
  class: "gap-y-2 flex flex-col border-b pb-3 border-oc-gray-200"
13
- }, Pl = { class: "gap-y-2 flex flex-col" }, Al = {
13
+ }, Cl = { class: "gap-y-2 flex flex-col" }, Pl = {
14
14
  key: 0,
15
15
  class: "flex items-center bg-white justify-between h-[26px]"
16
- }, Ll = { class: "flex items-center w-full gap-x-3" }, jl = { class: "truncate w-full max-w-[160px]" }, Bl = {
16
+ }, Al = { class: "flex items-center w-full gap-x-3" }, Ll = { class: "truncate w-full max-w-[160px]" }, jl = {
17
17
  __name: "ColumnEdit",
18
18
  props: {
19
19
  options: {
@@ -31,7 +31,7 @@ const El = { class: "p-5 gap-y-4 text-sm flex w-[250px] flex-col" }, Cl = {
31
31
  },
32
32
  emits: ["change-active", "onMoved", "update-order"],
33
33
  setup(F, { emit: se }) {
34
- const oe = se, u = F, g = w([]), d = w([]), T = w(!1), O = {
34
+ const oe = se, i = F, g = $([]), d = $([]), T = $(!1), O = {
35
35
  handle: ".drag-el",
36
36
  filter: ".is-disabled",
37
37
  group: "headers",
@@ -49,61 +49,61 @@ const El = { class: "p-5 gap-y-4 text-sm flex w-[250px] flex-col" }, Cl = {
49
49
  isOnMount: E
50
50
  });
51
51
  };
52
- return Ke(() => {
53
- const E = qe(u.localKey), { fixed: o, active: v } = Qe(E, u.headers, u.localKey);
54
- d.value = o || u.headers.slice(0, 1), g.value = v || u.headers.slice(1).map((C) => {
52
+ return Te(() => {
53
+ const E = Ne(i.localKey), { fixed: o, active: v } = qe(E, i.headers, i.localKey);
54
+ d.value = o || i.headers.slice(0, 1), g.value = v || i.headers.slice(1).map((C) => {
55
55
  var ee, le, ae;
56
56
  return {
57
57
  ...C,
58
- isActive: ((ae = (le = (ee = u.options) == null ? void 0 : ee.active) == null ? void 0 : le.find((ue) => ue.key === C.key)) == null ? void 0 : ae.isActive) ?? !0
58
+ isActive: ((ae = (le = (ee = i.options) == null ? void 0 : ee.active) == null ? void 0 : le.find((ie) => ie.key === C.key)) == null ? void 0 : ae.isActive) ?? !0
59
59
  };
60
60
  }), K(!0);
61
- }), (E, o) => (r(), L(i(Ie), {
61
+ }), (E, o) => (r(), L(u(Ke), {
62
62
  modelValue: T.value,
63
63
  "onUpdate:modelValue": o[3] || (o[3] = (v) => T.value = v),
64
64
  "is-attach-to-body": ""
65
65
  }, {
66
- menu: S(() => [
67
- q("div", El, [
68
- d.value.length ? (r(), h("div", Cl, [
66
+ menu: w(() => [
67
+ q("div", Dl, [
68
+ d.value.length ? (r(), h("div", El, [
69
69
  o[4] || (o[4] = q("span", { class: "text-oc-text-400 font-medium" }, "Fixed columns", -1)),
70
- j(i(Ue), Pe({
70
+ j(u(Be), Ce({
71
71
  key: "key",
72
72
  modelValue: d.value,
73
73
  "onUpdate:modelValue": o[0] || (o[0] = (v) => d.value = v)
74
74
  }, O), {
75
- default: S(() => [
75
+ default: w(() => [
76
76
  (r(!0), h(re, null, de(d.value, (v, C) => (r(), h("div", {
77
77
  key: v.key,
78
78
  class: ve(["flex items-center justify-between h-[26px]", C ? "" : "is-disabled"])
79
79
  }, [
80
- q("span", null, Ae(v.label), 1),
81
- C ? (r(), L(i(Te), {
80
+ q("span", null, Pe(v.label), 1),
81
+ C ? (r(), L(u(Ue), {
82
82
  key: 0,
83
83
  width: "18",
84
84
  height: "18",
85
85
  class: "text-oc-text-400 drag-el cursor-move",
86
86
  name: "draggable"
87
- })) : f("", !0)
87
+ })) : y("", !0)
88
88
  ], 2))), 128))
89
89
  ]),
90
90
  _: 1
91
91
  }, 16, ["modelValue"])
92
- ])) : f("", !0),
93
- q("div", Pl, [
92
+ ])) : y("", !0),
93
+ q("div", Cl, [
94
94
  o[5] || (o[5] = q("span", { class: "text-oc-text-400 font-medium" }, "Active columns", -1)),
95
- j(i(Ue), Pe({
95
+ j(u(Be), Ce({
96
96
  key: "key",
97
97
  modelValue: g.value,
98
98
  "onUpdate:modelValue": o[2] || (o[2] = (v) => g.value = v)
99
99
  }, O, { "data-active-headers": "true" }), {
100
- default: S(() => [
100
+ default: w(() => [
101
101
  (r(!0), h(re, null, de(g.value, (v) => (r(), h(re, {
102
102
  key: v.key
103
103
  }, [
104
- v.key !== "actions" ? (r(), h("div", Al, [
105
- q("div", Ll, [
106
- j(i(ml), {
104
+ v.key !== "actions" ? (r(), h("div", Pl, [
105
+ q("div", Al, [
106
+ j(u(cl), {
107
107
  modelValue: v.isActive,
108
108
  "onUpdate:modelValue": [
109
109
  (C) => v.isActive = C,
@@ -111,16 +111,16 @@ const El = { class: "p-5 gap-y-4 text-sm flex w-[250px] flex-col" }, Cl = {
111
111
  ],
112
112
  class: "!w-fit"
113
113
  }, null, 8, ["modelValue", "onUpdate:modelValue"]),
114
- q("div", jl, Ae(v.label), 1)
114
+ q("div", Ll, Pe(v.label), 1)
115
115
  ]),
116
- g.value.length > 1 ? (r(), L(i(Te), {
116
+ g.value.length > 1 ? (r(), L(u(Ue), {
117
117
  key: 0,
118
118
  width: "18",
119
119
  height: "18",
120
120
  class: "text-oc-text-400 drag-el cursor-move",
121
121
  name: "draggable"
122
- })) : f("", !0)
123
- ])) : f("", !0)
122
+ })) : y("", !0)
123
+ ])) : y("", !0)
124
124
  ], 64))), 128))
125
125
  ]),
126
126
  _: 1
@@ -128,8 +128,8 @@ const El = { class: "p-5 gap-y-4 text-sm flex w-[250px] flex-col" }, Cl = {
128
128
  ])
129
129
  ])
130
130
  ]),
131
- default: S(() => [
132
- j(i(Ne), {
131
+ default: w(() => [
132
+ j(u(Ie), {
133
133
  label: "Edit Column",
134
134
  "left-icon": "setting",
135
135
  size: "small",
@@ -140,25 +140,22 @@ const El = { class: "p-5 gap-y-4 text-sm flex w-[250px] flex-col" }, Cl = {
140
140
  _: 1
141
141
  }, 8, ["modelValue"]));
142
142
  }
143
- }, Ul = {
144
- key: 0,
145
- class: "relative flex flex-col gap-9"
146
- }, Tl = {
143
+ }, Bl = { class: "relative flex flex-col gap-9" }, Ul = {
147
144
  key: 0,
148
145
  class: "flex items-center px-4 min-h-[44px]"
149
- }, Kl = {
146
+ }, Tl = {
150
147
  key: 0,
151
148
  class: "absolute flex items-center gap-5 left-5"
152
- }, Il = {
149
+ }, Kl = {
153
150
  key: 1,
154
151
  class: "absolute flex gap-3 left-5"
155
- }, Nl = {
152
+ }, Il = {
156
153
  key: 1,
157
154
  class: "flex justify-center w-full gap-5 md:justify-start"
158
- }, ql = {
155
+ }, Nl = {
159
156
  key: 2,
160
157
  class: "items-center hidden md:flex"
161
- }, Zl = {
158
+ }, Yl = {
162
159
  __name: "OcDataTable",
163
160
  props: {
164
161
  isLoading: Boolean,
@@ -212,14 +209,14 @@ const El = { class: "p-5 gap-y-4 text-sm flex w-[250px] flex-col" }, Cl = {
212
209
  "update:sort-by": []
213
210
  },
214
211
  setup(F, { expose: se, emit: oe }) {
215
- var ge, be, ke, he, xe, we, Se, $e, Fe, Oe, Ve, De, Ee, Ce;
216
- const u = F, g = oe, d = $(() => {
212
+ var ye, ge, be, ke, he, xe, we, Se, $e, Fe, Oe, Ve, De, Ee;
213
+ const i = F, g = oe, d = S(() => {
217
214
  var e;
218
- return (e = u.options) == null ? void 0 : e.cursor;
219
- }), T = w(), O = $(() => {
215
+ return (e = i.options) == null ? void 0 : e.cursor;
216
+ }), T = $(), O = S(() => {
220
217
  var e;
221
- return (e = u.options) == null ? void 0 : e.tableOptions;
222
- }), K = $(() => u.localDb !== void 0), {
218
+ return (e = i.options) == null ? void 0 : e.tableOptions;
219
+ }), K = S(() => i.localDb !== void 0), {
223
220
  localData: E,
224
221
  paginationData: o,
225
222
  isLoading: v,
@@ -228,100 +225,100 @@ const El = { class: "p-5 gap-y-4 text-sm flex w-[250px] flex-col" }, Cl = {
228
225
  bulkDeleteLocalData: ee,
229
226
  getLocalDataUpdatedAt: le,
230
227
  getProductIdAndLastUpdatedAt: ae,
231
- syncLocalData: ue,
232
- sortByData: z,
228
+ syncLocalData: ie,
229
+ sortByData: R,
233
230
  // Setters
234
- setFilter: Re,
231
+ setFilter: Qe,
235
232
  setSortBy: ze
236
- } = wl({
237
- name: ((ge = u.localDb) == null ? void 0 : ge.table_name) ?? null,
238
- db: ((be = u.localDb) == null ? void 0 : be.db) ?? null,
239
- filterableFields: (ke = u.options) == null ? void 0 : ke.filterableFields,
240
- sortableFields: (he = u.options) == null ? void 0 : he.sortableFields,
241
- searchableFields: (xe = u.options) == null ? void 0 : xe.searchableFields
233
+ } = xl({
234
+ name: ((ye = i.localDb) == null ? void 0 : ye.table_name) ?? null,
235
+ db: ((ge = i.localDb) == null ? void 0 : ge.db) ?? null,
236
+ filterableFields: (be = i.options) == null ? void 0 : be.filterableFields,
237
+ sortableFields: (ke = i.options) == null ? void 0 : ke.sortableFields,
238
+ searchableFields: (he = i.options) == null ? void 0 : he.searchableFields
242
239
  });
243
240
  ne(
244
241
  () => {
245
242
  var e;
246
- return (e = u.options) == null ? void 0 : e.pagination;
243
+ return (e = i.options) == null ? void 0 : e.pagination;
247
244
  },
248
245
  (e) => {
249
246
  K.value || (o.value = e);
250
247
  },
251
248
  { deep: !0, immediate: !0 }
252
249
  );
253
- const ce = $(() => {
250
+ const ce = S(() => {
254
251
  var l, c;
255
252
  const e = {
256
253
  ...O.value,
257
254
  headers: T.value ? T.value.map((n) => {
258
- var y, m;
259
- return n.class = ((m = (y = O.value) == null ? void 0 : y.headers.find((s) => s.key === n.key)) == null ? void 0 : m.class) ?? "", n;
260
- }).filter((n) => n.isActive) : (l = O.value) == null ? void 0 : l.headers.filter((n) => _e(n.key))
255
+ var f, m;
256
+ return n.class = ((m = (f = O.value) == null ? void 0 : f.headers.find((s) => s.key === n.key)) == null ? void 0 : m.class) ?? "", n;
257
+ }).filter((n) => n.isActive) : (l = O.value) == null ? void 0 : l.headers.filter((n) => He(n.key))
261
258
  };
262
259
  return (c = e.fields) != null && c.length || (e.fields = E.value), e;
263
- }), a = $(() => {
260
+ }), a = S(() => {
264
261
  var e;
265
- return (e = u.options) == null ? void 0 : e.filterOptions;
266
- }), Je = $(() => {
262
+ return (e = i.options) == null ? void 0 : e.filterOptions;
263
+ }), Re = S(() => {
267
264
  var e;
268
- return (e = u.options) == null ? void 0 : e.hidePerPageDropdown;
269
- }), Me = $(() => {
265
+ return (e = i.options) == null ? void 0 : e.hidePerPageDropdown;
266
+ }), Je = S(() => {
270
267
  var e;
271
268
  return ((e = o.value) == null ? void 0 : e.last_page) === 1;
272
- }), J = JSON.parse(JSON.stringify({ ...u.filter }));
269
+ }), J = JSON.parse(JSON.stringify({ ...i.filter }));
273
270
  !J && o.value ? J.page = 1 : !J && d && (J.cursor = "");
274
- const t = w(J), Q = w(!1), B = w(t.value[(Se = (we = a.value) == null ? void 0 : we.tabs) == null ? void 0 : Se.key]), M = w(t.value.page), R = w(
275
- (Fe = ($e = a.value) == null ? void 0 : $e.per_page) != null && Fe.key ? t.value[(Ve = (Oe = a.value) == null ? void 0 : Oe.per_page) == null ? void 0 : Ve.key] : t.value.per_page
276
- ), me = ((Ce = t.value[t.value.selectedSearchOption || ((Ee = (De = a.value) == null ? void 0 : De.search) == null ? void 0 : Ee.key)]) == null ? void 0 : Ce.trim()) ?? "", U = w(me ? me.split(",") : []), pe = w(!1), Ge = $(
271
+ const t = $(J), Q = $(!1), B = $(t.value[(we = (xe = a.value) == null ? void 0 : xe.tabs) == null ? void 0 : we.key]), M = $(t.value.page), z = $(
272
+ ($e = (Se = a.value) == null ? void 0 : Se.per_page) != null && $e.key ? t.value[(Oe = (Fe = a.value) == null ? void 0 : Fe.per_page) == null ? void 0 : Oe.key] : t.value.per_page
273
+ ), me = ((Ee = t.value[t.value.selectedSearchOption || ((De = (Ve = a.value) == null ? void 0 : Ve.search) == null ? void 0 : De.key)]) == null ? void 0 : Ee.trim()) ?? "", U = $(me ? me.split(",") : []), pe = $(!1), Me = S(
277
274
  () => {
278
275
  var e;
279
- return Vl((e = u.options) == null ? void 0 : e.perPageOptions);
276
+ return Ol((e = i.options) == null ? void 0 : e.perPageOptions);
280
277
  }
281
- ), We = $(() => Dl(Ge.value, o.value)), Xe = $(() => {
278
+ ), Ge = S(() => Vl(Me.value, o.value)), We = S(() => {
282
279
  var e;
283
- return ((e = u.selected) == null ? void 0 : e.length) > 0;
284
- }), Ye = (e) => {
280
+ return ((e = i.selected) == null ? void 0 : e.length) > 0;
281
+ }), Xe = (e) => {
285
282
  !e.trim() || !t.value.selectedSearchOption && U.value.includes(e) || (U.value = [e], V(), g("search-query-changed", e));
286
- }, Ze = (e) => {
283
+ }, Ye = (e) => {
287
284
  U.value = U.value.filter((l) => l !== e), V();
288
- }, He = $(() => Fl(t.value, a.value)), _e = (e) => {
289
- var l, c, n, y, m, s;
290
- return ((s = (m = (y = (n = t.value) == null ? void 0 : n[(c = (l = a.value) == null ? void 0 : l.columnEdit) == null ? void 0 : c.key]) == null ? void 0 : y.active) == null ? void 0 : m.find((b) => b.key === e)) == null ? void 0 : s.isActive) ?? !0;
291
- }, el = ({ fixedHeaders: e, activeHeaders: l, isOnMount: c }) => {
292
- var n, y, m, s, b, x, P, D;
293
- if (t.value[(y = (n = a.value) == null ? void 0 : n.columnEdit) == null ? void 0 : y.key] || (t.value[(s = (m = a.value) == null ? void 0 : m.columnEdit) == null ? void 0 : s.key] = {}), t.value[(x = (b = a.value) == null ? void 0 : b.columnEdit) == null ? void 0 : x.key].fixed = e, t.value[(D = (P = a.value) == null ? void 0 : P.columnEdit) == null ? void 0 : D.key].active = l, T.value = [...e, ...l], !c) {
294
- const I = Sl(e, l);
295
- $l(a.value.columnEdit.localStorageKey, I);
285
+ }, Ze = S(() => $l(t.value, a.value)), He = (e) => {
286
+ var l, c, n, f, m, s;
287
+ return ((s = (m = (f = (n = t.value) == null ? void 0 : n[(c = (l = a.value) == null ? void 0 : l.columnEdit) == null ? void 0 : c.key]) == null ? void 0 : f.active) == null ? void 0 : m.find((b) => b.key === e)) == null ? void 0 : s.isActive) ?? !0;
288
+ }, _e = ({ fixedHeaders: e, activeHeaders: l, isOnMount: c }) => {
289
+ var n, f, m, s, b, x, P, D;
290
+ if (t.value[(f = (n = a.value) == null ? void 0 : n.columnEdit) == null ? void 0 : f.key] || (t.value[(s = (m = a.value) == null ? void 0 : m.columnEdit) == null ? void 0 : s.key] = {}), t.value[(x = (b = a.value) == null ? void 0 : b.columnEdit) == null ? void 0 : x.key].fixed = e, t.value[(D = (P = a.value) == null ? void 0 : P.columnEdit) == null ? void 0 : D.key].active = l, T.value = [...e, ...l], !c) {
291
+ const I = wl(e, l);
292
+ Sl(a.value.columnEdit.localStorageKey, I);
296
293
  }
297
294
  g("columns-changed", l);
298
- }, ll = () => {
299
- var e, l, c, n, y, m;
295
+ }, el = () => {
296
+ var e, l, c, n, f, m;
300
297
  if ((l = (e = a.value) == null ? void 0 : e.columnEdit) != null && l.localStorageKey) {
301
- const s = qe(a.value.columnEdit.localStorageKey);
298
+ const s = Ne(a.value.columnEdit.localStorageKey);
302
299
  if (s) {
303
- const { fixed: b, active: x } = Qe(
300
+ const { fixed: b, active: x } = qe(
304
301
  s,
305
302
  O.value.headers,
306
303
  a.value.columnEdit.localStorageKey
307
304
  );
308
- t.value[(n = (c = a.value) == null ? void 0 : c.columnEdit) == null ? void 0 : n.key].fixed = b, t.value[(m = (y = a.value) == null ? void 0 : y.columnEdit) == null ? void 0 : m.key].active = x, T.value = [...b, ...x];
305
+ t.value[(n = (c = a.value) == null ? void 0 : c.columnEdit) == null ? void 0 : n.key].fixed = b, t.value[(m = (f = a.value) == null ? void 0 : f.columnEdit) == null ? void 0 : m.key].active = x, T.value = [...b, ...x];
309
306
  }
310
307
  }
311
- }, al = (e) => {
308
+ }, ll = (e) => {
312
309
  t.value.selectedSearchOption = e;
313
- }, tl = () => {
314
- U.value = [], B.value = "", t.value = Ol(
310
+ }, al = () => {
311
+ U.value = [], B.value = "", t.value = Fl(
315
312
  t.value,
316
313
  a.value,
317
- R.value,
314
+ z.value,
318
315
  B.value
319
316
  ), V();
320
- }, sl = () => {
317
+ }, tl = () => {
321
318
  V(null, M.value);
322
- }, V = (e = null, l = !1, c = "", n = !1, y = !1) => {
319
+ }, V = (e = null, l = !1, c = "", n = !1, f = !1) => {
323
320
  var s, b, x, P, D, I, G, W, X, Y, Z, H, _;
324
- o.value && !l && (M.value = 1), o.value ? t.value.page = M.value : t.value.cursor = c, (s = a.value) != null && s.per_page ? t.value[a.value.per_page.key] = R.value : t.value.per_page = R.value, (b = a.value) != null && b.tabs && y && (t.value[a.value.tabs.key] = B.value), (x = a.value) != null && x.search && ((D = (P = a.value.search) == null ? void 0 : P.options) != null && D.length ? (Object.keys(t.value).forEach((k) => {
321
+ o.value && !l && (M.value = 1), o.value ? t.value.page = M.value : t.value.cursor = c, (s = a.value) != null && s.per_page ? t.value[a.value.per_page.key] = z.value : t.value.per_page = z.value, (b = a.value) != null && b.tabs && f && (t.value[a.value.tabs.key] = B.value), (x = a.value) != null && x.search && ((D = (P = a.value.search) == null ? void 0 : P.options) != null && D.length ? (Object.keys(t.value).forEach((k) => {
325
322
  var N;
326
323
  (N = a.value.search.options) != null && N.map((p) => p.value).includes(k) && delete t.value[k];
327
324
  }), t.value[((I = t.value) == null ? void 0 : I.selectedSearchOption) || ((X = (W = (G = a.value.search) == null ? void 0 : G.options) == null ? void 0 : W[0]) == null ? void 0 : X.value) || a.value.search.key] = U.value.join()) : t.value[a.value.search.key] = U.value.join()), e && (Q.value = !1, t.value = { ...t.value, ...e }, Object.keys(t.value).forEach((k) => {
@@ -337,58 +334,58 @@ const El = { class: "p-5 gap-y-4 text-sm flex w-[250px] flex-col" }, Cl = {
337
334
  );
338
335
  k != null && k.value && (B.value = k.value, V());
339
336
  }
340
- ol(n);
341
- }, fe = w(null), ol = (e = !1) => {
337
+ sl(n);
338
+ }, fe = $(null), sl = (e = !1) => {
342
339
  clearTimeout(fe.value), fe.value = setTimeout(() => {
343
340
  g("update:filter", { ...t.value }, e), g("apply-filter", { ...t.value }, e);
344
341
  }, 500);
345
- }, ul = (e, l) => {
342
+ }, ol = (e, l) => {
346
343
  (l === a.value.tabs.key || l === "tabs") && (B.value = ""), V(e), g("filter-removed", l);
347
- }, ye = w(!1);
348
- Ke(() => {
349
- ll(), dl(() => {
350
- g("on-table-ready"), ye.value = !0;
344
+ };
345
+ Te(() => {
346
+ el(), nl(() => {
347
+ g("on-table-ready");
351
348
  });
352
349
  });
353
- const ie = $(() => u.isLoading || v.value);
350
+ const ue = S(() => i.isLoading || v.value);
354
351
  se({
355
352
  localData: E,
356
353
  paginationData: o,
357
- tableIsLoading: ie,
354
+ tableIsLoading: ue,
358
355
  bulkPutLocalData: C,
359
356
  bulkDeleteLocalData: ee,
360
357
  getLocalDataUpdatedAt: le,
361
358
  getProductIdAndLastUpdatedAt: ae,
362
- syncLocalData: ue,
363
- sortByData: z
359
+ syncLocalData: ie,
360
+ sortByData: R
364
361
  });
365
362
  const il = ({ key: e, value: l }) => {
366
- Object.keys(z.value).forEach((c) => {
367
- c !== e && (z.value[c] = null);
368
- }), z.value[e] = l, g("update:sort-by", z.value);
363
+ Object.keys(R.value).forEach((c) => {
364
+ c !== e && (R.value[c] = null);
365
+ }), R.value[e] = l, g("update:sort-by", R.value);
369
366
  };
370
367
  return ne(
371
368
  () => t.value,
372
369
  () => {
373
- K.value && t.value && Re({ ...t.value });
370
+ K.value && t.value && Qe({ ...t.value });
374
371
  },
375
372
  { deep: !0, immediate: !0 }
376
373
  ), ne(
377
- () => u.sortBy,
374
+ () => i.sortBy,
378
375
  () => {
379
- K.value && u.sortBy && ze({ ...u.sortBy });
376
+ K.value && i.sortBy && ze({ ...i.sortBy });
380
377
  },
381
378
  { deep: !0, immediate: !0 }
382
379
  ), (e, l) => {
383
- var c, n, y, m;
384
- return ye.value ? (r(), h("div", Ul, [
385
- ce.value ? (r(), L(vl(F.isNewTable ? i(pl) : i(fl)), {
380
+ var c, n, f, m;
381
+ return r(), h("div", Bl, [
382
+ ce.value ? (r(), L(dl(F.isNewTable ? u(ml) : u(pl)), {
386
383
  key: 0,
387
384
  selected: F.selected,
388
385
  "row-key": F.rowKey,
389
386
  options: ce.value,
390
- "is-loading": ie.value,
391
- "loading-rows": R.value,
387
+ "is-loading": ue.value,
388
+ "loading-rows": z.value,
392
389
  "row-class": F.rowClass,
393
390
  "row-link": F.rowLink,
394
391
  "is-sticky": O.value.isSticky,
@@ -398,42 +395,42 @@ const El = { class: "p-5 gap-y-4 text-sm flex w-[250px] flex-col" }, Cl = {
398
395
  "onUpdate:sortBy": il,
399
396
  "onClick:row": l[9] || (l[9] = (s) => e.$emit("click:row", s)),
400
397
  "onHover:cell": l[10] || (l[10] = (s) => e.$emit("hover:cell", s))
401
- }, cl({
402
- after: S(() => [
398
+ }, vl({
399
+ after: w(() => [
403
400
  A(e.$slots, "after")
404
401
  ]),
405
- empty: S(() => [
402
+ empty: w(() => [
406
403
  A(e.$slots, "empty")
407
404
  ]),
408
- "table-header": S((s) => [
409
- A(e.$slots, "table-header", Le(je(s)))
405
+ "table-header": w((s) => [
406
+ A(e.$slots, "table-header", Ae(Le(s)))
410
407
  ]),
411
- "table-body": S((s) => [
412
- A(e.$slots, "table-body", Le(je(s)))
408
+ "table-body": w((s) => [
409
+ A(e.$slots, "table-body", Ae(Le(s)))
413
410
  ]),
414
411
  _: 2
415
412
  }, [
416
- e.$slots.before || (c = a.value) != null && c.search || (n = a.value) != null && n.form || (y = a.value) != null && y.tabs ? {
413
+ e.$slots.before || (c = a.value) != null && c.search || (n = a.value) != null && n.form || (f = a.value) != null && f.tabs ? {
417
414
  name: "before",
418
- fn: S(() => {
415
+ fn: w(() => {
419
416
  var s, b, x, P;
420
417
  return [
421
418
  A(e.$slots, "before"),
422
- (s = a.value) != null && s.search || (b = a.value) != null && b.form || (x = a.value) != null && x.tabs ? (r(), h("div", Tl, [
423
- Xe.value ? (r(), h("div", Kl, [
419
+ (s = a.value) != null && s.search || (b = a.value) != null && b.form || (x = a.value) != null && x.tabs ? (r(), h("div", Ul, [
420
+ We.value ? (r(), h("div", Tl, [
424
421
  A(e.$slots, "bulk-actions", { selectedRows: F.selected })
425
- ])) : (r(), h("div", Il, [
426
- (P = a.value) != null && P.tabs ? (r(), L(i(yl), {
422
+ ])) : (r(), h("div", Kl, [
423
+ (P = a.value) != null && P.tabs ? (r(), L(u(fl), {
427
424
  key: 0,
428
425
  modelValue: B.value,
429
426
  "onUpdate:modelValue": [
430
427
  l[0] || (l[0] = (D) => B.value = D),
431
428
  l[1] || (l[1] = (D) => V(null, !1, "", !1, !0))
432
429
  ],
433
- "is-disabled": ie.value,
430
+ "is-disabled": ue.value,
434
431
  tabs: a.value.tabs.options,
435
432
  variant: "pills"
436
- }, null, 8, ["modelValue", "is-disabled", "tabs"])) : f("", !0)
433
+ }, null, 8, ["modelValue", "is-disabled", "tabs"])) : y("", !0)
437
434
  ])),
438
435
  A(e.$slots, "filter-options", {}, () => {
439
436
  var D, I, G, W, X, Y, Z, H, _, k, N;
@@ -445,16 +442,16 @@ const El = { class: "p-5 gap-y-4 text-sm flex w-[250px] flex-col" }, Cl = {
445
442
  a.value ? pe.value ? "md:w-fit w-full" : "" : "w-full justify-end"
446
443
  ])
447
444
  }, [
448
- (W = a.value) != null && W.search ? (r(), L(i(gl), {
445
+ (W = a.value) != null && W.search ? (r(), L(u(yl), {
449
446
  key: 0,
450
447
  "is-search-only": !a.value.tabs || a.value.isSearchOnly,
451
448
  "search-options": ((X = a.value.search) == null ? void 0 : X.options) ?? [],
452
449
  "selected-option": (((Y = t.value) == null ? void 0 : Y.selectedSearchOption) || ((_ = (H = (Z = a.value.search) == null ? void 0 : Z.options) == null ? void 0 : H[0]) == null ? void 0 : _.value)) ?? "keywords",
453
- onAddQuery: Ye,
450
+ onAddQuery: Xe,
454
451
  onToggle: l[2] || (l[2] = (p) => pe.value = p),
455
- onChangeSearchKey: al
456
- }, null, 8, ["is-search-only", "search-options", "selected-option"])) : f("", !0),
457
- (k = a.value) != null && k.form ? (r(), L(i(Ie), {
452
+ onChangeSearchKey: ll
453
+ }, null, 8, ["is-search-only", "search-options", "selected-option"])) : y("", !0),
454
+ (k = a.value) != null && k.form ? (r(), L(u(Ke), {
458
455
  key: 1,
459
456
  modelValue: Q.value,
460
457
  "onUpdate:modelValue": [
@@ -465,8 +462,8 @@ const El = { class: "p-5 gap-y-4 text-sm flex w-[250px] flex-col" }, Cl = {
465
462
  placement: "bottom-end",
466
463
  "is-attach-to-body": ""
467
464
  }, {
468
- menu: S(() => [
469
- Q.value ? (r(), L(i(bl), {
465
+ menu: w(() => [
466
+ Q.value ? (r(), L(u(gl), {
470
467
  key: 0,
471
468
  id: F.id,
472
469
  "json-form": a.value.form ?? [],
@@ -477,19 +474,19 @@ const El = { class: "p-5 gap-y-4 text-sm flex w-[250px] flex-col" }, Cl = {
477
474
  onFilterFieldsChanged: l[4] || (l[4] = (p) => g("filter-fields-changed", p)),
478
475
  onCancel: l[5] || (l[5] = (p) => Q.value = !1)
479
476
  }, {
480
- default: S(({ errors: p, values: te, jsonForm: rl, updateForm: nl }) => [
477
+ default: w(({ errors: p, values: te, jsonForm: ul, updateForm: rl }) => [
481
478
  A(e.$slots, "custom-filter-form", {
482
479
  errors: p,
483
480
  values: te,
484
- jsonForm: rl,
485
- updateFilter: nl
481
+ jsonForm: ul,
482
+ updateFilter: rl
486
483
  })
487
484
  ]),
488
485
  _: 3
489
- }, 8, ["id", "json-form", "grid", "values", "actions"])) : f("", !0)
486
+ }, 8, ["id", "json-form", "grid", "values", "actions"])) : y("", !0)
490
487
  ]),
491
- default: S(() => [
492
- j(i(Ne), {
488
+ default: w(() => [
489
+ j(u(Ie), {
493
490
  "is-active": Q.value,
494
491
  variant: "secondary",
495
492
  "left-icon": "filter",
@@ -499,25 +496,25 @@ const El = { class: "p-5 gap-y-4 text-sm flex w-[250px] flex-col" }, Cl = {
499
496
  }, null, 8, ["is-active"])
500
497
  ]),
501
498
  _: 3
502
- }, 8, ["modelValue"])) : f("", !0),
503
- a.value.columnEdit ? (r(), L(Bl, {
499
+ }, 8, ["modelValue"])) : y("", !0),
500
+ a.value.columnEdit ? (r(), L(jl, {
504
501
  key: 2,
505
502
  options: t.value.columnEdit,
506
503
  headers: ((N = O.value) == null ? void 0 : N.headers) || [],
507
504
  "local-key": a.value.columnEdit.localStorageKey,
508
- onUpdateOrder: el
509
- }, null, 8, ["options", "headers", "local-key"])) : f("", !0)
510
- ], 2)) : f("", !0)
505
+ onUpdateOrder: _e
506
+ }, null, 8, ["options", "headers", "local-key"])) : y("", !0)
507
+ ], 2)) : y("", !0)
511
508
  ];
512
509
  })
513
- ])) : f("", !0),
514
- j(i(kl), {
515
- filters: He.value,
510
+ ])) : y("", !0),
511
+ j(u(bl), {
512
+ filters: Ze.value,
516
513
  queries: U.value,
517
514
  class: "border-t border-oc-gray-200",
518
- onRemoveQuery: Ze,
519
- onRemoveAll: tl,
520
- onRemoveFilter: ul
515
+ onRemoveQuery: Ye,
516
+ onRemoveAll: al,
517
+ onRemoveFilter: ol
521
518
  }, null, 8, ["filters", "queries"])
522
519
  ];
523
520
  }),
@@ -525,61 +522,61 @@ const El = { class: "p-5 gap-y-4 text-sm flex w-[250px] flex-col" }, Cl = {
525
522
  } : void 0,
526
523
  de((m = O.value) == null ? void 0 : m.headers, (s, b) => ({
527
524
  name: s.key,
528
- fn: S(({ data: x, item: P }) => [
525
+ fn: w(({ data: x, item: P }) => [
529
526
  A(e.$slots, s.key, {
530
527
  data: x,
531
528
  item: P
532
529
  })
533
530
  ])
534
531
  }))
535
- ]), 1064, ["selected", "row-key", "options", "is-loading", "loading-rows", "row-class", "row-link", "is-sticky", "is-borderless", "sort-by"])) : f("", !0),
532
+ ]), 1064, ["selected", "row-key", "options", "is-loading", "loading-rows", "row-class", "row-link", "is-sticky", "is-borderless", "sort-by"])) : y("", !0),
536
533
  A(e.$slots, "before-pagination"),
537
- i(o) || d.value ? (r(), h("div", {
534
+ u(o) || d.value ? (r(), h("div", {
538
535
  key: 1,
539
- class: ve(["flex items-center gap-3", i(o) && i(o).last_page === 1 ? "justify-end" : ""])
536
+ class: ve(["flex items-center gap-3", u(o) && u(o).last_page === 1 ? "justify-end" : ""])
540
537
  }, [
541
- i(o) && !Me.value ? (r(), L(i(hl), {
538
+ u(o) && !Je.value ? (r(), L(u(kl), {
542
539
  key: 0,
543
540
  modelValue: M.value,
544
541
  "onUpdate:modelValue": [
545
542
  l[11] || (l[11] = (s) => M.value = s),
546
- sl
543
+ tl
547
544
  ],
548
545
  class: "justify-center text-[13px]",
549
- "max-page": i(o).last_page,
550
- strategy: i(o).strategy,
546
+ "max-page": u(o).last_page,
547
+ strategy: u(o).strategy,
551
548
  "total-visible": "5"
552
- }, null, 8, ["modelValue", "max-page", "strategy"])) : f("", !0),
553
- d.value ? (r(), h("div", Nl, [
554
- j(i(Be), {
549
+ }, null, 8, ["modelValue", "max-page", "strategy"])) : y("", !0),
550
+ d.value ? (r(), h("div", Il, [
551
+ j(u(je), {
555
552
  disabled: !d.value.prev,
556
553
  onClick: l[12] || (l[12] = (s) => d.value.prev ? V(null, !1, d.value.prev) : null)
557
554
  }, null, 8, ["disabled"]),
558
- j(i(Be), {
555
+ j(u(je), {
559
556
  disabled: !d.value.next,
560
557
  "is-next": "",
561
558
  onClick: l[13] || (l[13] = (s) => d.value.next ? V(null, !1, d.value.next) : null)
562
559
  }, null, 8, ["disabled"])
563
- ])) : f("", !0),
564
- Je.value ? f("", !0) : (r(), h("div", ql, [
565
- j(i(xl), {
566
- modelValue: R.value,
560
+ ])) : y("", !0),
561
+ Re.value ? y("", !0) : (r(), h("div", Nl, [
562
+ j(u(hl), {
563
+ modelValue: z.value,
567
564
  "onUpdate:modelValue": [
568
- l[14] || (l[14] = (s) => R.value = s),
565
+ l[14] || (l[14] = (s) => z.value = s),
569
566
  l[15] || (l[15] = (s) => V(null))
570
567
  ],
571
568
  label: "Item per page",
572
569
  "is-inline-label": "",
573
570
  "popper-options": { placement: "auto" },
574
- options: We.value,
571
+ options: Ge.value,
575
572
  "select-text-class": "!text-[13px]"
576
573
  }, null, 8, ["modelValue", "options"])
577
574
  ]))
578
- ], 2)) : f("", !0)
579
- ])) : f("", !0);
575
+ ], 2)) : y("", !0)
576
+ ]);
580
577
  };
581
578
  }
582
579
  };
583
580
  export {
584
- Zl as default
581
+ Yl as default
585
582
  };