@vkzstudio/muza-ui 1.0.45 → 1.0.47
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/Accordion/Accordion.d.ts.map +1 -1
- package/dist/components/Accordion/Accordion.js +70 -62
- package/dist/components/Accordion/Accordion.stories.d.ts.map +1 -1
- package/dist/components/Button/Button.stories.d.ts.map +1 -1
- package/dist/components/Card/Card.d.ts +63 -0
- package/dist/components/Card/Card.d.ts.map +1 -0
- package/dist/components/Card/Card.js +67 -0
- package/dist/components/Card/Card.stories.d.ts +13 -0
- package/dist/components/Card/Card.stories.d.ts.map +1 -0
- package/dist/components/Card/index.d.ts +2 -0
- package/dist/components/Card/index.d.ts.map +1 -0
- package/dist/components/Carousel/Carousel.d.ts +140 -0
- package/dist/components/Carousel/Carousel.d.ts.map +1 -0
- package/dist/components/Carousel/Carousel.js +241 -0
- package/dist/components/Carousel/Carousel.stories.d.ts +13 -0
- package/dist/components/Carousel/Carousel.stories.d.ts.map +1 -0
- package/dist/components/Carousel/index.d.ts +2 -0
- package/dist/components/Carousel/index.d.ts.map +1 -0
- package/dist/components/DataTable/DataTable.stories.d.ts.map +1 -1
- package/dist/components/DropdownMenu/DropdownMenu.js +1 -1
- package/dist/components/EdgeButton/EdgeButton.stories.d.ts.map +1 -1
- package/dist/components/Flex/Flex.d.ts +372 -1
- package/dist/components/Flex/Flex.d.ts.map +1 -1
- package/dist/components/Flex/Flex.js +61 -63
- package/dist/components/Flex/Flex.stories.d.ts.map +1 -1
- package/dist/components/Icons/Icons.stories.d.ts.map +1 -1
- package/dist/components/Icons/LogosAndBadges.stories.d.ts.map +1 -1
- package/dist/components/MultiSelect/MultiSelect.stories.d.ts.map +1 -1
- package/dist/components/MuzaUIProvider/MuzaUIProvider.stories.d.ts.map +1 -1
- package/dist/components/Pagination/Pagination.js +1 -1
- package/dist/components/Pagination/Pagination.stories.d.ts.map +1 -1
- package/dist/components/Progress/Progress.d.ts +49 -0
- package/dist/components/Progress/Progress.d.ts.map +1 -0
- package/dist/components/Progress/Progress.js +64 -0
- package/dist/components/Progress/Progress.stories.d.ts +13 -0
- package/dist/components/Progress/Progress.stories.d.ts.map +1 -0
- package/dist/components/Progress/index.d.ts +2 -0
- package/dist/components/Progress/index.d.ts.map +1 -0
- package/dist/components/Reorderable/Reorderable.stories.d.ts.map +1 -1
- package/dist/components/Sheet/Sheet.d.ts +89 -0
- package/dist/components/Sheet/Sheet.d.ts.map +1 -0
- package/dist/components/Sheet/Sheet.js +189 -0
- package/dist/components/Sheet/Sheet.stories.d.ts +20 -0
- package/dist/components/Sheet/Sheet.stories.d.ts.map +1 -0
- package/dist/components/Sheet/index.d.ts +2 -0
- package/dist/components/Sheet/index.d.ts.map +1 -0
- package/dist/components/Slider/Slider.d.ts +65 -0
- package/dist/components/Slider/Slider.d.ts.map +1 -0
- package/dist/components/Slider/Slider.js +134 -0
- package/dist/components/Slider/Slider.stories.d.ts +12 -0
- package/dist/components/Slider/Slider.stories.d.ts.map +1 -0
- package/dist/components/Slider/index.d.ts +2 -0
- package/dist/components/Slider/index.d.ts.map +1 -0
- package/dist/components/TextEditor/TextEditor.stories.d.ts.map +1 -1
- package/dist/components/Typography/Typography.stories.d.ts.map +1 -1
- package/dist/components/index.d.ts +5 -0
- package/dist/components/index.d.ts.map +1 -1
- package/dist/index.js +310 -277
- package/dist/muza-ui.css +1 -1
- package/dist/styles/primitives.css +5 -1
- package/dist/styles/token-colors.css +175 -27
- package/dist/styles/token-sizes.css +602 -257
- package/dist/styles/typography.css +36 -7
- package/dist/translations/locales/cs.d.ts.map +1 -1
- package/dist/translations/locales/cs.js +17 -0
- package/dist/translations/locales/en.d.ts.map +1 -1
- package/dist/translations/locales/en.js +17 -0
- package/dist/translations/locales/sk.d.ts.map +1 -1
- package/dist/translations/locales/sk.js +19 -2
- package/dist/translations/types.d.ts +42 -0
- package/dist/translations/types.d.ts.map +1 -1
- package/dist/utils/cn.d.ts.map +1 -1
- package/dist/utils/cn.js +24 -10
- package/llms-full.md +38 -35
- package/llms.txt +10 -9
- package/package.json +6 -3
|
@@ -0,0 +1,241 @@
|
|
|
1
|
+
import { jsx as m, jsxs as H } from "react/jsx-runtime";
|
|
2
|
+
import * as o from "react";
|
|
3
|
+
import j from "embla-carousel-react";
|
|
4
|
+
import { Flex as B } from "../Flex/Flex.js";
|
|
5
|
+
import { useMuzaTranslations as y } from "../../translations/TranslationContext.js";
|
|
6
|
+
import { ButtonArrow as z } from "../ButtonArrow/ButtonArrow.js";
|
|
7
|
+
import { SliderIndicators as F } from "../SliderIndicators/SliderIndicators.js";
|
|
8
|
+
import { cn as b } from "../../utils/cn.js";
|
|
9
|
+
const P = o.createContext(null), x = () => {
|
|
10
|
+
const t = o.useContext(P);
|
|
11
|
+
if (!t)
|
|
12
|
+
throw new Error("useCarousel must be used within a <Carousel />");
|
|
13
|
+
return t;
|
|
14
|
+
}, M = o.forwardRef(
|
|
15
|
+
({
|
|
16
|
+
orientation: t = "horizontal",
|
|
17
|
+
opts: l,
|
|
18
|
+
setApi: n,
|
|
19
|
+
plugins: a,
|
|
20
|
+
className: u,
|
|
21
|
+
children: c,
|
|
22
|
+
...f
|
|
23
|
+
}, p) => {
|
|
24
|
+
const [C, e] = j(
|
|
25
|
+
{
|
|
26
|
+
...l,
|
|
27
|
+
axis: t === "horizontal" ? "x" : "y"
|
|
28
|
+
},
|
|
29
|
+
a
|
|
30
|
+
), [h, s] = o.useState(!1), [i, w] = o.useState(!1), [R, D] = o.useState(0), [E, L] = o.useState(0), d = o.useCallback((r) => {
|
|
31
|
+
r && (D(r.selectedScrollSnap()), s(r.canScrollPrev()), w(r.canScrollNext()));
|
|
32
|
+
}, []), v = o.useCallback((r) => {
|
|
33
|
+
r && L(r.scrollSnapList().length);
|
|
34
|
+
}, []), S = o.useCallback(() => {
|
|
35
|
+
e == null || e.scrollPrev();
|
|
36
|
+
}, [e]), N = o.useCallback(() => {
|
|
37
|
+
e == null || e.scrollNext();
|
|
38
|
+
}, [e]), A = o.useCallback(
|
|
39
|
+
(r) => {
|
|
40
|
+
e == null || e.scrollTo(r);
|
|
41
|
+
},
|
|
42
|
+
[e]
|
|
43
|
+
), k = o.useCallback(
|
|
44
|
+
(r) => {
|
|
45
|
+
const K = t === "horizontal" ? "ArrowLeft" : "ArrowUp", T = t === "horizontal" ? "ArrowRight" : "ArrowDown";
|
|
46
|
+
r.key === K ? (r.preventDefault(), S()) : r.key === T && (r.preventDefault(), N());
|
|
47
|
+
},
|
|
48
|
+
[t, S, N]
|
|
49
|
+
);
|
|
50
|
+
o.useEffect(() => {
|
|
51
|
+
!e || !n || n(e);
|
|
52
|
+
}, [e, n]), o.useEffect(() => {
|
|
53
|
+
if (e)
|
|
54
|
+
return L(e.scrollSnapList().length), d(e), e.on("select", d), e.on("reInit", d), e.on("reInit", v), () => {
|
|
55
|
+
e.off("select", d), e.off("reInit", d), e.off("reInit", v);
|
|
56
|
+
};
|
|
57
|
+
}, [e, d, v]);
|
|
58
|
+
const g = [], I = [];
|
|
59
|
+
return o.Children.forEach(c, (r) => {
|
|
60
|
+
o.isValidElement(r) && r.type === J ? g.push(r) : I.push(r);
|
|
61
|
+
}), /* @__PURE__ */ m(
|
|
62
|
+
P.Provider,
|
|
63
|
+
{
|
|
64
|
+
value: {
|
|
65
|
+
carouselRef: C,
|
|
66
|
+
api: e,
|
|
67
|
+
opts: l,
|
|
68
|
+
orientation: t,
|
|
69
|
+
plugins: a,
|
|
70
|
+
scrollPrev: S,
|
|
71
|
+
scrollNext: N,
|
|
72
|
+
canScrollPrev: h,
|
|
73
|
+
canScrollNext: i,
|
|
74
|
+
selectedIndex: R,
|
|
75
|
+
scrollTo: A,
|
|
76
|
+
slidesCount: E
|
|
77
|
+
},
|
|
78
|
+
children: /* @__PURE__ */ H(
|
|
79
|
+
"div",
|
|
80
|
+
{
|
|
81
|
+
ref: p,
|
|
82
|
+
onKeyDownCapture: k,
|
|
83
|
+
className: u,
|
|
84
|
+
role: "region",
|
|
85
|
+
"aria-roledescription": "carousel",
|
|
86
|
+
...f,
|
|
87
|
+
children: [
|
|
88
|
+
/* @__PURE__ */ m("div", { className: "relative", children: I }),
|
|
89
|
+
g
|
|
90
|
+
]
|
|
91
|
+
}
|
|
92
|
+
)
|
|
93
|
+
}
|
|
94
|
+
);
|
|
95
|
+
}
|
|
96
|
+
);
|
|
97
|
+
M.displayName = "Carousel";
|
|
98
|
+
const U = o.forwardRef(
|
|
99
|
+
({ className: t, ...l }, n) => {
|
|
100
|
+
const { carouselRef: a, orientation: u } = x(), c = u === "horizontal";
|
|
101
|
+
return /* @__PURE__ */ m("div", { ref: a, className: "overflow-hidden", children: /* @__PURE__ */ m(
|
|
102
|
+
B,
|
|
103
|
+
{
|
|
104
|
+
ref: n,
|
|
105
|
+
direction: c ? "row" : "column",
|
|
106
|
+
className: b(
|
|
107
|
+
c ? "-ml-comp-carousel-gap" : "-mt-comp-carousel-gap",
|
|
108
|
+
t
|
|
109
|
+
),
|
|
110
|
+
...l
|
|
111
|
+
}
|
|
112
|
+
) });
|
|
113
|
+
}
|
|
114
|
+
);
|
|
115
|
+
U.displayName = "CarouselContent";
|
|
116
|
+
const V = o.forwardRef(
|
|
117
|
+
({ className: t, ...l }, n) => {
|
|
118
|
+
const { orientation: a } = x();
|
|
119
|
+
return /* @__PURE__ */ m(
|
|
120
|
+
"div",
|
|
121
|
+
{
|
|
122
|
+
ref: n,
|
|
123
|
+
role: "group",
|
|
124
|
+
"aria-roledescription": "slide",
|
|
125
|
+
className: b(
|
|
126
|
+
"min-w-0 shrink-0 grow-0 basis-full",
|
|
127
|
+
{
|
|
128
|
+
"pl-comp-carousel-gap": a === "horizontal",
|
|
129
|
+
"pt-comp-carousel-gap": a !== "horizontal"
|
|
130
|
+
},
|
|
131
|
+
t
|
|
132
|
+
),
|
|
133
|
+
...l
|
|
134
|
+
}
|
|
135
|
+
);
|
|
136
|
+
}
|
|
137
|
+
);
|
|
138
|
+
V.displayName = "CarouselItem";
|
|
139
|
+
const q = o.forwardRef(
|
|
140
|
+
({
|
|
141
|
+
className: t,
|
|
142
|
+
size: l = "default",
|
|
143
|
+
ariaLabel: n,
|
|
144
|
+
onClick: a,
|
|
145
|
+
...u
|
|
146
|
+
}, c) => {
|
|
147
|
+
const { orientation: f, scrollPrev: p, canScrollPrev: C } = x(), e = y(), h = n ?? e.carousel.previousAriaLabel, s = f === "horizontal", i = l === "sm";
|
|
148
|
+
return /* @__PURE__ */ m(
|
|
149
|
+
z,
|
|
150
|
+
{
|
|
151
|
+
ref: c,
|
|
152
|
+
direction: "left",
|
|
153
|
+
size: l,
|
|
154
|
+
disabled: !C,
|
|
155
|
+
"aria-label": h,
|
|
156
|
+
onClick: (w) => {
|
|
157
|
+
p(), a == null || a(w);
|
|
158
|
+
},
|
|
159
|
+
className: b(
|
|
160
|
+
"absolute",
|
|
161
|
+
{
|
|
162
|
+
"top-1/2 -translate-y-1/2": s,
|
|
163
|
+
"left-1/2 -translate-x-1/2 rotate-90": !s,
|
|
164
|
+
"-left-comp-carousel-arrow-offset-sm": s && i,
|
|
165
|
+
"-left-comp-carousel-arrow-offset": s && !i,
|
|
166
|
+
"-top-comp-carousel-arrow-offset-v-sm": !s && i,
|
|
167
|
+
"-top-comp-carousel-arrow-offset-v": !s && !i
|
|
168
|
+
},
|
|
169
|
+
t
|
|
170
|
+
),
|
|
171
|
+
...u
|
|
172
|
+
}
|
|
173
|
+
);
|
|
174
|
+
}
|
|
175
|
+
);
|
|
176
|
+
q.displayName = "CarouselPrevious";
|
|
177
|
+
const G = o.forwardRef(
|
|
178
|
+
({
|
|
179
|
+
className: t,
|
|
180
|
+
size: l = "default",
|
|
181
|
+
ariaLabel: n,
|
|
182
|
+
onClick: a,
|
|
183
|
+
...u
|
|
184
|
+
}, c) => {
|
|
185
|
+
const { orientation: f, scrollNext: p, canScrollNext: C } = x(), e = y(), h = n ?? e.carousel.nextAriaLabel, s = f === "horizontal", i = l === "sm";
|
|
186
|
+
return /* @__PURE__ */ m(
|
|
187
|
+
z,
|
|
188
|
+
{
|
|
189
|
+
ref: c,
|
|
190
|
+
direction: "right",
|
|
191
|
+
size: l,
|
|
192
|
+
disabled: !C,
|
|
193
|
+
"aria-label": h,
|
|
194
|
+
onClick: (w) => {
|
|
195
|
+
p(), a == null || a(w);
|
|
196
|
+
},
|
|
197
|
+
className: b(
|
|
198
|
+
"absolute",
|
|
199
|
+
{
|
|
200
|
+
"top-1/2 -translate-y-1/2": s,
|
|
201
|
+
"left-1/2 -translate-x-1/2 rotate-90": !s,
|
|
202
|
+
"-right-comp-carousel-arrow-offset-sm": s && i,
|
|
203
|
+
"-right-comp-carousel-arrow-offset": s && !i,
|
|
204
|
+
"-bottom-comp-carousel-arrow-offset-v-sm": !s && i,
|
|
205
|
+
"-bottom-comp-carousel-arrow-offset-v": !s && !i
|
|
206
|
+
},
|
|
207
|
+
t
|
|
208
|
+
),
|
|
209
|
+
...u
|
|
210
|
+
}
|
|
211
|
+
);
|
|
212
|
+
}
|
|
213
|
+
);
|
|
214
|
+
G.displayName = "CarouselNext";
|
|
215
|
+
const J = ({
|
|
216
|
+
className: t,
|
|
217
|
+
ariaLabel: l,
|
|
218
|
+
buttonAriaLabel: n
|
|
219
|
+
}) => {
|
|
220
|
+
const { selectedIndex: a, scrollTo: u, slidesCount: c } = x(), f = y();
|
|
221
|
+
return c <= 1 ? null : /* @__PURE__ */ m(
|
|
222
|
+
F,
|
|
223
|
+
{
|
|
224
|
+
count: c,
|
|
225
|
+
activeIndex: a,
|
|
226
|
+
onDotClick: u,
|
|
227
|
+
interactive: !0,
|
|
228
|
+
className: b("mt-comp-carousel-dots-gap", t),
|
|
229
|
+
ariaLabel: l ?? f.carousel.dotsAriaLabel,
|
|
230
|
+
buttonAriaLabel: n ?? f.carousel.dotAriaLabel
|
|
231
|
+
}
|
|
232
|
+
);
|
|
233
|
+
};
|
|
234
|
+
export {
|
|
235
|
+
M as Carousel,
|
|
236
|
+
U as CarouselContent,
|
|
237
|
+
J as CarouselDots,
|
|
238
|
+
V as CarouselItem,
|
|
239
|
+
G as CarouselNext,
|
|
240
|
+
q as CarouselPrevious
|
|
241
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { Meta, StoryObj } from '@storybook/react-vite';
|
|
2
|
+
import { Carousel } from './Carousel';
|
|
3
|
+
declare const meta: Meta<typeof Carousel>;
|
|
4
|
+
export default meta;
|
|
5
|
+
type Story = StoryObj<typeof Carousel>;
|
|
6
|
+
export declare const Default: Story;
|
|
7
|
+
export declare const Vertical: Story;
|
|
8
|
+
export declare const MultipleVisible: Story;
|
|
9
|
+
export declare const WithLinks: Story;
|
|
10
|
+
export declare const Looping: Story;
|
|
11
|
+
export declare const SmallArrows: Story;
|
|
12
|
+
export declare const NoDots: Story;
|
|
13
|
+
//# sourceMappingURL=Carousel.stories.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Carousel.stories.d.ts","sourceRoot":"","sources":["../../../src/components/Carousel/Carousel.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAA;AAG3D,OAAO,EACL,QAAQ,EAMT,MAAM,YAAY,CAAA;AAEnB,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,OAAO,QAAQ,CAuC/B,CAAA;AAED,eAAe,IAAI,CAAA;AACnB,KAAK,KAAK,GAAG,QAAQ,CAAC,OAAO,QAAQ,CAAC,CAAA;AAiCtC,eAAO,MAAM,OAAO,EAAE,KA4BrB,CAAA;AAED,eAAO,MAAM,QAAQ,EAAE,KAiCtB,CAAA;AAED,eAAO,MAAM,eAAe,EAAE,KA4B7B,CAAA;AAED,eAAO,MAAM,SAAS,EAAE,KAyCvB,CAAA;AAED,eAAO,MAAM,OAAO,EAAE,KA8BrB,CAAA;AAED,eAAO,MAAM,WAAW,EAAE,KA6BzB,CAAA;AAED,eAAO,MAAM,MAAM,EAAE,KA2BpB,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Carousel/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DataTable.stories.d.ts","sourceRoot":"","sources":["../../../src/components/DataTable/DataTable.stories.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAA;AAQ3D,QAAA,MAAM,IAAI,EAAE,IAkDX,CAAA;AAED,eAAe,IAAI,CAAA;AACnB,KAAK,KAAK,GAAG,QAAQ,CAAA;
|
|
1
|
+
{"version":3,"file":"DataTable.stories.d.ts","sourceRoot":"","sources":["../../../src/components/DataTable/DataTable.stories.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAA;AAQ3D,QAAA,MAAM,IAAI,EAAE,IAkDX,CAAA;AAED,eAAe,IAAI,CAAA;AACnB,KAAK,KAAK,GAAG,QAAQ,CAAA;AA+FrB,eAAO,MAAM,OAAO,EAAE,KAUrB,CAAA;AAaD,eAAO,MAAM,WAAW,EAAE,KAazB,CAAA;AA0CD,eAAO,MAAM,iBAAiB,EAAE,KAa/B,CAAA;AAED,eAAO,MAAM,YAAY,EAAE,KAgB1B,CAAA;AAUD,eAAO,MAAM,kBAAkB,EAAE,KAwIhC,CAAA;AAED,eAAO,MAAM,YAAY,EAAE,KAwJ1B,CAAA;AAED,eAAO,MAAM,YAAY,EAAE,KAgB1B,CAAA;AAED,eAAO,MAAM,QAAQ,EAAE,KActB,CAAA;AAED,eAAO,MAAM,oBAAoB,EAAE,KAclC,CAAA;AAED,eAAO,MAAM,WAAW,EAAE,KAqEzB,CAAA"}
|
|
@@ -3,9 +3,9 @@ import * as m from "react";
|
|
|
3
3
|
import * as a from "@radix-ui/react-dropdown-menu";
|
|
4
4
|
import { cva as N } from "class-variance-authority";
|
|
5
5
|
import { Button as I } from "../Button/Button.js";
|
|
6
|
-
import { Flex as D } from "../Flex/Flex.js";
|
|
7
6
|
import { cn as s } from "../../utils/cn.js";
|
|
8
7
|
import { UnreadOutline as x } from "@solar-icons/react-perf";
|
|
8
|
+
import { Flex as D } from "../Flex/Flex.js";
|
|
9
9
|
import { Typography as f } from "../Typography/Typography.js";
|
|
10
10
|
const g = m.createContext(null), M = () => m.useContext(g), B = ({ ...o }) => /* @__PURE__ */ e(a.Root, { "data-slot": "dropdown-menu", ...o }), F = ({ ...o }) => /* @__PURE__ */ e(a.Portal, { "data-slot": "dropdown-menu-portal", ...o }), H = ({ ...o }) => /* @__PURE__ */ e(
|
|
11
11
|
a.Trigger,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EdgeButton.stories.d.ts","sourceRoot":"","sources":["../../../src/components/EdgeButton/EdgeButton.stories.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAA;AAI3D,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAA;AAIzC,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,OAAO,UAAU,CAkGjC,CAAA;AAED,eAAe,IAAI,CAAA;AAEnB,KAAK,KAAK,GAAG,QAAQ,CAAC,OAAO,UAAU,CAAC,CAAA;AAExC,eAAO,MAAM,OAAO,EAAE,KAYrB,CAAA;AAED,eAAO,MAAM,QAAQ,EAAE,KActB,CAAA;AAED,eAAO,MAAM,iBAAiB,EAAE,KAqD/B,CAAA;AAED,eAAO,MAAM,aAAa,EAAE,KAmD3B,CAAA;AAED,eAAO,MAAM,UAAU,EAAE,KAexB,CAAA;AAED,eAAO,MAAM,aAAa,EAAE,KAe3B,CAAA;
|
|
1
|
+
{"version":3,"file":"EdgeButton.stories.d.ts","sourceRoot":"","sources":["../../../src/components/EdgeButton/EdgeButton.stories.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAA;AAI3D,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAA;AAIzC,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,OAAO,UAAU,CAkGjC,CAAA;AAED,eAAe,IAAI,CAAA;AAEnB,KAAK,KAAK,GAAG,QAAQ,CAAC,OAAO,UAAU,CAAC,CAAA;AAExC,eAAO,MAAM,OAAO,EAAE,KAYrB,CAAA;AAED,eAAO,MAAM,QAAQ,EAAE,KActB,CAAA;AAED,eAAO,MAAM,iBAAiB,EAAE,KAqD/B,CAAA;AAED,eAAO,MAAM,aAAa,EAAE,KAmD3B,CAAA;AAED,eAAO,MAAM,UAAU,EAAE,KAexB,CAAA;AAED,eAAO,MAAM,aAAa,EAAE,KAe3B,CAAA;AAcD,eAAO,MAAM,gBAAgB,EAAE,KA+H9B,CAAA"}
|
|
@@ -1,6 +1,377 @@
|
|
|
1
1
|
import { VariantProps } from 'class-variance-authority';
|
|
2
2
|
import { SpacingProps } from '../../utils/spacing';
|
|
3
3
|
import * as React from 'react';
|
|
4
|
+
/**
|
|
5
|
+
* Reusable layout-variant block — the direction/wrap/justify/align/flex
|
|
6
|
+
* variants plus all spacing variants. Exposed so other cva-based components
|
|
7
|
+
* (e.g. Card) can compose Flex's full layout API into a single cva call
|
|
8
|
+
* without duplicating definitions.
|
|
9
|
+
*/
|
|
10
|
+
export declare const flexLayoutVariants: {
|
|
11
|
+
gap: {
|
|
12
|
+
none: string;
|
|
13
|
+
'3xs': string;
|
|
14
|
+
'2xs': string;
|
|
15
|
+
xs: string;
|
|
16
|
+
sm: string;
|
|
17
|
+
md: string;
|
|
18
|
+
lg: string;
|
|
19
|
+
xl: string;
|
|
20
|
+
'2xl': string;
|
|
21
|
+
'3xl': string;
|
|
22
|
+
'4xl': string;
|
|
23
|
+
'5xl': string;
|
|
24
|
+
'6xl': string;
|
|
25
|
+
'7xl': string;
|
|
26
|
+
'8xl': string;
|
|
27
|
+
'9xl': string;
|
|
28
|
+
'10xl': string;
|
|
29
|
+
};
|
|
30
|
+
gapX: {
|
|
31
|
+
none: string;
|
|
32
|
+
'3xs': string;
|
|
33
|
+
'2xs': string;
|
|
34
|
+
xs: string;
|
|
35
|
+
sm: string;
|
|
36
|
+
md: string;
|
|
37
|
+
lg: string;
|
|
38
|
+
xl: string;
|
|
39
|
+
'2xl': string;
|
|
40
|
+
'3xl': string;
|
|
41
|
+
'4xl': string;
|
|
42
|
+
'5xl': string;
|
|
43
|
+
'6xl': string;
|
|
44
|
+
'7xl': string;
|
|
45
|
+
'8xl': string;
|
|
46
|
+
'9xl': string;
|
|
47
|
+
'10xl': string;
|
|
48
|
+
};
|
|
49
|
+
gapY: {
|
|
50
|
+
none: string;
|
|
51
|
+
'3xs': string;
|
|
52
|
+
'2xs': string;
|
|
53
|
+
xs: string;
|
|
54
|
+
sm: string;
|
|
55
|
+
md: string;
|
|
56
|
+
lg: string;
|
|
57
|
+
xl: string;
|
|
58
|
+
'2xl': string;
|
|
59
|
+
'3xl': string;
|
|
60
|
+
'4xl': string;
|
|
61
|
+
'5xl': string;
|
|
62
|
+
'6xl': string;
|
|
63
|
+
'7xl': string;
|
|
64
|
+
'8xl': string;
|
|
65
|
+
'9xl': string;
|
|
66
|
+
'10xl': string;
|
|
67
|
+
};
|
|
68
|
+
p: {
|
|
69
|
+
none: string;
|
|
70
|
+
'3xs': string;
|
|
71
|
+
'2xs': string;
|
|
72
|
+
xs: string;
|
|
73
|
+
sm: string;
|
|
74
|
+
md: string;
|
|
75
|
+
lg: string;
|
|
76
|
+
xl: string;
|
|
77
|
+
'2xl': string;
|
|
78
|
+
'3xl': string;
|
|
79
|
+
'4xl': string;
|
|
80
|
+
'5xl': string;
|
|
81
|
+
'6xl': string;
|
|
82
|
+
'7xl': string;
|
|
83
|
+
'8xl': string;
|
|
84
|
+
'9xl': string;
|
|
85
|
+
'10xl': string;
|
|
86
|
+
};
|
|
87
|
+
px: {
|
|
88
|
+
none: string;
|
|
89
|
+
'3xs': string;
|
|
90
|
+
'2xs': string;
|
|
91
|
+
xs: string;
|
|
92
|
+
sm: string;
|
|
93
|
+
md: string;
|
|
94
|
+
lg: string;
|
|
95
|
+
xl: string;
|
|
96
|
+
'2xl': string;
|
|
97
|
+
'3xl': string;
|
|
98
|
+
'4xl': string;
|
|
99
|
+
'5xl': string;
|
|
100
|
+
'6xl': string;
|
|
101
|
+
'7xl': string;
|
|
102
|
+
'8xl': string;
|
|
103
|
+
'9xl': string;
|
|
104
|
+
'10xl': string;
|
|
105
|
+
};
|
|
106
|
+
py: {
|
|
107
|
+
none: string;
|
|
108
|
+
'3xs': string;
|
|
109
|
+
'2xs': string;
|
|
110
|
+
xs: string;
|
|
111
|
+
sm: string;
|
|
112
|
+
md: string;
|
|
113
|
+
lg: string;
|
|
114
|
+
xl: string;
|
|
115
|
+
'2xl': string;
|
|
116
|
+
'3xl': string;
|
|
117
|
+
'4xl': string;
|
|
118
|
+
'5xl': string;
|
|
119
|
+
'6xl': string;
|
|
120
|
+
'7xl': string;
|
|
121
|
+
'8xl': string;
|
|
122
|
+
'9xl': string;
|
|
123
|
+
'10xl': string;
|
|
124
|
+
};
|
|
125
|
+
pt: {
|
|
126
|
+
none: string;
|
|
127
|
+
'3xs': string;
|
|
128
|
+
'2xs': string;
|
|
129
|
+
xs: string;
|
|
130
|
+
sm: string;
|
|
131
|
+
md: string;
|
|
132
|
+
lg: string;
|
|
133
|
+
xl: string;
|
|
134
|
+
'2xl': string;
|
|
135
|
+
'3xl': string;
|
|
136
|
+
'4xl': string;
|
|
137
|
+
'5xl': string;
|
|
138
|
+
'6xl': string;
|
|
139
|
+
'7xl': string;
|
|
140
|
+
'8xl': string;
|
|
141
|
+
'9xl': string;
|
|
142
|
+
'10xl': string;
|
|
143
|
+
};
|
|
144
|
+
pr: {
|
|
145
|
+
none: string;
|
|
146
|
+
'3xs': string;
|
|
147
|
+
'2xs': string;
|
|
148
|
+
xs: string;
|
|
149
|
+
sm: string;
|
|
150
|
+
md: string;
|
|
151
|
+
lg: string;
|
|
152
|
+
xl: string;
|
|
153
|
+
'2xl': string;
|
|
154
|
+
'3xl': string;
|
|
155
|
+
'4xl': string;
|
|
156
|
+
'5xl': string;
|
|
157
|
+
'6xl': string;
|
|
158
|
+
'7xl': string;
|
|
159
|
+
'8xl': string;
|
|
160
|
+
'9xl': string;
|
|
161
|
+
'10xl': string;
|
|
162
|
+
};
|
|
163
|
+
pb: {
|
|
164
|
+
none: string;
|
|
165
|
+
'3xs': string;
|
|
166
|
+
'2xs': string;
|
|
167
|
+
xs: string;
|
|
168
|
+
sm: string;
|
|
169
|
+
md: string;
|
|
170
|
+
lg: string;
|
|
171
|
+
xl: string;
|
|
172
|
+
'2xl': string;
|
|
173
|
+
'3xl': string;
|
|
174
|
+
'4xl': string;
|
|
175
|
+
'5xl': string;
|
|
176
|
+
'6xl': string;
|
|
177
|
+
'7xl': string;
|
|
178
|
+
'8xl': string;
|
|
179
|
+
'9xl': string;
|
|
180
|
+
'10xl': string;
|
|
181
|
+
};
|
|
182
|
+
pl: {
|
|
183
|
+
none: string;
|
|
184
|
+
'3xs': string;
|
|
185
|
+
'2xs': string;
|
|
186
|
+
xs: string;
|
|
187
|
+
sm: string;
|
|
188
|
+
md: string;
|
|
189
|
+
lg: string;
|
|
190
|
+
xl: string;
|
|
191
|
+
'2xl': string;
|
|
192
|
+
'3xl': string;
|
|
193
|
+
'4xl': string;
|
|
194
|
+
'5xl': string;
|
|
195
|
+
'6xl': string;
|
|
196
|
+
'7xl': string;
|
|
197
|
+
'8xl': string;
|
|
198
|
+
'9xl': string;
|
|
199
|
+
'10xl': string;
|
|
200
|
+
};
|
|
201
|
+
m: {
|
|
202
|
+
none: string;
|
|
203
|
+
'3xs': string;
|
|
204
|
+
'2xs': string;
|
|
205
|
+
xs: string;
|
|
206
|
+
sm: string;
|
|
207
|
+
md: string;
|
|
208
|
+
lg: string;
|
|
209
|
+
xl: string;
|
|
210
|
+
'2xl': string;
|
|
211
|
+
'3xl': string;
|
|
212
|
+
'4xl': string;
|
|
213
|
+
'5xl': string;
|
|
214
|
+
'6xl': string;
|
|
215
|
+
'7xl': string;
|
|
216
|
+
'8xl': string;
|
|
217
|
+
'9xl': string;
|
|
218
|
+
'10xl': string;
|
|
219
|
+
};
|
|
220
|
+
mx: {
|
|
221
|
+
none: string;
|
|
222
|
+
'3xs': string;
|
|
223
|
+
'2xs': string;
|
|
224
|
+
xs: string;
|
|
225
|
+
sm: string;
|
|
226
|
+
md: string;
|
|
227
|
+
lg: string;
|
|
228
|
+
xl: string;
|
|
229
|
+
'2xl': string;
|
|
230
|
+
'3xl': string;
|
|
231
|
+
'4xl': string;
|
|
232
|
+
'5xl': string;
|
|
233
|
+
'6xl': string;
|
|
234
|
+
'7xl': string;
|
|
235
|
+
'8xl': string;
|
|
236
|
+
'9xl': string;
|
|
237
|
+
'10xl': string;
|
|
238
|
+
};
|
|
239
|
+
my: {
|
|
240
|
+
none: string;
|
|
241
|
+
'3xs': string;
|
|
242
|
+
'2xs': string;
|
|
243
|
+
xs: string;
|
|
244
|
+
sm: string;
|
|
245
|
+
md: string;
|
|
246
|
+
lg: string;
|
|
247
|
+
xl: string;
|
|
248
|
+
'2xl': string;
|
|
249
|
+
'3xl': string;
|
|
250
|
+
'4xl': string;
|
|
251
|
+
'5xl': string;
|
|
252
|
+
'6xl': string;
|
|
253
|
+
'7xl': string;
|
|
254
|
+
'8xl': string;
|
|
255
|
+
'9xl': string;
|
|
256
|
+
'10xl': string;
|
|
257
|
+
};
|
|
258
|
+
mt: {
|
|
259
|
+
none: string;
|
|
260
|
+
'3xs': string;
|
|
261
|
+
'2xs': string;
|
|
262
|
+
xs: string;
|
|
263
|
+
sm: string;
|
|
264
|
+
md: string;
|
|
265
|
+
lg: string;
|
|
266
|
+
xl: string;
|
|
267
|
+
'2xl': string;
|
|
268
|
+
'3xl': string;
|
|
269
|
+
'4xl': string;
|
|
270
|
+
'5xl': string;
|
|
271
|
+
'6xl': string;
|
|
272
|
+
'7xl': string;
|
|
273
|
+
'8xl': string;
|
|
274
|
+
'9xl': string;
|
|
275
|
+
'10xl': string;
|
|
276
|
+
};
|
|
277
|
+
mr: {
|
|
278
|
+
none: string;
|
|
279
|
+
'3xs': string;
|
|
280
|
+
'2xs': string;
|
|
281
|
+
xs: string;
|
|
282
|
+
sm: string;
|
|
283
|
+
md: string;
|
|
284
|
+
lg: string;
|
|
285
|
+
xl: string;
|
|
286
|
+
'2xl': string;
|
|
287
|
+
'3xl': string;
|
|
288
|
+
'4xl': string;
|
|
289
|
+
'5xl': string;
|
|
290
|
+
'6xl': string;
|
|
291
|
+
'7xl': string;
|
|
292
|
+
'8xl': string;
|
|
293
|
+
'9xl': string;
|
|
294
|
+
'10xl': string;
|
|
295
|
+
};
|
|
296
|
+
mb: {
|
|
297
|
+
none: string;
|
|
298
|
+
'3xs': string;
|
|
299
|
+
'2xs': string;
|
|
300
|
+
xs: string;
|
|
301
|
+
sm: string;
|
|
302
|
+
md: string;
|
|
303
|
+
lg: string;
|
|
304
|
+
xl: string;
|
|
305
|
+
'2xl': string;
|
|
306
|
+
'3xl': string;
|
|
307
|
+
'4xl': string;
|
|
308
|
+
'5xl': string;
|
|
309
|
+
'6xl': string;
|
|
310
|
+
'7xl': string;
|
|
311
|
+
'8xl': string;
|
|
312
|
+
'9xl': string;
|
|
313
|
+
'10xl': string;
|
|
314
|
+
};
|
|
315
|
+
ml: {
|
|
316
|
+
none: string;
|
|
317
|
+
'3xs': string;
|
|
318
|
+
'2xs': string;
|
|
319
|
+
xs: string;
|
|
320
|
+
sm: string;
|
|
321
|
+
md: string;
|
|
322
|
+
lg: string;
|
|
323
|
+
xl: string;
|
|
324
|
+
'2xl': string;
|
|
325
|
+
'3xl': string;
|
|
326
|
+
'4xl': string;
|
|
327
|
+
'5xl': string;
|
|
328
|
+
'6xl': string;
|
|
329
|
+
'7xl': string;
|
|
330
|
+
'8xl': string;
|
|
331
|
+
'9xl': string;
|
|
332
|
+
'10xl': string;
|
|
333
|
+
};
|
|
334
|
+
direction: {
|
|
335
|
+
row: string;
|
|
336
|
+
column: string;
|
|
337
|
+
'row-reverse': string;
|
|
338
|
+
'column-reverse': string;
|
|
339
|
+
};
|
|
340
|
+
wrap: {
|
|
341
|
+
nowrap: string;
|
|
342
|
+
wrap: string;
|
|
343
|
+
'wrap-reverse': string;
|
|
344
|
+
};
|
|
345
|
+
justify: {
|
|
346
|
+
start: string;
|
|
347
|
+
end: string;
|
|
348
|
+
center: string;
|
|
349
|
+
between: string;
|
|
350
|
+
around: string;
|
|
351
|
+
evenly: string;
|
|
352
|
+
stretch: string;
|
|
353
|
+
};
|
|
354
|
+
align: {
|
|
355
|
+
start: string;
|
|
356
|
+
end: string;
|
|
357
|
+
center: string;
|
|
358
|
+
baseline: string;
|
|
359
|
+
stretch: string;
|
|
360
|
+
};
|
|
361
|
+
flex: {
|
|
362
|
+
1: string;
|
|
363
|
+
auto: string;
|
|
364
|
+
initial: string;
|
|
365
|
+
none: string;
|
|
366
|
+
};
|
|
367
|
+
};
|
|
368
|
+
/** Default values for `flexLayoutVariants`, mirrored on the Flex component. */
|
|
369
|
+
export declare const flexLayoutDefaults: {
|
|
370
|
+
readonly direction: "row";
|
|
371
|
+
readonly wrap: "nowrap";
|
|
372
|
+
readonly justify: "start";
|
|
373
|
+
readonly align: "stretch";
|
|
374
|
+
};
|
|
4
375
|
declare const flexVariants: (props?: ({
|
|
5
376
|
gap?: "none" | "2xs" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl" | "3xl" | "3xs" | "4xl" | "5xl" | "6xl" | "7xl" | "8xl" | "9xl" | "10xl" | null | undefined;
|
|
6
377
|
gapX?: "none" | "2xs" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl" | "3xl" | "3xs" | "4xl" | "5xl" | "6xl" | "7xl" | "8xl" | "9xl" | "10xl" | null | undefined;
|
|
@@ -21,7 +392,7 @@ declare const flexVariants: (props?: ({
|
|
|
21
392
|
ml?: "none" | "2xs" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl" | "3xl" | "3xs" | "4xl" | "5xl" | "6xl" | "7xl" | "8xl" | "9xl" | "10xl" | null | undefined;
|
|
22
393
|
direction?: "row" | "column" | "row-reverse" | "column-reverse" | null | undefined;
|
|
23
394
|
wrap?: "wrap" | "nowrap" | "wrap-reverse" | null | undefined;
|
|
24
|
-
justify?: "end" | "start" | "center" | "
|
|
395
|
+
justify?: "end" | "start" | "center" | "stretch" | "between" | "around" | "evenly" | null | undefined;
|
|
25
396
|
align?: "end" | "start" | "center" | "baseline" | "stretch" | null | undefined;
|
|
26
397
|
flex?: 1 | "none" | "auto" | "initial" | null | undefined;
|
|
27
398
|
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Flex.d.ts","sourceRoot":"","sources":["../../../src/components/Flex/Flex.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,EAAE,KAAK,YAAY,EAAO,MAAM,0BAA0B,CAAA;AAEjE,OAAO,EACL,KAAK,YAAY,EAGlB,MAAM,iBAAiB,CAAA;AAExB,QAAA,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"Flex.d.ts","sourceRoot":"","sources":["../../../src/components/Flex/Flex.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,EAAE,KAAK,YAAY,EAAO,MAAM,0BAA0B,CAAA;AAEjE,OAAO,EACL,KAAK,YAAY,EAGlB,MAAM,iBAAiB,CAAA;AAExB;;;;;GAKG;AACH,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAmC9B,CAAA;AAED,+EAA+E;AAC/E,eAAO,MAAM,kBAAkB;;;;;CAKrB,CAAA;AAEV,QAAA,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;8EAGhB,CAAA;AAEF,KAAK,cAAc,GAAG,MAAM,KAAK,CAAC,GAAG,CAAC,iBAAiB,GACrD,MAAM,qBAAqB,CAAA;AAE7B;;;GAGG;AACH,MAAM,WAAW,SACf,SAAQ,IAAI,CACR,YAAY,CAAC,OAAO,YAAY,CAAC,EAC/B,KAAK,GACL,MAAM,GACN,MAAM,GACN,GAAG,GACH,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,GAAG,GACH,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,WAAW,GACX,MAAM,GACN,SAAS,GACT,OAAO,GACP,MAAM,CACT,EACD,YAAY;IACd,oDAAoD;IACpD,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAA;IAC1B,iEAAiE;IACjE,SAAS,CAAC,EAAE,cAAc,CAAA;IAC1B,iDAAiD;IACjD,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,2EAA2E;IAC3E,KAAK,CAAC,EAAE,KAAK,CAAC,aAAa,CAAA;IAC3B,kEAAkE;IAClE,SAAS,CAAC,EAAE,KAAK,GAAG,QAAQ,GAAG,aAAa,GAAG,gBAAgB,CAAA;IAC/D,4EAA4E;IAC5E,IAAI,CAAC,EAAE,QAAQ,GAAG,MAAM,GAAG,cAAc,CAAA;IACzC,yDAAyD;IACzD,OAAO,CAAC,EACJ,OAAO,GACP,KAAK,GACL,QAAQ,GACR,SAAS,GACT,QAAQ,GACR,QAAQ,GACR,SAAS,CAAA;IACb,4DAA4D;IAC5D,KAAK,CAAC,EAAE,OAAO,GAAG,KAAK,GAAG,QAAQ,GAAG,UAAU,GAAG,SAAS,CAAA;IAC3D,0CAA0C;IAC1C,IAAI,CAAC,EAAE,CAAC,GAAG,MAAM,GAAG,SAAS,GAAG,MAAM,CAAA;IACtC;;;;;;;OAOG;IACH,GAAG,CAAC,EAAE,YAAY,CAAC,KAAK,CAAC,CAAA;IACzB;;;;;;;;;OASG;IACH,OAAO,CAAC,EAAE,YAAY,CAAC,SAAS,CAAC,CAAA;IACjC;;;;;;;;;OASG;IACH,MAAM,CAAC,EAAE,YAAY,CAAC,QAAQ,CAAC,CAAA;CAChC;AAED,QAAA,MAAM,IAAI,+EA4CT,CAAA;AAID,OAAO,EAAE,IAAI,EAAE,YAAY,EAAE,CAAA"}
|