sakana-element 2.1.1 → 2.1.3
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/README.md +1 -0
- package/dist/es/Alert-A4stKumX.js +19 -0
- package/dist/es/Badge-BG-vYP8Y.js +13 -0
- package/dist/es/Button-CFGE4_Ng.js +22 -0
- package/dist/es/{Collapse-l_8qKOBG.js → Collapse-B08VhCVq.js} +2 -2
- package/dist/es/{ConfigProvider-BPm3h9RG.js → ConfigProvider-DZO1d5Eq.js} +1 -1
- package/dist/es/{Dropdown-ZjZ0qSn2.js → Dropdown-CA-nv-2j.js} +3 -3
- package/dist/es/{Form-pxRZxseS.js → Form-VB1SL_iW.js} +1 -1
- package/dist/es/{Icon-UBaqO2nY.js → Icon-DpJyuj7c.js} +1 -1
- package/dist/es/{Input-BJoBaFXa.js → Input-C-bIqqo_.js} +3 -3
- package/dist/es/{Loading-BJJBJhg3.js → Loading-4MsOvzx9.js} +3 -3
- package/dist/es/{Message-CqBKW0c8.js → Message-CxT9rRUp.js} +5 -5
- package/dist/es/{Notification-CVACM2cj.js → Notification-D6em5HmO.js} +7 -7
- package/dist/es/{Overlay-C1k4Jcl7.js → Overlay-BRDSWspM.js} +1 -1
- package/dist/es/{Popconfirm-CW8oRycq.js → Popconfirm-D0ABSr-F.js} +4 -4
- package/dist/es/{Select-C7mwByXa.js → Select-BKYDP224.js} +4 -4
- package/dist/es/{Switch-CgFPFC3j.js → Switch-C1IdbnUa.js} +1 -1
- package/dist/es/{Tooltip-D9rQ4LEg.js → Tooltip-KpwbZdMX.js} +16 -16
- package/dist/es/index.js +54 -52
- package/dist/es/utils-bsCscZfS.js +84 -0
- package/dist/index.css +1 -1
- package/dist/theme/Alert.css +114 -38
- package/dist/theme/Badge.css +208 -0
- package/dist/theme/Button.css +83 -83
- package/dist/types/components/Alert/types.d.ts +3 -0
- package/dist/types/components/Badge/index.d.ts +27 -0
- package/dist/types/components/Badge/types.d.ts +10 -0
- package/dist/types/components/Button/constants.d.ts +2 -0
- package/dist/types/components/index.d.ts +1 -0
- package/dist/types/hooks/useSystemTheme.d.ts +1 -1
- package/dist/types/utils/color.d.ts +33 -0
- package/dist/types/utils/index.d.ts +1 -0
- package/dist/umd/index.css +1 -1
- package/dist/umd/index.css.gz +0 -0
- package/dist/umd/index.umd.cjs +3 -3
- package/dist/umd/index.umd.cjs.gz +0 -0
- package/package.json +2 -2
- package/dist/es/Alert-C5X-XFGJ.js +0 -15
- package/dist/es/Button-DTik2ZP6.js +0 -33
- package/dist/es/utils-340oIQ8K.js +0 -59
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
import { h as o, d as e, y as r } from "./vendor-DXmGx29U.js";
|
|
2
|
+
import { defineComponent as n } from "vue";
|
|
3
|
+
function t(o2, e2) {
|
|
4
|
+
const r2 = parseInt(o2.replace("#", ""), 16);
|
|
5
|
+
return `#${(Math.max(0, (r2 >> 16) - Math.round(2.55 * e2)) << 16 | Math.max(0, (r2 >> 8 & 255) - Math.round(2.55 * e2)) << 8 | Math.max(0, (255 & r2) - Math.round(2.55 * e2))).toString(16).padStart(6, "0")}`;
|
|
6
|
+
}
|
|
7
|
+
function c(o2, e2) {
|
|
8
|
+
const r2 = parseInt(o2.replace("#", ""), 16);
|
|
9
|
+
return `#${(Math.min(255, (r2 >> 16) + Math.round(2.55 * e2)) << 16 | Math.min(255, (r2 >> 8 & 255) + Math.round(2.55 * e2)) << 8 | Math.min(255, (255 & r2) + Math.round(2.55 * e2))).toString(16).padStart(6, "0")}`;
|
|
10
|
+
}
|
|
11
|
+
function a(o2) {
|
|
12
|
+
const e2 = parseInt(o2.replace("#", ""), 16);
|
|
13
|
+
return (0.299 * (e2 >> 16) + 0.587 * (e2 >> 8 & 255) + 0.114 * (255 & e2)) / 255 > 0.6 ? "#1e1e2e" : "#ffffff";
|
|
14
|
+
}
|
|
15
|
+
function s(o2) {
|
|
16
|
+
return { color: o2, dark: t(o2, 15), light: c(o2, 35), contrast: a(o2), transparent: "transparent" };
|
|
17
|
+
}
|
|
18
|
+
function i(o2, e2, r2) {
|
|
19
|
+
const n2 = {};
|
|
20
|
+
for (const [t2, c2] of Object.entries(r2)) n2[`--${e2}-${t2}`] = o2[c2];
|
|
21
|
+
return n2;
|
|
22
|
+
}
|
|
23
|
+
const l = { outline: { "text-color": "color", "bg-color": "transparent", "border-color": "color", "shadow-color": "transparent" }, dash: { "text-color": "color", "bg-color": "light", "border-color": "color", "shadow-color": "transparent" }, default: { "text-color": "contrast", "bg-color": "color", "border-color": "dark", "shadow-color": "dark" } };
|
|
24
|
+
function f(o2, e2) {
|
|
25
|
+
}
|
|
26
|
+
const u = { spinner: "loader", loading: "loader", "eye-slash": "eye-closed", "eye-off": "eye-closed", xmark: "close", x: "close", times: "close", "circle-xmark": "close-box", "x-circle": "close-box", "times-circle": "close-box", error: "close-box", "circle-info": "info-box", "info-circle": "info-box", info: "info-box", "check-circle": "check", "circle-check": "check", success: "check", "circle-exclamation": "warning-box", "exclamation-circle": "warning-box", warning: "warning-box", "angle-down": "chevron-down", "caret-down": "chevron-down", "angle-up": "chevron-up", "caret-up": "chevron-up", "angle-left": "chevron-left", "caret-left": "chevron-left", "angle-right": "chevron-right", "caret-right": "chevron-right", "question-circle": "info-box", "circle-question": "info-box", help: "info-box", question: "info-box", gear: "sliders", cog: "sliders", settings: "sliders", star: "bookmark", "star-solid": "bookmark" };
|
|
27
|
+
function d(o2) {
|
|
28
|
+
return o2 in u ? u[o2] : o2;
|
|
29
|
+
}
|
|
30
|
+
const h = /* @__PURE__ */ new Set(["svg", "path", "rect", "circle", "ellipse", "line", "polyline", "polygon", "g", "defs", "clipPath", "mask", "title", "desc", "linearGradient", "radialGradient", "stop", "symbol", "use"]), p = /^on/i, m = /^\s*javascript\s*:/i;
|
|
31
|
+
function g(o2) {
|
|
32
|
+
if (!o2 || "string" != typeof o2) return "";
|
|
33
|
+
if ("undefined" == typeof DOMParser) return "";
|
|
34
|
+
const e2 = new DOMParser().parseFromString(o2, "image/svg+xml");
|
|
35
|
+
return e2.querySelector("parsererror") ? "" : (b(e2.documentElement), e2.documentElement.outerHTML);
|
|
36
|
+
}
|
|
37
|
+
function b(o2) {
|
|
38
|
+
const e2 = Array.from(o2.children);
|
|
39
|
+
for (const o3 of e2) {
|
|
40
|
+
const e3 = o3.tagName.toLowerCase();
|
|
41
|
+
if (h.has(e3)) {
|
|
42
|
+
for (const e4 of Array.from(o3.attributes)) (p.test(e4.name) || "href" === e4.name && m.test(e4.value) || "xlink:href" === e4.name && m.test(e4.value)) && o3.removeAttribute(e4.name);
|
|
43
|
+
b(o3);
|
|
44
|
+
} else o3.remove();
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
const x = /* @__PURE__ */ new Map();
|
|
48
|
+
function v(o2) {
|
|
49
|
+
for (const [e2, r2] of Object.entries(o2)) x.set(e2, g(r2));
|
|
50
|
+
}
|
|
51
|
+
function w(o2) {
|
|
52
|
+
return x.get(o2);
|
|
53
|
+
}
|
|
54
|
+
const k = (o2) => (o2.install = (e2) => {
|
|
55
|
+
const r2 = o2.name;
|
|
56
|
+
e2.component(r2, o2);
|
|
57
|
+
}, o2), M = (o2, e2) => (o2.install = (r2) => {
|
|
58
|
+
r2.config.globalProperties[e2] = o2;
|
|
59
|
+
}, o2);
|
|
60
|
+
function y(r2, n2 = "px") {
|
|
61
|
+
return r2 ? o(r2) || ((o2) => !!e(o2) && !Number.isNaN(Number(o2)))(r2) ? `${r2}${n2}` : e(r2) ? r2 : void 0 : "";
|
|
62
|
+
}
|
|
63
|
+
const N = /* @__PURE__ */ new Map([["info", "info-box"], ["success", "check"], ["warning", "warning-box"], ["danger", "close-box"], ["error", "close-box"]]), S = n({ props: { vNode: { type: [String, Object, Function], required: true } }, setup: (o2) => () => r(o2.vNode) ? o2.vNode() : o2.vNode }), O = (o2, e2) => {
|
|
64
|
+
const r2 = o2.__vccOpts || o2;
|
|
65
|
+
for (const [o3, n2] of e2) r2[o3] = n2;
|
|
66
|
+
return r2;
|
|
67
|
+
};
|
|
68
|
+
export {
|
|
69
|
+
S as R,
|
|
70
|
+
l as S,
|
|
71
|
+
O as _,
|
|
72
|
+
d as a,
|
|
73
|
+
v as b,
|
|
74
|
+
s as c,
|
|
75
|
+
f as d,
|
|
76
|
+
y as e,
|
|
77
|
+
M as f,
|
|
78
|
+
w as g,
|
|
79
|
+
c as l,
|
|
80
|
+
i as r,
|
|
81
|
+
g as s,
|
|
82
|
+
N as t,
|
|
83
|
+
k as w
|
|
84
|
+
};
|