orbital-ds 0.7.0 → 0.9.0
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/AGENTS.md +145 -80
- package/README.md +87 -73
- package/components.manifest.json +1326 -1267
- package/contract.json +226 -168
- package/dist/hooks/use-ds-messages.d.ts +36 -0
- package/dist/hooks/use-ds-messages.js +12 -0
- package/dist/hooks/use-ds-motion.d.ts +17 -0
- package/dist/hooks/use-ds-motion.js +50 -0
- package/dist/lib/i18n.d.ts +46 -0
- package/dist/lib/i18n.js +109 -0
- package/dist/lib/motion.d.ts +74 -0
- package/dist/lib/motion.js +97 -0
- package/dist/styles.css +876 -528
- package/dist/themes/friendly.css +362 -318
- package/dist/themes/friendly.meta.json +75 -14
- package/dist/themes/friendly.scoped.css +362 -318
- package/dist/themes/qratia.meta.json +42 -12
- package/dist/themes/tactile.css +575 -429
- package/dist/themes/tactile.fonts.css +3 -2
- package/dist/themes/tactile.guide.md +82 -49
- package/dist/themes/tactile.meta.json +175 -16
- package/dist/themes/tactile.scoped.css +575 -429
- package/dist/themes/twitter.css +354 -298
- package/dist/themes/twitter.meta.json +83 -61
- package/dist/themes/twitter.scoped.css +354 -298
- package/dist/themes/zyro.css +443 -389
- package/dist/themes/zyro.meta.json +67 -14
- package/dist/themes/zyro.scoped.css +443 -389
- package/dist/ui/accordion.js +5 -5
- package/dist/ui/alert-dialog.js +3 -3
- package/dist/ui/alert.d.ts +1 -1
- package/dist/ui/alert.js +9 -3
- package/dist/ui/attachment.d.ts +1 -1
- package/dist/ui/attachment.js +4 -4
- package/dist/ui/avatar.js +6 -6
- package/dist/ui/ayuda.js +3 -2
- package/dist/ui/badge.d.ts +1 -1
- package/dist/ui/badge.js +9 -3
- package/dist/ui/banner.d.ts +14 -0
- package/dist/ui/banner.js +88 -0
- package/dist/ui/breadcrumb.js +7 -3
- package/dist/ui/bubble.js +6 -6
- package/dist/ui/button-group.js +4 -4
- package/dist/ui/button.d.ts +1 -1
- package/dist/ui/button.js +5 -5
- package/dist/ui/calendar.js +33 -6
- package/dist/ui/card.js +4 -4
- package/dist/ui/carousel.js +15 -8
- package/dist/ui/chart.js +7 -3
- package/dist/ui/checkbox.js +1 -1
- package/dist/ui/combobox.js +7 -7
- package/dist/ui/command.js +13 -11
- package/dist/ui/context-menu.js +8 -8
- package/dist/ui/dialog.js +10 -6
- package/dist/ui/drawer.js +9 -9
- package/dist/ui/dropdown-menu.js +8 -8
- package/dist/ui/empty.js +3 -3
- package/dist/ui/field.js +2 -2
- package/dist/ui/hover-card.js +1 -1
- package/dist/ui/i18n-provider.d.ts +11 -0
- package/dist/ui/i18n-provider.js +18 -0
- package/dist/ui/icon-tile.d.ts +1 -1
- package/dist/ui/input-group.d.ts +1 -1
- package/dist/ui/input-group.js +11 -9
- package/dist/ui/input-otp.js +3 -3
- package/dist/ui/input.js +1 -1
- package/dist/ui/item.d.ts +1 -1
- package/dist/ui/item.js +3 -3
- package/dist/ui/kbd.js +1 -1
- package/dist/ui/label.js +1 -1
- package/dist/ui/marker.d.ts +1 -1
- package/dist/ui/marker.js +2 -2
- package/dist/ui/menubar.js +9 -9
- package/dist/ui/message-scroller.js +5 -2
- package/dist/ui/message.js +2 -2
- package/dist/ui/motion-provider.d.ts +11 -0
- package/dist/ui/motion-provider.js +16 -0
- package/dist/ui/native-select.js +4 -4
- package/dist/ui/navigation-menu.js +7 -6
- package/dist/ui/pagination.js +19 -11
- package/dist/ui/popover.js +2 -2
- package/dist/ui/progress.js +2 -2
- package/dist/ui/questionnaire.js +20 -15
- package/dist/ui/radio-group.js +2 -2
- package/dist/ui/resizable.js +2 -2
- package/dist/ui/scroll-area.js +3 -3
- package/dist/ui/select.js +6 -6
- package/dist/ui/separator.js +1 -1
- package/dist/ui/sheet.js +6 -4
- package/dist/ui/sidebar.js +42 -30
- package/dist/ui/skeleton.js +1 -1
- package/dist/ui/slider.js +6 -6
- package/dist/ui/sonner.js +25 -8
- package/dist/ui/spinner.js +4 -1
- package/dist/ui/switch.js +2 -2
- package/dist/ui/table.js +3 -3
- package/dist/ui/tabs.js +5 -5
- package/dist/ui/textarea.js +1 -1
- package/dist/ui/toast.js +15 -12
- package/dist/ui/toggle-group.js +2 -2
- package/dist/ui/toggle.js +6 -4
- package/dist/ui/tooltip.js +2 -2
- package/docs/CONTRACT.md +183 -153
- package/package.json +160 -142
- package/scripts/brand-core.mjs +153 -0
- package/scripts/doctor.mjs +128 -7
- package/scripts/i18n.mjs +111 -0
- package/scripts/init.mjs +294 -57
- package/scripts/setup.mjs +99 -0
|
@@ -55,7 +55,7 @@ function NavigationMenuItem({
|
|
|
55
55
|
);
|
|
56
56
|
}
|
|
57
57
|
const navigationMenuTriggerStyle = cva(
|
|
58
|
-
"group/navigation-menu-trigger inline-flex h-
|
|
58
|
+
"group/navigation-menu-trigger inline-flex h-(--ds-control-h-md) w-max items-center justify-center rounded-2xl px-4.5 py-2.5 text-sm font-medium transition-all duration-(--ds-motion-snap) outline-none hover:bg-muted focus:bg-muted focus-visible:ring-(length:--ds-ring-width) focus-visible:ring-(--ds-ring-color) focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-(--ds-disabled-opacity) data-popup-open:bg-muted/50 data-popup-open:hover:bg-muted data-open:bg-muted/50 data-open:hover:bg-muted data-open:focus:bg-muted"
|
|
59
59
|
);
|
|
60
60
|
function NavigationMenuTrigger({
|
|
61
61
|
className,
|
|
@@ -85,7 +85,7 @@ function NavigationMenuContent({
|
|
|
85
85
|
{
|
|
86
86
|
"data-slot": "navigation-menu-content",
|
|
87
87
|
className: cn(
|
|
88
|
-
"data-ending-style:data-activation-direction=left:translate-x-[50%] data-ending-style:data-activation-direction=right:translate-x-[-50%] data-starting-style:data-activation-direction=left:translate-x-[-50%] data-starting-style:data-activation-direction=right:translate-x-[50%] isolate z-(--ds-z-overlay) h-full w-auto p-2.5 pr-3 transition-[opacity,transform,translate] duration-
|
|
88
|
+
"data-ending-style:data-[activation-direction=left]:translate-x-[50%] data-ending-style:data-[activation-direction=right]:translate-x-[-50%] data-starting-style:data-[activation-direction=left]:translate-x-[-50%] data-starting-style:data-[activation-direction=right]:translate-x-[50%] isolate z-(--ds-z-overlay) h-full w-auto p-2.5 pr-3 transition-[opacity,transform,translate] duration-(--ds-motion-layout) ease-(--ds-ease-standard) group-data-[viewport=false]/navigation-menu:rounded-popover group-data-[viewport=false]/navigation-menu:bg-popover group-data-[viewport=false]/navigation-menu:text-popover-foreground group-data-[viewport=false]/navigation-menu:shadow-popover group-data-[viewport=false]/navigation-menu:ring-(length:--ds-layer-ring-w) group-data-[viewport=false]/navigation-menu:ring-(--ds-layer-ring) group-data-[viewport=false]/navigation-menu:duration-(--ds-motion-slow) data-ending-style:opacity-0 data-starting-style:opacity-0 data-[motion=from-end]:slide-in-from-right-52 data-[motion=from-start]:slide-in-from-left-52 data-[motion=to-end]:slide-out-to-right-52 data-[motion=to-start]:slide-out-to-left-52 data-[motion^=from-]:animate-in data-[motion^=from-]:fade-in data-[motion^=to-]:animate-out data-[motion^=to-]:fade-out **:data-[slot=navigation-menu-link]:focus:ring-0 **:data-[slot=navigation-menu-link]:focus:outline-none group-data-[viewport=false]/navigation-menu:data-open:animate-in group-data-[viewport=false]/navigation-menu:data-open:fade-in-0 group-data-[viewport=false]/navigation-menu:data-open:zoom-in-95 group-data-[viewport=false]/navigation-menu:data-closed:animate-out group-data-[viewport=false]/navigation-menu:data-closed:fade-out-0 group-data-[viewport=false]/navigation-menu:data-closed:zoom-out-95",
|
|
89
89
|
className
|
|
90
90
|
),
|
|
91
91
|
...props
|
|
@@ -103,16 +103,17 @@ function NavigationMenuPositioner({
|
|
|
103
103
|
return /* @__PURE__ */ jsx(NavigationMenuPrimitive.Portal, { children: /* @__PURE__ */ jsx(
|
|
104
104
|
NavigationMenuPrimitive.Positioner,
|
|
105
105
|
{
|
|
106
|
+
"data-slot": "navigation-menu-positioner",
|
|
106
107
|
side,
|
|
107
108
|
sideOffset,
|
|
108
109
|
align,
|
|
109
110
|
alignOffset,
|
|
110
111
|
className: cn(
|
|
111
|
-
"isolate z-(--ds-z-overlay) h-(--positioner-height) w-(--positioner-width) max-w-(--available-width) transition-[top,left,right,bottom] duration-
|
|
112
|
+
"isolate z-(--ds-z-overlay) h-(--positioner-height) w-(--positioner-width) max-w-(--available-width) transition-[top,left,right,bottom] duration-(--ds-motion-layout) ease-(--ds-ease-standard) data-instant:transition-none data-[side=bottom]:before:top-[-10px] data-[side=bottom]:before:right-0 data-[side=bottom]:before:left-0",
|
|
112
113
|
className
|
|
113
114
|
),
|
|
114
115
|
...props,
|
|
115
|
-
children: /* @__PURE__ */ jsx(NavigationMenuPrimitive.Popup, { className: "data-
|
|
116
|
+
children: /* @__PURE__ */ jsx(NavigationMenuPrimitive.Popup, { "data-slot": "navigation-menu-popup", className: "data-ending-style:ease-(--ds-ease-standard) xs:w-(--popup-width) relative h-(--popup-height) w-(--popup-width) origin-(--transform-origin) rounded-popover bg-popover text-popover-foreground shadow-popover ring-(length:--ds-layer-ring-w) ring-(--ds-layer-ring) transition-[opacity,transform,width,height,scale,translate] duration-(--ds-motion-layout) ease-(--ds-ease-standard) outline-none data-ending-style:scale-90 data-ending-style:opacity-0 data-ending-style:duration-(--ds-motion-fast) data-starting-style:scale-90 data-starting-style:opacity-0", children: /* @__PURE__ */ jsx(NavigationMenuPrimitive.Viewport, { "data-slot": "navigation-menu-viewport", className: "relative size-full overflow-hidden" }) })
|
|
116
117
|
}
|
|
117
118
|
) });
|
|
118
119
|
}
|
|
@@ -125,7 +126,7 @@ function NavigationMenuLink({
|
|
|
125
126
|
{
|
|
126
127
|
"data-slot": "navigation-menu-link",
|
|
127
128
|
className: cn(
|
|
128
|
-
"flex items-center gap-1.5 rounded-
|
|
129
|
+
"flex items-center gap-1.5 rounded-item p-3 text-sm transition-all duration-(--ds-motion-snap) outline-none hover:bg-muted focus:bg-muted focus-visible:ring-(length:--ds-ring-width) focus-visible:ring-(--ds-ring-color) focus-visible:outline-1 data-[active=true]:bg-muted/50 data-[active=true]:hover:bg-muted data-[active=true]:focus:bg-muted [&_svg:not([class*='size-'])]:size-4",
|
|
129
130
|
className
|
|
130
131
|
),
|
|
131
132
|
...props
|
|
@@ -145,7 +146,7 @@ function NavigationMenuIndicator({
|
|
|
145
146
|
className
|
|
146
147
|
),
|
|
147
148
|
...props,
|
|
148
|
-
children: /* @__PURE__ */ jsx("div", { className: "relative top-[60%] h-2 w-2 rotate-45 rounded-tl-sm bg-border shadow-overlay" })
|
|
149
|
+
children: /* @__PURE__ */ jsx("div", { "data-slot": "navigation-menu-arrow", className: "relative top-[60%] h-2 w-2 rotate-45 rounded-tl-sm bg-border shadow-overlay" })
|
|
149
150
|
}
|
|
150
151
|
);
|
|
151
152
|
}
|
package/dist/ui/pagination.js
CHANGED
|
@@ -1,13 +1,16 @@
|
|
|
1
|
+
"use client";
|
|
1
2
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
3
|
import { cn } from "../lib/utils";
|
|
3
4
|
import { Button } from "./button";
|
|
4
5
|
import { ChevronLeftIcon, ChevronRightIcon, MoreHorizontalIcon } from "lucide-react";
|
|
6
|
+
import { useDsMessages } from "../hooks/use-ds-messages";
|
|
5
7
|
function Pagination({ className, ...props }) {
|
|
8
|
+
const t = useDsMessages();
|
|
6
9
|
return /* @__PURE__ */ jsx(
|
|
7
10
|
"nav",
|
|
8
11
|
{
|
|
9
12
|
role: "navigation",
|
|
10
|
-
"aria-label":
|
|
13
|
+
"aria-label": t.pagination,
|
|
11
14
|
"data-slot": "pagination",
|
|
12
15
|
className: cn("mx-auto flex w-full justify-center", className),
|
|
13
16
|
...props
|
|
@@ -57,37 +60,41 @@ function PaginationLink({
|
|
|
57
60
|
}
|
|
58
61
|
function PaginationPrevious({
|
|
59
62
|
className,
|
|
60
|
-
text
|
|
63
|
+
text,
|
|
61
64
|
...props
|
|
62
65
|
}) {
|
|
66
|
+
const t = useDsMessages();
|
|
63
67
|
return /* @__PURE__ */ jsxs(
|
|
64
68
|
PaginationLink,
|
|
65
69
|
{
|
|
66
|
-
"aria-label":
|
|
70
|
+
"aria-label": t.paginationPreviousLabel,
|
|
67
71
|
size: "default",
|
|
68
|
-
|
|
72
|
+
"data-direction": "previous",
|
|
73
|
+
className: cn("pl-2", className),
|
|
69
74
|
...props,
|
|
70
75
|
children: [
|
|
71
76
|
/* @__PURE__ */ jsx(ChevronLeftIcon, { "data-icon": "inline-start" }),
|
|
72
|
-
/* @__PURE__ */ jsx("span", { className: "hidden sm:block", children: text })
|
|
77
|
+
/* @__PURE__ */ jsx("span", { className: "hidden sm:block", children: text ?? t.paginationPrevious })
|
|
73
78
|
]
|
|
74
79
|
}
|
|
75
80
|
);
|
|
76
81
|
}
|
|
77
82
|
function PaginationNext({
|
|
78
83
|
className,
|
|
79
|
-
text
|
|
84
|
+
text,
|
|
80
85
|
...props
|
|
81
86
|
}) {
|
|
87
|
+
const t = useDsMessages();
|
|
82
88
|
return /* @__PURE__ */ jsxs(
|
|
83
89
|
PaginationLink,
|
|
84
90
|
{
|
|
85
|
-
"aria-label":
|
|
91
|
+
"aria-label": t.paginationNextLabel,
|
|
86
92
|
size: "default",
|
|
87
|
-
|
|
93
|
+
"data-direction": "next",
|
|
94
|
+
className: cn("pr-2", className),
|
|
88
95
|
...props,
|
|
89
96
|
children: [
|
|
90
|
-
/* @__PURE__ */ jsx("span", { className: "hidden sm:block", children: text }),
|
|
97
|
+
/* @__PURE__ */ jsx("span", { className: "hidden sm:block", children: text ?? t.paginationNext }),
|
|
91
98
|
/* @__PURE__ */ jsx(ChevronRightIcon, { "data-icon": "inline-end" })
|
|
92
99
|
]
|
|
93
100
|
}
|
|
@@ -97,13 +104,14 @@ function PaginationEllipsis({
|
|
|
97
104
|
className,
|
|
98
105
|
...props
|
|
99
106
|
}) {
|
|
107
|
+
const t = useDsMessages();
|
|
100
108
|
return /* @__PURE__ */ jsxs(
|
|
101
109
|
"span",
|
|
102
110
|
{
|
|
103
111
|
"aria-hidden": true,
|
|
104
112
|
"data-slot": "pagination-ellipsis",
|
|
105
113
|
className: cn(
|
|
106
|
-
"flex size-
|
|
114
|
+
"flex size-(--ds-control-h-md) items-center justify-center [&_svg:not([class*='size-'])]:size-4",
|
|
107
115
|
className
|
|
108
116
|
),
|
|
109
117
|
...props,
|
|
@@ -112,7 +120,7 @@ function PaginationEllipsis({
|
|
|
112
120
|
MoreHorizontalIcon,
|
|
113
121
|
{}
|
|
114
122
|
),
|
|
115
|
-
/* @__PURE__ */ jsx("span", { className: "sr-only", children:
|
|
123
|
+
/* @__PURE__ */ jsx("span", { className: "sr-only", children: t.paginationMore })
|
|
116
124
|
]
|
|
117
125
|
}
|
|
118
126
|
);
|
package/dist/ui/popover.js
CHANGED
|
@@ -27,7 +27,7 @@ function PopoverContent({
|
|
|
27
27
|
{
|
|
28
28
|
"data-slot": "popover-content",
|
|
29
29
|
className: cn(
|
|
30
|
-
"flex w-
|
|
30
|
+
"flex w-(--ds-popover-w) origin-(--transform-origin) flex-col gap-(--ds-popover-p) rounded-popover bg-popover p-(--ds-popover-p) text-sm text-popover-foreground shadow-popover ring-(length:--ds-layer-ring-w) ring-(--ds-layer-ring) outline-hidden duration-(--ds-motion-fast) data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",
|
|
31
31
|
className
|
|
32
32
|
),
|
|
33
33
|
...props
|
|
@@ -54,7 +54,7 @@ function PopoverTitle({ className, ...props }) {
|
|
|
54
54
|
"div",
|
|
55
55
|
{
|
|
56
56
|
"data-slot": "popover-title",
|
|
57
|
-
className: cn("text-base font-
|
|
57
|
+
className: cn("text-base font-(--ds-overlay-title-weight)", className),
|
|
58
58
|
...props
|
|
59
59
|
}
|
|
60
60
|
);
|
package/dist/ui/progress.js
CHANGED
|
@@ -11,7 +11,7 @@ function Progress({
|
|
|
11
11
|
ProgressPrimitive.Track,
|
|
12
12
|
{
|
|
13
13
|
className: cn(
|
|
14
|
-
"relative flex h-
|
|
14
|
+
"relative flex h-(--ds-track-h) w-full items-center overflow-x-hidden rounded-track bg-muted",
|
|
15
15
|
className
|
|
16
16
|
),
|
|
17
17
|
"data-slot": "progress-track",
|
|
@@ -19,7 +19,7 @@ function Progress({
|
|
|
19
19
|
ProgressPrimitive.Indicator,
|
|
20
20
|
{
|
|
21
21
|
"data-slot": "progress-indicator",
|
|
22
|
-
className: "h-full bg-primary transition-all"
|
|
22
|
+
className: "h-full bg-primary transition-all duration-(--ds-motion-snap)"
|
|
23
23
|
}
|
|
24
24
|
)
|
|
25
25
|
}
|
package/dist/ui/questionnaire.js
CHANGED
|
@@ -4,6 +4,7 @@ import { Questionnaire as QuestionnairePrimitive } from "@shadcn/react/questionn
|
|
|
4
4
|
import { cn } from "../lib/utils";
|
|
5
5
|
import { buttonVariants } from "./button";
|
|
6
6
|
import { CheckIcon } from "lucide-react";
|
|
7
|
+
import { useDsMessages } from "../hooks/use-ds-messages";
|
|
7
8
|
function Questionnaire({
|
|
8
9
|
className,
|
|
9
10
|
...props
|
|
@@ -58,7 +59,7 @@ function QuestionnaireTitle({
|
|
|
58
59
|
{
|
|
59
60
|
"data-slot": "questionnaire-title",
|
|
60
61
|
className: cn(
|
|
61
|
-
"text-base font-
|
|
62
|
+
"text-base font-(--ds-title-weight) text-pretty [&:not(:has(~[data-slot=questionnaire-description]))]:mb-5",
|
|
62
63
|
className
|
|
63
64
|
),
|
|
64
65
|
...props
|
|
@@ -104,8 +105,8 @@ function QuestionnaireChoice({
|
|
|
104
105
|
{
|
|
105
106
|
"data-slot": "questionnaire-choice",
|
|
106
107
|
className: cn(
|
|
107
|
-
"group/questionnaire-choice relative flex min-h-
|
|
108
|
-
"data-disabled:pointer-events-none data-disabled:cursor-not-allowed data-disabled:opacity-
|
|
108
|
+
"group/questionnaire-choice relative flex min-h-(--ds-touch-target) cursor-pointer items-start gap-3 rounded-control border border-input px-4 py-3.5 text-start text-sm transition-colors duration-(--ds-motion-snap) outline-none select-none hover:bg-input/40 has-[>input:focus-visible]:border-ring has-[>input:focus-visible]:ring-(length:--ds-ring-width) has-[>input:focus-visible]:ring-(--ds-ring-color) data-invalid:border-destructive data-checked:border-(--ds-choice-selected-border) data-checked:bg-(--ds-choice-selected)",
|
|
109
|
+
"data-disabled:pointer-events-none data-disabled:cursor-not-allowed data-disabled:opacity-(--ds-disabled-opacity)",
|
|
109
110
|
className
|
|
110
111
|
),
|
|
111
112
|
...props,
|
|
@@ -122,7 +123,7 @@ function QuestionnaireChoice({
|
|
|
122
123
|
{
|
|
123
124
|
"aria-hidden": "true",
|
|
124
125
|
"data-slot": "questionnaire-choice-indicator",
|
|
125
|
-
className: "pointer-events-none relative flex size-4 shrink-0 translate-y-[--spacing(0.45)] items-center justify-center rounded-
|
|
126
|
+
className: "pointer-events-none relative flex size-4 shrink-0 translate-y-[--spacing(0.45)] items-center justify-center rounded-check border border-input group-has-data-[slot=questionnaire-choice-description]/questionnaire-choice:translate-y-0.5 group-data-[type=radio]/questionnaire-choice:rounded-full group-data-checked/questionnaire-choice:border-primary group-data-checked/questionnaire-choice:bg-primary group-data-checked/questionnaire-choice:text-primary-foreground bg-(--ds-check-bg) dark:group-data-checked/questionnaire-choice:bg-primary",
|
|
126
127
|
children: [
|
|
127
128
|
/* @__PURE__ */ jsx(
|
|
128
129
|
"span",
|
|
@@ -147,7 +148,7 @@ function QuestionnaireChoice({
|
|
|
147
148
|
QuestionnairePrimitive.ChoiceShortcut,
|
|
148
149
|
{
|
|
149
150
|
"data-slot": "questionnaire-choice-shortcut",
|
|
150
|
-
className: "pointer-events-none ms-auto hidden size-5 shrink-0 translate-y-[--spacing(0.45)] items-center justify-center rounded-full border border-input bg-background/80 font-mono text-
|
|
151
|
+
className: "pointer-events-none ms-auto hidden size-5 shrink-0 translate-y-[--spacing(0.45)] items-center justify-center rounded-full border border-input bg-background/80 font-mono text-2xs leading-none font-medium text-muted-foreground group-has-data-[slot=questionnaire-choice-description]/questionnaire-choice:translate-y-0.5 group-data-[shortcut]/questionnaire-choice:inline-flex"
|
|
151
152
|
}
|
|
152
153
|
)
|
|
153
154
|
]
|
|
@@ -181,7 +182,7 @@ function QuestionnaireInput({
|
|
|
181
182
|
{
|
|
182
183
|
"data-slot": "questionnaire-input",
|
|
183
184
|
className: cn(
|
|
184
|
-
"h-
|
|
185
|
+
"h-(--ds-control-h-md) min-h-(--ds-touch-target) w-full min-w-0 rounded-control border border-input bg-(--ds-field-bg) px-(--ds-field-px) py-1 text-base transition-[color,box-shadow,background-color] duration-(--ds-motion-snap) outline-none focus-visible:border-ring focus-visible:ring-(length:--ds-ring-width) focus-visible:ring-(--ds-ring-color) disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-(--ds-disabled-opacity) aria-invalid:border-(--ds-invalid-border) aria-invalid:ring-(length:--ds-ring-width) aria-invalid:ring-(--ds-invalid-ring) sm:min-h-0 md:text-sm",
|
|
185
186
|
"selection:bg-primary selection:text-primary-foreground placeholder:text-muted-foreground",
|
|
186
187
|
className
|
|
187
188
|
),
|
|
@@ -213,7 +214,7 @@ function QuestionnaireActions({
|
|
|
213
214
|
{
|
|
214
215
|
"data-slot": "questionnaire-actions",
|
|
215
216
|
className: cn(
|
|
216
|
-
"grid min-h-
|
|
217
|
+
"grid min-h-(--ds-touch-target) w-full grid-cols-[minmax(0,1fr)_auto_auto] items-center gap-2 sm:min-h-(--ds-control-h-md)",
|
|
217
218
|
className
|
|
218
219
|
),
|
|
219
220
|
...props
|
|
@@ -227,6 +228,7 @@ function QuestionnairePrevious({
|
|
|
227
228
|
variant = "outline",
|
|
228
229
|
...props
|
|
229
230
|
}) {
|
|
231
|
+
const t = useDsMessages();
|
|
230
232
|
return /* @__PURE__ */ jsx(
|
|
231
233
|
QuestionnairePrimitive.Previous,
|
|
232
234
|
{
|
|
@@ -235,11 +237,11 @@ function QuestionnairePrevious({
|
|
|
235
237
|
"data-variant": variant,
|
|
236
238
|
className: cn(
|
|
237
239
|
buttonVariants({ size, variant }),
|
|
238
|
-
"col-start-1 row-start-1 min-h-
|
|
240
|
+
"col-start-1 row-start-1 min-h-(--ds-touch-target) justify-self-start sm:min-h-0",
|
|
239
241
|
className
|
|
240
242
|
),
|
|
241
243
|
...props,
|
|
242
|
-
children: children ??
|
|
244
|
+
children: children ?? t.questionnairePrevious
|
|
243
245
|
}
|
|
244
246
|
);
|
|
245
247
|
}
|
|
@@ -250,6 +252,7 @@ function QuestionnaireSkip({
|
|
|
250
252
|
variant = "outline",
|
|
251
253
|
...props
|
|
252
254
|
}) {
|
|
255
|
+
const t = useDsMessages();
|
|
253
256
|
return /* @__PURE__ */ jsx(
|
|
254
257
|
QuestionnairePrimitive.Skip,
|
|
255
258
|
{
|
|
@@ -258,11 +261,11 @@ function QuestionnaireSkip({
|
|
|
258
261
|
"data-variant": variant,
|
|
259
262
|
className: cn(
|
|
260
263
|
buttonVariants({ size, variant }),
|
|
261
|
-
"col-start-2 row-start-1 min-h-
|
|
264
|
+
"col-start-2 row-start-1 min-h-(--ds-touch-target) justify-self-end sm:min-h-0",
|
|
262
265
|
className
|
|
263
266
|
),
|
|
264
267
|
...props,
|
|
265
|
-
children: children ??
|
|
268
|
+
children: children ?? t.questionnaireSkip
|
|
266
269
|
}
|
|
267
270
|
);
|
|
268
271
|
}
|
|
@@ -273,6 +276,7 @@ function QuestionnaireNext({
|
|
|
273
276
|
variant = "default",
|
|
274
277
|
...props
|
|
275
278
|
}) {
|
|
279
|
+
const t = useDsMessages();
|
|
276
280
|
return /* @__PURE__ */ jsx(
|
|
277
281
|
QuestionnairePrimitive.Next,
|
|
278
282
|
{
|
|
@@ -281,11 +285,11 @@ function QuestionnaireNext({
|
|
|
281
285
|
"data-variant": variant,
|
|
282
286
|
className: cn(
|
|
283
287
|
buttonVariants({ size, variant }),
|
|
284
|
-
"col-start-3 row-start-1 min-h-
|
|
288
|
+
"col-start-3 row-start-1 min-h-(--ds-touch-target) justify-self-end sm:min-h-0",
|
|
285
289
|
className
|
|
286
290
|
),
|
|
287
291
|
...props,
|
|
288
|
-
children: children ??
|
|
292
|
+
children: children ?? t.questionnaireNext
|
|
289
293
|
}
|
|
290
294
|
);
|
|
291
295
|
}
|
|
@@ -296,6 +300,7 @@ function QuestionnaireSubmit({
|
|
|
296
300
|
variant = "default",
|
|
297
301
|
...props
|
|
298
302
|
}) {
|
|
303
|
+
const t = useDsMessages();
|
|
299
304
|
return /* @__PURE__ */ jsx(
|
|
300
305
|
QuestionnairePrimitive.Submit,
|
|
301
306
|
{
|
|
@@ -304,11 +309,11 @@ function QuestionnaireSubmit({
|
|
|
304
309
|
"data-variant": variant,
|
|
305
310
|
className: cn(
|
|
306
311
|
buttonVariants({ size, variant }),
|
|
307
|
-
"col-start-3 row-start-1 min-h-
|
|
312
|
+
"col-start-3 row-start-1 min-h-(--ds-touch-target) justify-self-end sm:min-h-0",
|
|
308
313
|
className
|
|
309
314
|
),
|
|
310
315
|
...props,
|
|
311
|
-
children: children ??
|
|
316
|
+
children: children ?? t.questionnaireSubmit
|
|
312
317
|
}
|
|
313
318
|
);
|
|
314
319
|
}
|
package/dist/ui/radio-group.js
CHANGED
|
@@ -18,7 +18,7 @@ function RadioGroupItem({ className, ...props }) {
|
|
|
18
18
|
{
|
|
19
19
|
"data-slot": "radio-group-item",
|
|
20
20
|
className: cn(
|
|
21
|
-
"group/radio-group-item peer relative flex aspect-square size-
|
|
21
|
+
"group/radio-group-item peer relative flex aspect-square size-(--ds-check-size) shrink-0 rounded-full border border-input outline-none group-has-[:focus-visible]/field-label:ring-0 group-has-[:focus-visible]/field-label:not-data-checked:border-input after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:border-ring focus-visible:ring-(length:--ds-ring-width) focus-visible:ring-(--ds-ring-color) disabled:cursor-not-allowed disabled:opacity-(--ds-disabled-opacity) aria-invalid:border-(--ds-invalid-border) aria-invalid:ring-(length:--ds-ring-width) aria-invalid:ring-(--ds-invalid-ring) aria-invalid:aria-checked:border-primary bg-(--ds-check-bg) data-checked:border-primary data-checked:bg-primary data-checked:text-primary-foreground group-has-[:focus-visible]/field-label:data-checked:border-primary dark:data-checked:bg-primary",
|
|
22
22
|
className
|
|
23
23
|
),
|
|
24
24
|
...props,
|
|
@@ -26,7 +26,7 @@ function RadioGroupItem({ className, ...props }) {
|
|
|
26
26
|
RadioPrimitive.Indicator,
|
|
27
27
|
{
|
|
28
28
|
"data-slot": "radio-group-indicator",
|
|
29
|
-
className: "flex size-
|
|
29
|
+
className: "flex size-(--ds-check-size) items-center justify-center",
|
|
30
30
|
children: /* @__PURE__ */ jsx("span", { className: "absolute top-1/2 left-1/2 size-2 -translate-x-1/2 -translate-y-1/2 rounded-full bg-primary-foreground" })
|
|
31
31
|
}
|
|
32
32
|
)
|
package/dist/ui/resizable.js
CHANGED
|
@@ -31,11 +31,11 @@ function ResizableHandle({
|
|
|
31
31
|
{
|
|
32
32
|
"data-slot": "resizable-handle",
|
|
33
33
|
className: cn(
|
|
34
|
-
"relative flex w-
|
|
34
|
+
"relative flex w-(--ds-rule-w) items-center justify-center bg-border ring-offset-background after:absolute after:inset-y-0 after:left-1/2 after:w-1 after:-translate-x-1/2 focus-visible:ring-(length:--ds-ring-width) focus-visible:ring-ring focus-visible:outline-hidden aria-[orientation=horizontal]:h-(--ds-rule-w) aria-[orientation=horizontal]:w-full aria-[orientation=horizontal]:after:left-0 aria-[orientation=horizontal]:after:h-1 aria-[orientation=horizontal]:after:w-full aria-[orientation=horizontal]:after:translate-x-0 aria-[orientation=horizontal]:after:-translate-y-1/2 [&[aria-orientation=horizontal]>div]:rotate-90",
|
|
35
35
|
className
|
|
36
36
|
),
|
|
37
37
|
...props,
|
|
38
|
-
children: withHandle && /* @__PURE__ */ jsx("div", { className: "z-(--ds-z-raised) flex h-6 w-1 shrink-0 rounded-lg bg-border" })
|
|
38
|
+
children: withHandle && /* @__PURE__ */ jsx("div", { "data-slot": "resizable-handle-grip", className: "z-(--ds-z-raised) flex h-6 w-1 shrink-0 rounded-lg bg-border" })
|
|
39
39
|
}
|
|
40
40
|
);
|
|
41
41
|
}
|
package/dist/ui/scroll-area.js
CHANGED
|
@@ -17,12 +17,12 @@ function ScrollArea({
|
|
|
17
17
|
ScrollAreaPrimitive.Viewport,
|
|
18
18
|
{
|
|
19
19
|
"data-slot": "scroll-area-viewport",
|
|
20
|
-
className: "size-full rounded-[inherit] transition-[color,box-shadow] outline-none focus-visible:ring-(length:--ds-ring-width) focus-visible:ring-ring
|
|
20
|
+
className: "size-full rounded-[inherit] transition-[color,box-shadow] duration-(--ds-motion-snap) outline-none focus-visible:ring-(length:--ds-ring-width) focus-visible:ring-(--ds-ring-color) focus-visible:outline-1",
|
|
21
21
|
children
|
|
22
22
|
}
|
|
23
23
|
),
|
|
24
24
|
/* @__PURE__ */ jsx(ScrollBar, {}),
|
|
25
|
-
/* @__PURE__ */ jsx(ScrollAreaPrimitive.Corner, {})
|
|
25
|
+
/* @__PURE__ */ jsx(ScrollAreaPrimitive.Corner, { "data-slot": "scroll-area-corner" })
|
|
26
26
|
]
|
|
27
27
|
}
|
|
28
28
|
);
|
|
@@ -39,7 +39,7 @@ function ScrollBar({
|
|
|
39
39
|
"data-orientation": orientation,
|
|
40
40
|
orientation,
|
|
41
41
|
className: cn(
|
|
42
|
-
"flex touch-none p-px transition-colors select-none data-[orientation=horizontal]:h-
|
|
42
|
+
"flex touch-none p-px transition-colors duration-(--ds-motion-snap) select-none data-[orientation=horizontal]:h-(--ds-scrollbar-w) data-[orientation=horizontal]:flex-col data-[orientation=horizontal]:border-t data-[orientation=horizontal]:border-t-transparent data-[orientation=vertical]:h-full data-[orientation=vertical]:w-(--ds-scrollbar-w) data-[orientation=vertical]:border-l data-[orientation=vertical]:border-l-transparent",
|
|
43
43
|
className
|
|
44
44
|
),
|
|
45
45
|
...props,
|
package/dist/ui/select.js
CHANGED
|
@@ -8,7 +8,7 @@ function SelectGroup({ className, ...props }) {
|
|
|
8
8
|
SelectPrimitive.Group,
|
|
9
9
|
{
|
|
10
10
|
"data-slot": "select-group",
|
|
11
|
-
className: cn("scroll-my-1 p-
|
|
11
|
+
className: cn("scroll-my-1 p-(--ds-menu-p)", className),
|
|
12
12
|
...props
|
|
13
13
|
}
|
|
14
14
|
);
|
|
@@ -28,7 +28,7 @@ function SelectTrigger({
|
|
|
28
28
|
"data-slot": "select-trigger",
|
|
29
29
|
"data-size": size,
|
|
30
30
|
className: cn(
|
|
31
|
-
"flex w-fit items-center justify-between gap-1.5 rounded-control shadow-control border border-input bg-
|
|
31
|
+
"flex w-fit items-center justify-between gap-1.5 rounded-control shadow-control border border-input bg-(--ds-field-bg) px-(--ds-field-px) py-2 text-sm whitespace-nowrap transition-colors duration-(--ds-motion-snap) outline-none focus-visible:border-ring focus-visible:ring-(length:--ds-ring-width) focus-visible:ring-(--ds-ring-color) disabled:cursor-not-allowed disabled:opacity-(--ds-disabled-opacity) aria-invalid:border-(--ds-invalid-border) aria-invalid:ring-(length:--ds-ring-width) aria-invalid:ring-(--ds-invalid-ring) data-placeholder:text-muted-foreground data-[size=default]:h-(--ds-control-h-md) data-[size=sm]:h-(--ds-control-h-sm) *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-1.5 dark:hover:bg-(--ds-field-bg-hover) [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
|
|
32
32
|
className
|
|
33
33
|
),
|
|
34
34
|
...props,
|
|
@@ -69,7 +69,7 @@ function SelectContent({
|
|
|
69
69
|
"data-slot": "select-content",
|
|
70
70
|
"data-align-trigger": alignItemWithTrigger,
|
|
71
71
|
className: cn(
|
|
72
|
-
"relative z-(--ds-z-overlay) max-h-(--available-height) min-w-36 origin-(--transform-origin) overflow-x-hidden overflow-y-auto rounded-
|
|
72
|
+
"relative z-(--ds-z-overlay) max-h-(--available-height) min-w-36 origin-(--transform-origin) overflow-x-hidden overflow-y-auto rounded-popover bg-popover text-popover-foreground shadow-popover ring-(length:--ds-layer-ring-w) ring-(--ds-layer-ring) duration-(--ds-motion-fast) data-[align-trigger=true]:animate-none data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",
|
|
73
73
|
className
|
|
74
74
|
),
|
|
75
75
|
...props,
|
|
@@ -101,7 +101,7 @@ function SelectLabel({
|
|
|
101
101
|
SelectPrimitive.GroupLabel,
|
|
102
102
|
{
|
|
103
103
|
"data-slot": "select-label",
|
|
104
|
-
className: cn("px-
|
|
104
|
+
className: cn("px-(--ds-menu-item-px) py-2.5 text-xs text-muted-foreground", className),
|
|
105
105
|
...props
|
|
106
106
|
}
|
|
107
107
|
);
|
|
@@ -116,7 +116,7 @@ function SelectItem({
|
|
|
116
116
|
{
|
|
117
117
|
"data-slot": "select-item",
|
|
118
118
|
className: cn(
|
|
119
|
-
"relative flex w-full cursor-default items-center gap-2.5 rounded-
|
|
119
|
+
"relative flex w-full cursor-default items-center gap-2.5 rounded-item py-(--ds-menu-item-py) pr-8 pl-(--ds-menu-item-px) text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-(--ds-disabled-opacity) [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2",
|
|
120
120
|
className
|
|
121
121
|
),
|
|
122
122
|
...props,
|
|
@@ -136,7 +136,7 @@ function SelectSeparator({
|
|
|
136
136
|
{
|
|
137
137
|
"data-slot": "select-separator",
|
|
138
138
|
className: cn(
|
|
139
|
-
"pointer-events-none -mx-1 my-1 h-
|
|
139
|
+
"pointer-events-none -mx-1 my-1 h-(--ds-rule-w) bg-(--ds-separator)",
|
|
140
140
|
className
|
|
141
141
|
),
|
|
142
142
|
...props
|
package/dist/ui/separator.js
CHANGED
|
@@ -13,7 +13,7 @@ function Separator({
|
|
|
13
13
|
"data-slot": "separator",
|
|
14
14
|
orientation,
|
|
15
15
|
className: cn(
|
|
16
|
-
"shrink-0 bg-border data-[orientation=horizontal]:h-
|
|
16
|
+
"shrink-0 bg-border data-[orientation=horizontal]:h-(--ds-rule-w) data-[orientation=horizontal]:w-full data-[orientation=vertical]:w-(--ds-rule-w) data-[orientation=vertical]:self-stretch",
|
|
17
17
|
className
|
|
18
18
|
),
|
|
19
19
|
...props
|
package/dist/ui/sheet.js
CHANGED
|
@@ -4,6 +4,7 @@ import { Dialog as SheetPrimitive } from "@base-ui/react/dialog";
|
|
|
4
4
|
import { cn } from "../lib/utils";
|
|
5
5
|
import { Button } from "./button";
|
|
6
6
|
import { XIcon } from "lucide-react";
|
|
7
|
+
import { useDsMessages } from "../hooks/use-ds-messages";
|
|
7
8
|
function Sheet({ ...props }) {
|
|
8
9
|
return /* @__PURE__ */ jsx(SheetPrimitive.Root, { "data-slot": "sheet", ...props });
|
|
9
10
|
}
|
|
@@ -22,7 +23,7 @@ function SheetOverlay({ className, ...props }) {
|
|
|
22
23
|
{
|
|
23
24
|
"data-slot": "sheet-overlay",
|
|
24
25
|
className: cn(
|
|
25
|
-
"fixed inset-0 z-(--ds-z-overlay) bg-scrim duration-(--ds-motion-fast) supports-backdrop-filter:backdrop-blur-
|
|
26
|
+
"fixed inset-0 z-(--ds-z-overlay) bg-scrim duration-(--ds-motion-fast) supports-backdrop-filter:backdrop-blur-(--ds-scrim-blur) data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0",
|
|
26
27
|
className
|
|
27
28
|
),
|
|
28
29
|
...props
|
|
@@ -36,6 +37,7 @@ function SheetContent({
|
|
|
36
37
|
showCloseButton = true,
|
|
37
38
|
...props
|
|
38
39
|
}) {
|
|
40
|
+
const t = useDsMessages();
|
|
39
41
|
return /* @__PURE__ */ jsxs(SheetPortal, { children: [
|
|
40
42
|
/* @__PURE__ */ jsx(SheetOverlay, {}),
|
|
41
43
|
/* @__PURE__ */ jsxs(
|
|
@@ -44,7 +46,7 @@ function SheetContent({
|
|
|
44
46
|
"data-slot": "sheet-content",
|
|
45
47
|
"data-side": side,
|
|
46
48
|
className: cn(
|
|
47
|
-
"fixed z-(--ds-z-overlay) flex flex-col bg-popover bg-clip-padding text-sm text-popover-foreground shadow-overlay transition duration-(--ds-motion-base) ease-
|
|
49
|
+
"fixed z-(--ds-z-overlay) flex flex-col bg-popover bg-clip-padding text-sm text-popover-foreground shadow-overlay transition duration-(--ds-motion-base) ease-(--ds-ease-panel) data-[side=bottom]:inset-x-0 data-[side=bottom]:bottom-0 data-[side=bottom]:h-auto data-[side=bottom]:border-t-(length:--ds-rule-w) data-[side=left]:inset-y-0 data-[side=left]:left-0 data-[side=left]:h-full data-[side=left]:w-3/4 data-[side=left]:border-r-(length:--ds-rule-w) data-[side=right]:inset-y-0 data-[side=right]:right-0 data-[side=right]:h-full data-[side=right]:w-3/4 data-[side=right]:border-l-(length:--ds-rule-w) data-[side=top]:inset-x-0 data-[side=top]:top-0 data-[side=top]:h-auto data-[side=top]:border-b-(length:--ds-rule-w) data-[side=left]:sm:max-w-(--ds-sheet-w) data-[side=right]:sm:max-w-(--ds-sheet-w) data-open:animate-in data-open:fade-in-0 data-[side=bottom]:data-open:slide-in-from-bottom-10 data-[side=left]:data-open:slide-in-from-left-10 data-[side=right]:data-open:slide-in-from-right-10 data-[side=top]:data-open:slide-in-from-top-10 data-closed:animate-out data-closed:fade-out-0 data-[side=bottom]:data-closed:slide-out-to-bottom-10 data-[side=left]:data-closed:slide-out-to-left-10 data-[side=right]:data-closed:slide-out-to-right-10 data-[side=top]:data-closed:slide-out-to-top-10",
|
|
48
50
|
className
|
|
49
51
|
),
|
|
50
52
|
...props,
|
|
@@ -64,7 +66,7 @@ function SheetContent({
|
|
|
64
66
|
),
|
|
65
67
|
children: [
|
|
66
68
|
/* @__PURE__ */ jsx(XIcon, {}),
|
|
67
|
-
/* @__PURE__ */ jsx("span", { className: "sr-only", children:
|
|
69
|
+
/* @__PURE__ */ jsx("span", { className: "sr-only", children: t.close })
|
|
68
70
|
]
|
|
69
71
|
}
|
|
70
72
|
)
|
|
@@ -98,7 +100,7 @@ function SheetTitle({ className, ...props }) {
|
|
|
98
100
|
SheetPrimitive.Title,
|
|
99
101
|
{
|
|
100
102
|
"data-slot": "sheet-title",
|
|
101
|
-
className: cn("text-base font-
|
|
103
|
+
className: cn("text-base font-(--ds-overlay-title-weight) text-foreground", className),
|
|
102
104
|
...props
|
|
103
105
|
}
|
|
104
106
|
);
|