@dimasbaguspm/versaur 0.0.21 → 0.0.22
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/js/bottom-sheet-CCDa5VGo.js +573 -0
- package/dist/js/{bottom-sheet-input-DFGibm1I.js → bottom-sheet-input-nVi11sIJ.js} +1 -1
- package/dist/js/forms/index.js +1 -1
- package/dist/js/index.js +4 -4
- package/dist/js/layouts/index.js +1 -1
- package/dist/js/overlays/index.js +1 -1
- package/dist/js/providers/index.js +1 -1
- package/dist/js/{side-bar-BUACYQUo.js → side-bar-li3CbgUw.js} +73 -57
- package/dist/js/{use-snackbars-oPoF7J5t.js → use-snackbars-B0MaRlg1.js} +1 -1
- package/dist/types/layouts/app-bar/app-bar.atoms.d.ts +2 -2
- package/dist/types/layouts/app-bar/app-bar.d.ts +2 -2
- package/dist/types/layouts/app-bar/types.d.ts +3 -2
- package/dist/utils/enforce-subpath-import.js +2 -1
- package/package.json +1 -1
- package/dist/js/bottom-sheet-Eqduh3eY.js +0 -495
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { c as i, j as s, a as
|
|
1
|
+
import { c as i, j as s, a as c } from "./index-DOdDlCoL.js";
|
|
2
2
|
import * as f from "react";
|
|
3
3
|
import { forwardRef as n } from "react";
|
|
4
4
|
import "./image-rectangle-C6cgL8R9.js";
|
|
5
5
|
import "./snackbar-DH8jCh2V.js";
|
|
6
|
-
import { T as
|
|
6
|
+
import { T as p } from "./text-CRsIInRA.js";
|
|
7
7
|
const b = i(
|
|
8
|
-
"w-full flex flex-wrap items-center
|
|
8
|
+
"w-full flex flex-wrap items-center pt-3 mb-3 gap-2 bg-white [&>[data-versaur-appbar-bottom]]:basis-full [&>[data-versaur-appbar-bottom]]:w-full [&:has([data-versaur-appbar-bottom])>[data-versaur-appbar-leading]]:pl-4 [&:has([data-versaur-appbar-bottom])>[data-versaur-appbar-trailing]]:pr-4 [&:not(:has([data-versaur-appbar-bottom]))]:px-4",
|
|
9
9
|
{
|
|
10
10
|
variants: {
|
|
11
11
|
variant: {
|
|
@@ -40,36 +40,52 @@ const b = i(
|
|
|
40
40
|
{
|
|
41
41
|
ref: t,
|
|
42
42
|
"data-versaur-appbar-bottom": !0,
|
|
43
|
-
className:
|
|
43
|
+
className: c("w-full flex items-center min-h-[2.5rem] mt-2", a),
|
|
44
44
|
children: e
|
|
45
45
|
}
|
|
46
46
|
)
|
|
47
47
|
), y = n(
|
|
48
|
-
({ children: e, className: a }, t) => /* @__PURE__ */ s.jsx("div", { ref: t, className: l("flex items-center", a), children: e })
|
|
49
|
-
), B = n(
|
|
50
48
|
({ children: e, className: a }, t) => /* @__PURE__ */ s.jsx(
|
|
51
49
|
"div",
|
|
52
50
|
{
|
|
53
51
|
ref: t,
|
|
54
|
-
className:
|
|
52
|
+
className: c("flex items-center", a),
|
|
53
|
+
"data-versaur-appbar-leading": !0,
|
|
55
54
|
children: e
|
|
56
55
|
}
|
|
57
56
|
)
|
|
58
|
-
), h = n(
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
57
|
+
), h = n(({ children: e, ...a }, t) => /* @__PURE__ */ s.jsx(
|
|
58
|
+
p,
|
|
59
|
+
{
|
|
60
|
+
...a,
|
|
61
|
+
as: "h1",
|
|
62
|
+
ref: t,
|
|
63
|
+
fontSize: "lg",
|
|
64
|
+
fontWeight: "semibold",
|
|
65
|
+
ellipsis: !0,
|
|
66
|
+
clamp: 1,
|
|
67
|
+
children: e
|
|
68
|
+
}
|
|
69
|
+
)), B = n(({ children: e, ...a }, t) => /* @__PURE__ */ s.jsx(
|
|
70
|
+
p,
|
|
71
|
+
{
|
|
72
|
+
...a,
|
|
73
|
+
ref: t,
|
|
74
|
+
as: "p",
|
|
75
|
+
fontSize: "xs",
|
|
76
|
+
fontWeight: "normal",
|
|
77
|
+
ellipsis: !0,
|
|
78
|
+
clamp: 1,
|
|
79
|
+
color: "gray",
|
|
80
|
+
children: e
|
|
81
|
+
}
|
|
82
|
+
)), j = n(
|
|
68
83
|
({ children: e, className: a }, t) => /* @__PURE__ */ s.jsx(
|
|
69
84
|
"div",
|
|
70
85
|
{
|
|
71
86
|
ref: t,
|
|
72
|
-
className:
|
|
87
|
+
className: c("flex items-center justify-end gap-2", a),
|
|
88
|
+
"data-versaur-appbar-trailing": !0,
|
|
73
89
|
children: e
|
|
74
90
|
}
|
|
75
91
|
)
|
|
@@ -78,7 +94,7 @@ const b = i(
|
|
|
78
94
|
"div",
|
|
79
95
|
{
|
|
80
96
|
ref: r,
|
|
81
|
-
className:
|
|
97
|
+
className: c(g({ placement: t }), a),
|
|
82
98
|
children: e
|
|
83
99
|
}
|
|
84
100
|
)
|
|
@@ -89,18 +105,18 @@ const b = i(
|
|
|
89
105
|
}) => /* @__PURE__ */ s.jsx(
|
|
90
106
|
"header",
|
|
91
107
|
{
|
|
92
|
-
className:
|
|
108
|
+
className: c(b({ variant: t }), a),
|
|
93
109
|
role: "banner",
|
|
94
110
|
children: e
|
|
95
111
|
}
|
|
96
112
|
), ta = Object.assign(w, {
|
|
97
113
|
Leading: y,
|
|
98
|
-
Headline:
|
|
99
|
-
Subtitle:
|
|
114
|
+
Headline: h,
|
|
115
|
+
Subtitle: B,
|
|
100
116
|
Trailing: j,
|
|
101
117
|
Center: N,
|
|
102
118
|
Bottom: v
|
|
103
|
-
}),
|
|
119
|
+
}), S = i(
|
|
104
120
|
"sticky bottom-0 left-0 w-full flex justify-between items-center bg-white border-t border-border shadow-xs z-40 safe-bottom px-8 py-1",
|
|
105
121
|
{
|
|
106
122
|
variants: {
|
|
@@ -122,7 +138,7 @@ const b = i(
|
|
|
122
138
|
size: "md"
|
|
123
139
|
}
|
|
124
140
|
}
|
|
125
|
-
),
|
|
141
|
+
), T = i(
|
|
126
142
|
"flex flex-col items-center justify-center gap-1 px-2 py-1",
|
|
127
143
|
{
|
|
128
144
|
variants: {
|
|
@@ -136,12 +152,12 @@ const b = i(
|
|
|
136
152
|
}
|
|
137
153
|
}
|
|
138
154
|
), L = n(
|
|
139
|
-
({ icon: e, label: a, active: t = !1, className: r, ...o },
|
|
155
|
+
({ icon: e, label: a, active: t = !1, className: r, ...o }, l) => /* @__PURE__ */ s.jsxs(
|
|
140
156
|
"div",
|
|
141
157
|
{
|
|
142
|
-
ref:
|
|
158
|
+
ref: l,
|
|
143
159
|
"aria-current": t ? "page" : void 0,
|
|
144
|
-
className:
|
|
160
|
+
className: T({ active: t, className: r }),
|
|
145
161
|
...o,
|
|
146
162
|
children: [
|
|
147
163
|
e,
|
|
@@ -160,7 +176,7 @@ const b = i(
|
|
|
160
176
|
{
|
|
161
177
|
role: "navigation",
|
|
162
178
|
"aria-label": "Bottom navigation",
|
|
163
|
-
className:
|
|
179
|
+
className: S({ variant: a, size: t, className: r }),
|
|
164
180
|
...o,
|
|
165
181
|
children: e
|
|
166
182
|
}
|
|
@@ -201,12 +217,12 @@ const b = i(
|
|
|
201
217
|
function({ children: a, className: t, ...r }, o) {
|
|
202
218
|
return /* @__PURE__ */ s.jsx("div", { ref: o, className: I({ className: t }), ...r, children: a });
|
|
203
219
|
}
|
|
204
|
-
),
|
|
205
|
-
function({ children: a, className: t, active: r, ...o },
|
|
220
|
+
), W = n(
|
|
221
|
+
function({ children: a, className: t, active: r, ...o }, l) {
|
|
206
222
|
return /* @__PURE__ */ s.jsx(
|
|
207
223
|
"div",
|
|
208
224
|
{
|
|
209
|
-
ref:
|
|
225
|
+
ref: l,
|
|
210
226
|
className: C({ active: r, className: t }),
|
|
211
227
|
"aria-current": r ? "page" : void 0,
|
|
212
228
|
...o,
|
|
@@ -214,38 +230,38 @@ const b = i(
|
|
|
214
230
|
}
|
|
215
231
|
);
|
|
216
232
|
}
|
|
217
|
-
),
|
|
233
|
+
), H = n(
|
|
218
234
|
({ children: e, className: a, ...t }, r) => /* @__PURE__ */ s.jsx("header", { ref: r, className: A({ className: a }), ...t, children: e })
|
|
219
|
-
), sa = Object.assign(
|
|
235
|
+
), sa = Object.assign(H, {
|
|
220
236
|
Leading: P,
|
|
221
237
|
Trailing: G,
|
|
222
|
-
NavItem:
|
|
238
|
+
NavItem: W,
|
|
223
239
|
Nav: F,
|
|
224
240
|
Actions: O
|
|
225
|
-
}),
|
|
241
|
+
}), M = i("w-full mx-auto relative", {
|
|
226
242
|
variants: {
|
|
227
243
|
type: {
|
|
228
244
|
desktop: "max-w-7xl px-6 pb-10",
|
|
229
245
|
tablet: "max-w-3xl px-4",
|
|
230
|
-
mobile: "w-full
|
|
246
|
+
mobile: "w-full"
|
|
231
247
|
}
|
|
232
248
|
},
|
|
233
249
|
defaultVariants: {
|
|
234
250
|
type: "desktop"
|
|
235
251
|
}
|
|
236
252
|
}), ra = f.forwardRef(
|
|
237
|
-
function({ type: a = "desktop", className: t, children: r, ...o },
|
|
253
|
+
function({ type: a = "desktop", className: t, children: r, ...o }, l) {
|
|
238
254
|
return /* @__PURE__ */ s.jsx(
|
|
239
255
|
"div",
|
|
240
256
|
{
|
|
241
|
-
ref:
|
|
242
|
-
className:
|
|
257
|
+
ref: l,
|
|
258
|
+
className: c(M({ type: a }), t),
|
|
243
259
|
...o,
|
|
244
260
|
children: r
|
|
245
261
|
}
|
|
246
262
|
);
|
|
247
263
|
}
|
|
248
|
-
),
|
|
264
|
+
), E = i("grid w-full gap-4 grid-cols-12"), $ = i("", {
|
|
249
265
|
variants: {
|
|
250
266
|
span: {
|
|
251
267
|
1: "col-span-1",
|
|
@@ -271,20 +287,20 @@ const b = i(
|
|
|
271
287
|
"div",
|
|
272
288
|
{
|
|
273
289
|
ref: o,
|
|
274
|
-
className:
|
|
290
|
+
className: c(E(), a),
|
|
275
291
|
...r,
|
|
276
292
|
children: t
|
|
277
293
|
}
|
|
278
294
|
);
|
|
279
295
|
}
|
|
280
296
|
), D = n(
|
|
281
|
-
function({ span: a = 4, className: t, children: r, ...o },
|
|
297
|
+
function({ span: a = 4, className: t, children: r, ...o }, l) {
|
|
282
298
|
const m = Math.min(12, Math.max(1, a));
|
|
283
299
|
return /* @__PURE__ */ s.jsx(
|
|
284
300
|
"div",
|
|
285
301
|
{
|
|
286
|
-
ref:
|
|
287
|
-
className:
|
|
302
|
+
ref: l,
|
|
303
|
+
className: c(
|
|
288
304
|
$({ span: `${m}` }),
|
|
289
305
|
t
|
|
290
306
|
),
|
|
@@ -295,7 +311,7 @@ const b = i(
|
|
|
295
311
|
}
|
|
296
312
|
), oa = Object.assign(q, {
|
|
297
313
|
Column: D
|
|
298
|
-
}),
|
|
314
|
+
}), x = i(
|
|
299
315
|
"flex items-center gap-2 px-4 py-2 rounded-md hover:text-primary focus:outline-none transition-colors",
|
|
300
316
|
{
|
|
301
317
|
variants: {
|
|
@@ -315,41 +331,41 @@ const b = i(
|
|
|
315
331
|
}
|
|
316
332
|
), J = n(
|
|
317
333
|
(e, a) => {
|
|
318
|
-
const { icon: t, children: r, href: o, onClick:
|
|
334
|
+
const { icon: t, children: r, href: o, onClick: l, active: m, ...u } = e;
|
|
319
335
|
if (typeof o == "string") {
|
|
320
|
-
const
|
|
336
|
+
const d = u;
|
|
321
337
|
return /* @__PURE__ */ s.jsx("li", { children: /* @__PURE__ */ s.jsxs(
|
|
322
338
|
"a",
|
|
323
339
|
{
|
|
324
340
|
ref: a,
|
|
325
341
|
href: o,
|
|
326
|
-
className:
|
|
342
|
+
className: x({
|
|
327
343
|
disabled: !!e["aria-disabled"],
|
|
328
344
|
active: m
|
|
329
345
|
}),
|
|
330
|
-
...
|
|
346
|
+
...d,
|
|
331
347
|
children: [
|
|
332
348
|
t,
|
|
333
|
-
/* @__PURE__ */ s.jsx(
|
|
349
|
+
/* @__PURE__ */ s.jsx(p, { as: "span", color: "inherit", fontSize: "sm", children: r })
|
|
334
350
|
]
|
|
335
351
|
}
|
|
336
352
|
) });
|
|
337
353
|
} else {
|
|
338
|
-
const
|
|
354
|
+
const d = u;
|
|
339
355
|
return /* @__PURE__ */ s.jsx("li", { children: /* @__PURE__ */ s.jsxs(
|
|
340
356
|
"button",
|
|
341
357
|
{
|
|
342
358
|
ref: a,
|
|
343
359
|
type: "button",
|
|
344
|
-
onClick:
|
|
345
|
-
className:
|
|
346
|
-
|
|
360
|
+
onClick: l,
|
|
361
|
+
className: c(
|
|
362
|
+
x({ disabled: !!d.disabled, active: m }),
|
|
347
363
|
"w-full text-left"
|
|
348
364
|
),
|
|
349
|
-
...
|
|
365
|
+
...d,
|
|
350
366
|
children: [
|
|
351
367
|
t,
|
|
352
|
-
/* @__PURE__ */ s.jsx(
|
|
368
|
+
/* @__PURE__ */ s.jsx(p, { as: "span", color: "inherit", fontSize: "sm", children: r })
|
|
353
369
|
]
|
|
354
370
|
}
|
|
355
371
|
) });
|
|
@@ -359,7 +375,7 @@ const b = i(
|
|
|
359
375
|
function({ children: a, label: t, ...r }, o) {
|
|
360
376
|
return /* @__PURE__ */ s.jsxs("li", { ref: o, className: "flex flex-col gap-2 mt-2", ...r, children: [
|
|
361
377
|
/* @__PURE__ */ s.jsx(
|
|
362
|
-
|
|
378
|
+
p,
|
|
363
379
|
{
|
|
364
380
|
as: "h2",
|
|
365
381
|
fontSize: "xs",
|
|
@@ -10,11 +10,11 @@ export declare const AppBarLeading: import('react').ForwardRefExoticComponent<Ap
|
|
|
10
10
|
/**
|
|
11
11
|
* Headline section (main title)
|
|
12
12
|
*/
|
|
13
|
-
export declare const AppBarHeadline: import('react').ForwardRefExoticComponent<AppBarHeadlineProps & import('react').RefAttributes<
|
|
13
|
+
export declare const AppBarHeadline: import('react').ForwardRefExoticComponent<AppBarHeadlineProps & import('react').RefAttributes<HTMLParagraphElement>>;
|
|
14
14
|
/**
|
|
15
15
|
* Subtitle section (secondary text)
|
|
16
16
|
*/
|
|
17
|
-
export declare const AppBarSubtitle: import('react').ForwardRefExoticComponent<AppBarSubtitleProps & import('react').RefAttributes<
|
|
17
|
+
export declare const AppBarSubtitle: import('react').ForwardRefExoticComponent<AppBarSubtitleProps & import('react').RefAttributes<HTMLParagraphElement>>;
|
|
18
18
|
/**
|
|
19
19
|
* Trailing section (actions, avatar, etc.)
|
|
20
20
|
*/
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { AppBarProps } from './types';
|
|
2
2
|
export declare const AppBar: (({ children, className, variant, }: AppBarProps) => import("react/jsx-runtime").JSX.Element) & {
|
|
3
3
|
Leading: import('react').ForwardRefExoticComponent<import('./types').AppBarLeadingProps & import('react').RefAttributes<HTMLDivElement>>;
|
|
4
|
-
Headline: import('react').ForwardRefExoticComponent<import('./types').AppBarHeadlineProps & import('react').RefAttributes<
|
|
5
|
-
Subtitle: import('react').ForwardRefExoticComponent<import('./types').AppBarSubtitleProps & import('react').RefAttributes<
|
|
4
|
+
Headline: import('react').ForwardRefExoticComponent<import('./types').AppBarHeadlineProps & import('react').RefAttributes<HTMLParagraphElement>>;
|
|
5
|
+
Subtitle: import('react').ForwardRefExoticComponent<import('./types').AppBarSubtitleProps & import('react').RefAttributes<HTMLParagraphElement>>;
|
|
6
6
|
Trailing: import('react').ForwardRefExoticComponent<import('./types').AppBarTrailingProps & import('react').RefAttributes<HTMLDivElement>>;
|
|
7
7
|
Center: import('react').ForwardRefExoticComponent<import('./types').AppBarCenterProps & import('react').RefAttributes<HTMLDivElement>>;
|
|
8
8
|
Bottom: import('react').ForwardRefExoticComponent<import('./types').AppBarBottomProps & import('react').RefAttributes<HTMLDivElement>>;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { TextProps } from '../../primitive';
|
|
1
2
|
import { ReactNode, HTMLAttributes } from 'react';
|
|
2
3
|
/**
|
|
3
4
|
* Props for AppBarLeading
|
|
@@ -8,13 +9,13 @@ export interface AppBarLeadingProps extends HTMLAttributes<HTMLDivElement> {
|
|
|
8
9
|
/**
|
|
9
10
|
* Props for AppBarHeadline
|
|
10
11
|
*/
|
|
11
|
-
export interface AppBarHeadlineProps extends
|
|
12
|
+
export interface AppBarHeadlineProps extends TextProps {
|
|
12
13
|
children: ReactNode;
|
|
13
14
|
}
|
|
14
15
|
/**
|
|
15
16
|
* Props for AppBarSubtitle
|
|
16
17
|
*/
|
|
17
|
-
export interface AppBarSubtitleProps extends
|
|
18
|
+
export interface AppBarSubtitleProps extends TextProps {
|
|
18
19
|
children: ReactNode;
|
|
19
20
|
}
|
|
20
21
|
/**
|