laif-ds 0.2.48 → 0.2.50
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/kanban.js +90 -85
- package/dist/components/ui/app-kanban.js +128 -114
- package/dist/components/ui/app-radio-group.js +62 -48
- package/dist/components/ui/app-select.js +93 -90
- package/dist/components/ui/async-select.js +134 -126
- package/dist/components/ui/badge.js +38 -31
- package/dist/components/ui/button.js +49 -40
- package/dist/components/ui/card.js +36 -28
- package/dist/components/ui/checkbox.js +23 -20
- package/dist/components/ui/date-picker.js +64 -59
- package/dist/components/ui/dialog.js +54 -42
- package/dist/components/ui/input.js +116 -111
- package/dist/components/ui/popover.js +15 -13
- package/dist/components/ui/radio-group.js +29 -27
- package/dist/components/ui/select.js +74 -67
- package/dist/components/ui/sheet.js +39 -28
- package/dist/components/ui/slider.js +34 -28
- package/dist/components/ui/switch.js +16 -13
- package/dist/components/ui/tabs.js +35 -26
- package/dist/components/ui/textarea.js +26 -17
- package/dist/index.d.ts +4 -1
- package/dist/lib/design-tokens.js +43 -0
- package/dist/styles.v3.css +1 -1
- package/package.json +1 -1
|
@@ -1,16 +1,25 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { jsx as
|
|
3
|
-
import { Root as
|
|
4
|
-
import { cva as
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
|
|
8
|
-
|
|
2
|
+
import { jsx as t, jsxs as u } from "react/jsx-runtime";
|
|
3
|
+
import { Root as m } from "../../node_modules/@radix-ui/react-slot/dist/index.js";
|
|
4
|
+
import { cva as h } from "../../node_modules/class-variance-authority/dist/index.js";
|
|
5
|
+
import { designTokens as r } from "../../lib/design-tokens.js";
|
|
6
|
+
import { cn as s } from "../../lib/utils.js";
|
|
7
|
+
import { Icon as l } from "./icon.js";
|
|
8
|
+
const v = h(
|
|
9
|
+
s(
|
|
10
|
+
r.text.base,
|
|
11
|
+
r.radius.default,
|
|
12
|
+
r.focusRing,
|
|
13
|
+
r.interaction.active,
|
|
14
|
+
r.interaction.disabled,
|
|
15
|
+
"cursor-pointer inline-flex items-center justify-center gap-2 whitespace-nowrap overflow-hidden relative group",
|
|
16
|
+
"[&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 shrink-0 [&_svg]:shrink-0"
|
|
17
|
+
),
|
|
9
18
|
{
|
|
10
19
|
variants: {
|
|
11
20
|
variant: {
|
|
12
|
-
default: "bg-d-primary text-d-primary-foreground shadow-xs hover:bg-d-primary/90 hover:shadow-d-primary/25
|
|
13
|
-
destructive: "bg-d-destructive text-d-destructive-foreground shadow-xs hover:bg-d-destructive/90 hover:shadow-d-destructive/25 focus-visible:ring-d-destructive/20
|
|
21
|
+
default: "bg-d-primary text-d-primary-foreground shadow-xs hover:bg-d-primary/90 hover:shadow-d-primary/25 before:absolute before:inset-0 before:bg-gradient-to-r before:from-transparent before:via-white/20 before:to-transparent before:translate-x-[-100%] hover:before:translate-x-[100%] before:transition-transform before:duration-700 before:ease-out",
|
|
22
|
+
destructive: "bg-d-destructive text-d-destructive-foreground shadow-xs hover:bg-d-destructive/90 hover:shadow-d-destructive/25 focus-visible:ring-d-destructive/20 before:absolute before:inset-0 before:bg-gradient-to-r before:from-transparent before:via-white/20 before:to-transparent before:translate-x-[-100%] hover:before:translate-x-[100%] before:transition-transform before:duration-700 before:ease-out",
|
|
14
23
|
outline: "border border-d-foreground shadow-xs disabled:border-d-foreground/30 hover:bg-d-accent hover:text-d-accent-foreground hover:border-d-foreground/80",
|
|
15
24
|
"outline-primary": "border border-d-primary shadow-xs text-d-primary/80 hover:text-d-primary hover:bg-d-primary/10 hover:border-d-primary/80",
|
|
16
25
|
"outline-destructive": "border border-d-destructive shadow-xs text-d-destructive/80 hover:text-d-destructive hover:bg-d-destructive/10 hover:border-d-destructive/80",
|
|
@@ -21,10 +30,10 @@ const v = m(
|
|
|
21
30
|
link: "text-d-primary underline-offset-4 hover:underline"
|
|
22
31
|
},
|
|
23
32
|
size: {
|
|
24
|
-
default:
|
|
25
|
-
sm:
|
|
26
|
-
lg:
|
|
27
|
-
icon:
|
|
33
|
+
default: r.sizes.default + " has-[>svg]:px-3",
|
|
34
|
+
sm: r.sizes.sm + " has-[>svg]:px-2.5",
|
|
35
|
+
lg: r.sizes.lg + " has-[>svg]:px-4",
|
|
36
|
+
icon: r.sizes.icon.default
|
|
28
37
|
}
|
|
29
38
|
},
|
|
30
39
|
defaultVariants: {
|
|
@@ -33,30 +42,30 @@ const v = m(
|
|
|
33
42
|
}
|
|
34
43
|
}
|
|
35
44
|
);
|
|
36
|
-
function
|
|
37
|
-
className:
|
|
38
|
-
variant:
|
|
45
|
+
function N({
|
|
46
|
+
className: a,
|
|
47
|
+
variant: d,
|
|
39
48
|
size: e,
|
|
40
|
-
asChild:
|
|
41
|
-
iconLeft:
|
|
42
|
-
iconRight:
|
|
49
|
+
asChild: n = !1,
|
|
50
|
+
iconLeft: i,
|
|
51
|
+
iconRight: c,
|
|
43
52
|
isLoading: b = !1,
|
|
44
|
-
...
|
|
53
|
+
...o
|
|
45
54
|
}) {
|
|
46
|
-
const
|
|
47
|
-
return
|
|
48
|
-
|
|
55
|
+
const f = n ? m : "button";
|
|
56
|
+
return n ? /* @__PURE__ */ t(
|
|
57
|
+
f,
|
|
49
58
|
{
|
|
50
59
|
"data-slot": "button",
|
|
51
|
-
className:
|
|
52
|
-
...
|
|
60
|
+
className: s(v({ variant: d, size: e, className: a })),
|
|
61
|
+
...o
|
|
53
62
|
}
|
|
54
|
-
) : /* @__PURE__ */ u(
|
|
55
|
-
|
|
63
|
+
) : /* @__PURE__ */ t("div", { className: "realtive overflow-hidden", children: /* @__PURE__ */ u(
|
|
64
|
+
f,
|
|
56
65
|
{
|
|
57
66
|
"data-slot": "button",
|
|
58
|
-
className:
|
|
59
|
-
...
|
|
67
|
+
className: s(v({ variant: d, size: e, className: a }), "relative"),
|
|
68
|
+
...o,
|
|
60
69
|
children: [
|
|
61
70
|
b ? /* @__PURE__ */ u(
|
|
62
71
|
"svg",
|
|
@@ -68,7 +77,7 @@ function w({
|
|
|
68
77
|
width: e === "sm" ? 14 : e === "lg" ? 20 : 16,
|
|
69
78
|
height: e === "sm" ? 14 : e === "lg" ? 20 : 16,
|
|
70
79
|
children: [
|
|
71
|
-
/* @__PURE__ */
|
|
80
|
+
/* @__PURE__ */ t(
|
|
72
81
|
"circle",
|
|
73
82
|
{
|
|
74
83
|
className: "opacity-25",
|
|
@@ -79,7 +88,7 @@ function w({
|
|
|
79
88
|
strokeWidth: "4"
|
|
80
89
|
}
|
|
81
90
|
),
|
|
82
|
-
/* @__PURE__ */
|
|
91
|
+
/* @__PURE__ */ t(
|
|
83
92
|
"path",
|
|
84
93
|
{
|
|
85
94
|
className: "opacity-75",
|
|
@@ -89,26 +98,26 @@ function w({
|
|
|
89
98
|
)
|
|
90
99
|
]
|
|
91
100
|
}
|
|
92
|
-
) :
|
|
93
|
-
|
|
101
|
+
) : i && /* @__PURE__ */ t(
|
|
102
|
+
l,
|
|
94
103
|
{
|
|
95
|
-
name:
|
|
104
|
+
name: i,
|
|
96
105
|
size: e === "default" ? "md" : e === "sm" ? "xs" : "sm"
|
|
97
106
|
}
|
|
98
107
|
),
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
108
|
+
o.children,
|
|
109
|
+
c && /* @__PURE__ */ t(
|
|
110
|
+
l,
|
|
102
111
|
{
|
|
103
|
-
name:
|
|
112
|
+
name: c,
|
|
104
113
|
size: e === "default" ? "md" : e === "sm" ? "xs" : "sm"
|
|
105
114
|
}
|
|
106
115
|
)
|
|
107
116
|
]
|
|
108
117
|
}
|
|
109
|
-
);
|
|
118
|
+
) });
|
|
110
119
|
}
|
|
111
120
|
export {
|
|
112
|
-
|
|
121
|
+
N as Button,
|
|
113
122
|
v as buttonVariants
|
|
114
123
|
};
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { jsx as
|
|
3
|
-
import
|
|
2
|
+
import { jsx as a } from "react/jsx-runtime";
|
|
3
|
+
import { designTokens as c } from "../../lib/design-tokens.js";
|
|
4
4
|
import { cn as o } from "../../lib/utils.js";
|
|
5
|
+
import * as n from "react";
|
|
5
6
|
const s = n.createContext({
|
|
6
7
|
size: "default"
|
|
7
8
|
}), d = {
|
|
@@ -26,35 +27,42 @@ const s = n.createContext({
|
|
|
26
27
|
gap: ""
|
|
27
28
|
}
|
|
28
29
|
};
|
|
29
|
-
function
|
|
30
|
-
return /* @__PURE__ */
|
|
30
|
+
function x({ className: r, size: t = "default", ...e }) {
|
|
31
|
+
return /* @__PURE__ */ a(s.Provider, { value: { size: t }, children: /* @__PURE__ */ a(
|
|
31
32
|
"div",
|
|
32
33
|
{
|
|
33
34
|
"data-slot": "card",
|
|
34
35
|
className: o(
|
|
35
|
-
`bg-d-card text-d-card-foreground border-d-border flex flex-col
|
|
36
|
+
`bg-d-card text-d-card-foreground border-d-border flex flex-col border shadow-sm ${d[t].py} ${d[t].gap}`,
|
|
37
|
+
c.radius.lg.replace("rounded-", "rounded-xl"),
|
|
38
|
+
// Card uses XL radius by default in shadcn usually, but here it was XL. Let's keep it XL or standard? The original was rounded-xl. designTokens.radius.lg is rounded-lg.
|
|
39
|
+
// Let's stick to original visual intent but maybe update designTokens to include XL if needed?
|
|
40
|
+
// For now, I will leave it as rounded-xl to not break the design, or use designTokens.radius.lg if we want to standardize.
|
|
41
|
+
// User asked to "standardize". Usually Cards have slightly larger radius than inputs.
|
|
42
|
+
// Let's use rounded-xl hardcoded for now as it is a "Container" not an input.
|
|
43
|
+
"rounded-xl",
|
|
36
44
|
r
|
|
37
45
|
),
|
|
38
|
-
...
|
|
46
|
+
...e
|
|
39
47
|
}
|
|
40
48
|
) });
|
|
41
49
|
}
|
|
42
|
-
function
|
|
43
|
-
const { size:
|
|
44
|
-
return /* @__PURE__ */
|
|
50
|
+
function f({ className: r, ...t }) {
|
|
51
|
+
const { size: e } = n.useContext(s);
|
|
52
|
+
return /* @__PURE__ */ a(
|
|
45
53
|
"div",
|
|
46
54
|
{
|
|
47
55
|
"data-slot": "card-header",
|
|
48
56
|
className: o(
|
|
49
|
-
`@container/card-header grid auto-rows-min grid-rows-[auto_auto] items-start gap-1.5 ${d[
|
|
57
|
+
`@container/card-header grid auto-rows-min grid-rows-[auto_auto] items-start gap-1.5 ${d[e].px} has-data-[slot=card-action]:grid-cols-[1fr_auto] [.border-b]:pb-6 border-d-border`,
|
|
50
58
|
r
|
|
51
59
|
),
|
|
52
60
|
...t
|
|
53
61
|
}
|
|
54
62
|
);
|
|
55
63
|
}
|
|
56
|
-
function
|
|
57
|
-
return /* @__PURE__ */
|
|
64
|
+
function m({ className: r, ...t }) {
|
|
65
|
+
return /* @__PURE__ */ a(
|
|
58
66
|
"div",
|
|
59
67
|
{
|
|
60
68
|
"data-slot": "card-title",
|
|
@@ -63,8 +71,8 @@ function x({ className: r, ...t }) {
|
|
|
63
71
|
}
|
|
64
72
|
);
|
|
65
73
|
}
|
|
66
|
-
function
|
|
67
|
-
return /* @__PURE__ */
|
|
74
|
+
function g({ className: r, ...t }) {
|
|
75
|
+
return /* @__PURE__ */ a(
|
|
68
76
|
"div",
|
|
69
77
|
{
|
|
70
78
|
"data-slot": "card-description",
|
|
@@ -73,25 +81,25 @@ function f({ className: r, ...t }) {
|
|
|
73
81
|
}
|
|
74
82
|
);
|
|
75
83
|
}
|
|
76
|
-
function
|
|
77
|
-
const { size:
|
|
78
|
-
return /* @__PURE__ */
|
|
84
|
+
function b({ className: r, ...t }) {
|
|
85
|
+
const { size: e } = n.useContext(s);
|
|
86
|
+
return /* @__PURE__ */ a(
|
|
79
87
|
"div",
|
|
80
88
|
{
|
|
81
89
|
"data-slot": "card-content",
|
|
82
|
-
className: o(d[
|
|
90
|
+
className: o(d[e].px, r),
|
|
83
91
|
...t
|
|
84
92
|
}
|
|
85
93
|
);
|
|
86
94
|
}
|
|
87
|
-
function
|
|
88
|
-
const { size:
|
|
89
|
-
return /* @__PURE__ */
|
|
95
|
+
function C({ className: r, ...t }) {
|
|
96
|
+
const { size: e } = n.useContext(s);
|
|
97
|
+
return /* @__PURE__ */ a(
|
|
90
98
|
"div",
|
|
91
99
|
{
|
|
92
100
|
"data-slot": "card-footer",
|
|
93
101
|
className: o(
|
|
94
|
-
`flex items-center ${d[
|
|
102
|
+
`flex items-center ${d[e].px} [.border-t]:pt-6`,
|
|
95
103
|
r
|
|
96
104
|
),
|
|
97
105
|
...t
|
|
@@ -99,10 +107,10 @@ function g({ className: r, ...t }) {
|
|
|
99
107
|
);
|
|
100
108
|
}
|
|
101
109
|
export {
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
110
|
+
x as Card,
|
|
111
|
+
b as CardContent,
|
|
112
|
+
g as CardDescription,
|
|
113
|
+
C as CardFooter,
|
|
114
|
+
f as CardHeader,
|
|
115
|
+
m as CardTitle
|
|
108
116
|
};
|
|
@@ -1,42 +1,45 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsx as e } from "react/jsx-runtime";
|
|
3
|
-
import { Checkbox as
|
|
4
|
-
import {
|
|
5
|
-
import s from "../../
|
|
6
|
-
import c from "../../node_modules/lucide-react/dist/esm/icons/
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
3
|
+
import { Checkbox as a, CheckboxIndicator as n } from "../../node_modules/@radix-ui/react-checkbox/dist/index.js";
|
|
4
|
+
import { designTokens as o } from "../../lib/design-tokens.js";
|
|
5
|
+
import { cn as s } from "../../lib/utils.js";
|
|
6
|
+
import c from "../../node_modules/lucide-react/dist/esm/icons/minus.js";
|
|
7
|
+
import m from "../../node_modules/lucide-react/dist/esm/icons/check.js";
|
|
8
|
+
function x({
|
|
9
|
+
className: i,
|
|
10
|
+
checked: t,
|
|
11
|
+
...d
|
|
11
12
|
}) {
|
|
12
|
-
const r =
|
|
13
|
+
const r = t === "indeterminate";
|
|
13
14
|
return /* @__PURE__ */ e(
|
|
14
|
-
|
|
15
|
+
a,
|
|
15
16
|
{
|
|
16
17
|
"data-slot": "checkbox",
|
|
17
|
-
className:
|
|
18
|
-
"peer bg-d-input border-d-foreground size-4 shrink-0 cursor-pointer
|
|
18
|
+
className: s(
|
|
19
|
+
"peer bg-d-input border-d-foreground size-4 shrink-0 cursor-pointer border shadow-xs transition-shadow outline-none",
|
|
20
|
+
o.radius.sm,
|
|
21
|
+
// Checkboxes usually have smaller radius
|
|
22
|
+
o.focusRing,
|
|
19
23
|
"aria-invalid:border-d-destructive aria-invalid:ring-d-destructive/20",
|
|
20
|
-
"focus-visible:border-d-ring focus-visible:ring-d-ring/50 focus-visible:ring-[3px]",
|
|
21
24
|
"data-[state=checked]:bg-d-primary data-[state=checked]:border-d-primary data-[state=checked]:text-d-primary-foreground",
|
|
22
|
-
|
|
25
|
+
o.interaction.disabled,
|
|
23
26
|
r && "bg-d-primary border-d-primary text-d-primary-foreground disabled:border-d-muted-foreground",
|
|
24
|
-
|
|
27
|
+
i
|
|
25
28
|
),
|
|
26
|
-
checked: r ? !1 :
|
|
27
|
-
...
|
|
29
|
+
checked: r ? !1 : t,
|
|
30
|
+
...d,
|
|
28
31
|
children: /* @__PURE__ */ e(
|
|
29
|
-
|
|
32
|
+
n,
|
|
30
33
|
{
|
|
31
34
|
"data-slot": "checkbox-indicator",
|
|
32
35
|
className: "text-d-primary-foreground flex items-center justify-center transition-none",
|
|
33
36
|
forceMount: r || void 0,
|
|
34
|
-
children: r ? /* @__PURE__ */ e(
|
|
37
|
+
children: r ? /* @__PURE__ */ e(c, { className: "text-d-primary-foreground size-3.5" }) : /* @__PURE__ */ e(m, { className: "text-d-primary-foreground size-3.5" })
|
|
35
38
|
}
|
|
36
39
|
)
|
|
37
40
|
}
|
|
38
41
|
);
|
|
39
42
|
}
|
|
40
43
|
export {
|
|
41
|
-
|
|
44
|
+
x as Checkbox
|
|
42
45
|
};
|
|
@@ -1,87 +1,92 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { jsxs as
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import { cn as
|
|
8
|
-
import * as
|
|
9
|
-
import { useEffect as
|
|
10
|
-
import { it as
|
|
11
|
-
import { formatDate as
|
|
12
|
-
import { isSameDay as
|
|
13
|
-
function
|
|
2
|
+
import { jsxs as c, jsx as r } from "react/jsx-runtime";
|
|
3
|
+
import { Calendar as N } from "./calendar.js";
|
|
4
|
+
import { Icon as k } from "./icon.js";
|
|
5
|
+
import { Popover as I, PopoverTrigger as T, PopoverContent as v } from "./popover.js";
|
|
6
|
+
import { designTokens as t } from "../../lib/design-tokens.js";
|
|
7
|
+
import { cn as z } from "../../lib/utils.js";
|
|
8
|
+
import * as b from "react";
|
|
9
|
+
import { useEffect as E } from "react";
|
|
10
|
+
import { it as R } from "../../node_modules/date-fns/locale/it.js";
|
|
11
|
+
import { formatDate as d } from "../../node_modules/date-fns/format.js";
|
|
12
|
+
import { isSameDay as q } from "../../node_modules/date-fns/isSameDay.js";
|
|
13
|
+
function V({
|
|
14
14
|
value: e,
|
|
15
|
-
onChange:
|
|
16
|
-
placeholder:
|
|
17
|
-
dateFormat:
|
|
18
|
-
className:
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
size: i = "default",
|
|
15
|
+
onChange: p,
|
|
16
|
+
placeholder: y = "Seleziona data",
|
|
17
|
+
dateFormat: m = "dd/MM/yyyy",
|
|
18
|
+
className: j,
|
|
19
|
+
disabled: i = !1,
|
|
20
|
+
size: n = "default",
|
|
22
21
|
firstDate: a,
|
|
23
|
-
lastDate:
|
|
24
|
-
availableDates:
|
|
25
|
-
locale: C =
|
|
26
|
-
initialCalendarMonth:
|
|
22
|
+
lastDate: l,
|
|
23
|
+
availableDates: u,
|
|
24
|
+
locale: C = R,
|
|
25
|
+
initialCalendarMonth: h,
|
|
27
26
|
customCalendarProps: P
|
|
28
27
|
}) {
|
|
29
|
-
const [
|
|
30
|
-
|
|
31
|
-
), w = (
|
|
32
|
-
|
|
28
|
+
const [o, g] = b.useState(e), [S, x] = b.useState(
|
|
29
|
+
h
|
|
30
|
+
), w = (s) => {
|
|
31
|
+
g(s), s && x(s), p && p(s);
|
|
33
32
|
};
|
|
34
|
-
let
|
|
35
|
-
return a &&
|
|
36
|
-
(
|
|
37
|
-
(M) =>
|
|
33
|
+
let f = [];
|
|
34
|
+
return a && f.push({ before: a }), l && f.push({ after: l }), u?.length && f.push(
|
|
35
|
+
(s) => !u.some(
|
|
36
|
+
(M) => q(M, s)
|
|
38
37
|
)
|
|
39
|
-
),
|
|
40
|
-
|
|
41
|
-
}, [
|
|
42
|
-
/* @__PURE__ */
|
|
38
|
+
), i && (f = [!0]), E(() => {
|
|
39
|
+
g(o), x(o || h);
|
|
40
|
+
}, [o]), /* @__PURE__ */ c(I, { open: i ? !1 : void 0, children: [
|
|
41
|
+
/* @__PURE__ */ r(T, { asChild: !0, children: /* @__PURE__ */ r(
|
|
43
42
|
"div",
|
|
44
43
|
{
|
|
45
|
-
className:
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
t
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
44
|
+
className: z(
|
|
45
|
+
t.input.base,
|
|
46
|
+
t.radius.default,
|
|
47
|
+
t.text.base,
|
|
48
|
+
t.interaction.disabled,
|
|
49
|
+
"flex items-center justify-between px-3 py-2 font-normal whitespace-nowrap [&>span]:line-clamp-1",
|
|
50
|
+
"focus-visible:ring-d-ring/50 focus-visible:border-d-ring outline-none focus-visible:ring-[3px]",
|
|
51
|
+
"hover:border-d-ring cursor-pointer transition-colors",
|
|
52
|
+
!o && "text-d-muted-foreground",
|
|
53
|
+
i && "cursor-not-allowed opacity-50",
|
|
54
|
+
n === "default" && t.sizes.default,
|
|
55
|
+
n === "sm" && t.sizes.sm,
|
|
56
|
+
n === "lg" && t.sizes.lg,
|
|
57
|
+
j
|
|
53
58
|
),
|
|
54
|
-
"aria-disabled":
|
|
59
|
+
"aria-disabled": i,
|
|
55
60
|
role: "button",
|
|
56
|
-
tabIndex:
|
|
57
|
-
onClick:
|
|
61
|
+
tabIndex: i ? -1 : 0,
|
|
62
|
+
onClick: i ? void 0 : () => {
|
|
58
63
|
},
|
|
59
|
-
children: /* @__PURE__ */
|
|
60
|
-
/* @__PURE__ */
|
|
61
|
-
|
|
64
|
+
children: /* @__PURE__ */ c("div", { className: "flex w-full items-center justify-between gap-2", children: [
|
|
65
|
+
/* @__PURE__ */ r(
|
|
66
|
+
k,
|
|
62
67
|
{
|
|
63
68
|
name: "Calendar",
|
|
64
|
-
size:
|
|
69
|
+
size: n === "default" ? "md" : n === "sm" ? "xs" : "sm"
|
|
65
70
|
}
|
|
66
71
|
),
|
|
67
|
-
e && typeof e == "object" && "from" in e ? /* @__PURE__ */
|
|
68
|
-
e.from &&
|
|
72
|
+
e && typeof e == "object" && "from" in e ? /* @__PURE__ */ c("span", { children: [
|
|
73
|
+
e.from && d(e.from, m),
|
|
69
74
|
e.from && e.to && " - ",
|
|
70
|
-
e.to &&
|
|
71
|
-
] }) :
|
|
75
|
+
e.to && d(e.to, m)
|
|
76
|
+
] }) : o ? /* @__PURE__ */ r("span", { children: d(o, m) }) : /* @__PURE__ */ r("span", { className: "text-d-muted-foreground", children: y })
|
|
72
77
|
] })
|
|
73
78
|
}
|
|
74
79
|
) }),
|
|
75
|
-
/* @__PURE__ */
|
|
76
|
-
|
|
80
|
+
/* @__PURE__ */ r(v, { className: "w-auto p-0", children: /* @__PURE__ */ r(
|
|
81
|
+
N,
|
|
77
82
|
{
|
|
78
83
|
...P || {
|
|
79
84
|
mode: "single",
|
|
80
|
-
selected:
|
|
85
|
+
selected: o,
|
|
81
86
|
onSelect: w
|
|
82
87
|
},
|
|
83
88
|
autoFocus: !0,
|
|
84
|
-
disabled:
|
|
89
|
+
disabled: f,
|
|
85
90
|
locale: C,
|
|
86
91
|
defaultMonth: S
|
|
87
92
|
}
|
|
@@ -89,5 +94,5 @@ function X({
|
|
|
89
94
|
] });
|
|
90
95
|
}
|
|
91
96
|
export {
|
|
92
|
-
|
|
97
|
+
V as DatePicker
|
|
93
98
|
};
|