@plitzi/sdk-style 0.38.10 → 0.38.11
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/CHANGELOG.md +180 -0
- package/dist/components/InputEasing/InputEasingButton.mjs +1 -1
- package/dist/components/InputEasing/InputEasingList.mjs +5 -5
- package/dist/components/Selector/Selector.mjs +2 -1
- package/dist/components/Selector/SelectorItem/ItemOptions.mjs +45 -41
- package/dist/components/Selector/SelectorItem/SelectorItem.mjs +4 -4
- package/dist/components/Selector/SelectorItem/helpers.d.ts +2 -0
- package/dist/components/Selector/SelectorItem/helpers.mjs +4 -0
- package/dist/components/StyleInspector/Inspector.mjs +185 -171
- package/dist/components/StyleInspector/InspectorSearchContext.d.ts +3 -0
- package/dist/components/StyleInspector/InspectorSearchContext.mjs +6 -0
- package/dist/components/StyleInspector/StyleInspector.mjs +154 -128
- package/dist/components/StyleInspector/categories/Background/Background.mjs +82 -114
- package/dist/components/StyleInspector/categories/Background/components/BackgroundAttachment/BackgroundAttachment.d.ts +8 -0
- package/dist/components/StyleInspector/categories/Background/components/BackgroundAttachment/BackgroundAttachment.mjs +53 -0
- package/dist/components/StyleInspector/categories/Background/components/BackgroundAttachment/index.d.ts +3 -0
- package/dist/components/StyleInspector/categories/Background/components/BackgroundAttachment/index.mjs +5 -0
- package/dist/components/StyleInspector/categories/Background/components/BackgroundLayer/BackgroundLayer.mjs +159 -153
- package/dist/components/StyleInspector/categories/Background/components/BackgroundLayer/helpers.d.ts +11 -0
- package/dist/components/StyleInspector/categories/Background/components/BackgroundLayer/helpers.mjs +45 -0
- package/dist/components/StyleInspector/categories/Background/components/BackgroundPosition/BackgroundPosition.mjs +26 -23
- package/dist/components/StyleInspector/categories/Background/components/BackgroundSize/BackgroundSize.mjs +65 -56
- package/dist/components/StyleInspector/categories/Background/components/BackgroundSize/helpers.d.ts +4 -0
- package/dist/components/StyleInspector/categories/Background/components/BackgroundSize/helpers.mjs +8 -0
- package/dist/components/StyleInspector/categories/Background/components/BackgroundTile/BackgroundTile.mjs +28 -27
- package/dist/components/StyleInspector/categories/Background/components/GradientStopBar/GradientPreviewBar.d.ts +4 -2
- package/dist/components/StyleInspector/categories/Background/components/GradientStopBar/GradientPreviewBar.mjs +19 -18
- package/dist/components/StyleInspector/categories/Background/components/GradientStopBar/GradientStopBar.d.ts +4 -0
- package/dist/components/StyleInspector/categories/Background/components/GradientStopBar/GradientStopBar.mjs +48 -80
- package/dist/components/StyleInspector/categories/Background/components/GradientStopBar/GradientStopEditor.d.ts +5 -3
- package/dist/components/StyleInspector/categories/Background/components/GradientStopBar/GradientStopEditor.mjs +51 -41
- package/dist/components/StyleInspector/categories/Background/components/GradientStopBar/GradientStopHandle.d.ts +5 -1
- package/dist/components/StyleInspector/categories/Background/components/GradientStopBar/GradientStopHandle.mjs +54 -32
- package/dist/components/StyleInspector/categories/Background/components/GradientStopBar/GradientStopTrack.d.ts +3 -1
- package/dist/components/StyleInspector/categories/Background/components/GradientStopBar/GradientStopTrack.mjs +14 -13
- package/dist/components/StyleInspector/categories/Background/components/GradientStopBar/helpers.d.ts +8 -0
- package/dist/components/StyleInspector/categories/Background/components/GradientStopBar/helpers.mjs +8 -0
- package/dist/components/StyleInspector/categories/Background/components/LayerGroup/LayerGroup.d.ts +8 -0
- package/dist/components/StyleInspector/categories/Background/components/LayerGroup/LayerGroup.mjs +11 -0
- package/dist/components/StyleInspector/categories/Background/components/LayerGroup/index.d.ts +3 -0
- package/dist/components/StyleInspector/categories/Background/components/LayerGroup/index.mjs +5 -0
- package/dist/components/StyleInspector/categories/Background/helpers/backgroundParser.d.ts +21 -7
- package/dist/components/StyleInspector/categories/Background/helpers/backgroundParser.mjs +114 -113
- package/dist/components/StyleInspector/categories/Background/helpers/layerValues.d.ts +8 -0
- package/dist/components/StyleInspector/categories/Background/helpers/layerValues.mjs +11 -0
- package/dist/components/StyleInspector/categories/Background/modes/ConicGradientMode.mjs +52 -87
- package/dist/components/StyleInspector/categories/Background/modes/ImageMode.mjs +16 -77
- package/dist/components/StyleInspector/categories/Background/modes/LinearGradientMode.mjs +19 -62
- package/dist/components/StyleInspector/categories/Background/modes/RadialGradientMode.mjs +79 -97
- package/dist/components/StyleInspector/categories/Background/modes/RawMode.d.ts +8 -0
- package/dist/components/StyleInspector/categories/Background/modes/RawMode.mjs +22 -0
- package/dist/components/StyleInspector/categories/Background/modes/helpers.d.ts +19 -0
- package/dist/components/StyleInspector/categories/Background/modes/helpers.mjs +54 -0
- package/dist/components/StyleInspector/categories/Border/Border.mjs +26 -43
- package/dist/components/StyleInspector/categories/Border/BorderPlacements.mjs +60 -51
- package/dist/components/StyleInspector/categories/Display/Display.mjs +32 -49
- package/dist/components/StyleInspector/categories/DisplayFlexChild/DisplayFlexChild.mjs +33 -38
- package/dist/components/StyleInspector/categories/Effects/BoxShadow/BoxShadow.mjs +21 -33
- package/dist/components/StyleInspector/categories/Effects/Effects.mjs +131 -154
- package/dist/components/StyleInspector/categories/Effects/Filters/Filter.mjs +23 -31
- package/dist/components/StyleInspector/categories/Effects/Filters/FilterItem.d.ts +9 -5
- package/dist/components/StyleInspector/categories/Effects/Filters/FilterItem.mjs +57 -124
- package/dist/components/StyleInspector/categories/Effects/Filters/helpers.d.ts +25 -0
- package/dist/components/StyleInspector/categories/Effects/Filters/helpers.mjs +87 -0
- package/dist/components/StyleInspector/categories/Effects/Transform/Transform.mjs +18 -28
- package/dist/components/StyleInspector/categories/Effects/Transform/TransformItem.d.ts +1 -2
- package/dist/components/StyleInspector/categories/Effects/Transform/TransformItem.mjs +52 -76
- package/dist/components/StyleInspector/categories/Effects/Transform/transformFunctions.d.ts +5 -0
- package/dist/components/StyleInspector/categories/Effects/Transform/transformFunctions.mjs +8 -2
- package/dist/components/StyleInspector/categories/Effects/Transition/Transition.mjs +21 -37
- package/dist/components/StyleInspector/categories/Effects/Transition/TransitionEasing.d.ts +10 -0
- package/dist/components/StyleInspector/categories/Effects/Transition/TransitionEasing.mjs +92 -0
- package/dist/components/StyleInspector/categories/Effects/Transition/TransitionItem.d.ts +4 -4
- package/dist/components/StyleInspector/categories/Effects/Transition/TransitionItem.mjs +78 -359
- package/dist/components/StyleInspector/categories/Effects/Transition/helpers.d.ts +39 -0
- package/dist/components/StyleInspector/categories/Effects/Transition/helpers.mjs +268 -0
- package/dist/components/StyleInspector/categories/List/List.mjs +39 -38
- package/dist/components/StyleInspector/categories/ListItem/ListItem.mjs +29 -29
- package/dist/components/StyleInspector/categories/Others/Others.mjs +66 -88
- package/dist/components/StyleInspector/categories/Position/Position.mjs +67 -75
- package/dist/components/StyleInspector/categories/RawStyle/RawStyle.mjs +19 -18
- package/dist/components/StyleInspector/categories/Size/Size.mjs +68 -88
- package/dist/components/StyleInspector/categories/Spacing/Spacing.mjs +18 -27
- package/dist/components/StyleInspector/categories/Spacing/SpacingMargin.mjs +2 -2
- package/dist/components/StyleInspector/categories/Spacing/SpacingPadding.mjs +4 -3
- package/dist/components/StyleInspector/categories/Typography/Typography.mjs +88 -98
- package/dist/components/StyleInspector/categories/Typography/TypographyFont.mjs +1 -1
- package/dist/components/StyleInspector/categories/Typography/TypographyStyle.mjs +1 -1
- package/dist/components/StyleInspector/categories/Typography/TypographyTextShadow.mjs +26 -39
- package/dist/components/StyleInspector/categories/Variables/Variables.mjs +38 -37
- package/dist/components/StyleInspector/categoryKeys.d.ts +45 -0
- package/dist/components/StyleInspector/categoryKeys.mjs +220 -0
- package/dist/components/StyleInspector/components/CategoryContainer/CategoryContainer.mjs +43 -38
- package/dist/components/StyleInspector/components/CategoryOption/categoryTypes/OptionIconGroup.mjs +2 -1
- package/dist/components/StyleInspector/components/CategorySection/CategorySection.mjs +30 -15
- package/dist/components/StyleInspector/components/ColorSwatch/ColorSwatch.d.ts +8 -0
- package/dist/components/StyleInspector/components/ColorSwatch/ColorSwatch.mjs +23 -0
- package/dist/components/StyleInspector/components/ColorSwatch/helpers.d.ts +3 -0
- package/dist/components/StyleInspector/components/ColorSwatch/helpers.mjs +9 -0
- package/dist/components/StyleInspector/components/ColorSwatch/index.d.ts +3 -0
- package/dist/components/StyleInspector/components/ColorSwatch/index.mjs +5 -0
- package/dist/components/StyleInspector/components/InspectorDots/InspectorDots.d.ts +1 -0
- package/dist/components/StyleInspector/components/InspectorDots/InspectorDots.mjs +11 -11
- package/dist/components/StyleInspector/components/InspectorFooter/InspectorFooter.d.ts +11 -0
- package/dist/components/StyleInspector/components/InspectorFooter/InspectorFooter.mjs +38 -0
- package/dist/components/StyleInspector/components/InspectorFooter/helpers.d.ts +2 -0
- package/dist/components/StyleInspector/components/InspectorFooter/helpers.mjs +11 -0
- package/dist/components/StyleInspector/components/InspectorFooter/index.d.ts +3 -0
- package/dist/components/StyleInspector/components/InspectorFooter/index.mjs +5 -0
- package/dist/components/StyleInspector/components/InspectorLabel/InspectorLabel.mjs +34 -31
- package/dist/components/StyleInspector/components/InspectorLabel/helpers.d.ts +17 -0
- package/dist/components/StyleInspector/components/InspectorLabel/helpers.mjs +16 -0
- package/dist/components/StyleInspector/components/InspectorSearch/InspectorSearch.d.ts +7 -0
- package/dist/components/StyleInspector/components/InspectorSearch/InspectorSearch.mjs +24 -0
- package/dist/components/StyleInspector/components/InspectorSearch/index.d.ts +3 -0
- package/dist/components/StyleInspector/components/InspectorSearch/index.mjs +5 -0
- package/dist/components/StyleInspector/components/ShadowItem/ShadowItem.d.ts +9 -0
- package/dist/components/StyleInspector/components/ShadowItem/ShadowItem.mjs +110 -0
- package/dist/components/StyleInspector/components/ShadowItem/index.d.ts +3 -0
- package/dist/components/StyleInspector/components/ShadowItem/index.mjs +5 -0
- package/dist/components/StyleInspector/components/TargetSummary/TargetSummary.d.ts +7 -0
- package/dist/components/StyleInspector/components/TargetSummary/TargetSummary.mjs +24 -0
- package/dist/components/StyleInspector/components/TargetSummary/index.d.ts +3 -0
- package/dist/components/StyleInspector/components/TargetSummary/index.mjs +5 -0
- package/dist/components/StyleInspector/components/ValueList/ValueList.d.ts +12 -0
- package/dist/components/StyleInspector/components/ValueList/ValueList.mjs +25 -0
- package/dist/components/StyleInspector/components/ValueList/index.d.ts +3 -0
- package/dist/components/StyleInspector/components/ValueList/index.mjs +5 -0
- package/dist/components/StyleInspector/components/ValueListItem/ValueListItem.d.ts +16 -0
- package/dist/components/StyleInspector/components/ValueListItem/ValueListItem.mjs +71 -0
- package/dist/components/StyleInspector/components/ValueListItem/index.d.ts +3 -0
- package/dist/components/StyleInspector/components/ValueListItem/index.mjs +5 -0
- package/dist/components/StyleInspector/cssValues.d.ts +15 -0
- package/dist/components/StyleInspector/cssValues.mjs +27 -0
- package/dist/components/StyleInspector/helpers.d.ts +17 -1
- package/dist/components/StyleInspector/helpers.mjs +9 -2
- package/dist/components/StyleInspector/hooks/useInspectorValues.mjs +42 -45
- package/dist/components/StyleInspector/search.d.ts +11 -0
- package/dist/components/StyleInspector/search.mjs +14 -0
- package/dist/components/StyleInspector/shadowValue.d.ts +20 -0
- package/dist/components/StyleInspector/shadowValue.mjs +36 -0
- package/dist/components/StyleManager/StyleSelectorTag.mjs +1 -1
- package/package.json +185 -17
- package/dist/components/StyleInspector/categories/Effects/BoxShadow/BoxShadowItem.d.ts +0 -8
- package/dist/components/StyleInspector/categories/Effects/BoxShadow/BoxShadowItem.mjs +0 -132
- package/dist/components/StyleInspector/categories/Effects/BoxShadow/helpers.d.ts +0 -2
- package/dist/components/StyleInspector/categories/Effects/BoxShadow/helpers.mjs +0 -18
- package/dist/components/StyleInspector/categories/Typography/TypographyTextShadowItem.d.ts +0 -8
- package/dist/components/StyleInspector/categories/Typography/TypographyTextShadowItem.mjs +0 -83
|
@@ -1,41 +1,24 @@
|
|
|
1
1
|
import e from "../../StyleInspectorContext.mjs";
|
|
2
2
|
import t from "../../hooks/useInspectorValues.mjs";
|
|
3
|
-
import n from "../../
|
|
4
|
-
import r from "
|
|
5
|
-
import i from "./
|
|
6
|
-
import a from "./
|
|
7
|
-
import o from "./
|
|
8
|
-
import s from "./
|
|
9
|
-
import c from "./
|
|
10
|
-
import l from "./
|
|
11
|
-
import u from "./
|
|
12
|
-
import d from "./
|
|
13
|
-
import
|
|
14
|
-
import {
|
|
15
|
-
|
|
16
|
-
var
|
|
17
|
-
"flex-direction",
|
|
18
|
-
|
|
19
|
-
"align-items",
|
|
20
|
-
"justify-content",
|
|
21
|
-
"align-content",
|
|
22
|
-
"column-gap",
|
|
23
|
-
"row-gap",
|
|
24
|
-
"grid-row-gap",
|
|
25
|
-
"grid-column-gap",
|
|
26
|
-
"grid-template-areas",
|
|
27
|
-
"grid-template-columns",
|
|
28
|
-
"grid-template-rows",
|
|
29
|
-
"grid-auto-flow",
|
|
30
|
-
"grid-auto-rows",
|
|
31
|
-
"grid-auto-columns",
|
|
32
|
-
"display"
|
|
33
|
-
], y = f(({ replaceTokens: f = !1, isCollapsed: y = !0, onCollapse: b }) => {
|
|
34
|
-
let { setValue: x } = p(e), { display: S, "flex-direction": C, "flex-wrap": w, "align-items": T, "justify-content": E, "row-gap": D, "column-gap": O, "grid-template-areas": k, "grid-template-columns": A, "grid-template-rows": j, "grid-auto-flow": M, "grid-auto-rows": N, "grid-auto-columns": P, "grid-row-gap": F, "grid-column-gap": I, "align-content": L } = t({
|
|
35
|
-
keys: v,
|
|
3
|
+
import { DISPLAY_KEYS as n } from "../../categoryKeys.mjs";
|
|
4
|
+
import r from "../../components/CategoryContainer/index.mjs";
|
|
5
|
+
import i from "./DisplayElements.mjs";
|
|
6
|
+
import a from "./DisplayFlex.mjs";
|
|
7
|
+
import o from "./DisplayFlexAlignContent.mjs";
|
|
8
|
+
import s from "./DisplayFlexAlignItems.mjs";
|
|
9
|
+
import c from "./DisplayFlexDirection.mjs";
|
|
10
|
+
import l from "./DisplayFlexJustify.mjs";
|
|
11
|
+
import u from "./DisplayGap.mjs";
|
|
12
|
+
import d from "./DisplayGridGap.mjs";
|
|
13
|
+
import f from "./DisplayGridTemplate.mjs";
|
|
14
|
+
import { memo as p, use as m, useCallback as h } from "react";
|
|
15
|
+
import { Fragment as g, jsx as _, jsxs as v } from "react/jsx-runtime";
|
|
16
|
+
var y = p(({ replaceTokens: p = !1, isCollapsed: y = !0, onCollapse: b }) => {
|
|
17
|
+
let { setValue: x } = m(e), { display: S, "flex-direction": C, "flex-wrap": w, "align-items": T, "justify-content": E, "row-gap": D, "column-gap": O, "grid-template-areas": k, "grid-template-columns": A, "grid-template-rows": j, "grid-auto-flow": M, "grid-auto-rows": N, "grid-auto-columns": P, "grid-row-gap": F, "grid-column-gap": I, "align-content": L } = t({
|
|
18
|
+
keys: n.dot,
|
|
36
19
|
asValue: !0,
|
|
37
|
-
replaceTokens:
|
|
38
|
-
}), R =
|
|
20
|
+
replaceTokens: p
|
|
21
|
+
}), R = h((e, t) => {
|
|
39
22
|
e === "display" ? x(void 0, {
|
|
40
23
|
"flex-direction": void 0,
|
|
41
24
|
"flex-wrap": void 0,
|
|
@@ -54,47 +37,47 @@ var v = [
|
|
|
54
37
|
"grid-auto-columns": void 0,
|
|
55
38
|
display: t
|
|
56
39
|
}) : x(e, t);
|
|
57
|
-
}, [x]), z =
|
|
58
|
-
return /* @__PURE__ */
|
|
59
|
-
title:
|
|
60
|
-
dotKeys:
|
|
40
|
+
}, [x]), z = h((e) => b?.("display", e), [b]), B = typeof C == "string" && C.includes("reverse"), V = typeof C == "string" && C.includes("row"), H = typeof w == "string" && w.includes("reverse");
|
|
41
|
+
return /* @__PURE__ */ v(r, {
|
|
42
|
+
title: n.title,
|
|
43
|
+
dotKeys: n.dot,
|
|
61
44
|
isCollapsed: y,
|
|
62
45
|
onCollapse: z,
|
|
63
46
|
children: [
|
|
64
|
-
/* @__PURE__ */
|
|
47
|
+
/* @__PURE__ */ _(i, {
|
|
65
48
|
value: S,
|
|
66
49
|
onChange: R
|
|
67
50
|
}),
|
|
68
|
-
S === "flex" && /* @__PURE__ */
|
|
69
|
-
/* @__PURE__ */
|
|
51
|
+
S === "flex" && /* @__PURE__ */ v(g, { children: [
|
|
52
|
+
/* @__PURE__ */ _(c, {
|
|
70
53
|
value: C,
|
|
71
54
|
onChange: R,
|
|
72
55
|
isReverse: B
|
|
73
56
|
}),
|
|
74
|
-
/* @__PURE__ */
|
|
57
|
+
/* @__PURE__ */ _(s, {
|
|
75
58
|
value: T,
|
|
76
59
|
onChange: R,
|
|
77
60
|
isReverse: B,
|
|
78
61
|
isRow: V
|
|
79
62
|
}),
|
|
80
|
-
/* @__PURE__ */
|
|
63
|
+
/* @__PURE__ */ _(l, {
|
|
81
64
|
value: E,
|
|
82
65
|
onChange: R,
|
|
83
66
|
isReverse: B,
|
|
84
67
|
isRow: V
|
|
85
68
|
}),
|
|
86
|
-
/* @__PURE__ */
|
|
69
|
+
/* @__PURE__ */ _(a, {
|
|
87
70
|
value: w,
|
|
88
71
|
onChange: R,
|
|
89
72
|
isReverse: H
|
|
90
73
|
}),
|
|
91
|
-
/* @__PURE__ */
|
|
74
|
+
/* @__PURE__ */ _(u, {
|
|
92
75
|
rowGap: D,
|
|
93
76
|
columnGap: O,
|
|
94
77
|
onChange: R
|
|
95
78
|
})
|
|
96
79
|
] }),
|
|
97
|
-
S === "grid" && /* @__PURE__ */
|
|
80
|
+
S === "grid" && /* @__PURE__ */ v(g, { children: [/* @__PURE__ */ _(f, {
|
|
98
81
|
templateAreas: k,
|
|
99
82
|
templateColumns: A,
|
|
100
83
|
templateRows: j,
|
|
@@ -102,12 +85,12 @@ var v = [
|
|
|
102
85
|
templateAutoRows: N,
|
|
103
86
|
templateAutoColumns: P,
|
|
104
87
|
onChange: R
|
|
105
|
-
}), /* @__PURE__ */
|
|
88
|
+
}), /* @__PURE__ */ _(d, {
|
|
106
89
|
rowGap: F,
|
|
107
90
|
columnGap: I,
|
|
108
91
|
onChange: R
|
|
109
92
|
})] }),
|
|
110
|
-
S === "flex" && (w === "wrap" || w === "wrap-reverse") && /* @__PURE__ */
|
|
93
|
+
S === "flex" && (w === "wrap" || w === "wrap-reverse") && /* @__PURE__ */ _(o, {
|
|
111
94
|
value: L,
|
|
112
95
|
onChange: R,
|
|
113
96
|
isReverse: H,
|
|
@@ -2,39 +2,34 @@ import e from "../../StyleInspectorContext.mjs";
|
|
|
2
2
|
import t from "../../hooks/useInspectorValues.mjs";
|
|
3
3
|
import n from "../../components/CategoryOption/index.mjs";
|
|
4
4
|
import r from "../../components/CategorySection/index.mjs";
|
|
5
|
-
import i from "../../
|
|
6
|
-
import a from "
|
|
7
|
-
import o from "./
|
|
8
|
-
import
|
|
9
|
-
import {
|
|
10
|
-
import p from "
|
|
11
|
-
import m from "@plitzi/plitzi-ui/icons/
|
|
12
|
-
import h from "@plitzi/plitzi-ui/icons/
|
|
5
|
+
import { FLEX_CHILD_KEYS as i } from "../../categoryKeys.mjs";
|
|
6
|
+
import a from "../../components/CategoryContainer/index.mjs";
|
|
7
|
+
import o from "./DisplayAlignSelf.mjs";
|
|
8
|
+
import s from "./DisplayOrder.mjs";
|
|
9
|
+
import { memo as c, use as l, useCallback as u, useMemo as d } from "react";
|
|
10
|
+
import { jsx as f, jsxs as p } from "react/jsx-runtime";
|
|
11
|
+
import m from "@plitzi/plitzi-ui/icons/FlexGrowRow";
|
|
12
|
+
import h from "@plitzi/plitzi-ui/icons/FlexNoneRow";
|
|
13
|
+
import g from "@plitzi/plitzi-ui/icons/FlexShrinkRow";
|
|
13
14
|
//#region src/components/StyleInspector/categories/DisplayFlexChild/DisplayFlexChild.tsx
|
|
14
|
-
var
|
|
15
|
-
"align-self",
|
|
16
|
-
"order",
|
|
15
|
+
var _ = [
|
|
17
16
|
"flex-grow",
|
|
18
17
|
"flex-shrink",
|
|
19
18
|
"flex-basis"
|
|
20
|
-
],
|
|
21
|
-
"flex-grow",
|
|
22
|
-
|
|
23
|
-
"flex-basis"
|
|
24
|
-
], v = s(({ replaceTokens: s = !1, isCollapsed: v = !0, isFlexVertical: y = !1, onCollapse: b }) => {
|
|
25
|
-
let { setValue: x } = c(e), { "flex-grow": S, "flex-shrink": C, "flex-basis": w, "align-self": T, order: E } = t({
|
|
26
|
-
keys: g,
|
|
19
|
+
], v = c(({ replaceTokens: c = !1, isCollapsed: v = !0, isFlexVertical: y = !1, onCollapse: b }) => {
|
|
20
|
+
let { setValue: x } = l(e), { "flex-grow": S, "flex-shrink": C, "flex-basis": w, "align-self": T, order: E } = t({
|
|
21
|
+
keys: i.dot,
|
|
27
22
|
asValue: !0,
|
|
28
|
-
replaceTokens:
|
|
29
|
-
}), D =
|
|
23
|
+
replaceTokens: c
|
|
24
|
+
}), D = u((e) => {
|
|
30
25
|
x(void 0, e);
|
|
31
|
-
}, [x]), O =
|
|
26
|
+
}, [x]), O = u((e) => {
|
|
32
27
|
x("flex-grow", e);
|
|
33
|
-
}, [x]), k =
|
|
28
|
+
}, [x]), k = u((e) => {
|
|
34
29
|
x("flex-shrink", e);
|
|
35
|
-
}, [x]), A =
|
|
30
|
+
}, [x]), A = u((e) => {
|
|
36
31
|
x("flex-basis", e);
|
|
37
|
-
}, [x]), j =
|
|
32
|
+
}, [x]), j = u((e) => b?.("displayFlexChild", e), [b]), M = d(() => {
|
|
38
33
|
let e = (S !== "0" || C !== "1" || w !== "auto") && (S !== "1" || C !== "1" || w !== "0%") && (S !== "0" || C !== "0" || w !== "auto");
|
|
39
34
|
return [
|
|
40
35
|
{
|
|
@@ -43,7 +38,7 @@ var g = [
|
|
|
43
38
|
"flex-shrink": "1",
|
|
44
39
|
"flex-basis": "auto"
|
|
45
40
|
},
|
|
46
|
-
icon: /* @__PURE__ */
|
|
41
|
+
icon: /* @__PURE__ */ f(g, {}),
|
|
47
42
|
description: "Shrink if needed",
|
|
48
43
|
active: !e && S === "0" && C === "1" && w === "auto"
|
|
49
44
|
},
|
|
@@ -53,7 +48,7 @@ var g = [
|
|
|
53
48
|
"flex-shrink": "1",
|
|
54
49
|
"flex-basis": "0%"
|
|
55
50
|
},
|
|
56
|
-
icon: /* @__PURE__ */
|
|
51
|
+
icon: /* @__PURE__ */ f(m, {}),
|
|
57
52
|
description: "Grow if possible",
|
|
58
53
|
active: !e && S === "1" && C === "1" && w === "0%"
|
|
59
54
|
},
|
|
@@ -63,7 +58,7 @@ var g = [
|
|
|
63
58
|
"flex-shrink": "0",
|
|
64
59
|
"flex-basis": "auto"
|
|
65
60
|
},
|
|
66
|
-
icon: /* @__PURE__ */
|
|
61
|
+
icon: /* @__PURE__ */ f(h, {}),
|
|
67
62
|
description: "Don't shrink or grow",
|
|
68
63
|
active: !e && S === "0" && C === "0" && w === "auto"
|
|
69
64
|
}
|
|
@@ -72,36 +67,36 @@ var g = [
|
|
|
72
67
|
S,
|
|
73
68
|
C,
|
|
74
69
|
w
|
|
75
|
-
]), N =
|
|
76
|
-
return /* @__PURE__ */
|
|
77
|
-
title:
|
|
78
|
-
dotKeys:
|
|
70
|
+
]), N = u((e, t) => x(e, t), [x]);
|
|
71
|
+
return /* @__PURE__ */ p(a, {
|
|
72
|
+
title: i.title,
|
|
73
|
+
dotKeys: i.dot,
|
|
79
74
|
isCollapsed: v,
|
|
80
75
|
onCollapse: j,
|
|
81
76
|
children: [
|
|
82
|
-
/* @__PURE__ */
|
|
77
|
+
/* @__PURE__ */ f(n, {
|
|
83
78
|
keys: _,
|
|
84
79
|
label: "Sizing",
|
|
85
80
|
onChange: D,
|
|
86
81
|
type: "iconGroup",
|
|
87
82
|
items: M
|
|
88
83
|
}),
|
|
89
|
-
/* @__PURE__ */
|
|
90
|
-
/* @__PURE__ */
|
|
84
|
+
/* @__PURE__ */ p(r, { children: [
|
|
85
|
+
/* @__PURE__ */ f(n, {
|
|
91
86
|
keys: ["flex-grow"],
|
|
92
87
|
label: "Grow",
|
|
93
88
|
onChange: O,
|
|
94
89
|
type: "input",
|
|
95
90
|
value: S
|
|
96
91
|
}),
|
|
97
|
-
/* @__PURE__ */
|
|
92
|
+
/* @__PURE__ */ f(n, {
|
|
98
93
|
keys: ["flex-shrink"],
|
|
99
94
|
label: "Shrink",
|
|
100
95
|
onChange: k,
|
|
101
96
|
type: "input",
|
|
102
97
|
value: C
|
|
103
98
|
}),
|
|
104
|
-
/* @__PURE__ */
|
|
99
|
+
/* @__PURE__ */ f(n, {
|
|
105
100
|
keys: ["flex-basis"],
|
|
106
101
|
label: "Basis",
|
|
107
102
|
onChange: A,
|
|
@@ -109,12 +104,12 @@ var g = [
|
|
|
109
104
|
value: w
|
|
110
105
|
})
|
|
111
106
|
] }),
|
|
112
|
-
/* @__PURE__ */
|
|
107
|
+
/* @__PURE__ */ f(o, {
|
|
113
108
|
value: T,
|
|
114
109
|
isFlexVertical: y,
|
|
115
110
|
onChange: N
|
|
116
111
|
}),
|
|
117
|
-
/* @__PURE__ */
|
|
112
|
+
/* @__PURE__ */ f(s, {
|
|
118
113
|
value: E,
|
|
119
114
|
onChange: N
|
|
120
115
|
})
|
|
@@ -1,38 +1,26 @@
|
|
|
1
|
-
import e from "../../../
|
|
2
|
-
import
|
|
3
|
-
import n from "
|
|
4
|
-
import
|
|
5
|
-
import {
|
|
6
|
-
import
|
|
1
|
+
import { splitByCommaOutsideParens as e } from "../../../cssValues.mjs";
|
|
2
|
+
import t from "../../../components/ValueList/index.mjs";
|
|
3
|
+
import { DEFAULT_SHADOW as n, serializeShadow as r } from "../../../shadowValue.mjs";
|
|
4
|
+
import i from "../../../components/ShadowItem/index.mjs";
|
|
5
|
+
import { useCallback as a } from "react";
|
|
6
|
+
import { jsx as o } from "react/jsx-runtime";
|
|
7
7
|
//#region src/components/StyleInspector/categories/Effects/BoxShadow/BoxShadow.tsx
|
|
8
|
-
var c = ({ value: c = "", onChange: l }) => {
|
|
9
|
-
let u = []
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
children: "Box Shadow"
|
|
23
|
-
}), /* @__PURE__ */ a(s, {
|
|
24
|
-
className: "cursor-pointer",
|
|
25
|
-
icon: "fas fa-plus",
|
|
26
|
-
onClick: p
|
|
27
|
-
})]
|
|
28
|
-
}), u.length > 0 && /* @__PURE__ */ a("div", {
|
|
29
|
-
className: "flex flex-col gap-2",
|
|
30
|
-
children: u.map((e, t) => /* @__PURE__ */ a(n, {
|
|
31
|
-
value: e.trim(),
|
|
32
|
-
onChange: f(t),
|
|
33
|
-
onRemove: d(t)
|
|
8
|
+
var s = ["box-shadow"], c = ({ value: c = "", onChange: l }) => {
|
|
9
|
+
let u = typeof c == "string" && c !== "" ? e(c).map((e) => e.trim()) : [], d = a((e) => l?.(e.length > 0 ? e.join(", ") : ""), [l]), f = (e) => () => d(u.filter((t, n) => n !== e)), p = (e) => (t) => {
|
|
10
|
+
t !== u[e] && d(u.map((n, r) => r === e ? t : n));
|
|
11
|
+
};
|
|
12
|
+
return /* @__PURE__ */ o(t, {
|
|
13
|
+
label: "Box Shadow",
|
|
14
|
+
keys: s,
|
|
15
|
+
addLabel: "Add box shadow",
|
|
16
|
+
onAdd: () => d([...u, r(n, { withSpread: !0 })]),
|
|
17
|
+
children: u.length > 0 && u.map((e, t) => /* @__PURE__ */ o(i, {
|
|
18
|
+
value: e,
|
|
19
|
+
withSpread: !0,
|
|
20
|
+
onChange: p(t),
|
|
21
|
+
onRemove: f(t)
|
|
34
22
|
}, t))
|
|
35
|
-
})
|
|
23
|
+
});
|
|
36
24
|
};
|
|
37
25
|
//#endregion
|
|
38
26
|
export { c as default };
|