@gradient-ui/core 0.5.0-rc.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.
- package/README.md +4 -4
- package/dist/{GLoading.vue_vue_type_style_index_0_lang-CBB_GocW.js → GLoading.vue_vue_type_style_index_0_lang-COggAM7a.js} +90 -88
- package/dist/GLoading.vue_vue_type_style_index_0_lang-CoPHejAL.cjs +1 -0
- package/dist/{GSwitch.vue_vue_type_script_setup_true_lang-UTBNFP5X.js → GSwitch.vue_vue_type_script_setup_true_lang-CRlkCyW_.js} +2371 -2355
- package/dist/GSwitch.vue_vue_type_script_setup_true_lang-DZXv1j__.cjs +1 -0
- package/dist/{camelToKebabCase-6qY6WHvl.js → camelToKebabCase-BWbQb81D.js} +4 -4
- package/dist/components.cjs +1 -1
- package/dist/components.mjs +4 -4
- package/dist/default--73FwpwZ.cjs +4 -0
- package/dist/default-DlsS6GI_.js +58 -0
- package/dist/directives.cjs +1 -1
- package/dist/directives.mjs +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.mjs +112 -108
- package/dist/{mask-CZX-I_iy.js → mask-BqOamrcF.js} +2 -2
- package/dist/{mask-BbofdFd4.cjs → mask-ObMqNEfF.cjs} +1 -1
- package/dist/materialSurface-CbOpfFGO.js +634 -0
- package/dist/materialSurface-CjhWd_yD.cjs +1 -0
- package/dist/scheme-CZ0a0X5e.cjs +299 -0
- package/dist/scheme-Dqwdqg6N.js +1405 -0
- package/dist/services.cjs +1 -1
- package/dist/services.mjs +1 -1
- package/dist/style.css +1 -1
- package/dist/{surface-BKu4KfkY.js → surface-DImNM7I1.js} +49 -46
- package/dist/surface-_J0t7c3m.cjs +1 -0
- package/dist/theme.cjs +1 -1
- package/dist/theme.mjs +52 -48
- package/dist/types/components/ui/GAlert/GAlert.vue.d.ts +2 -2
- package/dist/types/components/ui/GBadge/GBadge.vue.d.ts +4 -4
- package/dist/types/components/ui/GButton/GButton.vue.d.ts +2 -2
- package/dist/types/components/ui/GChip/GChip.vue.d.ts +1 -1
- package/dist/types/components/ui/GExpansion/GExpansion.vue.d.ts +5 -5
- package/dist/types/components/ui/GFAB/GFAB.vue.d.ts +3 -3
- package/dist/types/components/ui/GGradientMaterial/GGradientMaterial.vue.d.ts +2 -2
- package/dist/types/components/ui/GSnackbar/GSnackbar.vue.d.ts +2 -2
- package/dist/types/components/ui/GTable/GTable.vue.d.ts +7 -7
- package/dist/types/components/ui/GToggleButton/GToggleButton.vue.d.ts +3 -3
- package/dist/types/theme/default.d.ts +2 -1
- package/dist/types/theme/gradient.d.ts +1 -1
- package/dist/types/theme/index.d.ts +6 -6
- package/dist/types/use/actionSurface.d.ts +5 -1650
- package/dist/types/use/gradient.d.ts +4 -1653
- package/dist/types/use/gradientMaterial.d.ts +1 -1
- package/dist/types/use/material.d.ts +3 -2
- package/dist/types/use/materialSurface.d.ts +10 -4
- package/dist/types/use/surfaceColor.d.ts +2 -1
- package/dist/types/use/surfaceMaterial.d.ts +45 -0
- package/dist/use.cjs +1 -1
- package/dist/use.mjs +2 -2
- package/dist/useSnackbar-D60dFSV1.cjs +1 -0
- package/dist/useSnackbar-us11nXny.js +922 -0
- package/package.json +4 -2
- package/dist/GLoading.vue_vue_type_style_index_0_lang-Bv3dWEq8.cjs +0 -1
- package/dist/GSwitch.vue_vue_type_script_setup_true_lang-BS6bb1XY.cjs +0 -1
- package/dist/default-BhuY-A3o.cjs +0 -4
- package/dist/default-OTmCd0Aq.js +0 -131
- package/dist/material-Ca7ZZAiO.cjs +0 -194
- package/dist/material-okvXHenb.js +0 -1162
- package/dist/materialSurface-BBrP9ltj.js +0 -591
- package/dist/materialSurface-CK8LN_dU.cjs +0 -1
- package/dist/surface-8z3gR7vF.cjs +0 -1
- package/dist/types/theme/gradient/animation/css.d.ts +0 -12
- package/dist/types/theme/gradient/animation/index.d.ts +0 -1
- package/dist/types/theme/gradient/colorMath.d.ts +0 -3
- package/dist/types/theme/gradient/constants.d.ts +0 -3
- package/dist/types/theme/gradient/core.d.ts +0 -1
- package/dist/types/theme/gradient/effects/index.d.ts +0 -1
- package/dist/types/theme/gradient/effects/morph.d.ts +0 -5
- package/dist/types/theme/gradient/effects/shadow.d.ts +0 -3
- package/dist/types/theme/gradient/formatters/canvas.d.ts +0 -2
- package/dist/types/theme/gradient/formatters/css.d.ts +0 -3
- package/dist/types/theme/gradient/formatters/index.d.ts +0 -1
- package/dist/types/theme/gradient/formatters/svg.d.ts +0 -5
- package/dist/types/theme/gradient/index.d.ts +0 -1
- package/dist/types/theme/gradient/material.d.ts +0 -1
- package/dist/types/theme/gradient/model.d.ts +0 -5
- package/dist/types/theme/gradient/presets.d.ts +0 -158
- package/dist/types/theme/gradient/recipes.d.ts +0 -14
- package/dist/types/theme/gradient/tokens.d.ts +0 -72
- package/dist/types/theme/gradient/types.d.ts +0 -117
- package/dist/types/theme/gradient/utils.d.ts +0 -10
- package/dist/useSnackbar-BHQshEZ8.cjs +0 -1
- package/dist/useSnackbar-DeNHZH8v.js +0 -908
|
@@ -1,1162 +0,0 @@
|
|
|
1
|
-
import { j as _, t as vt, i as A, H as k } from "./camelToKebabCase-6qY6WHvl.js";
|
|
2
|
-
const D = (t, e = 0, r = 1) => Math.min(r, Math.max(e, t)), Mt = (t) => {
|
|
3
|
-
const e = t.slice(1), r = e.length === 3 || e.length === 4 ? e.slice(0, 3).split("").map((a) => a.repeat(2)).join("") : e.slice(0, 6);
|
|
4
|
-
return r.length !== 6 || !/^[\da-f]{6}$/i.test(r) ? null : {
|
|
5
|
-
r: parseInt(r.slice(0, 2), 16),
|
|
6
|
-
g: parseInt(r.slice(2, 4), 16),
|
|
7
|
-
b: parseInt(r.slice(4, 6), 16)
|
|
8
|
-
};
|
|
9
|
-
}, kt = (t) => {
|
|
10
|
-
const e = t.match(
|
|
11
|
-
/^rgba?\(\s*([\d.]+)[,\s]+([\d.]+)[,\s]+([\d.]+)(?:\s*[,/]\s*[\d.]+%?)?\s*\)$/i
|
|
12
|
-
);
|
|
13
|
-
return e ? {
|
|
14
|
-
r: D(Number(e[1]), 0, 255),
|
|
15
|
-
g: D(Number(e[2]), 0, 255),
|
|
16
|
-
b: D(Number(e[3]), 0, 255)
|
|
17
|
-
} : null;
|
|
18
|
-
}, L = (t) => {
|
|
19
|
-
if (typeof t == "number") {
|
|
20
|
-
const r = t & 16777215;
|
|
21
|
-
return {
|
|
22
|
-
r: r >> 16 & 255,
|
|
23
|
-
g: r >> 8 & 255,
|
|
24
|
-
b: r & 255
|
|
25
|
-
};
|
|
26
|
-
}
|
|
27
|
-
const e = t.trim();
|
|
28
|
-
return e.startsWith("#") ? Mt(e) : e.toLowerCase().startsWith("rgb") ? kt(e) : null;
|
|
29
|
-
}, Ct = ({ r: t, g: e, b: r }) => `#${[t, e, r].map((a) => Math.round(a).toString(16).padStart(2, "0")).join("")}`, Gt = ({ r: t, g: e, b: r }) => `${Math.round(t)}, ${Math.round(e)}, ${Math.round(r)}`, Tt = (t, e) => {
|
|
30
|
-
const r = L(t) ?? L(e);
|
|
31
|
-
if (!r)
|
|
32
|
-
throw new Error(`Invalid fallback color: ${e}`);
|
|
33
|
-
return Ct(r);
|
|
34
|
-
}, P = 135, F = "center", nt = "farthest-corner", ot = (t = P) => typeof t == "number" ? `${t}deg` : t, v = (t) => typeof t == "number" ? `${t}px` : t, B = (t) => typeof t == "number" ? `${t}ms` : t, w = (t, e = 0, r = 1) => Math.min(r, Math.max(e, t)), C = (t, e) => {
|
|
35
|
-
if (e === void 0) return t;
|
|
36
|
-
const r = L(t);
|
|
37
|
-
return r ? `rgb(${Gt(r).replace(/,/g, "")} / ${w(e)})` : t;
|
|
38
|
-
}, R = ({ color: t, opacity: e, position: r }) => `${C(t, e)} ${r}%`, c = (t, e, r) => ({
|
|
39
|
-
color: t,
|
|
40
|
-
position: e
|
|
41
|
-
}), it = (t) => {
|
|
42
|
-
if (t.length <= 1) return t;
|
|
43
|
-
const e = t.map((a) => ({
|
|
44
|
-
...a,
|
|
45
|
-
position: a.position / 2
|
|
46
|
-
})), r = [...t].reverse().map((a) => ({
|
|
47
|
-
...a,
|
|
48
|
-
position: 100 - a.position / 2
|
|
49
|
-
}));
|
|
50
|
-
return [...e, ...r];
|
|
51
|
-
}, Nt = (t) => `@keyframes ${t} {
|
|
52
|
-
0% {
|
|
53
|
-
background-position: 0% 50%;
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
50% {
|
|
57
|
-
background-position: 100% 50%;
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
100% {
|
|
61
|
-
background-position: 0% 50%;
|
|
62
|
-
}
|
|
63
|
-
}`, Ot = (t) => `@keyframes ${t} {
|
|
64
|
-
0%, 100% {
|
|
65
|
-
filter: saturate(1) brightness(1);
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
50% {
|
|
69
|
-
filter: saturate(1.22) brightness(1.08);
|
|
70
|
-
}
|
|
71
|
-
}`, jt = (t) => `@keyframes ${t} {
|
|
72
|
-
0%, 100% {
|
|
73
|
-
filter: hue-rotate(0deg) saturate(1);
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
50% {
|
|
77
|
-
filter: hue-rotate(28deg) saturate(1.18);
|
|
78
|
-
}
|
|
79
|
-
}`, _t = (t) => `@keyframes ${t} {
|
|
80
|
-
from {
|
|
81
|
-
transform: translate(-50%, -50%) rotate(0deg);
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
to {
|
|
85
|
-
transform: translate(-50%, -50%) rotate(360deg);
|
|
86
|
-
}
|
|
87
|
-
}`, E = (t = {}) => {
|
|
88
|
-
const e = t.name ?? "g-gradient-shift", r = B(t.duration ?? 6e3), a = t.easing ?? "ease-in-out", o = t.selector ?? ".g-gradient-animated", n = t.preset ?? "shift";
|
|
89
|
-
return {
|
|
90
|
-
duration: r,
|
|
91
|
-
easing: a,
|
|
92
|
-
name: e,
|
|
93
|
-
preset: n,
|
|
94
|
-
selector: o
|
|
95
|
-
};
|
|
96
|
-
}, X = (t = {}) => {
|
|
97
|
-
const { name: e, preset: r } = E(t);
|
|
98
|
-
return r === "pulse" ? Ot(e) : r === "hue-rotate" ? jt(e) : r === "rotate" ? _t(e) : Nt(e);
|
|
99
|
-
}, st = (t = {}) => {
|
|
100
|
-
const { duration: e, easing: r, name: a, preset: o } = E(t);
|
|
101
|
-
return `${a} ${e} ${o === "rotate" ? "linear" : r} infinite`;
|
|
102
|
-
}, ct = (t = {}) => {
|
|
103
|
-
const { duration: e, easing: r, name: a, preset: o, selector: n } = E(t);
|
|
104
|
-
return o === "rotate" ? `${n} {
|
|
105
|
-
position: relative;
|
|
106
|
-
overflow: hidden;
|
|
107
|
-
}
|
|
108
|
-
|
|
109
|
-
${n}::before {
|
|
110
|
-
content: '';
|
|
111
|
-
position: absolute;
|
|
112
|
-
top: 50%;
|
|
113
|
-
left: 50%;
|
|
114
|
-
width: 200%;
|
|
115
|
-
height: 200%;
|
|
116
|
-
min-width: 150vmax;
|
|
117
|
-
min-height: 150vmax;
|
|
118
|
-
background: inherit;
|
|
119
|
-
animation: ${a} ${e} linear infinite;
|
|
120
|
-
transform-origin: center;
|
|
121
|
-
}` : o === "pulse" || o === "hue-rotate" ? `${n} {
|
|
122
|
-
animation: ${a} ${e} ${r} infinite;
|
|
123
|
-
}` : `${n} {
|
|
124
|
-
animation: ${a} ${e} ${r} infinite;
|
|
125
|
-
background-size: 220% 220%;
|
|
126
|
-
}`;
|
|
127
|
-
}, dt = (t = {}) => {
|
|
128
|
-
const e = X(t), r = ct(t);
|
|
129
|
-
return `${e}
|
|
130
|
-
${r}`;
|
|
131
|
-
}, _e = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
132
|
-
__proto__: null,
|
|
133
|
-
getGradientAnimationOptions: E,
|
|
134
|
-
toGradientAnimationCSS: dt,
|
|
135
|
-
toGradientAnimationKeyframes: X,
|
|
136
|
-
toGradientAnimationStyles: ct,
|
|
137
|
-
toGradientAnimationValue: st
|
|
138
|
-
}, Symbol.toStringTag, { value: "Module" })), At = [
|
|
139
|
-
50,
|
|
140
|
-
100,
|
|
141
|
-
200,
|
|
142
|
-
300,
|
|
143
|
-
400,
|
|
144
|
-
500,
|
|
145
|
-
600,
|
|
146
|
-
700,
|
|
147
|
-
800,
|
|
148
|
-
900
|
|
149
|
-
], Pt = {
|
|
150
|
-
50: 90,
|
|
151
|
-
100: 80,
|
|
152
|
-
200: 70,
|
|
153
|
-
300: 60,
|
|
154
|
-
400: 50,
|
|
155
|
-
500: 40,
|
|
156
|
-
600: 35,
|
|
157
|
-
700: 30,
|
|
158
|
-
800: 20,
|
|
159
|
-
900: 10
|
|
160
|
-
}, Bt = (t) => {
|
|
161
|
-
const e = Tt(t, "#000000");
|
|
162
|
-
return vt(A(e)).palettes.primary;
|
|
163
|
-
}, I = (t) => {
|
|
164
|
-
const e = Bt(t);
|
|
165
|
-
return Object.fromEntries(
|
|
166
|
-
At.map((r) => [
|
|
167
|
-
r,
|
|
168
|
-
_(e.tone(Pt[r]))
|
|
169
|
-
])
|
|
170
|
-
);
|
|
171
|
-
}, lt = (t, e = P) => `linear-gradient(${ot(e)}, ${t.join(", ")})`, V = (t) => {
|
|
172
|
-
const e = t.stops.map(R).join(", ");
|
|
173
|
-
if (t.type === "radial") {
|
|
174
|
-
const r = t.shape ?? "ellipse", a = t.size ?? nt, o = t.position ?? F;
|
|
175
|
-
return `radial-gradient(${r} ${a} at ${o}, ${e})`;
|
|
176
|
-
}
|
|
177
|
-
if (t.type === "conic") {
|
|
178
|
-
const r = ot(t.direction), a = t.position ?? F, o = it(t.stops).map(R).join(", ");
|
|
179
|
-
return `conic-gradient(from ${r} at ${a}, ${o})`;
|
|
180
|
-
}
|
|
181
|
-
return lt(t.stops.map(R), t.direction);
|
|
182
|
-
}, f = (t, e) => {
|
|
183
|
-
const r = k.fromInt(A(t));
|
|
184
|
-
return _(k.from(r.hue, r.chroma, e).toInt());
|
|
185
|
-
}, u = (t, e, r, a = 1) => {
|
|
186
|
-
const o = k.fromInt(A(t)), n = (o.hue + e + 360) % 360, i = Math.min(o.chroma * a, 100);
|
|
187
|
-
return _(k.from(n, i, r).toInt());
|
|
188
|
-
}, G = (t) => {
|
|
189
|
-
const e = k.fromInt(A(t)), r = (e.hue + 110) % 360, a = Math.min(e.chroma * 1.2, 100), o = e.tone < 50 ? 65 : Math.min(e.tone + 10, 75);
|
|
190
|
-
return _(k.from(r, a, o).toInt());
|
|
191
|
-
}, Et = (t) => {
|
|
192
|
-
const e = G(t);
|
|
193
|
-
return [
|
|
194
|
-
c(f(e, 95), 0),
|
|
195
|
-
c(e, 25),
|
|
196
|
-
c(t, 50),
|
|
197
|
-
c(f(t, 80), 75),
|
|
198
|
-
c(f(t, 20), 100)
|
|
199
|
-
];
|
|
200
|
-
}, It = (t) => [
|
|
201
|
-
c(f(t, 94), 0),
|
|
202
|
-
c(f(t, 72), 28),
|
|
203
|
-
c(t, 55),
|
|
204
|
-
c(f(t, 24), 100)
|
|
205
|
-
], Vt = (t) => [
|
|
206
|
-
c(f(G(t), 88), 0),
|
|
207
|
-
c(t, 50),
|
|
208
|
-
c(f(G(t), 32), 100)
|
|
209
|
-
], zt = (t) => [
|
|
210
|
-
c(u(t, 148, 82, 0.95), 0),
|
|
211
|
-
c(u(t, -148, 70, 1.05), 28),
|
|
212
|
-
c(t, 56),
|
|
213
|
-
c(u(t, 150, 34, 1.08), 100)
|
|
214
|
-
], Dt = (t) => [
|
|
215
|
-
c(u(t, -34, 72, 0.95), 0),
|
|
216
|
-
c(t, 50),
|
|
217
|
-
c(u(t, 34, 34, 1.05), 100)
|
|
218
|
-
], Rt = (t) => [
|
|
219
|
-
c(u(t, -120, 78, 0.9), 0),
|
|
220
|
-
c(t, 50),
|
|
221
|
-
c(u(t, 120, 36, 1.05), 100)
|
|
222
|
-
], Lt = (t) => [
|
|
223
|
-
c(u(t, -90, 78, 0.92), 0),
|
|
224
|
-
c(t, 32),
|
|
225
|
-
c(u(t, 90, 62, 1), 58),
|
|
226
|
-
c(u(t, 180, 34, 1.08), 100)
|
|
227
|
-
], Ft = (t) => [
|
|
228
|
-
c(u(t, -28, 82, 0.96), 0),
|
|
229
|
-
c(t, 27),
|
|
230
|
-
c(u(t, 152, 66, 1.02), 62),
|
|
231
|
-
c(u(t, 180, 34, 1.08), 100)
|
|
232
|
-
], Ht = (t) => [
|
|
233
|
-
c(u(t, -90, 78, 0.94), 0),
|
|
234
|
-
c(t, 30),
|
|
235
|
-
c(u(t, 90, 62, 1), 62),
|
|
236
|
-
c(u(t, 180, 36, 1.08), 100)
|
|
237
|
-
], Xt = (t, e) => {
|
|
238
|
-
const r = (e == null ? void 0 : e[0]) ?? f(t, 84), a = (e == null ? void 0 : e[1]) ?? G(t);
|
|
239
|
-
return [
|
|
240
|
-
c(r, 0),
|
|
241
|
-
c(t, 48),
|
|
242
|
-
c(a, 100)
|
|
243
|
-
];
|
|
244
|
-
}, gt = {
|
|
245
|
-
glare: Et,
|
|
246
|
-
monochrome: It,
|
|
247
|
-
complementary: Vt,
|
|
248
|
-
"split-complementary": zt,
|
|
249
|
-
analogous: Dt,
|
|
250
|
-
triadic: Rt,
|
|
251
|
-
tetradic: Lt,
|
|
252
|
-
rectangle: Ft,
|
|
253
|
-
square: Ht,
|
|
254
|
-
duotone: Xt
|
|
255
|
-
}, ht = (t, e, r) => gt[e](t, r), z = (t, e = {}) => {
|
|
256
|
-
const r = e.shade ?? 500, a = e.recipe ?? "glare";
|
|
257
|
-
return {
|
|
258
|
-
type: e.type ?? "linear",
|
|
259
|
-
stops: ht(t[r], a, e.colors),
|
|
260
|
-
direction: e.direction ?? P,
|
|
261
|
-
shape: e.shape ?? "ellipse",
|
|
262
|
-
position: e.position ?? F,
|
|
263
|
-
size: e.size ?? nt
|
|
264
|
-
};
|
|
265
|
-
}, Yt = (t, e = {}) => z(I(t), e), $ = (t) => t, mt = (t) => t, j = mt({
|
|
266
|
-
materialBorder: $({
|
|
267
|
-
label: "Material border",
|
|
268
|
-
description: "Default Gradient UI border material.",
|
|
269
|
-
gradient: {
|
|
270
|
-
recipe: "glare",
|
|
271
|
-
type: "linear",
|
|
272
|
-
direction: 135
|
|
273
|
-
},
|
|
274
|
-
shadow: {
|
|
275
|
-
layers: 2,
|
|
276
|
-
opacity: 0.22,
|
|
277
|
-
blur: 12,
|
|
278
|
-
y: 4,
|
|
279
|
-
spread: -3
|
|
280
|
-
},
|
|
281
|
-
dropShadow: {
|
|
282
|
-
layers: 2,
|
|
283
|
-
opacity: 0.32,
|
|
284
|
-
blur: 12,
|
|
285
|
-
y: 5
|
|
286
|
-
},
|
|
287
|
-
animation: {
|
|
288
|
-
preset: "shift",
|
|
289
|
-
duration: 6400,
|
|
290
|
-
easing: "ease-in-out"
|
|
291
|
-
}
|
|
292
|
-
}),
|
|
293
|
-
materialAction: $({
|
|
294
|
-
label: "Material action",
|
|
295
|
-
description: "Compact action material for buttons, chips and controls.",
|
|
296
|
-
gradient: {
|
|
297
|
-
recipe: "glare",
|
|
298
|
-
type: "linear",
|
|
299
|
-
direction: 135
|
|
300
|
-
},
|
|
301
|
-
shadow: {
|
|
302
|
-
layers: 2,
|
|
303
|
-
opacity: 0.2,
|
|
304
|
-
blur: 10,
|
|
305
|
-
y: 3,
|
|
306
|
-
spread: -2
|
|
307
|
-
},
|
|
308
|
-
dropShadow: {
|
|
309
|
-
layers: 2,
|
|
310
|
-
opacity: 0.28,
|
|
311
|
-
blur: 10,
|
|
312
|
-
y: 4
|
|
313
|
-
},
|
|
314
|
-
animation: {
|
|
315
|
-
preset: "shift",
|
|
316
|
-
duration: 6800,
|
|
317
|
-
easing: "ease-in-out"
|
|
318
|
-
}
|
|
319
|
-
}),
|
|
320
|
-
materialSurface: $({
|
|
321
|
-
label: "Material surface",
|
|
322
|
-
description: "Soft surface material for calm gradient backgrounds.",
|
|
323
|
-
gradient: {
|
|
324
|
-
recipe: "monochrome",
|
|
325
|
-
type: "linear",
|
|
326
|
-
direction: 145
|
|
327
|
-
},
|
|
328
|
-
shadow: {
|
|
329
|
-
layers: 2,
|
|
330
|
-
opacity: 0.18,
|
|
331
|
-
blur: 14,
|
|
332
|
-
y: 5,
|
|
333
|
-
spread: -3
|
|
334
|
-
},
|
|
335
|
-
dropShadow: {
|
|
336
|
-
layers: 2,
|
|
337
|
-
opacity: 0.22,
|
|
338
|
-
blur: 14,
|
|
339
|
-
y: 5
|
|
340
|
-
},
|
|
341
|
-
animation: {
|
|
342
|
-
preset: "pulse",
|
|
343
|
-
duration: 7600,
|
|
344
|
-
easing: "ease-in-out"
|
|
345
|
-
}
|
|
346
|
-
}),
|
|
347
|
-
brandGlare: $({
|
|
348
|
-
label: "Brand glare",
|
|
349
|
-
description: "Classic Gradient UI glare with a vivid complementary highlight.",
|
|
350
|
-
gradient: {
|
|
351
|
-
recipe: "glare",
|
|
352
|
-
type: "linear",
|
|
353
|
-
direction: 135
|
|
354
|
-
},
|
|
355
|
-
shadow: {
|
|
356
|
-
layers: 2,
|
|
357
|
-
opacity: 0.24,
|
|
358
|
-
blur: 16,
|
|
359
|
-
y: 6,
|
|
360
|
-
spread: -3
|
|
361
|
-
},
|
|
362
|
-
dropShadow: {
|
|
363
|
-
layers: 3,
|
|
364
|
-
opacity: 0.38,
|
|
365
|
-
blur: 16,
|
|
366
|
-
y: 6
|
|
367
|
-
},
|
|
368
|
-
animation: {
|
|
369
|
-
preset: "shift",
|
|
370
|
-
duration: 6e3,
|
|
371
|
-
easing: "ease-in-out"
|
|
372
|
-
}
|
|
373
|
-
}),
|
|
374
|
-
softMono: $({
|
|
375
|
-
label: "Soft mono",
|
|
376
|
-
description: "Quiet monochrome ramp for subtle surfaces.",
|
|
377
|
-
gradient: {
|
|
378
|
-
recipe: "monochrome",
|
|
379
|
-
type: "linear",
|
|
380
|
-
direction: 145
|
|
381
|
-
},
|
|
382
|
-
shadow: {
|
|
383
|
-
layers: 2,
|
|
384
|
-
opacity: 0.18,
|
|
385
|
-
blur: 18,
|
|
386
|
-
y: 7,
|
|
387
|
-
spread: -4
|
|
388
|
-
},
|
|
389
|
-
dropShadow: {
|
|
390
|
-
layers: 2,
|
|
391
|
-
opacity: 0.26,
|
|
392
|
-
blur: 16,
|
|
393
|
-
y: 6
|
|
394
|
-
},
|
|
395
|
-
animation: {
|
|
396
|
-
preset: "pulse",
|
|
397
|
-
duration: 7200,
|
|
398
|
-
easing: "ease-in-out"
|
|
399
|
-
}
|
|
400
|
-
}),
|
|
401
|
-
neonDuo: $({
|
|
402
|
-
label: "Neon duo",
|
|
403
|
-
description: "Punchy duotone setup with stronger glow defaults.",
|
|
404
|
-
gradient: {
|
|
405
|
-
recipe: "duotone",
|
|
406
|
-
type: "linear",
|
|
407
|
-
direction: 120
|
|
408
|
-
},
|
|
409
|
-
shadow: {
|
|
410
|
-
layers: 2,
|
|
411
|
-
opacity: 0.32,
|
|
412
|
-
blur: 18,
|
|
413
|
-
y: 7,
|
|
414
|
-
spread: -3
|
|
415
|
-
},
|
|
416
|
-
dropShadow: {
|
|
417
|
-
layers: 3,
|
|
418
|
-
opacity: 0.52,
|
|
419
|
-
blur: 18,
|
|
420
|
-
y: 7
|
|
421
|
-
},
|
|
422
|
-
animation: {
|
|
423
|
-
preset: "shift",
|
|
424
|
-
duration: 5200,
|
|
425
|
-
easing: "ease-in-out"
|
|
426
|
-
}
|
|
427
|
-
}),
|
|
428
|
-
orbitalConic: $({
|
|
429
|
-
label: "Orbital conic",
|
|
430
|
-
description: "Smooth mirrored conic gradient for badges and marks.",
|
|
431
|
-
gradient: {
|
|
432
|
-
recipe: "triadic",
|
|
433
|
-
type: "conic",
|
|
434
|
-
direction: 35,
|
|
435
|
-
position: "center"
|
|
436
|
-
},
|
|
437
|
-
shadow: {
|
|
438
|
-
layers: 2,
|
|
439
|
-
opacity: 0.24,
|
|
440
|
-
blur: 16,
|
|
441
|
-
y: 6,
|
|
442
|
-
spread: -3
|
|
443
|
-
},
|
|
444
|
-
dropShadow: {
|
|
445
|
-
layers: 3,
|
|
446
|
-
opacity: 0.36,
|
|
447
|
-
blur: 16,
|
|
448
|
-
y: 6
|
|
449
|
-
},
|
|
450
|
-
animation: {
|
|
451
|
-
preset: "rotate",
|
|
452
|
-
duration: 9e3
|
|
453
|
-
}
|
|
454
|
-
}),
|
|
455
|
-
auroraRadial: $({
|
|
456
|
-
label: "Aurora radial",
|
|
457
|
-
description: "Radial analogous gradient with slow hue motion.",
|
|
458
|
-
gradient: {
|
|
459
|
-
recipe: "analogous",
|
|
460
|
-
type: "radial",
|
|
461
|
-
direction: 0,
|
|
462
|
-
position: "top left",
|
|
463
|
-
shape: "circle"
|
|
464
|
-
},
|
|
465
|
-
shadow: {
|
|
466
|
-
layers: 2,
|
|
467
|
-
opacity: 0.22,
|
|
468
|
-
blur: 18,
|
|
469
|
-
y: 7,
|
|
470
|
-
spread: -4
|
|
471
|
-
},
|
|
472
|
-
dropShadow: {
|
|
473
|
-
layers: 3,
|
|
474
|
-
opacity: 0.32,
|
|
475
|
-
blur: 18,
|
|
476
|
-
y: 7
|
|
477
|
-
},
|
|
478
|
-
animation: {
|
|
479
|
-
preset: "hue-rotate",
|
|
480
|
-
duration: 8e3,
|
|
481
|
-
easing: "ease-in-out"
|
|
482
|
-
}
|
|
483
|
-
})
|
|
484
|
-
}), ut = (t, e = j) => e[t] ?? j.brandGlare, pt = (t, e = {}) => V(z(t, e)), Ut = (t, e = {}) => pt(I(t), e), Ae = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
485
|
-
__proto__: null,
|
|
486
|
-
createGradient: pt,
|
|
487
|
-
createGradientFromColor: Ut,
|
|
488
|
-
createGradientModel: z,
|
|
489
|
-
createGradientModelFromColor: Yt,
|
|
490
|
-
createRecipeStops: ht,
|
|
491
|
-
defineGradientPreset: $,
|
|
492
|
-
defineGradientPresetRegistry: mt,
|
|
493
|
-
getGradientPreset: ut,
|
|
494
|
-
gradientPresets: j,
|
|
495
|
-
gradientRecipes: gt
|
|
496
|
-
}, Symbol.toStringTag, { value: "Module" })), Wt = "http://www.w3.org/2000/svg", Kt = {
|
|
497
|
-
soft: {
|
|
498
|
-
blobCount: 5,
|
|
499
|
-
blur: 40,
|
|
500
|
-
contrast: 18,
|
|
501
|
-
duration: 12e3,
|
|
502
|
-
opacity: 0.76,
|
|
503
|
-
scale: 1.05
|
|
504
|
-
},
|
|
505
|
-
liquid: {
|
|
506
|
-
blobCount: 6,
|
|
507
|
-
blur: 46,
|
|
508
|
-
contrast: 22,
|
|
509
|
-
duration: 9200,
|
|
510
|
-
opacity: 0.82,
|
|
511
|
-
scale: 1.18
|
|
512
|
-
},
|
|
513
|
-
ripple: {
|
|
514
|
-
blobCount: 7,
|
|
515
|
-
blur: 34,
|
|
516
|
-
contrast: 20,
|
|
517
|
-
duration: 7200,
|
|
518
|
-
opacity: 0.78,
|
|
519
|
-
scale: 0.94
|
|
520
|
-
}
|
|
521
|
-
}, T = (t = {}) => {
|
|
522
|
-
const e = Kt[t.preset ?? "soft"];
|
|
523
|
-
return {
|
|
524
|
-
blobCount: Math.max(
|
|
525
|
-
2,
|
|
526
|
-
Math.round(t.blobCount ?? e.blobCount)
|
|
527
|
-
),
|
|
528
|
-
blur: w(t.blur ?? e.blur, 0, 80),
|
|
529
|
-
contrast: w(t.contrast ?? e.contrast, 0, 36),
|
|
530
|
-
duration: t.duration ?? e.duration,
|
|
531
|
-
id: t.id ?? "g-gradient-morph",
|
|
532
|
-
opacity: w(t.opacity ?? e.opacity),
|
|
533
|
-
scale: w(t.scale ?? e.scale, 0.4, 2)
|
|
534
|
-
};
|
|
535
|
-
}, qt = (t, e) => {
|
|
536
|
-
var r, a;
|
|
537
|
-
return ((r = t.stops[e % t.stops.length]) == null ? void 0 : r.color) ?? ((a = t.stops[0]) == null ? void 0 : a.color) ?? "currentColor";
|
|
538
|
-
}, Jt = (t) => {
|
|
539
|
-
if (typeof t == "number") return t;
|
|
540
|
-
const e = Number.parseFloat(t);
|
|
541
|
-
return Number.isFinite(e) ? e : 9e3;
|
|
542
|
-
}, Zt = (t, e) => {
|
|
543
|
-
const r = Math.sin((t + 1) * 12.9898 + e * 78.233) * 43758.5453;
|
|
544
|
-
return r - Math.floor(r);
|
|
545
|
-
}, y = (t, e, r, a) => r + Zt(t, e) * (a - r), S = (t) => Number(t.toFixed(3)), rt = [
|
|
546
|
-
{
|
|
547
|
-
animationName: "g-gradient-morph-drift",
|
|
548
|
-
dx: 20,
|
|
549
|
-
dx2: 8,
|
|
550
|
-
dy: -8,
|
|
551
|
-
dy2: 16,
|
|
552
|
-
originX: "50%",
|
|
553
|
-
originY: "50%",
|
|
554
|
-
scaleMid: 1.16,
|
|
555
|
-
scaleTo: 1.04,
|
|
556
|
-
x: 6,
|
|
557
|
-
y: 58
|
|
558
|
-
},
|
|
559
|
-
{
|
|
560
|
-
animationName: "g-gradient-morph-orbit",
|
|
561
|
-
dx: -18,
|
|
562
|
-
dx2: 10,
|
|
563
|
-
dy: 18,
|
|
564
|
-
dy2: -10,
|
|
565
|
-
originX: "24%",
|
|
566
|
-
originY: "68%",
|
|
567
|
-
scaleMid: 0.96,
|
|
568
|
-
scaleTo: 1.12,
|
|
569
|
-
x: 44,
|
|
570
|
-
y: 20
|
|
571
|
-
},
|
|
572
|
-
{
|
|
573
|
-
animationName: "g-gradient-morph-float",
|
|
574
|
-
dx: -16,
|
|
575
|
-
dx2: -8,
|
|
576
|
-
dy: -12,
|
|
577
|
-
dy2: 18,
|
|
578
|
-
originX: "50%",
|
|
579
|
-
originY: "50%",
|
|
580
|
-
scaleMid: 1.2,
|
|
581
|
-
scaleTo: 1.08,
|
|
582
|
-
x: 74,
|
|
583
|
-
y: 58
|
|
584
|
-
},
|
|
585
|
-
{
|
|
586
|
-
animationName: "g-gradient-morph-orbit",
|
|
587
|
-
dx: 12,
|
|
588
|
-
dx2: -20,
|
|
589
|
-
dy: 14,
|
|
590
|
-
dy2: 6,
|
|
591
|
-
originX: "70%",
|
|
592
|
-
originY: "30%",
|
|
593
|
-
scaleMid: 1.04,
|
|
594
|
-
scaleTo: 1.18,
|
|
595
|
-
x: 88,
|
|
596
|
-
y: 25
|
|
597
|
-
},
|
|
598
|
-
{
|
|
599
|
-
animationName: "g-gradient-morph-drift",
|
|
600
|
-
dx: 24,
|
|
601
|
-
dx2: -12,
|
|
602
|
-
dy: -16,
|
|
603
|
-
dy2: -8,
|
|
604
|
-
originX: "50%",
|
|
605
|
-
originY: "50%",
|
|
606
|
-
scaleMid: 1.12,
|
|
607
|
-
scaleTo: 0.98,
|
|
608
|
-
x: 30,
|
|
609
|
-
y: 78
|
|
610
|
-
},
|
|
611
|
-
{
|
|
612
|
-
animationName: "g-gradient-morph-float",
|
|
613
|
-
dx: -22,
|
|
614
|
-
dx2: 14,
|
|
615
|
-
dy: 10,
|
|
616
|
-
dy2: -18,
|
|
617
|
-
originX: "50%",
|
|
618
|
-
originY: "50%",
|
|
619
|
-
scaleMid: 0.94,
|
|
620
|
-
scaleTo: 1.1,
|
|
621
|
-
x: 104,
|
|
622
|
-
y: 82
|
|
623
|
-
},
|
|
624
|
-
{
|
|
625
|
-
animationName: "g-gradient-morph-orbit",
|
|
626
|
-
dx: 14,
|
|
627
|
-
dx2: -16,
|
|
628
|
-
dy: -22,
|
|
629
|
-
dy2: 10,
|
|
630
|
-
originX: "35%",
|
|
631
|
-
originY: "35%",
|
|
632
|
-
scaleMid: 1.18,
|
|
633
|
-
scaleTo: 1.02,
|
|
634
|
-
x: 55,
|
|
635
|
-
y: 64
|
|
636
|
-
},
|
|
637
|
-
{
|
|
638
|
-
animationName: "g-gradient-morph-drift",
|
|
639
|
-
dx: -18,
|
|
640
|
-
dx2: 18,
|
|
641
|
-
dy: -14,
|
|
642
|
-
dy2: 14,
|
|
643
|
-
originX: "50%",
|
|
644
|
-
originY: "50%",
|
|
645
|
-
scaleMid: 1.08,
|
|
646
|
-
scaleTo: 0.96,
|
|
647
|
-
x: 18,
|
|
648
|
-
y: 24
|
|
649
|
-
}
|
|
650
|
-
], Y = (t, e = {}) => {
|
|
651
|
-
const { blobCount: r, duration: a, scale: o } = T(e), n = Jt(a);
|
|
652
|
-
return Array.from({ length: r }, (i, s) => {
|
|
653
|
-
const l = rt[s % rt.length], d = y(s, 1, 0.88, 1.16), h = y(s, 2, 0.86, 1.24), g = y(s, 3, 0.72, 1), m = y(s, 4, 0, 4), p = (34 + s % 4 * 9) * o * d;
|
|
654
|
-
return {
|
|
655
|
-
animationName: l.animationName,
|
|
656
|
-
blur: S(m),
|
|
657
|
-
color: qt(t, s),
|
|
658
|
-
delay: Math.round(
|
|
659
|
-
s * -0.19 * n - y(s, 5, 0, 900)
|
|
660
|
-
),
|
|
661
|
-
dx: S(l.dx * y(s, 6, 0.84, 1.18)),
|
|
662
|
-
dx2: S(l.dx2 * y(s, 7, 0.82, 1.22)),
|
|
663
|
-
dy: S(l.dy * y(s, 8, 0.84, 1.18)),
|
|
664
|
-
dy2: S(l.dy2 * y(s, 9, 0.82, 1.22)),
|
|
665
|
-
duration: Math.round(
|
|
666
|
-
n * (1 + s % 3 * 0.11) * h
|
|
667
|
-
),
|
|
668
|
-
opacity: S(g),
|
|
669
|
-
originX: l.originX,
|
|
670
|
-
originY: l.originY,
|
|
671
|
-
rotateMid: Math.round(y(s, 10, 95, 165)),
|
|
672
|
-
rotateTo: Math.round(y(s, 11, 220, 310)),
|
|
673
|
-
scaleMid: l.scaleMid,
|
|
674
|
-
scaleTo: l.scaleTo,
|
|
675
|
-
size: S(p),
|
|
676
|
-
x: l.x,
|
|
677
|
-
y: l.y
|
|
678
|
-
};
|
|
679
|
-
});
|
|
680
|
-
}, U = (t = {}) => `url(#${T(t).id}) blur(${T(t).blur}px)`, yt = (t = {}) => {
|
|
681
|
-
const { blur: e, contrast: r, id: a } = T(t), o = Math.max(2, Math.round(e * 0.25)), n = -(r * 0.45), i = r <= 0 ? "" : `
|
|
682
|
-
<feColorMatrix in="g-gradient-morph-blur" mode="matrix" values="1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 ${r} ${n}" result="g-gradient-morph-goo" />
|
|
683
|
-
<feBlend in="SourceGraphic" in2="g-gradient-morph-goo" />`;
|
|
684
|
-
return `<svg xmlns="${Wt}" width="0" height="0" aria-hidden="true" focusable="false" style="position:absolute;overflow:hidden;inline-size:0;block-size:0;">
|
|
685
|
-
<filter id="${a}" x="-30%" y="-30%" width="160%" height="160%" color-interpolation-filters="sRGB">
|
|
686
|
-
<feGaussianBlur in="SourceGraphic" stdDeviation="${o}" result="g-gradient-morph-blur" />${i}
|
|
687
|
-
</filter>
|
|
688
|
-
</svg>`;
|
|
689
|
-
}, Qt = (t, e = {}) => {
|
|
690
|
-
const r = e.selector ?? ".g-gradient-morph", { opacity: a } = T(e), o = Y(t, e);
|
|
691
|
-
return `${r} {
|
|
692
|
-
position: relative;
|
|
693
|
-
overflow: hidden;
|
|
694
|
-
}
|
|
695
|
-
|
|
696
|
-
${r}__blobs {
|
|
697
|
-
position: absolute;
|
|
698
|
-
inset: -18%;
|
|
699
|
-
opacity: ${a};
|
|
700
|
-
filter: ${U(e)};
|
|
701
|
-
mix-blend-mode: hard-light;
|
|
702
|
-
}
|
|
703
|
-
|
|
704
|
-
${r}__blob {
|
|
705
|
-
position: absolute;
|
|
706
|
-
transform: translate(-50%, -50%);
|
|
707
|
-
transform-origin: var(--g-gradient-morph-origin-x) var(--g-gradient-morph-origin-y);
|
|
708
|
-
opacity: var(--g-gradient-morph-opacity);
|
|
709
|
-
filter: blur(var(--g-gradient-morph-blur));
|
|
710
|
-
border-radius: 999px;
|
|
711
|
-
background: radial-gradient(circle, var(--g-gradient-morph-blob-color) 0%, transparent 72%);
|
|
712
|
-
animation: var(--g-gradient-morph-animation) var(--g-gradient-morph-duration, 9000ms) ease-in-out infinite alternate;
|
|
713
|
-
}
|
|
714
|
-
|
|
715
|
-
${o.map(
|
|
716
|
-
(n, i) => `${r}__blob:nth-child(${i + 1}) {
|
|
717
|
-
top: ${n.y}%;
|
|
718
|
-
left: ${n.x}%;
|
|
719
|
-
width: ${n.size}%;
|
|
720
|
-
aspect-ratio: 1;
|
|
721
|
-
--g-gradient-morph-blob-color: ${n.color};
|
|
722
|
-
--g-gradient-morph-x: ${n.dx}%;
|
|
723
|
-
--g-gradient-morph-x2: ${n.dx2}%;
|
|
724
|
-
--g-gradient-morph-y: ${n.dy}%;
|
|
725
|
-
--g-gradient-morph-y2: ${n.dy2}%;
|
|
726
|
-
--g-gradient-morph-origin-x: ${n.originX};
|
|
727
|
-
--g-gradient-morph-origin-y: ${n.originY};
|
|
728
|
-
--g-gradient-morph-animation: ${n.animationName};
|
|
729
|
-
--g-gradient-morph-blur: ${n.blur}px;
|
|
730
|
-
--g-gradient-morph-opacity: ${n.opacity};
|
|
731
|
-
--g-gradient-morph-rotate-mid: ${n.rotateMid}deg;
|
|
732
|
-
--g-gradient-morph-rotate-to: ${n.rotateTo}deg;
|
|
733
|
-
--g-gradient-morph-scale-mid: ${n.scaleMid};
|
|
734
|
-
--g-gradient-morph-scale: ${n.scaleTo};
|
|
735
|
-
animation-delay: ${n.delay}ms;
|
|
736
|
-
animation-duration: ${B(n.duration)};
|
|
737
|
-
}`
|
|
738
|
-
).join(`
|
|
739
|
-
|
|
740
|
-
`)}
|
|
741
|
-
|
|
742
|
-
@keyframes g-gradient-morph-drift {
|
|
743
|
-
0% {
|
|
744
|
-
transform: translate(-50%, -50%) scale(0.92);
|
|
745
|
-
}
|
|
746
|
-
|
|
747
|
-
42% {
|
|
748
|
-
transform: translate(calc(-50% + var(--g-gradient-morph-x)), calc(-50% + var(--g-gradient-morph-y))) scale(var(--g-gradient-morph-scale));
|
|
749
|
-
}
|
|
750
|
-
|
|
751
|
-
100% {
|
|
752
|
-
transform: translate(calc(-50% + var(--g-gradient-morph-x2)), calc(-50% + var(--g-gradient-morph-y2))) scale(var(--g-gradient-morph-scale-mid));
|
|
753
|
-
}
|
|
754
|
-
}
|
|
755
|
-
|
|
756
|
-
@keyframes g-gradient-morph-float {
|
|
757
|
-
0% {
|
|
758
|
-
transform: translate(-50%, -50%) scale(1);
|
|
759
|
-
}
|
|
760
|
-
|
|
761
|
-
50% {
|
|
762
|
-
transform: translate(calc(-50% + var(--g-gradient-morph-x)), calc(-50% + var(--g-gradient-morph-y))) scale(var(--g-gradient-morph-scale-mid));
|
|
763
|
-
}
|
|
764
|
-
|
|
765
|
-
100% {
|
|
766
|
-
transform: translate(calc(-50% + var(--g-gradient-morph-x2)), calc(-50% + var(--g-gradient-morph-y2))) scale(var(--g-gradient-morph-scale));
|
|
767
|
-
}
|
|
768
|
-
}
|
|
769
|
-
|
|
770
|
-
@keyframes g-gradient-morph-orbit {
|
|
771
|
-
0% {
|
|
772
|
-
transform: translate(-50%, -50%) rotate(0deg) scale(0.96);
|
|
773
|
-
}
|
|
774
|
-
|
|
775
|
-
50% {
|
|
776
|
-
transform: translate(calc(-50% + var(--g-gradient-morph-x)), calc(-50% + var(--g-gradient-morph-y))) rotate(var(--g-gradient-morph-rotate-mid)) scale(var(--g-gradient-morph-scale-mid));
|
|
777
|
-
}
|
|
778
|
-
|
|
779
|
-
100% {
|
|
780
|
-
transform: translate(calc(-50% + var(--g-gradient-morph-x2)), calc(-50% + var(--g-gradient-morph-y2))) rotate(var(--g-gradient-morph-rotate-to)) scale(var(--g-gradient-morph-scale));
|
|
781
|
-
}
|
|
782
|
-
}`;
|
|
783
|
-
}, ft = (t, e) => {
|
|
784
|
-
const r = t.stops.filter(
|
|
785
|
-
(n) => n.position >= 25 && n.position <= 85
|
|
786
|
-
), a = t.stops.filter(
|
|
787
|
-
(n) => !r.includes(n)
|
|
788
|
-
);
|
|
789
|
-
return [...r, ...a].sort(
|
|
790
|
-
(n, i) => Math.abs(n.position - 50) - Math.abs(i.position - 50)
|
|
791
|
-
).slice(0, e);
|
|
792
|
-
}, te = (t, e) => t * ([1, 0.54, 0.3, 0.18][e] ?? 0.12), M = (t, e) => {
|
|
793
|
-
const r = String(t).match(/^(-?\d*\.?\d+)(.*)$/);
|
|
794
|
-
return r ? `${Math.round(Number(r[1]) * e * 1e3) / 1e3}${r[2] || "px"}` : null;
|
|
795
|
-
}, at = (t, e, r) => M(t, 1 / e) ?? (r === 0 ? v(t) : "0px"), ee = (t, e) => M(t, 1 / Math.sqrt(e)) ?? v(t), $t = (t, e = {}) => {
|
|
796
|
-
var b;
|
|
797
|
-
const r = e.x ?? 0, a = e.y ?? 6, o = e.blur ?? 14, n = e.spread ?? -3, i = e.opacity ?? 0.24, s = Math.max(1, Math.round(e.layers ?? 2)), l = ((b = ft(t, 1)[0]) == null ? void 0 : b.color) ?? "#000000", d = `${v(r)} ${v(a)} ${v(o)} ${v(n)} ${C(l, i)}`;
|
|
798
|
-
if (s === 1) return d;
|
|
799
|
-
const h = M(r, 0.35) ?? "0px", g = M(a, 0.35) ?? "2px", m = M(o, 0.3) ?? "4px", p = M(n, 0.5) ?? "-2px", x = Math.min(0.18, i * 0.65);
|
|
800
|
-
return `${`${h} ${g} ${m} ${p} ${C("#000000", x)}`}, ${d}`;
|
|
801
|
-
}, bt = (t, e = {}) => {
|
|
802
|
-
const r = e.x ?? 0, a = e.y ?? 6, o = e.blur ?? 14, n = e.opacity ?? 0.42, i = Math.max(1, Math.round(e.layers ?? 2)), s = ee(o, i);
|
|
803
|
-
return ft(t, i).map((l, d) => {
|
|
804
|
-
const h = at(r, i, d), g = at(a, i, d);
|
|
805
|
-
return `drop-shadow(${h} ${g} ${s} ${C(l.color, te(n, d))})`;
|
|
806
|
-
}).join(" ");
|
|
807
|
-
}, Pe = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
808
|
-
__proto__: null,
|
|
809
|
-
createGradientMorphBlobs: Y,
|
|
810
|
-
toGradientBoxShadow: $t,
|
|
811
|
-
toGradientDropShadow: bt,
|
|
812
|
-
toGradientMorphCSS: Qt,
|
|
813
|
-
toGradientMorphFilter: U,
|
|
814
|
-
toGradientMorphFilterMarkup: yt
|
|
815
|
-
}, Symbol.toStringTag, { value: "Module" })), re = (t, e, r = {}) => {
|
|
816
|
-
const a = r.width ?? t.canvas.width, o = r.height ?? t.canvas.height, n = a / 2, i = o / 2, s = Math.hypot(a, o) / 2, d = ((typeof e.direction == "number" ? e.direction : Number.parseFloat(e.direction) || P) - 90) * Math.PI / 180, h = a / 2, g = o / 2, m = Math.cos(d) * h, p = Math.sin(d) * g, x = e.type === "radial" ? t.createRadialGradient(
|
|
817
|
-
r.x0 ?? n,
|
|
818
|
-
r.y0 ?? i,
|
|
819
|
-
r.r0 ?? 0,
|
|
820
|
-
r.x1 ?? n,
|
|
821
|
-
r.y1 ?? i,
|
|
822
|
-
r.r1 ?? s
|
|
823
|
-
) : e.type === "conic" && typeof t.createConicGradient == "function" ? t.createConicGradient(
|
|
824
|
-
r.startAngle ?? d,
|
|
825
|
-
r.x0 ?? n,
|
|
826
|
-
r.y0 ?? i
|
|
827
|
-
) : t.createLinearGradient(
|
|
828
|
-
r.x0 ?? n - m,
|
|
829
|
-
r.y0 ?? i - p,
|
|
830
|
-
r.x1 ?? n + m,
|
|
831
|
-
r.y1 ?? i + p
|
|
832
|
-
), O = e.type === "conic" ? it(e.stops) : e.stops;
|
|
833
|
-
for (const b of O)
|
|
834
|
-
x.addColorStop(
|
|
835
|
-
b.position / 100,
|
|
836
|
-
C(b.color, b.opacity)
|
|
837
|
-
);
|
|
838
|
-
return x;
|
|
839
|
-
}, W = "http://www.w3.org/2000/svg", ae = "http://www.w3.org/1999/xhtml", N = (t) => t.replace(/&/g, "&").replace(/"/g, """).replace(/</g, "<").replace(/>/g, ">"), K = (t) => {
|
|
840
|
-
const e = t.opacity === void 0 ? "" : ` stop-opacity="${w(t.opacity)}"`;
|
|
841
|
-
return `<stop offset="${t.position}%" stop-color="${t.color}"${e} />`;
|
|
842
|
-
}, ne = (t, e) => {
|
|
843
|
-
var r, a, o;
|
|
844
|
-
return {
|
|
845
|
-
active: e.activeStroke ?? ((r = t.stops[Math.max(0, Math.floor(t.stops.length / 2))]) == null ? void 0 : r.color) ?? ((a = t.stops[0]) == null ? void 0 : a.color) ?? "currentColor",
|
|
846
|
-
background: e.backgroundStroke ?? ((o = t.stops[0]) == null ? void 0 : o.color) ?? e.activeStroke ?? "currentColor"
|
|
847
|
-
};
|
|
848
|
-
}, oe = (t, e) => {
|
|
849
|
-
var n;
|
|
850
|
-
const r = (n = t.match(/\bviewBox=(["'])(.*?)\1/i)) == null ? void 0 : n[2];
|
|
851
|
-
if (r) return r;
|
|
852
|
-
const a = e.width ?? 240, o = e.height ?? 120;
|
|
853
|
-
return `0 0 ${a} ${o}`;
|
|
854
|
-
}, ie = (t) => {
|
|
855
|
-
var e;
|
|
856
|
-
return ((e = t.replace(/<\?xml[\s\S]*?\?>/gi, "").replace(/<!doctype[\s\S]*?>/gi, "").match(/<svg\b[^>]*>([\s\S]*?)<\/svg>/i)) == null ? void 0 : e[1].trim()) ?? t;
|
|
857
|
-
}, se = (t) => {
|
|
858
|
-
const e = t.trim().split(/(?=M\s*[-+.\d])/).map((r) => r.trim()).filter(Boolean);
|
|
859
|
-
return e.length > 1 ? e : [t];
|
|
860
|
-
}, ce = (t) => [...t.matchAll(/<path\b[^>]*\sd=(["'])([\s\S]*?)\1/gi)].flatMap(
|
|
861
|
-
(e) => se(e[2])
|
|
862
|
-
), xt = (t) => {
|
|
863
|
-
var e;
|
|
864
|
-
return Math.max(1, ((e = t.match(/[LlHhVvCcSsQqTtAaZz]/g)) == null ? void 0 : e.length) ?? 0);
|
|
865
|
-
}, de = (t, e) => {
|
|
866
|
-
const a = 0.5 + (1 - xt(t) / e) * 0.22;
|
|
867
|
-
return Math.round(a * 1e3) / 1e3;
|
|
868
|
-
}, q = (t) => {
|
|
869
|
-
const [e = "0", r = "0", a = "240", o = "120"] = t.trim().split(/[\s,]+/);
|
|
870
|
-
return {
|
|
871
|
-
height: Number(o) || 120,
|
|
872
|
-
width: Number(a) || 240,
|
|
873
|
-
x: Number(e) || 0,
|
|
874
|
-
y: Number(r) || 0
|
|
875
|
-
};
|
|
876
|
-
}, le = (t, e, r) => {
|
|
877
|
-
if (r.viewBoxPadding === !1) return t;
|
|
878
|
-
const a = q(t), o = Math.max(
|
|
879
|
-
e * 2,
|
|
880
|
-
Math.min(a.width, a.height) * 0.02
|
|
881
|
-
), n = r.viewBoxPadding ?? o;
|
|
882
|
-
return [
|
|
883
|
-
a.x - n,
|
|
884
|
-
a.y - n,
|
|
885
|
-
a.width + n * 2,
|
|
886
|
-
a.height + n * 2
|
|
887
|
-
].join(" ");
|
|
888
|
-
}, ge = (t) => {
|
|
889
|
-
const { height: e, width: r } = q(t);
|
|
890
|
-
return {
|
|
891
|
-
height: Number(e) || 120,
|
|
892
|
-
width: Number(r) || 240
|
|
893
|
-
};
|
|
894
|
-
}, he = (t, e, r) => {
|
|
895
|
-
if (r.normalizeStrokeWidth === !1) return t;
|
|
896
|
-
const { height: a, width: o } = ge(e), n = r.strokeWidthBase ?? 180;
|
|
897
|
-
return t * (Math.min(o, a) / n);
|
|
898
|
-
}, J = (t, e = {}) => {
|
|
899
|
-
const r = e.id ?? "g-gradient", a = t.stops.map(K).join("");
|
|
900
|
-
return t.type === "radial" ? `<radialGradient id="${r}" cx="${e.cx ?? "50%"}" cy="${e.cy ?? "50%"}" r="${e.r ?? "75%"}">${a}</radialGradient>` : t.type === "conic" ? `<pattern id="${r}" patternUnits="objectBoundingBox" width="1" height="1"><foreignObject x="0" y="0" width="100%" height="100%"><div xmlns="${ae}" style="width:100%;height:100%;background:${N(V(t))};"></div></foreignObject></pattern>` : `<linearGradient id="${r}" x1="${e.x1 ?? "0%"}" y1="${e.y1 ?? "0%"}" x2="${e.x2 ?? "100%"}" y2="${e.y2 ?? "100%"}">${a}</linearGradient>`;
|
|
901
|
-
}, me = (t, e = {}) => {
|
|
902
|
-
const r = e.id ?? "g-gradient", a = e.width ?? 240, o = e.height ?? 120, n = e.rx ?? 18;
|
|
903
|
-
return `<svg xmlns="${W}" viewBox="0 0 ${a} ${o}" role="img">
|
|
904
|
-
<defs>
|
|
905
|
-
${J(t, e)}
|
|
906
|
-
</defs>
|
|
907
|
-
<rect width="${a}" height="${o}" rx="${n}" fill="url(#${r})" />
|
|
908
|
-
</svg>`;
|
|
909
|
-
}, ue = (t, e, r = {}) => {
|
|
910
|
-
const o = `${r.id ?? "g-gradient-source"}-stroke`, n = oe(t, r), i = ie(t), s = ce(t), l = he(
|
|
911
|
-
r.strokeWidth ?? 1.4,
|
|
912
|
-
n,
|
|
913
|
-
r
|
|
914
|
-
), d = le(n, l, r), { width: h, x: g } = q(d), m = r.linecap ?? "round", p = B(r.duration ?? 3600), x = r.repeatCount ?? "indefinite", O = r.sourceOpacity ?? 0.22, b = e.stops.map(K).join(""), wt = Math.max(...s.map(xt));
|
|
915
|
-
return `<svg xmlns="${W}" viewBox="${N(d)}" role="img">
|
|
916
|
-
<defs>
|
|
917
|
-
<linearGradient id="${o}" gradientUnits="userSpaceOnUse" x1="${g}" y1="0" x2="${g + h}" y2="0">
|
|
918
|
-
${b}
|
|
919
|
-
</linearGradient>
|
|
920
|
-
</defs>
|
|
921
|
-
<g opacity="${w(O)}">
|
|
922
|
-
${i}
|
|
923
|
-
</g>
|
|
924
|
-
<g fill="none" stroke="url(#${o})" stroke-width="${l}" stroke-linecap="${m}" stroke-linejoin="round">
|
|
925
|
-
${s.map((tt) => {
|
|
926
|
-
const et = de(tt, wt);
|
|
927
|
-
return `<path d="${N(tt)}" pathLength="100" stroke-dasharray="0 100" stroke-dashoffset="0">
|
|
928
|
-
<animate attributeName="stroke-dasharray" values="0 100;100 100;0 100" keyTimes="0;${et};1" dur="${p}" repeatCount="${x}" calcMode="linear" />
|
|
929
|
-
<animate attributeName="stroke-dashoffset" values="0;0;-100" keyTimes="0;${et};1" dur="${p}" repeatCount="${x}" calcMode="linear" />
|
|
930
|
-
</path>`;
|
|
931
|
-
}).join(`
|
|
932
|
-
`)}
|
|
933
|
-
</g>
|
|
934
|
-
</svg>`;
|
|
935
|
-
}, pe = (t, e = {}) => {
|
|
936
|
-
const a = `${e.id ?? "g-gradient-path"}-stroke`, o = e.width ?? 240, n = e.height ?? 120, i = e.path ?? `M 20 ${n * 0.64} C ${o * 0.28} ${n * 0.18}, ${o * 0.58} ${n * 0.18}, ${o - 20} ${n * 0.64}`, s = e.strokeWidth ?? 12, l = e.linecap ?? "round", d = B(e.duration ?? 2800), h = e.repeatCount ?? "indefinite", g = e.backgroundOpacity ?? 0.24, m = ne(t, e), p = t.stops.map(K).join("");
|
|
937
|
-
return `<svg xmlns="${W}" viewBox="0 0 ${o} ${n}" role="img">
|
|
938
|
-
<defs>
|
|
939
|
-
<linearGradient id="${a}" gradientUnits="userSpaceOnUse" x1="0" y1="0" x2="${o}" y2="0">
|
|
940
|
-
${p}
|
|
941
|
-
</linearGradient>
|
|
942
|
-
</defs>
|
|
943
|
-
<path d="${N(i)}" fill="none" stroke="${m.background}" stroke-width="${s}" stroke-linecap="${l}" opacity="${g}" />
|
|
944
|
-
<path d="${N(i)}" fill="none" stroke="${e.activeStroke ? m.active : `url(#${a})`}" stroke-width="${s}" stroke-linecap="${l}" pathLength="100" stroke-dasharray="100 100" stroke-dashoffset="100">
|
|
945
|
-
<animate attributeName="stroke-dashoffset" values="100;0;-100" dur="${d}" repeatCount="${h}" />
|
|
946
|
-
</path>
|
|
947
|
-
</svg>`;
|
|
948
|
-
}, Be = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
949
|
-
__proto__: null,
|
|
950
|
-
createLinearGradient: lt,
|
|
951
|
-
toCanvasGradient: re,
|
|
952
|
-
toCssGradient: V,
|
|
953
|
-
toSvgGradient: J,
|
|
954
|
-
toSvgGradientMarkup: me,
|
|
955
|
-
toSvgPathAnimationMarkup: pe,
|
|
956
|
-
toSvgSourceAnimationMarkup: ue
|
|
957
|
-
}, Symbol.toStringTag, { value: "Module" })), ye = ["glare", "soft", "mesh"], fe = (t) => t.replace(/[A-Z]/g, (e) => `-${e.toLowerCase()}`), $e = (t) => fe(t), be = (t, e, r) => `${t}-${e}`, Z = (t) => Object.entries(t).map(([e, r]) => `${e}: ${r};`).join(`
|
|
958
|
-
`), xe = (t) => t.replace(/[A-Z]/g, (e) => `-${e.toLowerCase()}`), Se = (t) => Object.entries(t).map(([e, r]) => `${xe(e)}: ${r};`).join(`
|
|
959
|
-
`), H = (t) => t === null || typeof t != "object" ? JSON.stringify(t) : Array.isArray(t) ? `[${t.map(H).join(",")}]` : `{${Object.entries(t).filter(([, e]) => e !== void 0).sort(([e], [r]) => e.localeCompare(r)).map(
|
|
960
|
-
([e, r]) => `${JSON.stringify(e)}:${H(r)}`
|
|
961
|
-
).join(",")}}`, we = (t) => {
|
|
962
|
-
let e = 5381;
|
|
963
|
-
for (let r = 0; r < t.length; r += 1)
|
|
964
|
-
e = e * 33 ^ t.charCodeAt(r);
|
|
965
|
-
return (e >>> 0).toString(36);
|
|
966
|
-
}, ve = (t, e, r, a) => {
|
|
967
|
-
const o = Z(e), n = Se(r), i = [o, n].filter(Boolean).join(`
|
|
968
|
-
`);
|
|
969
|
-
return [`.${t} {
|
|
970
|
-
${i}
|
|
971
|
-
}`, a].filter(Boolean).join(`
|
|
972
|
-
|
|
973
|
-
`);
|
|
974
|
-
}, Me = (t, e) => t in e, St = (t, e) => Me(t, e) ? ut(t, e) : t === "soft" ? {
|
|
975
|
-
label: "Soft",
|
|
976
|
-
description: "Quiet monochrome radial gradient.",
|
|
977
|
-
gradient: {
|
|
978
|
-
recipe: "monochrome",
|
|
979
|
-
type: "radial",
|
|
980
|
-
position: "center",
|
|
981
|
-
shape: "ellipse"
|
|
982
|
-
},
|
|
983
|
-
shadow: {
|
|
984
|
-
layers: 2,
|
|
985
|
-
opacity: 0.18,
|
|
986
|
-
blur: 18,
|
|
987
|
-
y: 7,
|
|
988
|
-
spread: -4
|
|
989
|
-
},
|
|
990
|
-
dropShadow: {
|
|
991
|
-
layers: 2,
|
|
992
|
-
opacity: 0.26,
|
|
993
|
-
blur: 16,
|
|
994
|
-
y: 6
|
|
995
|
-
},
|
|
996
|
-
animation: {
|
|
997
|
-
preset: "pulse",
|
|
998
|
-
duration: 7200,
|
|
999
|
-
easing: "ease-in-out"
|
|
1000
|
-
}
|
|
1001
|
-
} : t === "mesh" ? null : {
|
|
1002
|
-
label: t,
|
|
1003
|
-
gradient: {
|
|
1004
|
-
recipe: t,
|
|
1005
|
-
type: "linear",
|
|
1006
|
-
direction: t === "glare" ? 135 : 145
|
|
1007
|
-
}
|
|
1008
|
-
}, ke = (t) => {
|
|
1009
|
-
const e = [
|
|
1010
|
-
`radial-gradient(circle at 16% 18%, ${u(t, -42, 72, 1.05)} 0%, transparent 34%)`,
|
|
1011
|
-
`radial-gradient(circle at 86% 20%, ${G(t)} 0%, transparent 32%)`,
|
|
1012
|
-
`radial-gradient(circle at 50% 84%, ${u(t, 56, 64, 1.08)} 0%, transparent 38%)`,
|
|
1013
|
-
`linear-gradient(135deg, ${f(t, 94)}, ${f(t, 28)})`
|
|
1014
|
-
];
|
|
1015
|
-
return {
|
|
1016
|
-
layers: e,
|
|
1017
|
-
value: e.join(", ")
|
|
1018
|
-
};
|
|
1019
|
-
}, Ce = (t, e, r, a, o) => {
|
|
1020
|
-
if (e === "mesh") {
|
|
1021
|
-
const l = ke(t);
|
|
1022
|
-
return {
|
|
1023
|
-
cssVar: r,
|
|
1024
|
-
layers: l.layers,
|
|
1025
|
-
value: l.value
|
|
1026
|
-
};
|
|
1027
|
-
}
|
|
1028
|
-
const n = St(e, o), i = I(t), s = z(i, {
|
|
1029
|
-
...n == null ? void 0 : n.gradient,
|
|
1030
|
-
...a
|
|
1031
|
-
});
|
|
1032
|
-
return {
|
|
1033
|
-
cssVar: r,
|
|
1034
|
-
model: s,
|
|
1035
|
-
stops: s.stops,
|
|
1036
|
-
svg: J(s, { id: r.replace(/^--/, "") }),
|
|
1037
|
-
value: V(s)
|
|
1038
|
-
};
|
|
1039
|
-
}, Ge = (t, e, r, a) => {
|
|
1040
|
-
var i;
|
|
1041
|
-
if (!t) return {};
|
|
1042
|
-
const o = `${e.replace(/^--/, "")}-morph`, n = {
|
|
1043
|
-
...a == null ? void 0 : a.morph,
|
|
1044
|
-
id: ((i = a == null ? void 0 : a.morph) == null ? void 0 : i.id) ?? o
|
|
1045
|
-
};
|
|
1046
|
-
return {
|
|
1047
|
-
boxShadow: {
|
|
1048
|
-
cssVar: `${e}-shadow`,
|
|
1049
|
-
value: $t(t, (a == null ? void 0 : a.shadow) ?? (r == null ? void 0 : r.shadow))
|
|
1050
|
-
},
|
|
1051
|
-
dropShadow: {
|
|
1052
|
-
cssVar: `${e}-drop-shadow`,
|
|
1053
|
-
value: bt(
|
|
1054
|
-
t,
|
|
1055
|
-
(a == null ? void 0 : a.dropShadow) ?? (r == null ? void 0 : r.dropShadow)
|
|
1056
|
-
)
|
|
1057
|
-
},
|
|
1058
|
-
morph: {
|
|
1059
|
-
cssVar: `${e}-morph`,
|
|
1060
|
-
svg: yt(n),
|
|
1061
|
-
value: U(n)
|
|
1062
|
-
}
|
|
1063
|
-
};
|
|
1064
|
-
}, Te = (t, e, r, a) => {
|
|
1065
|
-
var n;
|
|
1066
|
-
const o = {
|
|
1067
|
-
...r == null ? void 0 : r.animation,
|
|
1068
|
-
...a,
|
|
1069
|
-
name: `g-gradient-${t}-${(a == null ? void 0 : a.preset) ?? ((n = r == null ? void 0 : r.animation) == null ? void 0 : n.preset) ?? "shift"}`,
|
|
1070
|
-
selector: `.g-gradient-${t}`
|
|
1071
|
-
};
|
|
1072
|
-
return {
|
|
1073
|
-
css: dt(o),
|
|
1074
|
-
cssVar: `${e}-animation`,
|
|
1075
|
-
keyframes: X(o),
|
|
1076
|
-
name: o.name,
|
|
1077
|
-
value: st(o)
|
|
1078
|
-
};
|
|
1079
|
-
}, Q = (t, e = "glare", r = {}) => {
|
|
1080
|
-
const a = r.registry ?? j, o = $e(e), n = be(r.prefix ?? "--g-gradient", o), i = St(e, a), l = I(t)[500], d = Ce(
|
|
1081
|
-
l,
|
|
1082
|
-
e,
|
|
1083
|
-
n,
|
|
1084
|
-
r,
|
|
1085
|
-
a
|
|
1086
|
-
), h = {
|
|
1087
|
-
[n]: d.value
|
|
1088
|
-
}, g = r.effects ? Ge(d.model, n, i, {
|
|
1089
|
-
dropShadow: r.dropShadow,
|
|
1090
|
-
morph: r.morph,
|
|
1091
|
-
shadow: r.shadow
|
|
1092
|
-
}) : void 0, m = r.animations ? Te(o, n, i, r.animation) : void 0;
|
|
1093
|
-
return g != null && g.boxShadow && (h[g.boxShadow.cssVar] = g.boxShadow.value), g != null && g.dropShadow && (h[g.dropShadow.cssVar] = g.dropShadow.value), g != null && g.morph && (h[g.morph.cssVar] = g.morph.value), m && (h[m.cssVar] = m.value), {
|
|
1094
|
-
animation: m,
|
|
1095
|
-
cssText: Z(h),
|
|
1096
|
-
cssVars: h,
|
|
1097
|
-
description: i == null ? void 0 : i.description,
|
|
1098
|
-
effects: g,
|
|
1099
|
-
gradient: d,
|
|
1100
|
-
keyframes: (m == null ? void 0 : m.keyframes) ?? "",
|
|
1101
|
-
label: (i == null ? void 0 : i.label) ?? o,
|
|
1102
|
-
name: o
|
|
1103
|
-
};
|
|
1104
|
-
}, Ne = (t, e = {}) => {
|
|
1105
|
-
const r = e.recipes ?? ye, a = {}, o = {}, n = {}, i = {}, s = [];
|
|
1106
|
-
for (const l of r) {
|
|
1107
|
-
const d = Q(t, l, {
|
|
1108
|
-
animations: e.animations,
|
|
1109
|
-
effects: e.effects,
|
|
1110
|
-
morph: e.morph,
|
|
1111
|
-
prefix: e.prefix,
|
|
1112
|
-
registry: e.registry
|
|
1113
|
-
});
|
|
1114
|
-
a[d.name] = d.gradient, Object.assign(i, d.cssVars), d.effects && (o[d.name] = d.effects), d.animation && (n[d.name] = d.animation, s.push(d.animation.keyframes));
|
|
1115
|
-
}
|
|
1116
|
-
return {
|
|
1117
|
-
animations: n,
|
|
1118
|
-
cssText: Z(i),
|
|
1119
|
-
cssVars: i,
|
|
1120
|
-
effects: o,
|
|
1121
|
-
gradients: a,
|
|
1122
|
-
keyframes: s.join(`
|
|
1123
|
-
`)
|
|
1124
|
-
};
|
|
1125
|
-
}, Oe = (t, e = {}) => {
|
|
1126
|
-
var g, m;
|
|
1127
|
-
const { className: r, id: a, recipe: o = "glare", ...n } = e, i = Q(t, o, n), s = i.gradient.model && e.effects && e.morph ? Y(i.gradient.model, e.morph) : void 0, l = a ?? `g-gradient-${i.name}-${we(
|
|
1128
|
-
H({ options: e, seed: t })
|
|
1129
|
-
)}`, d = r ?? l, h = {
|
|
1130
|
-
backgroundImage: `var(${i.gradient.cssVar})`
|
|
1131
|
-
};
|
|
1132
|
-
return (g = i.effects) != null && g.boxShadow && (h.boxShadow = `var(${i.effects.boxShadow.cssVar})`), (m = i.effects) != null && m.dropShadow && (h.filter = `var(${i.effects.dropShadow.cssVar})`), i.animation && (h.animation = `var(${i.animation.cssVar})`), {
|
|
1133
|
-
animation: i.animation,
|
|
1134
|
-
className: d,
|
|
1135
|
-
cssText: ve(
|
|
1136
|
-
d,
|
|
1137
|
-
i.cssVars,
|
|
1138
|
-
h,
|
|
1139
|
-
i.keyframes
|
|
1140
|
-
),
|
|
1141
|
-
cssVars: i.cssVars,
|
|
1142
|
-
effects: i.effects,
|
|
1143
|
-
gradient: i.gradient,
|
|
1144
|
-
id: l,
|
|
1145
|
-
keyframes: i.keyframes,
|
|
1146
|
-
morphBlobs: s,
|
|
1147
|
-
preset: i,
|
|
1148
|
-
style: h
|
|
1149
|
-
};
|
|
1150
|
-
}, Ee = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
1151
|
-
__proto__: null,
|
|
1152
|
-
createGradientMaterial: Oe,
|
|
1153
|
-
createGradientPreset: Q,
|
|
1154
|
-
createGradientTokens: Ne
|
|
1155
|
-
}, Symbol.toStringTag, { value: "Module" }));
|
|
1156
|
-
export {
|
|
1157
|
-
Pe as a,
|
|
1158
|
-
Be as b,
|
|
1159
|
-
Ae as c,
|
|
1160
|
-
_e as i,
|
|
1161
|
-
Ee as m
|
|
1162
|
-
};
|