golden-logic-ui 1.2.371 → 1.2.373

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.
@@ -1,8 +1,14 @@
1
- import { ref as $, computed as x, watch as ge, onMounted as me, onUnmounted as ve, createElementBlock as g, openBlock as m, Fragment as S, createCommentVNode as T, normalizeClass as b, createElementVNode as r, toDisplayString as u, withDirectives as fe, renderList as I, vShow as he } from "vue";
2
- const ye = {
1
+ import { ref as _, computed as D, watch as de, onMounted as ce, onUnmounted as ge, createElementBlock as u, openBlock as d, Fragment as C, createCommentVNode as S, normalizeClass as b, createElementVNode as r, toDisplayString as c, withDirectives as me, renderList as N, vShow as ve } from "vue";
2
+ const fe = {
3
3
  key: 0,
4
4
  class: "gl-label-form"
5
- }, pe = { class: "mt-1 text-gray-900 dark:text-white" }, De = ["dir"], ke = ["for"], xe = { class: "relative" }, we = { class: "relative" }, Me = ["required", "name", "id", "value", "placeholder"], Ye = { class: "absolute z-50 mt-1 bg-white dark:bg-gray-800 rounded-lg shadow-lg border border-gray-200 dark:border-gray-700 p-4 w-[20rem] sm:w-auto max-w-[calc(100vw-2rem)]" }, be = { class: "flex flex-col sm:flex-row gap-4 sm:gap-6" }, _e = { class: "w-full sm:w-64" }, $e = { class: "flex items-center justify-between mb-3" }, Ce = { class: "text-sm font-semibold text-gray-900 dark:text-white" }, Se = { class: "grid grid-cols-7 gap-y-1 mb-1" }, Te = { class: "grid grid-cols-7" }, Ve = ["onClick", "onMouseenter", "disabled"], Ne = { class: "hidden sm:block sm:w-64" }, Ie = { class: "flex items-center justify-between mb-3" }, Le = { class: "text-sm font-semibold text-gray-900 dark:text-white" }, Be = { class: "grid grid-cols-7 gap-y-1 mb-1" }, Ee = { class: "grid grid-cols-7" }, Fe = ["onClick", "onMouseenter", "disabled"], qe = { class: "flex items-center justify-between gap-3 mt-4 pt-3 border-t border-gray-200 dark:border-gray-700" }, He = { class: "text-sm text-gray-600 dark:text-gray-300 truncate" }, Re = { class: "flex items-center gap-2 shrink-0" }, Ae = { class: "gl-span-form-error" }, Ze = {
5
+ }, he = { class: "mt-1 text-gray-900 dark:text-white" }, ye = ["dir"], pe = ["for"], ke = { class: "relative" }, De = { class: "relative" }, we = ["required", "name", "id", "value", "placeholder"], xe = { class: "absolute z-50 mt-1 bg-white dark:bg-gray-800 rounded-lg shadow-lg border border-gray-200 dark:border-gray-700 p-4 w-[20rem] sm:w-auto max-w-[calc(100vw-2rem)]" }, Ye = { class: "flex flex-col sm:flex-row gap-4 sm:gap-6" }, be = { class: "w-full sm:w-64" }, Me = { class: "flex items-center justify-between mb-3" }, _e = { class: "text-sm font-semibold text-gray-900 dark:text-white" }, $e = { class: "grid grid-cols-7 gap-y-1 mb-1" }, Ce = { class: "grid grid-cols-7" }, Se = ["onClick", "onMouseenter", "disabled"], Te = {
6
+ key: 1,
7
+ class: "w-9 h-9 mx-auto"
8
+ }, Ve = { class: "hidden sm:block sm:w-64" }, Ne = { class: "flex items-center justify-between mb-3" }, Ie = { class: "text-sm font-semibold text-gray-900 dark:text-white" }, Be = { class: "grid grid-cols-7 gap-y-1 mb-1" }, Le = { class: "grid grid-cols-7" }, Ee = ["onClick", "onMouseenter", "disabled"], Fe = {
9
+ key: 1,
10
+ class: "w-9 h-9 mx-auto"
11
+ }, qe = { class: "flex items-center justify-between gap-3 mt-4 pt-3 border-t border-gray-200 dark:border-gray-700" }, He = { class: "text-sm text-gray-600 dark:text-gray-300 truncate" }, Re = { class: "flex items-center gap-2 shrink-0" }, Ae = { class: "gl-span-form-error" }, Ze = {
6
12
  key: 1,
7
13
  class: "block mt-1 text-sm font-normal leading-5 text-gray-500"
8
14
  }, Pe = {
@@ -85,100 +91,95 @@ const ye = {
85
91
  }
86
92
  },
87
93
  emits: ["update:modelValue", "change"],
88
- setup(s, { emit: te }) {
89
- const o = s, E = te, L = $(null), M = $(!1), F = /* @__PURE__ */ new Date(), v = $(F.getMonth()), _ = $(F.getFullYear()), c = $(null), f = $(null), V = $(null), ae = x(() => H() === "ar"), q = {
94
+ setup(l, { emit: ee }) {
95
+ const o = l, E = ee, I = _(null), x = _(!1), F = /* @__PURE__ */ new Date(), v = _(F.getMonth()), M = _(F.getFullYear()), g = _(null), f = _(null), T = _(null), te = D(() => B() === "ar"), q = {
90
96
  en: { apply: "Apply", cancel: "Cancel" },
91
97
  ar: { apply: "تطبيق", cancel: "إلغاء" }
92
- }, H = () => o.locale && o.locale.startsWith("ar") ? "ar" : "en", R = (a) => q[H()][a] || q.en[a] || a, A = x(() => {
98
+ }, B = () => o.locale && o.locale.startsWith("ar") ? "ar" : "en", H = (a) => q[B()][a] || q.en[a] || a, R = D(() => {
93
99
  const a = [];
94
100
  for (let e = 0; e < 12; e++)
95
101
  a.push(new Date(2e3, e, 1).toLocaleDateString(o.locale, { month: "long" }));
96
102
  return a;
97
- }), Z = x(() => {
98
- const a = [];
99
- for (let e = 0; e < 7; e++)
100
- a.push(new Date(2e3, 0, 2 + e).toLocaleDateString(o.locale, { weekday: "short" }));
101
- return a;
103
+ }), A = D(() => {
104
+ const a = B() === "ar" ? "narrow" : "short", e = [];
105
+ for (let t = 0; t < 7; t++)
106
+ e.push(new Date(2e3, 0, 2 + t).toLocaleDateString(o.locale, { weekday: a }));
107
+ return e;
102
108
  }), Y = (a) => {
103
109
  if (!a) return null;
104
110
  let e, t, n;
105
- const l = String(a).split(/[-/]/);
106
- if (l.length !== 3) return null;
111
+ const s = String(a).split(/[-/]/);
112
+ if (s.length !== 3) return null;
107
113
  switch (o.date_format) {
108
114
  case "DD-MM-YYYY":
109
115
  case "DD/MM/YYYY":
110
- n = parseInt(l[0]), t = parseInt(l[1]) - 1, e = parseInt(l[2]);
116
+ n = parseInt(s[0]), t = parseInt(s[1]) - 1, e = parseInt(s[2]);
111
117
  break;
112
118
  case "MM-DD-YYYY":
113
119
  case "MM/DD/YYYY":
114
- t = parseInt(l[0]) - 1, n = parseInt(l[1]), e = parseInt(l[2]);
120
+ t = parseInt(s[0]) - 1, n = parseInt(s[1]), e = parseInt(s[2]);
115
121
  break;
116
122
  default:
117
- e = parseInt(l[0]), t = parseInt(l[1]) - 1, n = parseInt(l[2]);
123
+ e = parseInt(s[0]), t = parseInt(s[1]) - 1, n = parseInt(s[2]);
118
124
  break;
119
125
  }
120
126
  const p = new Date(e, t, n);
121
127
  return isNaN(p.getTime()) || p.getFullYear() !== e || p.getMonth() !== t || p.getDate() !== n ? null : p;
122
- }, z = (a) => {
128
+ }, Z = (a) => {
123
129
  if (!a) return null;
124
130
  if (String(a).toLowerCase() === "today") return /* @__PURE__ */ new Date();
125
131
  const e = String(a).match(/^([+-]?)(\d+)([dmy])$/i);
126
132
  if (e) {
127
- const l = e[1] === "-" ? -1 : 1, p = parseInt(e[2]) * l, w = e[3].toLowerCase(), k = /* @__PURE__ */ new Date();
128
- return w === "d" ? k.setDate(k.getDate() + p) : w === "m" ? k.setMonth(k.getMonth() + p) : w === "y" && k.setFullYear(k.getFullYear() + p), k;
133
+ const s = e[1] === "-" ? -1 : 1, p = parseInt(e[2]) * s, w = e[3].toLowerCase(), m = /* @__PURE__ */ new Date();
134
+ return w === "d" ? m.setDate(m.getDate() + p) : w === "m" ? m.setMonth(m.getMonth() + p) : w === "y" && m.setFullYear(m.getFullYear() + p), m;
129
135
  }
130
136
  const t = Y(a);
131
137
  if (t) return t;
132
138
  const n = new Date(a);
133
139
  return isNaN(n.getTime()) ? null : n;
134
- }, C = (a) => {
140
+ }, $ = (a) => {
135
141
  if (!a) return "";
136
142
  let e = a instanceof Date ? a : Y(a);
137
143
  if ((!e || isNaN(e.getTime())) && (e = new Date(a)), isNaN(e.getTime())) return "";
138
- const t = e.getFullYear(), n = String(e.getMonth() + 1).padStart(2, "0"), l = String(e.getDate()).padStart(2, "0");
144
+ const t = e.getFullYear(), n = String(e.getMonth() + 1).padStart(2, "0"), s = String(e.getDate()).padStart(2, "0");
139
145
  switch (o.date_format) {
140
146
  case "DD-MM-YYYY":
141
- return `${l}-${n}-${t}`;
147
+ return `${s}-${n}-${t}`;
142
148
  case "MM-DD-YYYY":
143
- return `${n}-${l}-${t}`;
149
+ return `${n}-${s}-${t}`;
144
150
  case "DD/MM/YYYY":
145
- return `${l}/${n}/${t}`;
151
+ return `${s}/${n}/${t}`;
146
152
  case "MM/DD/YYYY":
147
- return `${n}/${l}/${t}`;
153
+ return `${n}/${s}/${t}`;
148
154
  case "YYYY/MM/DD":
149
- return `${t}/${n}/${l}`;
155
+ return `${t}/${n}/${s}`;
150
156
  default:
151
- return `${t}-${n}-${l}`;
157
+ return `${t}-${n}-${s}`;
152
158
  }
153
159
  }, i = (a) => {
154
160
  const e = new Date(a);
155
161
  return e.setHours(0, 0, 0, 0), e;
156
- }, P = (a, e) => a && e && a.toDateString() === e.toDateString(), G = x(() => {
162
+ }, z = (a, e) => a && e && a.toDateString() === e.toDateString(), P = D(() => {
157
163
  const a = o.modelValue?.start, e = o.modelValue?.end;
158
164
  if (!a && !e) return "";
159
- const t = a ? C(Y(a) || new Date(a)) : "", n = e ? C(Y(e) || new Date(e)) : "";
165
+ const t = a ? $(Y(a) || new Date(a)) : "", n = e ? $(Y(e) || new Date(e)) : "";
160
166
  return t && n ? `${t} ${o.separator} ${n}` : t || n;
161
- }), re = x(() => {
162
- const a = c.value ? C(c.value) : "…", e = f.value ? C(f.value) : "…";
167
+ }), ae = D(() => {
168
+ const a = g.value ? $(g.value) : "…", e = f.value ? $(f.value) : "…";
163
169
  return `${a} ${o.separator} ${e}`;
164
- }), U = (a, e) => {
165
- const t = new Date(a, e, 1), n = new Date(a, e + 1, 0), l = t.getDay(), p = n.getDate(), w = [], k = new Date(a, e, 0).getDate();
166
- for (let d = l - 1; d >= 0; d--)
167
- w.push({
168
- day: k - d,
169
- currentMonth: !1,
170
- date: new Date(a, e - 1, k - d)
171
- });
172
- for (let d = 1; d <= p; d++)
173
- w.push({ day: d, currentMonth: !0, date: new Date(a, e, d) });
174
- const de = 42 - w.length;
175
- for (let d = 1; d <= de; d++)
176
- w.push({ day: d, currentMonth: !1, date: new Date(a, e + 1, d) });
170
+ }), G = (a, e) => {
171
+ const t = new Date(a, e, 1), n = new Date(a, e + 1, 0), s = t.getDay(), p = n.getDate(), w = [];
172
+ for (let m = 0; m < s; m++)
173
+ w.push({ day: null, currentMonth: !1, date: null });
174
+ for (let m = 1; m <= p; m++)
175
+ w.push({ day: m, currentMonth: !0, date: new Date(a, e, m) });
176
+ for (; w.length % 7 !== 0; )
177
+ w.push({ day: null, currentMonth: !1, date: null });
177
178
  return w;
178
- }, N = x(() => {
179
- const a = v.value === 11 ? 0 : v.value + 1, e = v.value === 11 ? _.value + 1 : _.value;
179
+ }, V = D(() => {
180
+ const a = v.value === 11 ? 0 : v.value + 1, e = v.value === 11 ? M.value + 1 : M.value;
180
181
  return { month: a, year: e };
181
- }), ne = x(() => U(_.value, v.value)), se = x(() => U(N.value.year, N.value.month)), D = (a) => {
182
+ }), re = D(() => G(M.value, v.value)), ne = D(() => G(V.value.year, V.value.month)), k = (a) => {
182
183
  if (o.disabled_days.includes(a.getDay())) return !0;
183
184
  if (o.disabled_dates && o.disabled_dates.length > 0) {
184
185
  const e = i(a);
@@ -189,110 +190,110 @@ const ye = {
189
190
  }
190
191
  }
191
192
  if (o.min_date) {
192
- const e = z(o.min_date);
193
+ const e = Z(o.min_date);
193
194
  if (e && i(a) < i(e)) return !0;
194
195
  }
195
196
  if (o.max_date) {
196
- const e = z(o.max_date);
197
+ const e = Z(o.max_date);
197
198
  if (e && i(a) > i(e)) return !0;
198
199
  }
199
200
  return !1;
200
- }, le = x(() => c.value && !f.value && V.value ? V.value : f.value), B = x(() => {
201
- const a = c.value, e = le.value;
201
+ }, le = D(() => g.value && !f.value && T.value ? T.value : f.value), L = D(() => {
202
+ const a = g.value, e = le.value;
202
203
  return !a || !e ? null : a <= e ? { lo: i(a), hi: i(e) } : { lo: i(e), hi: i(a) };
203
204
  }), h = (a) => {
204
- const e = B.value;
205
- return e ? i(a).getTime() === e.lo.getTime() : P(a, c.value);
205
+ const e = L.value;
206
+ return e ? i(a).getTime() === e.lo.getTime() : z(a, g.value);
206
207
  }, y = (a) => {
207
- const e = B.value;
208
+ const e = L.value;
208
209
  return e ? i(a).getTime() === e.hi.getTime() : !1;
209
- }, W = (a) => {
210
- const e = B.value;
210
+ }, U = (a) => {
211
+ const e = L.value;
211
212
  if (!e) return !1;
212
213
  const t = i(a).getTime();
213
214
  return t > e.lo.getTime() && t < e.hi.getTime();
214
- }, J = (a) => P(a, /* @__PURE__ */ new Date()), K = (a) => {
215
+ }, W = (a) => z(a, /* @__PURE__ */ new Date()), J = (a) => {
215
216
  const e = a.date;
216
- D(e) || (!c.value || c.value && f.value ? (c.value = i(e), f.value = null) : i(e) < c.value ? (f.value = c.value, c.value = i(e)) : f.value = i(e));
217
- }, Q = (a) => {
218
- c.value && !f.value && !D(a.date) && (V.value = a.date);
219
- }, oe = () => {
220
- v.value === 0 ? (v.value = 11, _.value--) : v.value--;
217
+ k(e) || (!g.value || g.value && f.value ? (g.value = i(e), f.value = null) : i(e) < g.value ? (f.value = g.value, g.value = i(e)) : f.value = i(e));
218
+ }, K = (a) => {
219
+ g.value && !f.value && !k(a.date) && (T.value = a.date);
220
+ }, se = () => {
221
+ v.value === 0 ? (v.value = 11, M.value--) : v.value--;
222
+ }, Q = () => {
223
+ v.value === 11 ? (v.value = 0, M.value++) : v.value++;
221
224
  }, X = () => {
222
- v.value === 11 ? (v.value = 0, _.value++) : v.value++;
223
- }, j = () => {
224
225
  const a = o.modelValue?.start, e = a ? Y(a) || new Date(a) : /* @__PURE__ */ new Date();
225
- isNaN(e.getTime()) || (v.value = e.getMonth(), _.value = e.getFullYear());
226
- }, ie = () => {
226
+ isNaN(e.getTime()) || (v.value = e.getMonth(), M.value = e.getFullYear());
227
+ }, oe = () => {
227
228
  const a = o.modelValue?.start, e = o.modelValue?.end;
228
- c.value = a ? i(Y(a) || new Date(a)) : null, f.value = e ? i(Y(e) || new Date(e)) : null, V.value = null, j(), M.value = !0;
229
- }, O = () => {
230
- M.value ? M.value = !1 : ie();
231
- }, ue = () => {
229
+ g.value = a ? i(Y(a) || new Date(a)) : null, f.value = e ? i(Y(e) || new Date(e)) : null, T.value = null, X(), x.value = !0;
230
+ }, j = () => {
231
+ x.value ? x.value = !1 : oe();
232
+ }, ie = () => {
232
233
  const a = {
233
- start: c.value ? C(c.value) : "",
234
- end: f.value ? C(f.value) : ""
234
+ start: g.value ? $(g.value) : "",
235
+ end: f.value ? $(f.value) : ""
235
236
  };
236
- E("update:modelValue", a), E("change", a), M.value = !1;
237
- }, ce = () => {
238
- M.value = !1;
239
- }, ee = (a) => {
240
- L.value && !L.value.contains(a.target) && (M.value = !1);
237
+ E("update:modelValue", a), E("change", a), x.value = !1;
238
+ }, ue = () => {
239
+ x.value = !1;
240
+ }, O = (a) => {
241
+ I.value && !I.value.contains(a.target) && (x.value = !1);
241
242
  };
242
- return ge(
243
+ return de(
243
244
  () => o.modelValue,
244
245
  () => {
245
- M.value || j();
246
+ x.value || X();
246
247
  },
247
248
  { deep: !0 }
248
- ), me(() => document.addEventListener("click", ee)), ve(() => document.removeEventListener("click", ee)), (a, e) => (m(), g(S, null, [
249
- s.show ? (m(), g("div", {
249
+ ), ce(() => document.addEventListener("click", O)), ge(() => document.removeEventListener("click", O)), (a, e) => (d(), u(C, null, [
250
+ l.show ? (d(), u("div", {
250
251
  key: 0,
251
- class: b(s.field_name)
252
+ class: b(l.field_name)
252
253
  }, [
253
- s.label_name ? (m(), g("label", ye, u(s.label_name), 1)) : T("", !0),
254
- r("p", pe, u(G.value), 1),
254
+ l.label_name ? (d(), u("label", fe, c(l.label_name), 1)) : S("", !0),
255
+ r("p", he, c(P.value), 1),
255
256
  e[0] || (e[0] = r("hr", { class: "opacity-100! bg-gray-200 border-0 dark:bg-gray-700" }, null, -1))
256
- ], 2)) : T("", !0),
257
- s.show ? T("", !0) : (m(), g("div", {
257
+ ], 2)) : S("", !0),
258
+ l.show ? S("", !0) : (d(), u("div", {
258
259
  key: 1,
259
260
  ref_key: "datepickerContainer",
260
- ref: L,
261
- dir: ae.value ? "rtl" : "ltr",
261
+ ref: I,
262
+ dir: te.value ? "rtl" : "ltr",
262
263
  class: b({
263
- [s.field_name]: s.field_name && s.field_name !== "",
264
- [s.container_class]: s.container_class && s.container_class !== ""
264
+ [l.field_name]: l.field_name && l.field_name !== "",
265
+ [l.container_class]: l.container_class && l.container_class !== ""
265
266
  })
266
267
  }, [
267
- s.label_name ? (m(), g("label", {
268
+ l.label_name ? (d(), u("label", {
268
269
  key: 0,
269
270
  class: b({
270
- "gl-label-form": s.error_message == "",
271
- "gl-label-form-invalid": s.error_message !== "",
272
- required: s.is_required
271
+ "gl-label-form": l.error_message == "",
272
+ "gl-label-form-invalid": l.error_message !== "",
273
+ required: l.is_required
273
274
  }),
274
- for: s.field_name
275
- }, u(s.label_name), 11, ke)) : T("", !0),
276
- r("div", xe, [
277
- r("div", we, [
275
+ for: l.field_name
276
+ }, c(l.label_name), 11, pe)) : S("", !0),
277
+ r("div", ke, [
278
+ r("div", De, [
278
279
  r("input", {
279
280
  type: "text",
280
281
  readonly: "",
281
282
  class: b(["rtl:text-right pe-10 cursor-pointer", {
282
- "gl-input-form": s.error_message == "",
283
- "gl-input-form-invalid": s.error_message !== "",
284
- [s.input_class]: s.input_class && s.input_class !== ""
283
+ "gl-input-form": l.error_message == "",
284
+ "gl-input-form-invalid": l.error_message !== "",
285
+ [l.input_class]: l.input_class && l.input_class !== ""
285
286
  }]),
286
- required: s.is_required,
287
- name: s.field_name,
288
- id: s.field_name,
289
- value: G.value,
290
- placeholder: s.placeholder,
291
- onClick: O
292
- }, null, 10, Me),
287
+ required: l.is_required,
288
+ name: l.field_name,
289
+ id: l.field_name,
290
+ value: P.value,
291
+ placeholder: l.placeholder,
292
+ onClick: j
293
+ }, null, 10, we),
293
294
  r("div", {
294
295
  class: "absolute inset-y-0 end-0 flex items-center pe-3 cursor-pointer",
295
- onClick: O
296
+ onClick: j
296
297
  }, e[1] || (e[1] = [
297
298
  r("svg", {
298
299
  class: "w-4 h-4 text-gray-500 dark:text-gray-400",
@@ -305,13 +306,13 @@ const ye = {
305
306
  ], -1)
306
307
  ]))
307
308
  ]),
308
- fe(r("div", Ye, [
309
- r("div", be, [
310
- r("div", _e, [
311
- r("div", $e, [
309
+ me(r("div", xe, [
310
+ r("div", Ye, [
311
+ r("div", be, [
312
+ r("div", Me, [
312
313
  r("button", {
313
314
  type: "button",
314
- onClick: oe,
315
+ onClick: se,
315
316
  class: "p-1 rounded text-gray-500 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-700"
316
317
  }, e[2] || (e[2] = [
317
318
  r("svg", {
@@ -328,11 +329,11 @@ const ye = {
328
329
  })
329
330
  ], -1)
330
331
  ])),
331
- r("span", Ce, u(A.value[v.value]) + " " + u(_.value), 1),
332
+ r("span", _e, c(R.value[v.value]) + " " + c(M.value), 1),
332
333
  e[4] || (e[4] = r("span", { class: "w-7 sm:hidden" }, null, -1)),
333
334
  r("button", {
334
335
  type: "button",
335
- onClick: X,
336
+ onClick: Q,
336
337
  class: "p-1 rounded text-gray-500 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-700 sm:hidden"
337
338
  }, e[3] || (e[3] = [
338
339
  r("svg", {
@@ -350,48 +351,48 @@ const ye = {
350
351
  ], -1)
351
352
  ]))
352
353
  ]),
353
- r("div", Se, [
354
- (m(!0), g(S, null, I(Z.value, (t) => (m(), g("div", {
354
+ r("div", $e, [
355
+ (d(!0), u(C, null, N(A.value, (t) => (d(), u("div", {
355
356
  key: "lh-" + t,
356
- class: "text-center text-xs font-semibold text-gray-700 dark:text-gray-300 py-1"
357
- }, u(t), 1))), 128))
357
+ class: "text-center text-xs font-semibold text-gray-700 dark:text-gray-300 py-1 truncate"
358
+ }, c(t), 1))), 128))
358
359
  ]),
359
- r("div", Te, [
360
- (m(!0), g(S, null, I(ne.value, (t, n) => (m(), g("div", {
360
+ r("div", Ce, [
361
+ (d(!0), u(C, null, N(re.value, (t, n) => (d(), u("div", {
361
362
  key: "l-" + n,
362
363
  class: b(["py-0.5", {
363
- "bg-primary/10 dark:bg-primaryDark/20": t.currentMonth && (W(t.date) || h(t.date) || y(t.date)),
364
+ "bg-primary/10 dark:bg-primaryDark/20": t.currentMonth && (U(t.date) || h(t.date) || y(t.date)),
364
365
  "rounded-s-full": h(t.date),
365
366
  "rounded-e-full": y(t.date)
366
367
  }])
367
368
  }, [
368
- r("button", {
369
+ t.currentMonth ? (d(), u("button", {
370
+ key: 0,
369
371
  type: "button",
370
- onClick: (l) => K(t),
371
- onMouseenter: (l) => Q(t),
372
- disabled: D(t.date),
372
+ onClick: (s) => J(t),
373
+ onMouseenter: (s) => K(t),
374
+ disabled: k(t.date),
373
375
  class: b([
374
376
  "w-9 h-9 mx-auto text-sm rounded-full flex items-center justify-center transition-colors",
375
377
  {
376
- "text-gray-300 dark:text-gray-600 pointer-events-none": !t.currentMonth,
377
- "text-gray-900 dark:text-white": t.currentMonth && !h(t.date) && !y(t.date) && !D(t.date),
378
- "bg-primary dark:bg-primaryDark text-white font-semibold": t.currentMonth && (h(t.date) || y(t.date)),
379
- "ring-1 ring-primary dark:ring-primaryDark": J(t.date) && t.currentMonth && !h(t.date) && !y(t.date),
380
- "hover:bg-gray-100 dark:hover:bg-gray-700": t.currentMonth && !h(t.date) && !y(t.date) && !D(t.date),
381
- "opacity-40 cursor-not-allowed": D(t.date)
378
+ "text-gray-900 dark:text-white": !h(t.date) && !y(t.date) && !k(t.date),
379
+ "bg-primary dark:bg-primaryDark text-white font-semibold": h(t.date) || y(t.date),
380
+ "ring-1 ring-primary dark:ring-primaryDark": W(t.date) && !h(t.date) && !y(t.date),
381
+ "hover:bg-gray-100 dark:hover:bg-gray-700": !h(t.date) && !y(t.date) && !k(t.date),
382
+ "opacity-40 cursor-not-allowed": k(t.date)
382
383
  }
383
384
  ])
384
- }, u(t.day), 43, Ve)
385
+ }, c(t.day), 43, Se)) : (d(), u("div", Te))
385
386
  ], 2))), 128))
386
387
  ])
387
388
  ]),
388
- r("div", Ne, [
389
- r("div", Ie, [
389
+ r("div", Ve, [
390
+ r("div", Ne, [
390
391
  e[6] || (e[6] = r("span", { class: "w-7" }, null, -1)),
391
- r("span", Le, u(A.value[N.value.month]) + " " + u(N.value.year), 1),
392
+ r("span", Ie, c(R.value[V.value.month]) + " " + c(V.value.year), 1),
392
393
  r("button", {
393
394
  type: "button",
394
- onClick: X,
395
+ onClick: Q,
395
396
  class: "p-1 rounded text-gray-500 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-700"
396
397
  }, e[5] || (e[5] = [
397
398
  r("svg", {
@@ -410,63 +411,63 @@ const ye = {
410
411
  ]))
411
412
  ]),
412
413
  r("div", Be, [
413
- (m(!0), g(S, null, I(Z.value, (t) => (m(), g("div", {
414
+ (d(!0), u(C, null, N(A.value, (t) => (d(), u("div", {
414
415
  key: "rh-" + t,
415
- class: "text-center text-xs font-semibold text-gray-700 dark:text-gray-300 py-1"
416
- }, u(t), 1))), 128))
416
+ class: "text-center text-xs font-semibold text-gray-700 dark:text-gray-300 py-1 truncate"
417
+ }, c(t), 1))), 128))
417
418
  ]),
418
- r("div", Ee, [
419
- (m(!0), g(S, null, I(se.value, (t, n) => (m(), g("div", {
419
+ r("div", Le, [
420
+ (d(!0), u(C, null, N(ne.value, (t, n) => (d(), u("div", {
420
421
  key: "r-" + n,
421
422
  class: b(["py-0.5", {
422
- "bg-primary/10 dark:bg-primaryDark/20": t.currentMonth && (W(t.date) || h(t.date) || y(t.date)),
423
+ "bg-primary/10 dark:bg-primaryDark/20": t.currentMonth && (U(t.date) || h(t.date) || y(t.date)),
423
424
  "rounded-s-full": h(t.date),
424
425
  "rounded-e-full": y(t.date)
425
426
  }])
426
427
  }, [
427
- r("button", {
428
+ t.currentMonth ? (d(), u("button", {
429
+ key: 0,
428
430
  type: "button",
429
- onClick: (l) => K(t),
430
- onMouseenter: (l) => Q(t),
431
- disabled: D(t.date),
431
+ onClick: (s) => J(t),
432
+ onMouseenter: (s) => K(t),
433
+ disabled: k(t.date),
432
434
  class: b([
433
435
  "w-9 h-9 mx-auto text-sm rounded-full flex items-center justify-center transition-colors",
434
436
  {
435
- "text-gray-300 dark:text-gray-600 pointer-events-none": !t.currentMonth,
436
- "text-gray-900 dark:text-white": t.currentMonth && !h(t.date) && !y(t.date) && !D(t.date),
437
- "bg-primary dark:bg-primaryDark text-white font-semibold": t.currentMonth && (h(t.date) || y(t.date)),
438
- "ring-1 ring-primary dark:ring-primaryDark": J(t.date) && t.currentMonth && !h(t.date) && !y(t.date),
439
- "hover:bg-gray-100 dark:hover:bg-gray-700": t.currentMonth && !h(t.date) && !y(t.date) && !D(t.date),
440
- "opacity-40 cursor-not-allowed": D(t.date)
437
+ "text-gray-900 dark:text-white": !h(t.date) && !y(t.date) && !k(t.date),
438
+ "bg-primary dark:bg-primaryDark text-white font-semibold": h(t.date) || y(t.date),
439
+ "ring-1 ring-primary dark:ring-primaryDark": W(t.date) && !h(t.date) && !y(t.date),
440
+ "hover:bg-gray-100 dark:hover:bg-gray-700": !h(t.date) && !y(t.date) && !k(t.date),
441
+ "opacity-40 cursor-not-allowed": k(t.date)
441
442
  }
442
443
  ])
443
- }, u(t.day), 43, Fe)
444
+ }, c(t.day), 43, Ee)) : (d(), u("div", Fe))
444
445
  ], 2))), 128))
445
446
  ])
446
447
  ])
447
448
  ]),
448
449
  r("div", qe, [
449
- r("span", He, u(re.value), 1),
450
+ r("span", He, c(ae.value), 1),
450
451
  r("div", Re, [
451
452
  r("button", {
452
453
  type: "button",
453
- onClick: ce,
454
+ onClick: ue,
454
455
  class: "px-4 py-2 text-sm font-medium rounded-lg text-gray-700 dark:text-gray-200 bg-gray-100 dark:bg-gray-700 hover:bg-gray-200 dark:hover:bg-gray-600 transition-colors"
455
- }, u(R("cancel")), 1),
456
+ }, c(H("cancel")), 1),
456
457
  r("button", {
457
458
  type: "button",
458
- onClick: ue,
459
+ onClick: ie,
459
460
  class: "px-4 py-2 text-sm font-medium rounded-lg text-white bg-primary dark:bg-primaryDark hover:bg-primary/90 dark:hover:bg-primaryDark/90 transition-colors"
460
- }, u(R("apply")), 1)
461
+ }, c(H("apply")), 1)
461
462
  ])
462
463
  ])
463
464
  ], 512), [
464
- [he, M.value]
465
+ [ve, x.value]
465
466
  ])
466
467
  ]),
467
- r("span", Ae, u(s.error_message), 1),
468
- s.description ? (m(), g("small", Ze, u(s.description), 1)) : T("", !0)
469
- ], 10, De))
468
+ r("span", Ae, c(l.error_message), 1),
469
+ l.description ? (d(), u("small", Ze, c(l.description), 1)) : S("", !0)
470
+ ], 10, ye))
470
471
  ], 64));
471
472
  }
472
473
  };
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "description": "The most popular library of interactive components built with Vuejs && Tailwind CSS",
4
4
  "type": "module",
5
5
  "private": false,
6
- "version": "1.2.371",
6
+ "version": "1.2.373",
7
7
  "repository": {
8
8
  "type": "git",
9
9
  "url": "git+https://github.com/mrgiant/GoldenLogicUi.git"