@plitzi/sdk-style 0.38.11 → 0.38.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (43) hide show
  1. package/CHANGELOG.md +109 -0
  2. package/dist/StyleMap/helpers/isValueValid.mjs +5 -4
  3. package/dist/StyleMap/helpers/utils.mjs +13 -12
  4. package/dist/components/StyleInspector/StyleInspector.mjs +217 -217
  5. package/dist/components/StyleInspector/categories/Background/Background.mjs +86 -147
  6. package/dist/components/StyleInspector/categories/Background/components/GradientCenter/GradientCenter.d.ts +8 -0
  7. package/dist/components/StyleInspector/categories/Background/components/GradientCenter/GradientCenter.mjs +28 -0
  8. package/dist/components/StyleInspector/categories/Background/components/GradientCenter/index.d.ts +3 -0
  9. package/dist/components/StyleInspector/categories/Background/components/GradientCenter/index.mjs +5 -0
  10. package/dist/components/StyleInspector/categories/Background/modes/ConicGradientMode.mjs +26 -48
  11. package/dist/components/StyleInspector/categories/Background/modes/RadialGradientMode.mjs +45 -67
  12. package/dist/components/StyleInspector/categories/Display/Display.mjs +59 -58
  13. package/dist/components/StyleInspector/categories/Display/DisplayGap.d.ts +14 -1
  14. package/dist/components/StyleInspector/categories/Display/DisplayGap.mjs +26 -13
  15. package/dist/components/StyleInspector/categories/Effects/BoxShadow/BoxShadow.mjs +13 -24
  16. package/dist/components/StyleInspector/categories/Effects/Effects.mjs +41 -102
  17. package/dist/components/StyleInspector/categories/List/List.mjs +15 -65
  18. package/dist/components/StyleInspector/categories/ListItem/ListItem.mjs +15 -64
  19. package/dist/components/StyleInspector/categories/Others/Others.mjs +60 -60
  20. package/dist/components/StyleInspector/categories/Size/Size.mjs +67 -67
  21. package/dist/components/StyleInspector/categories/Spacing/SpacingBox.d.ts +15 -0
  22. package/dist/components/StyleInspector/categories/Spacing/SpacingBox.mjs +63 -0
  23. package/dist/components/StyleInspector/categories/Spacing/SpacingMargin.d.ts +3 -11
  24. package/dist/components/StyleInspector/categories/Spacing/SpacingMargin.mjs +18 -70
  25. package/dist/components/StyleInspector/categories/Spacing/SpacingPadding.d.ts +3 -7
  26. package/dist/components/StyleInspector/categories/Spacing/SpacingPadding.mjs +16 -68
  27. package/dist/components/StyleInspector/categories/Typography/Typography.mjs +79 -78
  28. package/dist/components/StyleInspector/categories/Typography/TypographyTextShadow.mjs +17 -28
  29. package/dist/components/StyleInspector/categories/blendModes.d.ts +2 -0
  30. package/dist/components/StyleInspector/categories/blendModes.mjs +21 -0
  31. package/dist/components/StyleInspector/categories/listMarkers.d.ts +8 -0
  32. package/dist/components/StyleInspector/categories/listMarkers.mjs +25 -0
  33. package/dist/components/StyleInspector/components/ShadowList/ShadowList.d.ts +15 -0
  34. package/dist/components/StyleInspector/components/ShadowList/ShadowList.mjs +25 -0
  35. package/dist/components/StyleInspector/components/ShadowList/index.d.ts +3 -0
  36. package/dist/components/StyleInspector/components/ShadowList/index.mjs +5 -0
  37. package/dist/components/StyleInspector/cssValues.d.ts +2 -4
  38. package/dist/components/StyleInspector/cssValues.mjs +12 -16
  39. package/dist/components/StyleInspector/hooks/usePropertyChange.d.ts +6 -0
  40. package/dist/components/StyleInspector/hooks/usePropertyChange.mjs +9 -0
  41. package/package.json +44 -8
  42. package/dist/components/StyleInspector/categories/Display/DisplayGridGap.d.ts +0 -8
  43. package/dist/components/StyleInspector/categories/Display/DisplayGridGap.mjs +0 -27
@@ -3,344 +3,344 @@ import ae from "../Selector/index.mjs";
3
3
  import oe from "./components/AncestorRules/index.mjs";
4
4
  import se from "./components/TargetSummary/index.mjs";
5
5
  import ce from "./Inspector.mjs";
6
- import { use as le, useCallback as a, useEffect as ue, useMemo as o, useState as s } from "react";
7
- import { useBuilderStore as de, useBuilderStoreSync as c } from "@plitzi/sdk-shared/store";
8
- import { get as l, pick as fe, set as pe } from "@plitzi/plitzi-ui/helpers";
9
- import { produce as me } from "immer";
10
- import { canonicalCondition as he } from "@plitzi/sdk-shared/style/styleConditions";
11
- import { isParentAncestor as ge } from "@plitzi/sdk-shared/style/styleStates";
6
+ import { use as le, useCallback as a, useEffect as ue, useEffectEvent as de, useMemo as o, useState as s } from "react";
7
+ import { useBuilderStore as fe, useBuilderStoreSync as c } from "@plitzi/sdk-shared/store";
8
+ import { get as l, pick as pe, set as me } from "@plitzi/plitzi-ui/helpers";
9
+ import { produce as he } from "immer";
10
+ import { canonicalCondition as ge } from "@plitzi/sdk-shared/style/styleConditions";
11
+ import { isParentAncestor as _e } from "@plitzi/sdk-shared/style/styleStates";
12
12
  import { jsx as u, jsxs as d } from "react/jsx-runtime";
13
- import { clsx as f } from "clsx";
14
- import _e from "@plitzi/plitzi-ui/Icon";
15
- import ve from "@plitzi/sdk-shared/builder/contexts/BuilderContext";
16
- import p from "@plitzi/plitzi-ui/hooks/useDidUpdateEffect";
17
- import ye from "@plitzi/plitzi-ui/hooks/useStorage";
18
- import m from "@plitzi/plitzi-ui/Select";
19
- import h from "@plitzi/plitzi-ui/Select2";
13
+ import { clsx as ve } from "clsx";
14
+ import ye from "@plitzi/plitzi-ui/Icon";
15
+ import be from "@plitzi/sdk-shared/builder/contexts/BuilderContext";
16
+ import f from "@plitzi/plitzi-ui/hooks/useDidUpdateEffect";
17
+ import xe from "@plitzi/plitzi-ui/hooks/useStorage";
18
+ import p from "@plitzi/plitzi-ui/Select";
19
+ import m from "@plitzi/plitzi-ui/Select2";
20
20
  //#region src/components/StyleInspector/StyleInspector.tsx
21
- var g = ({ displayMode: g, selectors: _, value: v, element: y, mode: b = "element", componentType: x, styleSelectors: S, styleSelectorsAvailables: C, componentSubTypesAvailables: w, allowStyleSelector: be = !0, allowStyleState: T = !0, allowStyleVariant: E = !0, onChange: D, onRemoveVariant: O }) => {
22
- let [xe, k] = s(void 0), [A, j] = s("base"), [M, N] = s(void 0), [P, F] = s(void 0);
23
- c("styleSelector", A, { enabled: b === "element" }), c("styleVariant", M, { enabled: b === "element" });
24
- let [I, L] = s(void 0), [R, z] = s(void 0), [B, V] = s(void 0);
25
- c("styleState", P, { enabled: b === "element" }), c("styleAncestor", I, { enabled: b === "element" }), c("stylePseudo", R, { enabled: b === "element" }), c("styleCondition", B, { enabled: b === "element" });
26
- let [[H, U]] = de(["schema.flat", "style.platform"]), [Se, W] = ye("builder-state.styleInspector.moreTargets", !1), { builderHandler: G } = le(ve), K = o(() => l(S, A, ""), [S, A]), Ce = o(() => Object.values(fe(_ ?? {}, y ? [y.definition.type, ...K.split(" ")] : K.split(" "))), [
27
- _,
28
- y,
29
- K
30
- ]), q = o(() => v ? l(_, v) : void 0, [_, v]), J = q?.attributes[A]?.ancestors, Y = o(() => b === "element" ? t(H, y) : Object.values(_ ?? {}).filter((e) => e.type === "class" && e.name !== v).map((e) => e.name).sort((e, t) => e.localeCompare(t)), [
21
+ var h = ({ displayMode: h, selectors: g, value: _, element: v, mode: y = "element", componentType: b, styleSelectors: x, styleSelectorsAvailables: S, componentSubTypesAvailables: C, allowStyleSelector: Se = !0, allowStyleState: w = !0, allowStyleVariant: T = !0, onChange: E, onRemoveVariant: D }) => {
22
+ let [Ce, O] = s(void 0), [k, A] = s("base"), [j, M] = s(void 0), [N, P] = s(void 0);
23
+ c("styleSelector", k, { enabled: y === "element" }), c("styleVariant", j, { enabled: y === "element" });
24
+ let [F, I] = s(void 0), [L, R] = s(void 0), [z, B] = s(void 0);
25
+ c("styleState", N, { enabled: y === "element" }), c("styleAncestor", F, { enabled: y === "element" }), c("stylePseudo", L, { enabled: y === "element" }), c("styleCondition", z, { enabled: y === "element" });
26
+ let [[V, H]] = fe(["schema.flat", "style.platform"]), [we, U] = xe("builder-state.styleInspector.moreTargets", !1), { builderHandler: W } = le(be), G = o(() => l(x, k, ""), [x, k]), Te = o(() => Object.values(pe(g ?? {}, v ? [v.definition.type, ...G.split(" ")] : G.split(" "))), [
27
+ g,
28
+ v,
29
+ G
30
+ ]), K = o(() => _ ? l(g, _) : void 0, [g, _]), q = K?.attributes[k]?.ancestors, J = o(() => y === "element" ? t(V, v) : Object.values(g ?? {}).filter((e) => e.type === "class" && e.name !== _).map((e) => e.name).sort((e, t) => e.localeCompare(t)), [
31
+ v,
32
+ V,
31
33
  y,
32
- H,
33
- b,
34
- _,
35
- v
36
- ]), we = o(() => r(Y, J), [Y, J]), Te = o(() => n(J), [J]), X = o(() => q ? ie(H, q) : /* @__PURE__ */ new Set(), [H, q]), Ee = o(() => {
37
- let e = Object.keys(J ?? {}).length;
34
+ g,
35
+ _
36
+ ]), Y = o(() => r(J, q), [J, q]), Ee = o(() => n(q), [q]), X = o(() => K ? ie(V, K) : /* @__PURE__ */ new Set(), [V, K]), De = o(() => {
37
+ let e = Object.keys(q ?? {}).length;
38
38
  return e ? `When an ancestor is… (${e} set)` : "When an ancestor is…";
39
- }, [J]), De = o(() => {
40
- let e = q?.attributes[A], t = I ? [...Object.keys(_?.[I]?.attributes.base.variants ?? {}), ...Object.keys(e?.ancestors?.[I]?.variants ?? {})] : Object.keys(e?.variants ?? {});
39
+ }, [q]), Oe = o(() => {
40
+ let e = K?.attributes[k], t = F ? [...Object.keys(g?.[F]?.attributes.base.variants ?? {}), ...Object.keys(e?.ancestors?.[F]?.variants ?? {})] : Object.keys(e?.variants ?? {});
41
41
  return [...new Set(t)].map((e) => ({
42
42
  label: e,
43
43
  value: e
44
44
  }));
45
45
  }, [
46
- q?.attributes,
47
- _,
48
- I,
49
- A
50
- ]), Oe = o(() => ne(q?.attributes[A]), [q?.attributes, A]), ke = o(() => ee(q?.attributes[A]), [q?.attributes, A]), Ae = !!I && ge(I), Z = !!I || !!R || !!B, Q = Se || Z, je = re({
51
- styleSelector: A,
52
- styleVariant: M,
53
- styleState: P,
54
- styleAncestor: I,
55
- stylePseudo: R,
56
- styleCondition: B
46
+ K?.attributes,
47
+ g,
48
+ F,
49
+ k
50
+ ]), ke = o(() => ne(K?.attributes[k]), [K?.attributes, k]), Ae = o(() => ee(K?.attributes[k]), [K?.attributes, k]), je = !!F && _e(F), Z = !!F || !!L || !!z, Q = we || Z, Me = re({
51
+ styleSelector: k,
52
+ styleVariant: j,
53
+ styleState: N,
54
+ styleAncestor: F,
55
+ stylePseudo: L,
56
+ styleCondition: z
57
+ }), Ne = de(() => {
58
+ if (A("base"), y !== "element") return;
59
+ let e = l(x, "base", "").split(" "), t = e[e.length - 1];
60
+ E?.(t || ""), P(void 0), I(void 0), R(void 0), B(void 0), O(void 0);
57
61
  });
58
- ue(() => {
59
- if (j("base"), b !== "element") return;
60
- let e = l(S, "base", "").split(" "), t = e[e.length - 1];
61
- D?.(t || ""), F(void 0), L(void 0), z(void 0), V(void 0), k(void 0);
62
- }, [D, S]), p(() => {
63
- if (b === "element") {
64
- if (v !== y?.definition.type) {
65
- let e = l(S, A, "").split(" ");
66
- D?.(e[e.length - 1]);
62
+ ue(() => Ne(), [E, x]), f(() => {
63
+ if (y === "element") {
64
+ if (_ !== v?.definition.type) {
65
+ let e = l(x, k, "").split(" ");
66
+ E?.(e[e.length - 1]);
67
67
  }
68
- F(void 0), N(void 0), L(void 0), z(void 0), V(void 0), k(void 0);
68
+ P(void 0), M(void 0), I(void 0), R(void 0), B(void 0), O(void 0);
69
69
  }
70
- }, [A]), p(() => {
71
- F(void 0), N(void 0), L(void 0), z(void 0), V(void 0), k(void 0);
72
- }, [v]);
73
- let Me = a((e, t, n) => {
70
+ }, [k]), f(() => {
71
+ P(void 0), M(void 0), I(void 0), R(void 0), B(void 0), O(void 0);
72
+ }, [_]);
73
+ let Pe = a((e, t, n) => {
74
74
  if (t && !n) return;
75
75
  let { name: r, type: i } = e;
76
- !t && r !== "" && !_?.[r] ? G("styleAddSelector", g, r, i, void 0, void 0, {
77
- styleSelector: A,
78
- componentType: i === "element" ? x : void 0
79
- }) : t && n && n.name !== r && _?.[n.name] && !_[r] && G("styleAddSelector", g, r, i, void 0, l(_, `${n.name}.attributes.${A}.default`, {}), {
80
- styleSelector: A,
81
- componentType: i === "element" ? x : void 0
76
+ !t && r !== "" && !g?.[r] ? W("styleAddSelector", h, r, i, void 0, void 0, {
77
+ styleSelector: k,
78
+ componentType: i === "element" ? b : void 0
79
+ }) : t && n && n.name !== r && g?.[n.name] && !g[r] && W("styleAddSelector", h, r, i, void 0, l(g, `${n.name}.attributes.${k}.default`, {}), {
80
+ styleSelector: k,
81
+ componentType: i === "element" ? b : void 0
82
82
  });
83
83
  }, [
84
- G,
85
- x,
84
+ W,
85
+ b,
86
+ h,
86
87
  g,
87
- _,
88
- A
89
- ]), Ne = a((e) => {
90
- if (!e || v && v === e.name) {
91
- D?.(void 0);
88
+ k
89
+ ]), Fe = a((e) => {
90
+ if (!e || _ && _ === e.name) {
91
+ E?.(void 0);
92
92
  return;
93
93
  }
94
- D?.(e.name);
95
- }, [D, v]), Pe = a((e) => {
96
- y && G("schemaUpdateElement", me(y, (t) => {
97
- pe(t, `definition.styleSelectors.${A}`, e);
94
+ E?.(e.name);
95
+ }, [E, _]), Ie = a((e) => {
96
+ v && W("schemaUpdateElement", he(v, (t) => {
97
+ me(t, `definition.styleSelectors.${k}`, e);
98
98
  }));
99
99
  }, [
100
- y,
101
- G,
102
- A
103
- ]), Fe = a((e) => {
104
- G("styleRemoveSelector", g, e.name);
105
- }, [G, g]), Ie = a(() => W((e) => !e), [W]), Le = a(() => {
106
- j("base"), F(void 0), N(void 0), L(void 0), z(void 0), V(void 0);
107
- }, []), Re = a((e) => k(e), []), ze = a((e) => {
108
- j(e);
109
- }, []), Be = a((e) => F(e?.value), []), Ve = a((e) => {
110
- L(e?.value), F(void 0), N(void 0), z(void 0), V(void 0);
111
- }, []), He = a((e) => z(e?.value), []), Ue = a((e) => {
112
- let t = e ? he(e.value) : void 0;
113
- (!e || t) && (V(t), t && (N(void 0), L(void 0)));
114
- }, []), We = a((e) => {
115
- e.value === B && (V(void 0), F(void 0)), q?.attributes[A]?.conditions?.[e.value] && G("styleUpdateSelector", g, q.name, void 0, void 0, {
116
- styleSelector: A,
100
+ v,
101
+ W,
102
+ k
103
+ ]), Le = a((e) => {
104
+ W("styleRemoveSelector", h, e.name);
105
+ }, [W, h]), Re = a(() => U((e) => !e), [U]), ze = a(() => {
106
+ A("base"), P(void 0), M(void 0), I(void 0), R(void 0), B(void 0);
107
+ }, []), Be = a((e) => O(e), []), Ve = a((e) => {
108
+ A(e);
109
+ }, []), He = a((e) => P(e?.value), []), Ue = a((e) => {
110
+ I(e?.value), P(void 0), M(void 0), R(void 0), B(void 0);
111
+ }, []), We = a((e) => R(e?.value), []), Ge = a((e) => {
112
+ let t = e ? ge(e.value) : void 0;
113
+ (!e || t) && (B(t), t && (M(void 0), I(void 0)));
114
+ }, []), Ke = a((e) => {
115
+ e.value === z && (B(void 0), P(void 0)), K?.attributes[k]?.conditions?.[e.value] && W("styleUpdateSelector", h, K.name, void 0, void 0, {
116
+ styleSelector: k,
117
117
  styleCondition: e.value,
118
- componentType: q.componentType
118
+ componentType: K.componentType
119
119
  });
120
120
  }, [
121
- G,
122
- g,
123
- q,
124
- B,
125
- A
126
- ]), Ge = a((e) => {
127
- e.value === I && (L(void 0), F(void 0), N(void 0)), q?.attributes[A]?.ancestors?.[e.value] && G("styleUpdateSelector", g, q.name, void 0, void 0, {
128
- styleSelector: A,
121
+ W,
122
+ h,
123
+ K,
124
+ z,
125
+ k
126
+ ]), qe = a((e) => {
127
+ e.value === F && (I(void 0), P(void 0), M(void 0)), K?.attributes[k]?.ancestors?.[e.value] && W("styleUpdateSelector", h, K.name, void 0, void 0, {
128
+ styleSelector: k,
129
129
  styleAncestor: e.value,
130
- componentType: q.componentType
130
+ componentType: K.componentType
131
131
  });
132
132
  }, [
133
- G,
134
- g,
135
- q,
136
- I,
137
- A
138
- ]), Ke = a((e) => {
139
- L(e.ancestor), N(e.variant), F(e.state), z(void 0), V(void 0);
140
- }, []), qe = a((e) => {
141
- if (!q) return;
133
+ W,
134
+ h,
135
+ K,
136
+ F,
137
+ k
138
+ ]), Je = a((e) => {
139
+ I(e.ancestor), M(e.variant), P(e.state), R(void 0), B(void 0);
140
+ }, []), Ye = a((e) => {
141
+ if (!K) return;
142
142
  let { ancestor: t, state: n, variant: r } = e;
143
- t === I && n === P && r === M && (F(void 0), N(void 0)), G("styleUpdateSelector", g, q.name, void 0, n || r ? void 0 : {}, {
144
- styleSelector: A,
143
+ t === F && n === N && r === j && (P(void 0), M(void 0)), W("styleUpdateSelector", h, K.name, void 0, n || r ? void 0 : {}, {
144
+ styleSelector: k,
145
145
  styleAncestor: t,
146
146
  styleState: n,
147
147
  styleVariant: r,
148
- componentType: q.componentType
148
+ componentType: K.componentType
149
149
  });
150
150
  }, [
151
- G,
152
- g,
153
- q,
154
- I,
155
- A,
156
- P,
157
- M
158
- ]), Je = a(() => {
159
- if (q) {
160
- I && X.has(I) && (L(void 0), F(void 0), N(void 0));
161
- for (let e of i(U, q.name, X)) G("styleUpdateSelector", e.displayMode, q.name, void 0, void 0, {
151
+ W,
152
+ h,
153
+ K,
154
+ F,
155
+ k,
156
+ N,
157
+ j
158
+ ]), Xe = a(() => {
159
+ if (K) {
160
+ F && X.has(F) && (I(void 0), P(void 0), M(void 0));
161
+ for (let e of i(H, K.name, X)) W("styleUpdateSelector", e.displayMode, K.name, void 0, void 0, {
162
162
  styleSelector: e.styleSelector,
163
163
  styleAncestor: e.styleAncestor,
164
- componentType: q.componentType
164
+ componentType: K.componentType
165
165
  });
166
166
  }
167
167
  }, [
168
- G,
169
- U,
170
- q,
171
- I,
168
+ W,
169
+ H,
170
+ K,
171
+ F,
172
172
  X
173
- ]), Ye = a((e) => {
174
- N(e?.value), e && V(void 0);
175
- }, []), Xe = a((e) => {
176
- O?.(e.value), P && F(void 0), e.value === M && N(void 0), G("styleUpdateSelector", g, q?.name, void 0, void 0, {
177
- styleSelector: A,
173
+ ]), Ze = a((e) => {
174
+ M(e?.value), e && B(void 0);
175
+ }, []), Qe = a((e) => {
176
+ D?.(e.value), N && P(void 0), e.value === j && M(void 0), W("styleUpdateSelector", h, K?.name, void 0, void 0, {
177
+ styleSelector: k,
178
178
  styleVariant: e.value,
179
- styleAncestor: I,
180
- componentType: q?.componentType
179
+ styleAncestor: F,
180
+ componentType: K?.componentType
181
181
  });
182
182
  }, [
183
- G,
184
- g,
185
- O,
186
- q?.componentType,
187
- q?.name,
188
- A,
189
- P,
190
- M,
191
- I
192
- ]), $ = E || T || !!C?.length || !!w?.length;
183
+ W,
184
+ h,
185
+ D,
186
+ K?.componentType,
187
+ K?.name,
188
+ k,
189
+ N,
190
+ j,
191
+ F
192
+ ]), $ = T || w || !!S?.length || !!C?.length;
193
193
  return /* @__PURE__ */ d("div", {
194
194
  className: "flex w-full grow flex-col gap-2",
195
195
  children: [/* @__PURE__ */ d("div", {
196
196
  className: "flex w-full flex-col gap-2 px-1",
197
197
  children: [
198
- b === "element" && /* @__PURE__ */ u(ae, {
198
+ y === "element" && /* @__PURE__ */ u(ae, {
199
199
  className: "min-h-0 w-full",
200
- value: K,
201
- selectors: _,
202
- selector: q,
203
- componentType: x,
204
- onAdd: Me,
205
- onChange: Pe,
206
- onRemove: Fe,
207
- onSelectorSelected: Ne
200
+ value: G,
201
+ selectors: g,
202
+ selector: K,
203
+ componentType: b,
204
+ onAdd: Pe,
205
+ onChange: Ie,
206
+ onRemove: Le,
207
+ onSelectorSelected: Fe
208
208
  }),
209
209
  $ && /* @__PURE__ */ d("div", {
210
- className: f("flex w-full items-center gap-2", { "mt-2": b === "manager" }),
210
+ className: ve("flex w-full items-center gap-2", { "mt-2": y === "manager" }),
211
211
  children: [
212
- !!w?.length && /* @__PURE__ */ u(m, {
212
+ !!C?.length && /* @__PURE__ */ u(p, {
213
213
  className: "grow basis-0",
214
214
  size: "xs",
215
- value: xe,
216
- onChange: Re,
217
- children: w.map((e) => /* @__PURE__ */ u("option", {
215
+ value: Ce,
216
+ onChange: Be,
217
+ children: C.map((e) => /* @__PURE__ */ u("option", {
218
218
  value: e,
219
219
  children: e
220
220
  }, e))
221
221
  }),
222
- be && C && C.length > 1 && /* @__PURE__ */ u(m, {
222
+ Se && S && S.length > 1 && /* @__PURE__ */ u(p, {
223
223
  className: "grow basis-0",
224
224
  size: "xs",
225
- onChange: ze,
226
- value: A,
227
- children: C.map((e) => /* @__PURE__ */ u("option", {
225
+ onChange: Ve,
226
+ value: k,
227
+ children: S.map((e) => /* @__PURE__ */ u("option", {
228
228
  value: e,
229
229
  children: e
230
230
  }, e))
231
231
  }),
232
- E && !Ae && /* @__PURE__ */ u("div", {
232
+ T && !je && /* @__PURE__ */ u("div", {
233
233
  className: "grow basis-0",
234
- children: /* @__PURE__ */ u(h, {
234
+ children: /* @__PURE__ */ u(m, {
235
235
  className: "grow basis-0",
236
- value: M,
237
- options: De,
236
+ value: j,
237
+ options: Oe,
238
238
  placeholder: "Variant",
239
239
  size: "xs",
240
240
  allowCreateOptions: !0,
241
241
  allowRemoveOptions: !0,
242
242
  clearable: !0,
243
- onChange: Ye,
244
- onRemove: Xe
243
+ onChange: Ze,
244
+ onRemove: Qe
245
245
  })
246
246
  }),
247
- T && /* @__PURE__ */ u("div", {
247
+ w && /* @__PURE__ */ u("div", {
248
248
  className: "grow basis-0",
249
- children: /* @__PURE__ */ u(h, {
249
+ children: /* @__PURE__ */ u(m, {
250
250
  className: "grow basis-0",
251
- value: P,
251
+ value: N,
252
252
  options: e,
253
253
  placeholder: "State",
254
254
  size: "xs",
255
255
  clearable: !0,
256
- onChange: Be
256
+ onChange: He
257
257
  })
258
258
  }),
259
- T && /* @__PURE__ */ u(_e, {
260
- className: f("shrink-0 cursor-pointer rounded-sm p-1 text-xs", {
259
+ w && /* @__PURE__ */ u(ye, {
260
+ className: ve("shrink-0 cursor-pointer rounded-sm p-1 text-xs", {
261
261
  "bg-primary-500/15 text-primary-600 dark:text-primary-300": Q,
262
262
  "text-zinc-500 hover:text-zinc-900 dark:text-zinc-400 dark:hover:text-zinc-100": !Q
263
263
  }),
264
264
  icon: "fa-solid fa-crosshairs",
265
265
  title: te(Z, Q),
266
- onClick: Z ? void 0 : Ie
266
+ onClick: Z ? void 0 : Re
267
267
  })
268
268
  ]
269
269
  }),
270
- $ && T && Q && !!we.length && /* @__PURE__ */ u(h, {
270
+ $ && w && Q && !!Y.length && /* @__PURE__ */ u(m, {
271
271
  className: "w-full",
272
- value: I,
273
- options: we,
274
- placeholder: Ee,
272
+ value: F,
273
+ options: Y,
274
+ placeholder: De,
275
275
  size: "xs",
276
276
  clearable: !0,
277
277
  allowRemoveOptions: !0,
278
- onChange: Ve,
279
- onRemove: Ge
278
+ onChange: Ue,
279
+ onRemove: qe
280
280
  }),
281
- $ && T && Q && !I && /* @__PURE__ */ d("div", {
281
+ $ && w && Q && !F && /* @__PURE__ */ d("div", {
282
282
  className: "flex w-full items-center gap-2",
283
283
  children: [/* @__PURE__ */ u("div", {
284
284
  className: "grow basis-0",
285
- children: /* @__PURE__ */ u(h, {
285
+ children: /* @__PURE__ */ u(m, {
286
286
  className: "grow basis-0",
287
- value: R,
288
- options: Oe,
287
+ value: L,
288
+ options: ke,
289
289
  placeholder: "Pseudo-element",
290
290
  size: "xs",
291
291
  clearable: !0,
292
- onChange: He
292
+ onChange: We
293
293
  })
294
294
  }), /* @__PURE__ */ u("div", {
295
295
  className: "grow basis-0",
296
- children: /* @__PURE__ */ u(h, {
296
+ children: /* @__PURE__ */ u(m, {
297
297
  className: "grow basis-0",
298
- value: B,
299
- options: ke,
298
+ value: z,
299
+ options: Ae,
300
300
  placeholder: "Condition",
301
301
  size: "xs",
302
302
  clearable: !0,
303
303
  allowCreateOptions: !0,
304
304
  allowRemoveOptions: !0,
305
- onChange: Ue,
306
- onRemove: We
305
+ onChange: Ge,
306
+ onRemove: Ke
307
307
  })
308
308
  })]
309
309
  }),
310
- T && Te.length > 0 && /* @__PURE__ */ u(oe, {
311
- conditions: Te,
310
+ w && Ee.length > 0 && /* @__PURE__ */ u(oe, {
311
+ conditions: Ee,
312
312
  unused: X,
313
- activeAncestor: I,
314
- activeState: P,
315
- activeVariant: M,
316
- onSelect: Ke,
317
- onRemove: qe,
318
- onRemoveUnused: Je
313
+ activeAncestor: F,
314
+ activeState: N,
315
+ activeVariant: j,
316
+ onSelect: Je,
317
+ onRemove: Ye,
318
+ onRemoveUnused: Xe
319
319
  }),
320
- je.length > 0 && /* @__PURE__ */ u(se, {
321
- selectorName: v,
322
- parts: je,
323
- onReset: Le
320
+ Me.length > 0 && /* @__PURE__ */ u(se, {
321
+ selectorName: _,
322
+ parts: Me,
323
+ onReset: ze
324
324
  })
325
325
  ]
326
326
  }), /* @__PURE__ */ u("div", {
327
327
  className: "flex grow basis-0 flex-col overflow-auto border-t border-gray-300 dark:border-zinc-700",
328
328
  children: /* @__PURE__ */ u(ce, {
329
- selectors: Ce,
330
- componentType: x,
331
- selector: q,
332
- styleSelector: A,
333
- styleState: P,
334
- styleVariant: M,
335
- styleAncestor: I,
336
- stylePseudo: R,
337
- styleCondition: B,
338
- element: y,
339
- displayMode: g,
340
- mode: b
329
+ selectors: Te,
330
+ componentType: b,
331
+ selector: K,
332
+ styleSelector: k,
333
+ styleState: N,
334
+ styleVariant: j,
335
+ styleAncestor: F,
336
+ stylePseudo: L,
337
+ styleCondition: z,
338
+ element: v,
339
+ displayMode: h,
340
+ mode: y
341
341
  })
342
342
  })]
343
343
  });
344
344
  };
345
345
  //#endregion
346
- export { g as default };
346
+ export { h as default };