cleek 3.0.16 → 3.0.17
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.
- package/dist/main.cjs.js +1 -1
- package/dist/main.css +1 -1
- package/dist/main.es.js +48 -48
- package/package.json +1 -1
package/dist/main.es.js
CHANGED
|
@@ -856,7 +856,7 @@ const Ml = ["title", "aria-label", "disabled", "tabindex"], zl = 3e4, ft = "tran
|
|
|
856
856
|
pe(
|
|
857
857
|
() => n.value,
|
|
858
858
|
(B) => {
|
|
859
|
-
q && k.value === "number" && Number(v.value || 0) === Number(B) || (q = !0,
|
|
859
|
+
q && k.value === "number" && Number(v.value || 0) === Number(B) || (q = !0, ke(B));
|
|
860
860
|
},
|
|
861
861
|
{ immediate: !0 }
|
|
862
862
|
);
|
|
@@ -878,7 +878,7 @@ const Ml = ["title", "aria-label", "disabled", "tabindex"], zl = 3e4, ft = "tran
|
|
|
878
878
|
n.value === B && s("changeDelayed", B);
|
|
879
879
|
}, l.delayChangeTime);
|
|
880
880
|
}
|
|
881
|
-
function
|
|
881
|
+
function ye(B) {
|
|
882
882
|
var P;
|
|
883
883
|
s("click", B), (l.autoSelect || l.plusMinusButtons) && ((P = p.value) == null || P.select());
|
|
884
884
|
}
|
|
@@ -888,29 +888,29 @@ const Ml = ["title", "aria-label", "disabled", "tabindex"], zl = 3e4, ft = "tran
|
|
|
888
888
|
n.value = oe, !te && Number(P) !== oe && (v.value = oe), ee(oe);
|
|
889
889
|
return;
|
|
890
890
|
}
|
|
891
|
-
const B =
|
|
891
|
+
const B = ke(v.value);
|
|
892
892
|
ee(B);
|
|
893
893
|
}
|
|
894
894
|
function E() {
|
|
895
895
|
var P;
|
|
896
896
|
const B = (P = p.value) == null ? void 0 : P.value;
|
|
897
|
-
return B === void 0 || B === `${v.value}` ? !1 : (
|
|
897
|
+
return B === void 0 || B === `${v.value}` ? !1 : (ke(B), !0);
|
|
898
898
|
}
|
|
899
899
|
function Y() {
|
|
900
900
|
E(), ce(n.value);
|
|
901
901
|
}
|
|
902
|
-
function
|
|
902
|
+
function we(B) {
|
|
903
903
|
m.value = !0, s("focus", B), l.preventAutocomplete && (i.value = !0), k.value === "number" && !v.value && (v.value = "");
|
|
904
904
|
}
|
|
905
905
|
function fe(B) {
|
|
906
906
|
m.value = !1, E() && ce(n.value), s("blur", B);
|
|
907
907
|
}
|
|
908
908
|
function xe() {
|
|
909
|
-
const B =
|
|
909
|
+
const B = ke(+v.value - 1);
|
|
910
910
|
ee(B), ce(B);
|
|
911
911
|
}
|
|
912
912
|
function Ne() {
|
|
913
|
-
const B =
|
|
913
|
+
const B = ke(+v.value + 1);
|
|
914
914
|
ee(B), ce(B);
|
|
915
915
|
}
|
|
916
916
|
function Ce(B) {
|
|
@@ -925,7 +925,7 @@ const Ml = ["title", "aria-label", "disabled", "tabindex"], zl = 3e4, ft = "tran
|
|
|
925
925
|
const P = Number(Ce(B));
|
|
926
926
|
return Number.isFinite(P) ? P : 0;
|
|
927
927
|
}
|
|
928
|
-
function
|
|
928
|
+
function ke(B) {
|
|
929
929
|
if (k.value === "number") {
|
|
930
930
|
const te = B === "" || B === null || B === void 0, oe = te ? 0 : Ae(B);
|
|
931
931
|
return n.value = oe, v.value = te ? "" : oe, oe;
|
|
@@ -934,7 +934,7 @@ const Ml = ["title", "aria-label", "disabled", "tabindex"], zl = 3e4, ft = "tran
|
|
|
934
934
|
return n.value = P, v.value = P, P;
|
|
935
935
|
}
|
|
936
936
|
return Se(() => {
|
|
937
|
-
l.autofocus && (re(),
|
|
937
|
+
l.autofocus && (re(), ye(null));
|
|
938
938
|
}), (B, P) => {
|
|
939
939
|
var oe;
|
|
940
940
|
const te = at("tooltip");
|
|
@@ -989,10 +989,10 @@ const Ml = ["title", "aria-label", "disabled", "tabindex"], zl = 3e4, ft = "tran
|
|
|
989
989
|
style: U(O.value),
|
|
990
990
|
disabled: e.disabled,
|
|
991
991
|
tabindex: e.tabindex,
|
|
992
|
-
onClick: P[2] || (P[2] = (se) =>
|
|
992
|
+
onClick: P[2] || (P[2] = (se) => ye(se)),
|
|
993
993
|
onInput: P[3] || (P[3] = (se) => R()),
|
|
994
994
|
onChange: P[4] || (P[4] = (se) => Y()),
|
|
995
|
-
onFocus: P[5] || (P[5] = (se) =>
|
|
995
|
+
onFocus: P[5] || (P[5] = (se) => we(se)),
|
|
996
996
|
onBlur: P[6] || (P[6] = (se) => fe(se))
|
|
997
997
|
}, null, 46, Wl), [
|
|
998
998
|
[lo, v.value]
|
|
@@ -1636,11 +1636,11 @@ const Tn = { class: "ck-table" }, Sn = {
|
|
|
1636
1636
|
}, (L) => {
|
|
1637
1637
|
L && (ce.value = !0);
|
|
1638
1638
|
}, { immediate: !0 });
|
|
1639
|
-
const
|
|
1639
|
+
const ye = r(() => !a.rows || a.rows.length || typeof a.isLoading > "u" ? !1 : ce.value ? ee.value : !0), R = r(() => ye.value || typeof a.listLength > "u" || a.listLength ? !1 : typeof a.isLoading > "u" ? !0 : a.rows ? ce.value : !a.isLoading), E = r(() => {
|
|
1640
1640
|
var L;
|
|
1641
1641
|
return ee.value && !!((L = a.rows) != null && L.length);
|
|
1642
1642
|
}), Y = r(() => Math.min(a.itemsPerPage || 8, 8));
|
|
1643
|
-
function
|
|
1643
|
+
function we(L, g) {
|
|
1644
1644
|
return `${55 + (L * 7 + g * 13) % 35}%`;
|
|
1645
1645
|
}
|
|
1646
1646
|
function fe(L = !1) {
|
|
@@ -1663,7 +1663,7 @@ const Tn = { class: "ck-table" }, Sn = {
|
|
|
1663
1663
|
if (t.value.areAllRowsSelecteds(L)) return !0;
|
|
1664
1664
|
if (!t.value.isAnyRowsSelected(L))
|
|
1665
1665
|
return !1;
|
|
1666
|
-
}),
|
|
1666
|
+
}), ke = r(() => Ae.value === void 0 ? null : Ae.value), B = r(() => {
|
|
1667
1667
|
var L, g;
|
|
1668
1668
|
return ((g = (L = t.value) == null ? void 0 : L.ids) == null ? void 0 : g.size) || 0;
|
|
1669
1669
|
}), P = r(() => !!a.listLength && B.value >= a.listLength);
|
|
@@ -1698,7 +1698,7 @@ const Tn = { class: "ck-table" }, Sn = {
|
|
|
1698
1698
|
n.value = [...n.value, z];
|
|
1699
1699
|
}
|
|
1700
1700
|
return (L, g) => {
|
|
1701
|
-
var
|
|
1701
|
+
var be, Ee, rt, ct;
|
|
1702
1702
|
const z = X("ck-chip"), j = X("ck-th"), W = X("ck-checkbox"), ae = X("ck-skeleton");
|
|
1703
1703
|
return c(), h("div", Tn, [
|
|
1704
1704
|
L.$slots.header || !e.hideHeaderActions ? (c(), h("div", Sn, [
|
|
@@ -1729,11 +1729,11 @@ const Tn = { class: "ck-table" }, Sn = {
|
|
|
1729
1729
|
K(L.$slots, "headerBottom", {}, void 0, !0)
|
|
1730
1730
|
])) : y("", !0),
|
|
1731
1731
|
i.value || x.value.length && !(L.$slots.mobile && le.value) ? (c(), h("div", Mn, [
|
|
1732
|
-
(Ee = (
|
|
1732
|
+
(Ee = (be = t.value) == null ? void 0 : be.ids) != null && Ee.size ? (c(), h("div", zn, [
|
|
1733
1733
|
C("div", En, [
|
|
1734
1734
|
F(Tt, {
|
|
1735
1735
|
class: "main-checkbox",
|
|
1736
|
-
"page-selection-state":
|
|
1736
|
+
"page-selection-state": ke.value,
|
|
1737
1737
|
"page-count": e.rows.length,
|
|
1738
1738
|
"selected-count": B.value,
|
|
1739
1739
|
"list-length": e.listLength,
|
|
@@ -1780,7 +1780,7 @@ const Tn = { class: "ck-table" }, Sn = {
|
|
|
1780
1780
|
i.value ? (c(), h("th", Fn, [
|
|
1781
1781
|
F(Tt, {
|
|
1782
1782
|
class: "main-checkbox",
|
|
1783
|
-
"page-selection-state":
|
|
1783
|
+
"page-selection-state": ke.value,
|
|
1784
1784
|
"page-count": e.rows.length,
|
|
1785
1785
|
"selected-count": B.value,
|
|
1786
1786
|
"list-length": e.listLength,
|
|
@@ -1875,14 +1875,14 @@ const Tn = { class: "ck-table" }, Sn = {
|
|
|
1875
1875
|
} : void 0
|
|
1876
1876
|
]), 1032, ["is-selected", "is-expandable", "is-expanded", "columns-count", "row-class", "onToggleExpansion"]);
|
|
1877
1877
|
}), 128)),
|
|
1878
|
-
|
|
1878
|
+
ye.value ? (c(!0), h(_, { key: 0 }, ie(Y.value, (Z) => (c(), h("tr", {
|
|
1879
1879
|
key: Z,
|
|
1880
1880
|
class: "ck-table__skeleton-row"
|
|
1881
1881
|
}, [
|
|
1882
1882
|
(c(!0), h(_, null, ie(Je.value, (me) => (c(), h("td", { key: me }, [
|
|
1883
1883
|
F(ae, {
|
|
1884
1884
|
height: "0.9rem",
|
|
1885
|
-
width:
|
|
1885
|
+
width: we(Z, me)
|
|
1886
1886
|
}, null, 8, ["width"])
|
|
1887
1887
|
]))), 128))
|
|
1888
1888
|
]))), 128)) : y("", !0),
|
|
@@ -1901,17 +1901,17 @@ const Tn = { class: "ck-table" }, Sn = {
|
|
|
1901
1901
|
class: V(["ck-table--mobile-container", { "ck-table__body--refreshing": E.value }])
|
|
1902
1902
|
}, [
|
|
1903
1903
|
K(L.$slots, "mobile", {}, void 0, !0),
|
|
1904
|
-
|
|
1904
|
+
ye.value ? (c(!0), h(_, { key: 0 }, ie(Y.value, (Z) => (c(), h("div", {
|
|
1905
1905
|
key: Z,
|
|
1906
1906
|
class: "ck-table__skeleton-card"
|
|
1907
1907
|
}, [
|
|
1908
1908
|
F(ae, {
|
|
1909
1909
|
height: "0.9rem",
|
|
1910
|
-
width:
|
|
1910
|
+
width: we(Z, 0)
|
|
1911
1911
|
}, null, 8, ["width"]),
|
|
1912
1912
|
F(ae, {
|
|
1913
1913
|
height: "0.9rem",
|
|
1914
|
-
width:
|
|
1914
|
+
width: we(Z, 1)
|
|
1915
1915
|
}, null, 8, ["width"])
|
|
1916
1916
|
]))), 128)) : y("", !0),
|
|
1917
1917
|
R.value ? (c(), S(St, {
|
|
@@ -3169,11 +3169,11 @@ const Ea = /* @__PURE__ */ Fe(Ta, [["render", za]]), Oa = ["id"], Ra = {
|
|
|
3169
3169
|
if (!O.length) return;
|
|
3170
3170
|
const q = O.find((xe) => xe.offsetWidth > 0) || O[0], le = (x.querySelector(".v3dp__datepicker input") || x).getBoundingClientRect();
|
|
3171
3171
|
q.style.top = "0px", q.style.left = "0px";
|
|
3172
|
-
const ee = q.getBoundingClientRect(), ce = ee.height || 300,
|
|
3172
|
+
const ee = q.getBoundingClientRect(), ce = ee.height || 300, ye = ee.width || 280;
|
|
3173
3173
|
let E = le.bottom + 4;
|
|
3174
3174
|
const Y = window.innerHeight - ce - 8;
|
|
3175
3175
|
E > Y && (E = Math.max(Y, 8));
|
|
3176
|
-
const
|
|
3176
|
+
const we = window.innerWidth - ye - 8, fe = Math.max(Math.min(le.left, we), 8);
|
|
3177
3177
|
for (const xe of O)
|
|
3178
3178
|
xe.style.top = `${E - ee.top}px`, xe.style.left = `${fe - ee.left}px`;
|
|
3179
3179
|
}
|
|
@@ -3926,8 +3926,8 @@ const Ti = {
|
|
|
3926
3926
|
E && R.push({ "font-size": E }), l.width && R.push({ width: l.width });
|
|
3927
3927
|
const Y = l.width ? "95%" : l.maxWidth || a.value.popup.maxWidth;
|
|
3928
3928
|
Y && R.push({ "max-width": Y });
|
|
3929
|
-
const
|
|
3930
|
-
|
|
3929
|
+
const we = l.textColor || a.value.popup.textColor;
|
|
3930
|
+
we && !I.isColorTemplateVariable(we) && (R.push(`ck-component__color--${we}`), R.push({ color: we }));
|
|
3931
3931
|
let fe = "var(--ck-surface-solid)";
|
|
3932
3932
|
return a.value.popup.backgroundColor && (fe = a.value.popup.backgroundColor), a.value.darkMode && (fe = a.value.darkModeColorItems), l.backgroundColor && (fe = l.backgroundColor), fe && !I.isColorTemplateVariable(fe) && R.push({ backgroundColor: fe }), R;
|
|
3933
3933
|
}), d = r(() => {
|
|
@@ -3974,16 +3974,16 @@ const Ti = {
|
|
|
3974
3974
|
const E = R.target;
|
|
3975
3975
|
return E instanceof HTMLElement ? E instanceof HTMLTextAreaElement || E.isContentEditable : !1;
|
|
3976
3976
|
}
|
|
3977
|
-
function
|
|
3977
|
+
function ye(R) {
|
|
3978
3978
|
if (t.value && (R.key === "Escape" && ee(), R.key === "Enter" && R.shiftKey)) {
|
|
3979
3979
|
if (ce(R)) return;
|
|
3980
3980
|
le();
|
|
3981
3981
|
}
|
|
3982
3982
|
}
|
|
3983
3983
|
return Se(() => {
|
|
3984
|
-
window.addEventListener("keydown",
|
|
3984
|
+
window.addEventListener("keydown", ye), t.value && f();
|
|
3985
3985
|
}), Ge(() => {
|
|
3986
|
-
window.removeEventListener("keydown",
|
|
3986
|
+
window.removeEventListener("keydown", ye), i();
|
|
3987
3987
|
}), (R, E) => (c(), S(Ue, { to: "body" }, [
|
|
3988
3988
|
F(qe, { name: "ck-popup" }, {
|
|
3989
3989
|
default: N(() => [
|
|
@@ -4216,18 +4216,18 @@ const Wi = {
|
|
|
4216
4216
|
if (k.value) return l.options;
|
|
4217
4217
|
const g = At(i.value).split(" ");
|
|
4218
4218
|
return l.options.filter((z) => {
|
|
4219
|
-
const j = At(Ae(z));
|
|
4219
|
+
const j = At(`${Ae(z)} ${ke(z)}`);
|
|
4220
4220
|
return g.every((W) => j.includes(W));
|
|
4221
4221
|
});
|
|
4222
4222
|
}), x = r(() => {
|
|
4223
|
-
const g = G.value, z = [...new Set(g.map((W) =>
|
|
4223
|
+
const g = G.value, z = [...new Set(g.map((W) => ke(W)).filter(Boolean))];
|
|
4224
4224
|
if (!z.length) return g;
|
|
4225
|
-
const j = z.flatMap((W) => g.filter((ae) =>
|
|
4226
|
-
return [...g.filter((W) => !
|
|
4225
|
+
const j = z.flatMap((W) => g.filter((ae) => ke(ae) === W));
|
|
4226
|
+
return [...g.filter((W) => !ke(W)), ...j];
|
|
4227
4227
|
}), O = r(() => {
|
|
4228
4228
|
let g = "";
|
|
4229
4229
|
return x.value.map((z, j) => {
|
|
4230
|
-
const W =
|
|
4230
|
+
const W = ke(z), ae = W && W !== g ? W : "";
|
|
4231
4231
|
return g = W, { option: z, optionIndex: j, headerName: ae };
|
|
4232
4232
|
});
|
|
4233
4233
|
}), q = r(() => x.value.length), re = r(() => {
|
|
@@ -4250,12 +4250,12 @@ const Wi = {
|
|
|
4250
4250
|
default:
|
|
4251
4251
|
return null;
|
|
4252
4252
|
}
|
|
4253
|
-
}),
|
|
4253
|
+
}), ye = r(() => {
|
|
4254
4254
|
const g = n.value;
|
|
4255
4255
|
return ee.value ? g === ee.value : typeof g == "number" ? g === 0 : typeof g == "string" ? g === "" : typeof g == "object" && g ? Array.isArray(g) ? g.length === 0 : Object.keys(g).length === 0 : g === null;
|
|
4256
4256
|
}), R = r(() => l.isLoading ? "Cargando..." : M.value ? l.emptyOptionsMsg : l.placeholder), E = r(
|
|
4257
|
-
() => (M.value ||
|
|
4258
|
-
), Y = r(() => le.value || l.notClearable ? !1 : !
|
|
4257
|
+
() => (M.value || ye.value) && !i.value && R.value || l.isLoading
|
|
4258
|
+
), Y = r(() => le.value || l.notClearable ? !1 : !ye.value), we = r(() => {
|
|
4259
4259
|
const g = [];
|
|
4260
4260
|
return l.icon && g.push("has-icon-left"), l.iconRight && g.push("has-icon-right"), g;
|
|
4261
4261
|
}), fe = r(() => {
|
|
@@ -4288,12 +4288,12 @@ const Wi = {
|
|
|
4288
4288
|
f.value = { display: "none" };
|
|
4289
4289
|
return;
|
|
4290
4290
|
}
|
|
4291
|
-
const z = 4, j = document.documentElement.clientHeight, W = document.documentElement.clientWidth, ae = p.value.getBoundingClientRect(),
|
|
4292
|
-
Ee ?
|
|
4291
|
+
const z = 4, j = document.documentElement.clientHeight, W = document.documentElement.clientWidth, ae = p.value.getBoundingClientRect(), be = {}, Ee = ae.top < j / 2;
|
|
4292
|
+
Ee ? be.top = `${ae.bottom + z}px` : be.bottom = `${j - ae.top + z}px`;
|
|
4293
4293
|
const Z = Math.min(360, W - ae.left - 8);
|
|
4294
|
-
|
|
4294
|
+
be.left = `${ae.left}px`, be.width = "max-content", be["min-width"] = `${ae.width}px`, be["max-width"] = `${Math.max(ae.width, Z)}px`;
|
|
4295
4295
|
const me = 100;
|
|
4296
|
-
|
|
4296
|
+
be["max-height"] = Ee ? `${j - ae.top - me}px` : `${ae.bottom - me}px`, be.display = "block", f.value = be;
|
|
4297
4297
|
});
|
|
4298
4298
|
function Ce(g) {
|
|
4299
4299
|
return l.reduceValueFunction ? l.reduceValueFunction(g) : l.notReduceValue || l.notReduce ? g : l.reduceValueMethod ? g[l.reduceValueMethod]() : g[l.reduceValueProp];
|
|
@@ -4301,7 +4301,7 @@ const Wi = {
|
|
|
4301
4301
|
function Ae(g) {
|
|
4302
4302
|
return l.reduceNameFunction ? l.reduceNameFunction(g) : l.notReduceName || l.notReduce ? g : l.reduceNameMethod ? g[l.reduceNameMethod]() : g[l.reduceNameProp];
|
|
4303
4303
|
}
|
|
4304
|
-
function
|
|
4304
|
+
function ke(g) {
|
|
4305
4305
|
return l.reduceGroupFunction ? l.reduceGroupFunction(g) || "" : (g == null ? void 0 : g[l.reduceGroupProp]) || "";
|
|
4306
4306
|
}
|
|
4307
4307
|
function B() {
|
|
@@ -4358,7 +4358,7 @@ const Wi = {
|
|
|
4358
4358
|
}), ze(), (g, z) => {
|
|
4359
4359
|
const j = X("ck-button");
|
|
4360
4360
|
return c(), h("div", {
|
|
4361
|
-
class: V(["ck-select",
|
|
4361
|
+
class: V(["ck-select", we.value]),
|
|
4362
4362
|
style: U(fe.value)
|
|
4363
4363
|
}, [
|
|
4364
4364
|
e.label ? (c(), S(Xe, {
|
|
@@ -4403,15 +4403,15 @@ const Wi = {
|
|
|
4403
4403
|
class: "ck-input-dropdown",
|
|
4404
4404
|
style: U(f.value)
|
|
4405
4405
|
}, [
|
|
4406
|
-
(c(!0), h(_, null, ie(O.value, ({ option: W, optionIndex: ae, headerName:
|
|
4406
|
+
(c(!0), h(_, null, ie(O.value, ({ option: W, optionIndex: ae, headerName: be }) => (c(), h(_, {
|
|
4407
4407
|
key: Ce(W)
|
|
4408
4408
|
}, [
|
|
4409
|
-
|
|
4409
|
+
be ? (c(), h("li", Qi, A(be), 1)) : y("", !0),
|
|
4410
4410
|
C("li", {
|
|
4411
4411
|
class: V(["dropdown--option", {
|
|
4412
4412
|
"dropdown--option__selected": Ce(W) === n.value,
|
|
4413
4413
|
"dropdown--option__index-selected": ae === d.value,
|
|
4414
|
-
"dropdown--option__grouped":
|
|
4414
|
+
"dropdown--option__grouped": ke(W)
|
|
4415
4415
|
}]),
|
|
4416
4416
|
onMousedown: (Ee) => Me(Ce(W)),
|
|
4417
4417
|
onMouseenter: (Ee) => d.value = ae
|
|
@@ -4468,7 +4468,7 @@ const Wi = {
|
|
|
4468
4468
|
], 6);
|
|
4469
4469
|
};
|
|
4470
4470
|
}
|
|
4471
|
-
}), Xi = /* @__PURE__ */ Q(ji, [["__scopeId", "data-v-
|
|
4471
|
+
}), Xi = /* @__PURE__ */ Q(ji, [["__scopeId", "data-v-bc53592f"]]), Ji = {
|
|
4472
4472
|
key: 0,
|
|
4473
4473
|
class: "sidebar-header-title"
|
|
4474
4474
|
}, Yi = {
|