docthub-core-components 2.99.2 → 3.1.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/dist/components/overrides/ui/auto-complete.js +466 -0
- package/dist/components/overrides/ui/autocomplete-checkbox.js +480 -0
- package/dist/components/overrides/ui/chips/doct-chip.js +157 -0
- package/dist/components/overrides/ui/circular-progress.js +32 -0
- package/dist/components/overrides/ui/composed/address-form-section.js +67 -0
- package/dist/components/overrides/ui/composed/contact-form-section.js +56 -0
- package/dist/components/overrides/ui/composed/search-filter-section.js +132 -0
- package/dist/components/overrides/ui/composed/user-registration-section.js +77 -0
- package/dist/components/overrides/ui/currencyInput/currency-input.js +69 -0
- package/dist/components/overrides/ui/doct-animation-loader.js +13 -0
- package/dist/components/overrides/ui/expandable-card.js +115 -0
- package/dist/components/overrides/ui/footer/doct-footer.js +35 -0
- package/dist/components/overrides/ui/footer/footer-desktop.js +92 -0
- package/dist/components/overrides/ui/footer/footer-mobile.js +123 -0
- package/dist/components/overrides/ui/footer/footer-routes.js +87 -0
- package/dist/components/overrides/ui/footer/footer-shared.js +137 -0
- package/dist/components/overrides/ui/footer/presets.js +269 -0
- package/dist/components/overrides/ui/inputs/labeled-input.js +92 -0
- package/dist/components/overrides/ui/inputs/otp-input.js +101 -0
- package/dist/components/overrides/ui/inputs/password-input.js +77 -0
- package/dist/components/overrides/ui/inputs/phone-input.js +336 -0
- package/dist/components/overrides/ui/navigation-menu/doct-navigation-menu.js +22 -0
- package/dist/components/overrides/ui/navigation-menu/individual-nav-routes.js +46 -0
- package/dist/components/overrides/ui/navigation-menu/individual-navigation-menu-desktop.js +109 -0
- package/dist/components/overrides/ui/navigation-menu/individual-navigation-menu-mobile.js +231 -0
- package/dist/components/overrides/ui/navigation-menu/individual-navigation-menu.js +44 -0
- package/dist/components/overrides/ui/navigation-menu/nav-env.js +64 -0
- package/dist/components/overrides/ui/navigation-menu/navigation-menu-adapter.js +55 -0
- package/dist/components/overrides/ui/navigation-menu/navigation-menu-internal.js +36 -0
- package/dist/components/overrides/ui/navigation-menu/organization-nav-routes.js +34 -0
- package/dist/components/overrides/ui/navigation-menu/organization-navigation-menu-desktop.js +109 -0
- package/dist/components/overrides/ui/navigation-menu/organization-navigation-menu-mobile.js +231 -0
- package/dist/components/overrides/ui/navigation-menu/organization-navigation-menu.js +44 -0
- package/dist/components/overrides/ui/navigation-menu/presets.js +238 -0
- package/dist/components/overrides/ui/navigation-menu/types.js +6 -0
- package/dist/components/overrides/ui/pickers/date-picker-field.js +361 -0
- package/dist/components/overrides/ui/pickers/date-range-picker-field.js +288 -0
- package/dist/components/overrides/ui/pickers/day-picker-bounds.js +38 -0
- package/dist/components/overrides/ui/pickers/select-field.js +158 -0
- package/dist/components/overrides/ui/search/auto-complete.js +64 -0
- package/dist/components/overrides/ui/search/search-input.js +65 -0
- package/dist/components/overrides/ui/showcase/component-section.js +45 -0
- package/dist/components/ui/alert.js +94 -0
- package/dist/components/ui/avatar.js +69 -0
- package/dist/components/ui/badge.js +37 -0
- package/dist/components/ui/breadcrumb.js +117 -0
- package/dist/components/ui/button.js +223 -0
- package/dist/components/ui/calendar.js +100 -0
- package/dist/components/ui/checkbox.js +57 -0
- package/dist/components/ui/collapsible.js +25 -0
- package/dist/components/ui/command.js +132 -0
- package/dist/components/ui/dialog.js +230 -0
- package/dist/components/ui/drawer.js +119 -0
- package/dist/components/ui/dropdown-menu.js +216 -0
- package/dist/components/ui/input.js +48 -0
- package/dist/components/ui/label.js +22 -0
- package/dist/components/ui/popover.js +181 -0
- package/dist/components/ui/progress.js +91 -0
- package/dist/components/ui/radio-group.js +49 -0
- package/dist/components/ui/select.js +169 -0
- package/dist/components/ui/skeleton.js +91 -0
- package/dist/components/ui/spinner.js +32 -0
- package/dist/components/ui/tabs.js +68 -0
- package/dist/components/ui/textarea.js +73 -0
- package/dist/components/ui/timeline.js +177 -0
- package/dist/components/ui/toast.js +82 -0
- package/dist/components/ui/tooltip.js +91 -0
- package/dist/components/ui/typography.js +213 -0
- package/dist/hooks/use-exclusive-dropdown.js +53 -0
- package/dist/hooks/use-mobile.js +19 -0
- package/dist/hooks/useAutocompleteCheckbox.js +204 -0
- package/dist/index.esm.js +7173 -7126
- package/dist/index.js +187 -0
- package/dist/lib/dropdown-manager.js +17 -0
- package/dist/lib/get-floating-dropdown-position.js +32 -0
- package/dist/lib/get-scroll-parents.js +20 -0
- package/dist/lib/slot.js +40 -0
- package/dist/lib/utils.js +9 -0
- package/dist/src/components/ui/alert.d.ts +1 -1
- package/dist/src/components/ui/button.d.ts +1 -1
- package/dist/src/components/ui/command.d.ts +3 -3
- package/dist/src/components/ui/timeline.d.ts +1 -1
- package/dist/src/index.d.ts +15 -15
- package/dist/src/lib/get-floating-dropdown-position.d.ts +9 -1
- package/dist/src/lib/get-scroll-parents.d.ts +6 -0
- package/dist/style.css +1 -1
- package/dist/util/getInputClasses.js +19 -0
- package/package.json +131 -132
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx as m, jsxs as N } from "react/jsx-runtime";
|
|
3
|
+
import { c as d } from "react-compiler-runtime";
|
|
4
|
+
import { ChevronRight as b, MoreHorizontal as h } from "lucide-react";
|
|
5
|
+
import * as f from "react";
|
|
6
|
+
import { Slot as B } from "../../lib/slot.js";
|
|
7
|
+
import { cn as n } from "../../lib/utils.js";
|
|
8
|
+
const x = f.forwardRef((i, s) => {
|
|
9
|
+
const e = d(5);
|
|
10
|
+
let t;
|
|
11
|
+
e[0] !== i ? ({
|
|
12
|
+
...t
|
|
13
|
+
} = i, e[0] = i, e[1] = t) : t = e[1];
|
|
14
|
+
let l;
|
|
15
|
+
return e[2] !== t || e[3] !== s ? (l = /* @__PURE__ */ m("nav", { ref: s, "aria-label": "breadcrumb", ...t }), e[2] = t, e[3] = s, e[4] = l) : l = e[4], l;
|
|
16
|
+
});
|
|
17
|
+
x.displayName = "Breadcrumb";
|
|
18
|
+
const w = f.forwardRef((i, s) => {
|
|
19
|
+
const e = d(9);
|
|
20
|
+
let t, l;
|
|
21
|
+
e[0] !== i ? ({
|
|
22
|
+
className: t,
|
|
23
|
+
...l
|
|
24
|
+
} = i, e[0] = i, e[1] = t, e[2] = l) : (t = e[1], l = e[2]);
|
|
25
|
+
let r;
|
|
26
|
+
e[3] !== t ? (r = n("flex flex-wrap items-center gap-1.5 break-words text-sm text-[#323333] font-semibold sm:gap-2.5", t), e[3] = t, e[4] = r) : r = e[4];
|
|
27
|
+
let a;
|
|
28
|
+
return e[5] !== l || e[6] !== s || e[7] !== r ? (a = /* @__PURE__ */ m("ol", { ref: s, className: r, ...l }), e[5] = l, e[6] = s, e[7] = r, e[8] = a) : a = e[8], a;
|
|
29
|
+
});
|
|
30
|
+
w.displayName = "BreadcrumbList";
|
|
31
|
+
const y = f.forwardRef((i, s) => {
|
|
32
|
+
const e = d(9);
|
|
33
|
+
let t, l;
|
|
34
|
+
e[0] !== i ? ({
|
|
35
|
+
className: t,
|
|
36
|
+
...l
|
|
37
|
+
} = i, e[0] = i, e[1] = t, e[2] = l) : (t = e[1], l = e[2]);
|
|
38
|
+
let r;
|
|
39
|
+
e[3] !== t ? (r = n("inline-flex items-center gap-1.5", t), e[3] = t, e[4] = r) : r = e[4];
|
|
40
|
+
let a;
|
|
41
|
+
return e[5] !== l || e[6] !== s || e[7] !== r ? (a = /* @__PURE__ */ m("li", { ref: s, className: r, ...l }), e[5] = l, e[6] = s, e[7] = r, e[8] = a) : a = e[8], a;
|
|
42
|
+
});
|
|
43
|
+
y.displayName = "BreadcrumbItem";
|
|
44
|
+
const g = f.forwardRef((i, s) => {
|
|
45
|
+
const e = d(11);
|
|
46
|
+
let t, l, r;
|
|
47
|
+
e[0] !== i ? ({
|
|
48
|
+
asChild: t,
|
|
49
|
+
className: l,
|
|
50
|
+
...r
|
|
51
|
+
} = i, e[0] = i, e[1] = t, e[2] = l, e[3] = r) : (t = e[1], l = e[2], r = e[3]);
|
|
52
|
+
const a = t ? B : "a";
|
|
53
|
+
let o;
|
|
54
|
+
e[4] !== l ? (o = n("transition-colors font-semibold text-[#323333]", l), e[4] = l, e[5] = o) : o = e[5];
|
|
55
|
+
let c;
|
|
56
|
+
return e[6] !== a || e[7] !== r || e[8] !== s || e[9] !== o ? (c = /* @__PURE__ */ m(a, { ref: s, className: o, ...r }), e[6] = a, e[7] = r, e[8] = s, e[9] = o, e[10] = c) : c = e[10], c;
|
|
57
|
+
});
|
|
58
|
+
g.displayName = "BreadcrumbLink";
|
|
59
|
+
const R = f.forwardRef((i, s) => {
|
|
60
|
+
const e = d(9);
|
|
61
|
+
let t, l;
|
|
62
|
+
e[0] !== i ? ({
|
|
63
|
+
className: t,
|
|
64
|
+
...l
|
|
65
|
+
} = i, e[0] = i, e[1] = t, e[2] = l) : (t = e[1], l = e[2]);
|
|
66
|
+
let r;
|
|
67
|
+
e[3] !== t ? (r = n("font-semibold text-[#323333]", t), e[3] = t, e[4] = r) : r = e[4];
|
|
68
|
+
let a;
|
|
69
|
+
return e[5] !== l || e[6] !== s || e[7] !== r ? (a = /* @__PURE__ */ m("span", { ref: s, "aria-current": "page", className: r, ...l }), e[5] = l, e[6] = s, e[7] = r, e[8] = a) : a = e[8], a;
|
|
70
|
+
});
|
|
71
|
+
R.displayName = "BreadcrumbPage";
|
|
72
|
+
const $ = (i) => {
|
|
73
|
+
const s = d(16);
|
|
74
|
+
let e, t, l, r, a;
|
|
75
|
+
s[0] !== i ? ({
|
|
76
|
+
children: e,
|
|
77
|
+
className: t,
|
|
78
|
+
iconClassName: l,
|
|
79
|
+
strokeWidth: a,
|
|
80
|
+
...r
|
|
81
|
+
} = i, s[0] = i, s[1] = e, s[2] = t, s[3] = l, s[4] = r, s[5] = a) : (e = s[1], t = s[2], l = s[3], r = s[4], a = s[5]);
|
|
82
|
+
const o = a === void 0 ? 2 : a;
|
|
83
|
+
let c;
|
|
84
|
+
s[6] !== t ? (c = n("[&>svg]:w-3.5 [&>svg]:h-3.5", t), s[6] = t, s[7] = c) : c = s[7];
|
|
85
|
+
let p;
|
|
86
|
+
s[8] !== e || s[9] !== l || s[10] !== o ? (p = e ?? /* @__PURE__ */ m(b, { strokeWidth: o, className: n("text-[#6E6F70]", l) }), s[8] = e, s[9] = l, s[10] = o, s[11] = p) : p = s[11];
|
|
87
|
+
let u;
|
|
88
|
+
return s[12] !== r || s[13] !== c || s[14] !== p ? (u = /* @__PURE__ */ m("li", { role: "presentation", "aria-hidden": "true", className: c, ...r, children: p }), s[12] = r, s[13] = c, s[14] = p, s[15] = u) : u = s[15], u;
|
|
89
|
+
};
|
|
90
|
+
$.displayName = "BreadcrumbSeparator";
|
|
91
|
+
const k = (i) => {
|
|
92
|
+
const s = d(10);
|
|
93
|
+
let e, t;
|
|
94
|
+
s[0] !== i ? ({
|
|
95
|
+
className: e,
|
|
96
|
+
...t
|
|
97
|
+
} = i, s[0] = i, s[1] = e, s[2] = t) : (e = s[1], t = s[2]);
|
|
98
|
+
let l;
|
|
99
|
+
s[3] !== e ? (l = n("flex h-9 w-9 items-center justify-center", e), s[3] = e, s[4] = l) : l = s[4];
|
|
100
|
+
let r, a;
|
|
101
|
+
s[5] === Symbol.for("react.memo_cache_sentinel") ? (r = /* @__PURE__ */ m(h, { className: "h-4 w-4" }), a = /* @__PURE__ */ m("span", { className: "sr-only", children: "More" }), s[5] = r, s[6] = a) : (r = s[5], a = s[6]);
|
|
102
|
+
let o;
|
|
103
|
+
return s[7] !== t || s[8] !== l ? (o = /* @__PURE__ */ N("span", { role: "presentation", "aria-hidden": "true", className: l, ...t, children: [
|
|
104
|
+
r,
|
|
105
|
+
a
|
|
106
|
+
] }), s[7] = t, s[8] = l, s[9] = o) : o = s[9], o;
|
|
107
|
+
};
|
|
108
|
+
k.displayName = "BreadcrumbEllipsis";
|
|
109
|
+
export {
|
|
110
|
+
x as Breadcrumb,
|
|
111
|
+
k as BreadcrumbEllipsis,
|
|
112
|
+
y as BreadcrumbItem,
|
|
113
|
+
g as BreadcrumbLink,
|
|
114
|
+
w as BreadcrumbList,
|
|
115
|
+
R as BreadcrumbPage,
|
|
116
|
+
$ as BreadcrumbSeparator
|
|
117
|
+
};
|
|
@@ -0,0 +1,223 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx as L, jsxs as T } from "react/jsx-runtime";
|
|
3
|
+
import { c as Y } from "react-compiler-runtime";
|
|
4
|
+
import { cva as Z } from "class-variance-authority";
|
|
5
|
+
import $ from "react";
|
|
6
|
+
import { Slot as q } from "../../lib/slot.js";
|
|
7
|
+
import { cn as H } from "../../lib/utils.js";
|
|
8
|
+
const J = Z("inline-flex items-center justify-center transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50", {
|
|
9
|
+
variants: {
|
|
10
|
+
variant: {
|
|
11
|
+
// High Emphasis - Filled
|
|
12
|
+
default: "bg-[#002830] text-white hover:bg-[#002830]/90 active:bg-[#002830]/80",
|
|
13
|
+
primary: "bg-[#002830] text-white hover:bg-[#002830]/90 active:bg-[#002830]/80",
|
|
14
|
+
error: "bg-[#EA4335] text-white hover:bg-[#EA4335]/90 active:bg-[#EA4335]/80",
|
|
15
|
+
success: "bg-[#00C752] text-white hover:bg-[#00C752]/90 active:bg-[#00C752]/80",
|
|
16
|
+
warning: "bg-[#FFB200] text-white hover:bg-[#FFB200]/90 active:bg-[#FFB200]/80",
|
|
17
|
+
informative: "bg-[#4389FF] text-white hover:bg-[#4389FF]/90 active:bg-[#4389FF]/80",
|
|
18
|
+
// Low Emphasis - Contained (using semantic colors)
|
|
19
|
+
secondary: "bg-[rgba(0,0,0,0.12)] text-[rgba(0,0,0,0.8)] hover:bg-[rgba(0,0,0,0.16)] active:bg-[rgba(0,0,0,0.2)] [&>span[data-testid='button-icon']_svg]:text-[rgba(0,0,0,0.8)]",
|
|
20
|
+
"secondary-error": "bg-semantic-negative/10 text-semantic-negative hover:bg-semantic-negative/15 active:bg-semantic-negative/20 [&>span[data-testid='button-icon']_svg]:text-semantic-negative",
|
|
21
|
+
"secondary-success": "bg-semantic-positive/10 text-semantic-positive hover:bg-semantic-positive/15 active:bg-semantic-positive/20 [&>span[data-testid='button-icon']_svg]:text-semantic-positive",
|
|
22
|
+
"secondary-warning": "bg-semantic-warning/10 text-semantic-warning hover:bg-semantic-warning/15 active:bg-semantic-warning/20 [&>span[data-testid='button-icon']_svg]:text-semantic-warning",
|
|
23
|
+
"secondary-informative": "bg-semantic-informative/10 text-semantic-informative hover:bg-semantic-informative/15 active:bg-semantic-informative/20 [&>span[data-testid='button-icon']_svg]:text-semantic-informative",
|
|
24
|
+
// Outlined (with exact border opacity from Figma)
|
|
25
|
+
outline: "border-2 border-[rgba(0,0,0,0.1)] bg-transparent [color:rgba(0,0,0,0.8)] hover:bg-[rgba(0,0,0,0.04)] active:bg-[rgba(0,0,0,0.08)] [&>span[data-testid='button-icon']_svg]:text-[rgba(0,0,0,0.8)]",
|
|
26
|
+
"outline-error": "border-2 border-[rgba(234,67,53,0.16)] bg-transparent text-[#EA4335] hover:bg-[rgba(234,67,53,0.04)] active:bg-[rgba(234,67,53,0.08)] [&>span[data-testid='button-icon']_svg]:text-[#EA4335]",
|
|
27
|
+
"outline-success": "border-2 border-[rgba(0,199,82,0.24)] bg-transparent text-[#00C752] hover:bg-[rgba(0,199,82,0.04)] active:bg-[rgba(0,199,82,0.08)] [&>span[data-testid='button-icon']_svg]:text-[#00C752]",
|
|
28
|
+
"outline-warning": "border-2 border-[rgba(255,178,0,0.24)] bg-transparent text-[#FFB200] hover:bg-[rgba(255,178,0,0.04)] active:bg-[rgba(255,178,0,0.08)] [&>span[data-testid='button-icon']_svg]:text-[#FFB200]",
|
|
29
|
+
"outline-informative": "border-2 border-[rgba(67,137,255,0.2)] bg-transparent text-[#4389FF] hover:bg-[rgba(67,137,255,0.04)] active:bg-[rgba(67,137,255,0.08)] [&>span[data-testid='button-icon']_svg]:text-[#4389FF]",
|
|
30
|
+
// Text/Ghost (no background)
|
|
31
|
+
ghost: "bg-transparent text-[rgba(0,0,0,0.8)] hover:bg-[rgba(0,0,0,0.06)] active:bg-[rgba(0,0,0,0.1)] [&>span[data-testid='button-icon']_svg]:text-[rgba(0,0,0,0.8)]",
|
|
32
|
+
"ghost-error": "bg-transparent text-[#EA4335] hover:bg-[rgba(234,67,53,0.06)] active:bg-[rgba(234,67,53,0.1)] [&>span[data-testid='button-icon']_svg]:text-[#EA4335]",
|
|
33
|
+
"ghost-success": "bg-transparent text-[#00C752] hover:bg-[rgba(0,199,82,0.06)] active:bg-[rgba(0,199,82,0.1)] [&>span[data-testid='button-icon']_svg]:text-[#00C752]",
|
|
34
|
+
"ghost-warning": "bg-transparent text-[#FFB200] hover:bg-[rgba(255,178,0,0.06)] active:bg-[rgba(255,178,0,0.1)] [&>span[data-testid='button-icon']_svg]:text-[#FFB200]",
|
|
35
|
+
"ghost-informative": "bg-transparent text-[#4389FF] hover:bg-[rgba(67,137,255,0.06)] active:bg-[rgba(67,137,255,0.1)] [&>span[data-testid='button-icon']_svg]:text-[#4389FF]",
|
|
36
|
+
// Legacy/Custom
|
|
37
|
+
blue: "bg-[#4389FF] text-white hover:bg-[#4389FF]/90 active:bg-[#4389FF]/80",
|
|
38
|
+
disabled: "bg-[rgba(0,0,0,0.12)] text-[rgba(0,0,0,0.38)] cursor-not-allowed hover:bg-[rgba(0,0,0,0.12)]",
|
|
39
|
+
brandBlue: "bg-brandBlue text-white hover:bg-brandBlue/90 active:bg-brandBlue/80"
|
|
40
|
+
},
|
|
41
|
+
size: {
|
|
42
|
+
large: "rounded-[12px] text-[16px] leading-[22px] py-[10px] px-[20px] font-semibold gap-[10px]",
|
|
43
|
+
medium: "rounded-[10px] text-[14px] leading-[20px] py-[8px] px-[16px] font-semibold gap-[10px]",
|
|
44
|
+
small: "rounded-full text-[12px] leading-[16px] py-[9px] px-[12px] font-semibold gap-[10px]",
|
|
45
|
+
"icon.large": "rounded-[12px] p-[10px]",
|
|
46
|
+
"icon.medium": "rounded-[10px] p-[8px]",
|
|
47
|
+
"icon.small": "rounded-full p-[5px]"
|
|
48
|
+
},
|
|
49
|
+
iconSize: {
|
|
50
|
+
large: "[&_svg]:w-6 [&_svg]:h-6",
|
|
51
|
+
medium: "[&_svg]:w-5 [&_svg]:h-5",
|
|
52
|
+
small: "[&_svg]:w-4 [&_svg]:h-4"
|
|
53
|
+
},
|
|
54
|
+
iconPosition: {
|
|
55
|
+
left: "flex-row",
|
|
56
|
+
right: "flex-row-reverse"
|
|
57
|
+
},
|
|
58
|
+
fullWidth: {
|
|
59
|
+
true: "w-full",
|
|
60
|
+
false: "w-auto"
|
|
61
|
+
}
|
|
62
|
+
},
|
|
63
|
+
compoundVariants: [
|
|
64
|
+
// Adjust padding for outlined buttons to compensate for border-2
|
|
65
|
+
{
|
|
66
|
+
variant: ["outline", "outline-error", "outline-success", "outline-warning", "outline-informative"],
|
|
67
|
+
size: "large",
|
|
68
|
+
className: "py-[8px] px-[18px]"
|
|
69
|
+
},
|
|
70
|
+
{
|
|
71
|
+
variant: ["outline", "outline-error", "outline-success", "outline-warning", "outline-informative"],
|
|
72
|
+
size: "medium",
|
|
73
|
+
className: "py-[6px] px-[14px]"
|
|
74
|
+
},
|
|
75
|
+
{
|
|
76
|
+
variant: ["outline", "outline-error", "outline-success", "outline-warning", "outline-informative"],
|
|
77
|
+
size: "small",
|
|
78
|
+
className: "py-[7px] px-[10px]"
|
|
79
|
+
},
|
|
80
|
+
{
|
|
81
|
+
variant: ["outline", "outline-error", "outline-success", "outline-warning", "outline-informative"],
|
|
82
|
+
size: "icon.large",
|
|
83
|
+
className: "p-[8px]"
|
|
84
|
+
},
|
|
85
|
+
{
|
|
86
|
+
variant: ["outline", "outline-error", "outline-success", "outline-warning", "outline-informative"],
|
|
87
|
+
size: "icon.medium",
|
|
88
|
+
className: "p-[6px]"
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
variant: ["outline", "outline-error", "outline-success", "outline-warning", "outline-informative"],
|
|
92
|
+
size: "icon.small",
|
|
93
|
+
className: "p-[3px]"
|
|
94
|
+
}
|
|
95
|
+
],
|
|
96
|
+
defaultVariants: {
|
|
97
|
+
variant: "default",
|
|
98
|
+
size: "medium",
|
|
99
|
+
iconPosition: "left",
|
|
100
|
+
fullWidth: !1
|
|
101
|
+
}
|
|
102
|
+
}), K = {
|
|
103
|
+
small: {
|
|
104
|
+
outlined: {
|
|
105
|
+
left: "pl-[8px] pr-[10px] py-[5px]",
|
|
106
|
+
right: "pl-[10px] pr-[8px] py-[5px]"
|
|
107
|
+
},
|
|
108
|
+
filled: {
|
|
109
|
+
left: "pl-[10px] pr-[12px] py-[6px]",
|
|
110
|
+
right: "pl-[12px] pr-[10px] py-[6px]"
|
|
111
|
+
}
|
|
112
|
+
},
|
|
113
|
+
medium: {
|
|
114
|
+
outlined: {
|
|
115
|
+
left: "pl-[10px] pr-[14px] py-[6px]",
|
|
116
|
+
right: "pl-[14px] pr-[10px] py-[6px]"
|
|
117
|
+
},
|
|
118
|
+
filled: {
|
|
119
|
+
left: "pl-[12px] pr-[16px] py-[8px]",
|
|
120
|
+
right: "pl-[16px] pr-[12px] py-[8px]"
|
|
121
|
+
}
|
|
122
|
+
},
|
|
123
|
+
large: {
|
|
124
|
+
outlined: {
|
|
125
|
+
left: "pl-[14px] pr-[18px] py-[8px]",
|
|
126
|
+
right: "pl-[18px] pr-[14px] py-[8px]"
|
|
127
|
+
},
|
|
128
|
+
filled: {
|
|
129
|
+
left: "pl-[16px] pr-[20px] py-[10px]",
|
|
130
|
+
right: "pl-[20px] pr-[16px] py-[10px]"
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
}, Q = {
|
|
134
|
+
small: "[&_svg]:w-[18px] [&_svg]:h-[18px]",
|
|
135
|
+
medium: "[&_svg]:w-[20px] [&_svg]:h-[20px]",
|
|
136
|
+
large: "[&_svg]:w-[24px] [&_svg]:h-[24px]"
|
|
137
|
+
}, U = $.forwardRef((g, N) => {
|
|
138
|
+
var W, M;
|
|
139
|
+
const t = Y(53);
|
|
140
|
+
let h, p, b, o, a, r, s, y, l, e, i, c, w, _, n;
|
|
141
|
+
t[0] !== g ? ({
|
|
142
|
+
className: p,
|
|
143
|
+
variant: n,
|
|
144
|
+
size: i,
|
|
145
|
+
iconSize: y,
|
|
146
|
+
iconPosition: s,
|
|
147
|
+
fullWidth: b,
|
|
148
|
+
asChild: w,
|
|
149
|
+
icon: o,
|
|
150
|
+
iconOnly: r,
|
|
151
|
+
children: h,
|
|
152
|
+
type: _,
|
|
153
|
+
style: c,
|
|
154
|
+
outlineColor: l,
|
|
155
|
+
iconColor: a,
|
|
156
|
+
...e
|
|
157
|
+
} = g, t[0] = g, t[1] = h, t[2] = p, t[3] = b, t[4] = o, t[5] = a, t[6] = r, t[7] = s, t[8] = y, t[9] = l, t[10] = e, t[11] = i, t[12] = c, t[13] = w, t[14] = _, t[15] = n) : (h = t[1], p = t[2], b = t[3], o = t[4], a = t[5], r = t[6], s = t[7], y = t[8], l = t[9], e = t[10], i = t[11], c = t[12], w = t[13], _ = t[14], n = t[15]);
|
|
158
|
+
const d = w === void 0 ? !1 : w, A = d ? q : "button";
|
|
159
|
+
let x = i;
|
|
160
|
+
if (r && i)
|
|
161
|
+
t: switch (i) {
|
|
162
|
+
case "large": {
|
|
163
|
+
x = "icon.large";
|
|
164
|
+
break t;
|
|
165
|
+
}
|
|
166
|
+
case "medium": {
|
|
167
|
+
x = "icon.medium";
|
|
168
|
+
break t;
|
|
169
|
+
}
|
|
170
|
+
case "small":
|
|
171
|
+
x = "icon.small";
|
|
172
|
+
}
|
|
173
|
+
const S = y || (i === "large" ? "large" : i === "small" ? "small" : "medium");
|
|
174
|
+
let F = "";
|
|
175
|
+
if (o && !r && h && i) {
|
|
176
|
+
const R = n != null && n.includes("outline") ? "outlined" : "filled", G = s || "left";
|
|
177
|
+
F = ((M = (W = K[i]) == null ? void 0 : W[R]) == null ? void 0 : M[G]) || "";
|
|
178
|
+
}
|
|
179
|
+
const E = r && i ? Q[i] : "";
|
|
180
|
+
let u;
|
|
181
|
+
t[16] !== l ? (u = l && {
|
|
182
|
+
borderColor: l
|
|
183
|
+
}, t[16] = l, t[17] = u) : u = t[17];
|
|
184
|
+
let v;
|
|
185
|
+
t[18] !== a ? (v = a && {
|
|
186
|
+
"--icon-color": a
|
|
187
|
+
}, t[18] = a, t[19] = v) : v = t[19];
|
|
188
|
+
let C;
|
|
189
|
+
t[20] !== c || t[21] !== u || t[22] !== v ? (C = {
|
|
190
|
+
...c,
|
|
191
|
+
...u,
|
|
192
|
+
...v
|
|
193
|
+
}, t[20] = c, t[21] = u, t[22] = v, t[23] = C) : C = t[23];
|
|
194
|
+
const P = C;
|
|
195
|
+
let z;
|
|
196
|
+
t[24] !== x || t[25] !== p || t[26] !== b || t[27] !== a || t[28] !== E || t[29] !== F || t[30] !== s || t[31] !== S || t[32] !== n ? (z = H(J({
|
|
197
|
+
variant: n,
|
|
198
|
+
size: x,
|
|
199
|
+
iconSize: S,
|
|
200
|
+
iconPosition: s,
|
|
201
|
+
fullWidth: b,
|
|
202
|
+
className: p
|
|
203
|
+
}), a && "[&>span[data-testid='button-icon']_svg]:text-[var(--icon-color)]", F, E), t[24] = x, t[25] = p, t[26] = b, t[27] = a, t[28] = E, t[29] = F, t[30] = s, t[31] = S, t[32] = n, t[33] = z) : z = t[33];
|
|
204
|
+
const k = z, D = d ? void 0 : _ ?? "button", I = d ? void 0 : e.disabled, O = e.disabled || void 0, j = r && !e["aria-label"] ? "Icon button" : e["aria-label"];
|
|
205
|
+
let m;
|
|
206
|
+
t[34] !== d || t[35] !== e.disabled || t[36] !== e.onClick ? (m = d && e.disabled ? X : e.onClick, t[34] = d, t[35] = e.disabled, t[36] = e.onClick, t[37] = m) : m = t[37];
|
|
207
|
+
let f;
|
|
208
|
+
t[38] !== o ? (f = o && /* @__PURE__ */ L("span", { "data-testid": "button-icon", children: o }), t[38] = o, t[39] = f) : f = t[39];
|
|
209
|
+
const V = !r && h;
|
|
210
|
+
let B;
|
|
211
|
+
return t[40] !== A || t[41] !== k || t[42] !== P || t[43] !== e || t[44] !== N || t[45] !== m || t[46] !== f || t[47] !== V || t[48] !== D || t[49] !== I || t[50] !== O || t[51] !== j ? (B = /* @__PURE__ */ T(A, { className: k, style: P, ref: N, ...e, type: D, disabled: I, "aria-disabled": O, "aria-label": j, onClick: m, children: [
|
|
212
|
+
f,
|
|
213
|
+
V
|
|
214
|
+
] }), t[40] = A, t[41] = k, t[42] = P, t[43] = e, t[44] = N, t[45] = m, t[46] = f, t[47] = V, t[48] = D, t[49] = I, t[50] = O, t[51] = j, t[52] = B) : B = t[52], B;
|
|
215
|
+
});
|
|
216
|
+
U.displayName = "DoctButton";
|
|
217
|
+
function X(g) {
|
|
218
|
+
g.preventDefault(), g.stopPropagation();
|
|
219
|
+
}
|
|
220
|
+
export {
|
|
221
|
+
U as DoctButton,
|
|
222
|
+
J as DoctButtonVariants
|
|
223
|
+
};
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx as l } from "react/jsx-runtime";
|
|
3
|
+
import { c as C } from "react-compiler-runtime";
|
|
4
|
+
import { ChevronLeftIcon as D, ChevronRightIcon as j, ChevronDownIcon as B } from "lucide-react";
|
|
5
|
+
import * as _ from "react";
|
|
6
|
+
import { getDefaultClassNames as y, DayPicker as R } from "react-day-picker";
|
|
7
|
+
import { DoctButton as S, DoctButtonVariants as h } from "./button.js";
|
|
8
|
+
import { cn as t } from "../../lib/utils.js";
|
|
9
|
+
function W({
|
|
10
|
+
className: m,
|
|
11
|
+
classNames: e,
|
|
12
|
+
showOutsideDays: i = !0,
|
|
13
|
+
captionLayout: o = "label",
|
|
14
|
+
buttonVariant: a = "ghost",
|
|
15
|
+
formatters: s,
|
|
16
|
+
components: p,
|
|
17
|
+
...g
|
|
18
|
+
}) {
|
|
19
|
+
const r = y();
|
|
20
|
+
return /* @__PURE__ */ l(R, { showOutsideDays: i, className: t("bg-background group/calendar p-3 [--cell-size:2rem] [[data-slot=card-content]_&]:bg-transparent [[data-slot=popover-content]_&]:bg-transparent", String.raw`rtl:**:[.rdp-button\_next>svg]:rotate-180`, String.raw`rtl:**:[.rdp-button\_previous>svg]:rotate-180`, m), captionLayout: o, formatters: {
|
|
21
|
+
formatMonthDropdown: (n) => n.toLocaleString("default", {
|
|
22
|
+
month: "short"
|
|
23
|
+
}),
|
|
24
|
+
...s
|
|
25
|
+
}, classNames: {
|
|
26
|
+
root: t("w-fit", r.root),
|
|
27
|
+
months: t("relative flex flex-col gap-4 md:flex-row", r.months),
|
|
28
|
+
month: t("flex w-full flex-col gap-4", r.month),
|
|
29
|
+
nav: t("absolute inset-x-0 top-0 flex w-full items-center justify-between gap-1", r.nav),
|
|
30
|
+
button_previous: t(h({
|
|
31
|
+
variant: a
|
|
32
|
+
}), "h-[--cell-size] w-[--cell-size] select-none p-0 aria-disabled:opacity-50", r.button_previous),
|
|
33
|
+
button_next: t(h({
|
|
34
|
+
variant: a
|
|
35
|
+
}), "h-[--cell-size] w-[--cell-size] select-none p-0 aria-disabled:opacity-50", r.button_next),
|
|
36
|
+
month_caption: t("flex h-[--cell-size] w-full items-center justify-center px-[--cell-size]", r.month_caption),
|
|
37
|
+
dropdowns: t("flex h-[--cell-size] w-full items-center justify-center gap-1.5 text-sm font-medium", r.dropdowns),
|
|
38
|
+
dropdown_root: t("has-focus:border-ring border-input shadow-xs has-focus:ring-ring/50 has-focus:ring-[3px] relative rounded-md border", r.dropdown_root),
|
|
39
|
+
dropdown: t("absolute inset-0 opacity-0", r.dropdown),
|
|
40
|
+
caption_label: t("select-none font-medium", o === "label" ? "text-sm" : "[&>svg]:text-muted-foreground flex h-8 items-center gap-1 rounded-md pl-2 pr-1 text-sm [&>svg]:size-3.5", r.caption_label),
|
|
41
|
+
table: "w-full border-collapse",
|
|
42
|
+
weekdays: t("flex", r.weekdays),
|
|
43
|
+
weekday: t("text-muted-foreground flex-1 select-none rounded-md text-[0.8rem] font-normal", r.weekday),
|
|
44
|
+
week: t("mt-2 flex w-full", r.week),
|
|
45
|
+
week_number_header: t("w-[--cell-size] select-none", r.week_number_header),
|
|
46
|
+
week_number: t("text-muted-foreground select-none text-[0.8rem]", r.week_number),
|
|
47
|
+
day: t("group/day relative aspect-square h-full w-full select-none p-0 text-center [&:first-child[data-selected=true]_button]:rounded-l-md [&:last-child[data-selected=true]_button]:rounded-r-md", r.day),
|
|
48
|
+
range_start: t("bg-accent rounded-l-md", r.range_start),
|
|
49
|
+
range_middle: t("rounded-none", r.range_middle),
|
|
50
|
+
range_end: t("bg-accent rounded-r-md", r.range_end),
|
|
51
|
+
today: t("bg-accent text-accent-foreground rounded-md data-[selected=true]:rounded-none", r.today),
|
|
52
|
+
outside: t("text-muted-foreground aria-selected:text-muted-foreground", r.outside),
|
|
53
|
+
disabled: t("text-muted-foreground opacity-50", r.disabled),
|
|
54
|
+
hidden: t("invisible", r.hidden),
|
|
55
|
+
...e
|
|
56
|
+
}, components: {
|
|
57
|
+
Root: ({
|
|
58
|
+
className: n,
|
|
59
|
+
rootRef: d,
|
|
60
|
+
...u
|
|
61
|
+
}) => /* @__PURE__ */ l("div", { "data-slot": "calendar", ref: d, className: t(n), ...u }),
|
|
62
|
+
Chevron: ({
|
|
63
|
+
className: n,
|
|
64
|
+
orientation: d,
|
|
65
|
+
...u
|
|
66
|
+
}) => d === "left" ? /* @__PURE__ */ l(D, { className: t("size-4", n), ...u }) : d === "right" ? /* @__PURE__ */ l(j, { className: t("size-4", n), ...u }) : /* @__PURE__ */ l(B, { className: t("size-4", n), ...u }),
|
|
67
|
+
DayButton: I,
|
|
68
|
+
WeekNumber: ({
|
|
69
|
+
children: n,
|
|
70
|
+
...d
|
|
71
|
+
}) => /* @__PURE__ */ l("td", { ...d, children: /* @__PURE__ */ l("div", { className: "flex size-[--cell-size] items-center justify-center text-center", children: n }) }),
|
|
72
|
+
...p
|
|
73
|
+
}, ...g });
|
|
74
|
+
}
|
|
75
|
+
function I(m) {
|
|
76
|
+
const e = C(19);
|
|
77
|
+
let i, o, a, s;
|
|
78
|
+
e[0] !== m ? ({
|
|
79
|
+
className: i,
|
|
80
|
+
day: o,
|
|
81
|
+
modifiers: a,
|
|
82
|
+
...s
|
|
83
|
+
} = m, e[0] = m, e[1] = i, e[2] = o, e[3] = a, e[4] = s) : (i = e[1], o = e[2], a = e[3], s = e[4]);
|
|
84
|
+
const p = y(), g = _.useRef(null);
|
|
85
|
+
let r, n;
|
|
86
|
+
e[5] !== a.focused ? (r = () => {
|
|
87
|
+
var w;
|
|
88
|
+
a.focused && ((w = g.current) == null || w.focus());
|
|
89
|
+
}, n = [a.focused], e[5] = a.focused, e[6] = r, e[7] = n) : (r = e[6], n = e[7]), _.useEffect(r, n);
|
|
90
|
+
const d = S, u = "ghost", v = "icon.small";
|
|
91
|
+
let c;
|
|
92
|
+
e[8] !== o.date ? (c = o.date.toLocaleDateString(), e[8] = o.date, e[9] = c) : c = e[9];
|
|
93
|
+
const x = a.selected && !a.range_start && !a.range_end && !a.range_middle, z = a.range_start, k = a.range_end, N = a.range_middle, b = t("flex aspect-square h-auto w-full min-w-[--cell-size] flex-col gap-1 font-normal leading-none", "data-[selected-single=true]:bg-primary data-[selected-single=true]:text-primary-foreground", "data-[range-middle=true]:bg-accent data-[range-middle=true]:text-accent-foreground data-[range-start=true]:bg-primary data-[range-start=true]:text-primary-foreground data-[range-end=true]:bg-primary data-[range-end=true]:text-primary-foreground", "data-[range-end=true]:rounded-md data-[range-middle=true]:rounded-none data-[range-start=true]:rounded-md", "group-data-[focused=true]/day:relative group-data-[focused=true]/day:z-10 group-data-[focused=true]/day:border-ring group-data-[focused=true]/day:ring-ring/50 group-data-[focused=true]/day:ring-[3px]", "[&>span]:text-xs [&>span]:opacity-70", p.day, i);
|
|
94
|
+
let f;
|
|
95
|
+
return e[10] !== d || e[11] !== a.range_end || e[12] !== a.range_middle || e[13] !== a.range_start || e[14] !== s || e[15] !== b || e[16] !== c || e[17] !== x ? (f = /* @__PURE__ */ l(d, { ref: g, variant: u, size: v, "data-day": c, "data-selected-single": x, "data-range-start": z, "data-range-end": k, "data-range-middle": N, className: b, ...s }), e[10] = d, e[11] = a.range_end, e[12] = a.range_middle, e[13] = a.range_start, e[14] = s, e[15] = b, e[16] = c, e[17] = x, e[18] = f) : f = e[18], f;
|
|
96
|
+
}
|
|
97
|
+
export {
|
|
98
|
+
W as Calendar,
|
|
99
|
+
I as CalendarDayButton
|
|
100
|
+
};
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx as B } from "react/jsx-runtime";
|
|
3
|
+
import { c as E } from "react-compiler-runtime";
|
|
4
|
+
import { Checkbox as q } from "@base-ui/react/checkbox";
|
|
5
|
+
import { Minus as F, Check as M } from "lucide-react";
|
|
6
|
+
import * as P from "react";
|
|
7
|
+
import { cn as T } from "../../lib/utils.js";
|
|
8
|
+
const U = "#029cfd", V = P.forwardRef((R, I) => {
|
|
9
|
+
const e = E(47);
|
|
10
|
+
let g, r, t, k, s, c, n, o, a, d, f;
|
|
11
|
+
e[0] !== R ? ({
|
|
12
|
+
className: t,
|
|
13
|
+
color: k,
|
|
14
|
+
borderColor: g,
|
|
15
|
+
checked: r,
|
|
16
|
+
defaultChecked: s,
|
|
17
|
+
onCheckedChange: o,
|
|
18
|
+
disabled: c,
|
|
19
|
+
required: a,
|
|
20
|
+
name: n,
|
|
21
|
+
value: f,
|
|
22
|
+
...d
|
|
23
|
+
} = R, e[0] = R, e[1] = g, e[2] = r, e[3] = t, e[4] = k, e[5] = s, e[6] = c, e[7] = n, e[8] = o, e[9] = a, e[10] = d, e[11] = f) : (g = e[1], r = e[2], t = e[3], k = e[4], s = e[5], c = e[6], n = e[7], o = e[8], a = e[9], d = e[10], f = e[11]);
|
|
24
|
+
const A = k !== void 0, x = k ?? U, j = g ?? x, i = r === "indeterminate", L = r !== void 0, N = i ? !1 : r === !0;
|
|
25
|
+
let l;
|
|
26
|
+
e[12] !== N || e[13] !== s || e[14] !== L ? (l = {}, L && (l.checked = N), s !== void 0 && (l.defaultChecked = s), e[12] = N, e[13] = s, e[14] = L, e[15] = l) : l = e[15];
|
|
27
|
+
let p;
|
|
28
|
+
e[16] !== t ? (p = t == null ? void 0 : t.includes("bg-"), e[16] = t, e[17] = p) : p = e[17];
|
|
29
|
+
const v = A || !p;
|
|
30
|
+
let h;
|
|
31
|
+
e[18] !== t ? (h = !(t != null && t.match(/\bh-\d/)) && "h-4 w-4", e[18] = t, e[19] = h) : h = e[19];
|
|
32
|
+
const O = v && "data-[checked]:bg-[var(--checkbox-bg)] data-[indeterminate]:bg-[var(--checkbox-bg)]";
|
|
33
|
+
let u;
|
|
34
|
+
e[20] !== t || e[21] !== h || e[22] !== O ? (u = T("peer shrink-0 rounded-sm border cursor-pointer ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 data-[disabled]:cursor-not-allowed data-[disabled]:opacity-50", "data-[checked]:text-white data-[indeterminate]:text-white", h, O, t), e[20] = t, e[21] = h, e[22] = O, e[23] = u) : u = e[23];
|
|
35
|
+
let b;
|
|
36
|
+
e[24] !== x || e[25] !== v ? (b = v ? {
|
|
37
|
+
"--checkbox-bg": x
|
|
38
|
+
} : {}, e[24] = x, e[25] = v, e[26] = b) : b = e[26];
|
|
39
|
+
let w;
|
|
40
|
+
e[27] !== j || e[28] !== b ? (w = {
|
|
41
|
+
borderColor: j,
|
|
42
|
+
...b
|
|
43
|
+
}, e[27] = j, e[28] = b, e[29] = w) : w = e[29];
|
|
44
|
+
const $ = w;
|
|
45
|
+
let m;
|
|
46
|
+
e[30] !== o ? (m = (D) => {
|
|
47
|
+
o == null || o(D);
|
|
48
|
+
}, e[30] = o, e[31] = m) : m = e[31];
|
|
49
|
+
let C;
|
|
50
|
+
e[32] !== i ? (C = /* @__PURE__ */ B(q.Indicator, { className: "flex h-full w-full items-center justify-center text-current", children: i ? /* @__PURE__ */ B(F, { className: "h-4 w-4 text-white" }) : /* @__PURE__ */ B(M, { className: "h-4 w-4" }) }), e[32] = i, e[33] = C) : C = e[33];
|
|
51
|
+
let y;
|
|
52
|
+
return e[34] !== l || e[35] !== c || e[36] !== i || e[37] !== n || e[38] !== I || e[39] !== a || e[40] !== d || e[41] !== u || e[42] !== $ || e[43] !== m || e[44] !== C || e[45] !== f ? (y = /* @__PURE__ */ B(q.Root, { ref: I, className: u, style: $, indeterminate: i, onCheckedChange: m, disabled: c, required: a, name: n, value: f, ...d, ...l, children: C }), e[34] = l, e[35] = c, e[36] = i, e[37] = n, e[38] = I, e[39] = a, e[40] = d, e[41] = u, e[42] = $, e[43] = m, e[44] = C, e[45] = f, e[46] = y) : y = e[46], y;
|
|
53
|
+
});
|
|
54
|
+
V.displayName = "Checkbox";
|
|
55
|
+
export {
|
|
56
|
+
V as Checkbox
|
|
57
|
+
};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx as n } from "react/jsx-runtime";
|
|
3
|
+
import { c as m } from "react-compiler-runtime";
|
|
4
|
+
import { Collapsible as r } from "@base-ui/react/collapsible";
|
|
5
|
+
import * as c from "react";
|
|
6
|
+
import { cn as f } from "../../lib/utils.js";
|
|
7
|
+
const w = r.Root, N = r.Trigger, b = c.forwardRef((s, p) => {
|
|
8
|
+
const e = m(9);
|
|
9
|
+
let l, o;
|
|
10
|
+
e[0] !== s ? ({
|
|
11
|
+
className: l,
|
|
12
|
+
...o
|
|
13
|
+
} = s, e[0] = s, e[1] = l, e[2] = o) : (l = e[1], o = e[2]);
|
|
14
|
+
const i = p;
|
|
15
|
+
let t;
|
|
16
|
+
e[3] !== l ? (t = f("overflow-hidden data-[closed]:animate-collapsible-up data-[open]:animate-collapsible-down", l), e[3] = l, e[4] = t) : t = e[4];
|
|
17
|
+
let a;
|
|
18
|
+
return e[5] !== o || e[6] !== i || e[7] !== t ? (a = /* @__PURE__ */ n(r.Panel, { ref: i, className: t, ...o }), e[5] = o, e[6] = i, e[7] = t, e[8] = a) : a = e[8], a;
|
|
19
|
+
});
|
|
20
|
+
b.displayName = "CollapsibleContent";
|
|
21
|
+
export {
|
|
22
|
+
w as Collapsible,
|
|
23
|
+
b as CollapsibleContent,
|
|
24
|
+
N as CollapsibleTrigger
|
|
25
|
+
};
|
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx as d, jsxs as f } from "react/jsx-runtime";
|
|
3
|
+
import { c as n } from "react-compiler-runtime";
|
|
4
|
+
import { Command as r } from "cmdk";
|
|
5
|
+
import { Search as g } from "lucide-react";
|
|
6
|
+
import * as i from "react";
|
|
7
|
+
import { DialogContent as h, Dialog as x } from "./dialog.js";
|
|
8
|
+
import { cn as p } from "../../lib/utils.js";
|
|
9
|
+
const u = i.forwardRef((l, t) => {
|
|
10
|
+
const e = n(9);
|
|
11
|
+
let s, a;
|
|
12
|
+
e[0] !== l ? ({
|
|
13
|
+
className: s,
|
|
14
|
+
...a
|
|
15
|
+
} = l, e[0] = l, e[1] = s, e[2] = a) : (s = e[1], a = e[2]);
|
|
16
|
+
let o;
|
|
17
|
+
e[3] !== s ? (o = p("flex h-full w-full flex-col overflow-hidden rounded-md bg-popover text-popover-foreground", s), e[3] = s, e[4] = o) : o = e[4];
|
|
18
|
+
let m;
|
|
19
|
+
return e[5] !== a || e[6] !== t || e[7] !== o ? (m = /* @__PURE__ */ d(r, { ref: t, className: o, ...a }), e[5] = a, e[6] = t, e[7] = o, e[8] = m) : m = e[8], m;
|
|
20
|
+
});
|
|
21
|
+
u.displayName = r.displayName;
|
|
22
|
+
const E = (l) => {
|
|
23
|
+
const t = n(8);
|
|
24
|
+
let e, s;
|
|
25
|
+
t[0] !== l ? ({
|
|
26
|
+
children: e,
|
|
27
|
+
...s
|
|
28
|
+
} = l, t[0] = l, t[1] = e, t[2] = s) : (e = t[1], s = t[2]);
|
|
29
|
+
let a;
|
|
30
|
+
t[3] !== e ? (a = /* @__PURE__ */ d(h, { className: "overflow-hidden p-0 shadow-lg", children: /* @__PURE__ */ d(u, { className: "[&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0 [&_[cmdk-group]]:px-2 [&_[cmdk-input-wrapper]_svg]:h-5 [&_[cmdk-input-wrapper]_svg]:w-5 [&_[cmdk-input]]:h-12 [&_[cmdk-item]]:px-2 [&_[cmdk-item]]:py-3 [&_[cmdk-item]_svg]:h-5 [&_[cmdk-item]_svg]:w-5", children: e }) }), t[3] = e, t[4] = a) : a = t[4];
|
|
31
|
+
let o;
|
|
32
|
+
return t[5] !== s || t[6] !== a ? (o = /* @__PURE__ */ d(x, { ...s, children: a }), t[5] = s, t[6] = a, t[7] = o) : o = t[7], o;
|
|
33
|
+
}, N = i.forwardRef((l, t) => {
|
|
34
|
+
const e = n(10);
|
|
35
|
+
let s, a;
|
|
36
|
+
e[0] !== l ? ({
|
|
37
|
+
className: s,
|
|
38
|
+
...a
|
|
39
|
+
} = l, e[0] = l, e[1] = s, e[2] = a) : (s = e[1], a = e[2]);
|
|
40
|
+
let o;
|
|
41
|
+
e[3] === Symbol.for("react.memo_cache_sentinel") ? (o = /* @__PURE__ */ d(g, { strokeWidth: 1.25, className: "mr-2 h-4 w-4 shrink-0" }), e[3] = o) : o = e[3];
|
|
42
|
+
let m;
|
|
43
|
+
e[4] !== s ? (m = p("flex h-11 w-full rounded-md bg-transparent py-3 text-sm outline-none placeholder:text-gray-400 disabled:cursor-not-allowed disabled:opacity-50", s), e[4] = s, e[5] = m) : m = e[5];
|
|
44
|
+
let c;
|
|
45
|
+
return e[6] !== a || e[7] !== t || e[8] !== m ? (c = /* @__PURE__ */ f("div", { className: "flex items-center h-auto px-3", "cmdk-input-wrapper": "", children: [
|
|
46
|
+
o,
|
|
47
|
+
/* @__PURE__ */ d(r.Input, { ref: t, className: m, ...a })
|
|
48
|
+
] }), e[6] = a, e[7] = t, e[8] = m, e[9] = c) : c = e[9], c;
|
|
49
|
+
});
|
|
50
|
+
N.displayName = r.Input.displayName;
|
|
51
|
+
const y = i.forwardRef((l, t) => {
|
|
52
|
+
const e = n(9);
|
|
53
|
+
let s, a;
|
|
54
|
+
e[0] !== l ? ({
|
|
55
|
+
className: s,
|
|
56
|
+
...a
|
|
57
|
+
} = l, e[0] = l, e[1] = s, e[2] = a) : (s = e[1], a = e[2]);
|
|
58
|
+
let o;
|
|
59
|
+
e[3] !== s ? (o = p("max-h-[300px] overflow-y-auto overflow-x-hidden", s), e[3] = s, e[4] = o) : o = e[4];
|
|
60
|
+
let m;
|
|
61
|
+
return e[5] !== a || e[6] !== t || e[7] !== o ? (m = /* @__PURE__ */ d(r.List, { ref: t, className: o, ...a }), e[5] = a, e[6] = t, e[7] = o, e[8] = m) : m = e[8], m;
|
|
62
|
+
});
|
|
63
|
+
y.displayName = r.List.displayName;
|
|
64
|
+
const _ = i.forwardRef((l, t) => {
|
|
65
|
+
const e = n(3);
|
|
66
|
+
let s;
|
|
67
|
+
return e[0] !== l || e[1] !== t ? (s = /* @__PURE__ */ d(r.Empty, { ref: t, className: "py-6 text-center text-sm", ...l }), e[0] = l, e[1] = t, e[2] = s) : s = e[2], s;
|
|
68
|
+
});
|
|
69
|
+
_.displayName = r.Empty.displayName;
|
|
70
|
+
const k = i.forwardRef((l, t) => {
|
|
71
|
+
const e = n(9);
|
|
72
|
+
let s, a;
|
|
73
|
+
e[0] !== l ? ({
|
|
74
|
+
className: s,
|
|
75
|
+
...a
|
|
76
|
+
} = l, e[0] = l, e[1] = s, e[2] = a) : (s = e[1], a = e[2]);
|
|
77
|
+
let o;
|
|
78
|
+
e[3] !== s ? (o = p("overflow-hidden p-1 text-foreground [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground", s), e[3] = s, e[4] = o) : o = e[4];
|
|
79
|
+
let m;
|
|
80
|
+
return e[5] !== a || e[6] !== t || e[7] !== o ? (m = /* @__PURE__ */ d(r.Group, { ref: t, className: o, ...a }), e[5] = a, e[6] = t, e[7] = o, e[8] = m) : m = e[8], m;
|
|
81
|
+
});
|
|
82
|
+
k.displayName = r.Group.displayName;
|
|
83
|
+
const w = i.forwardRef((l, t) => {
|
|
84
|
+
const e = n(9);
|
|
85
|
+
let s, a;
|
|
86
|
+
e[0] !== l ? ({
|
|
87
|
+
className: s,
|
|
88
|
+
...a
|
|
89
|
+
} = l, e[0] = l, e[1] = s, e[2] = a) : (s = e[1], a = e[2]);
|
|
90
|
+
let o;
|
|
91
|
+
e[3] !== s ? (o = p("-mx-1 h-px bg-border", s), e[3] = s, e[4] = o) : o = e[4];
|
|
92
|
+
let m;
|
|
93
|
+
return e[5] !== a || e[6] !== t || e[7] !== o ? (m = /* @__PURE__ */ d(r.Separator, { ref: t, className: o, ...a }), e[5] = a, e[6] = t, e[7] = o, e[8] = m) : m = e[8], m;
|
|
94
|
+
});
|
|
95
|
+
w.displayName = r.Separator.displayName;
|
|
96
|
+
const v = i.forwardRef((l, t) => {
|
|
97
|
+
const e = n(9);
|
|
98
|
+
let s, a;
|
|
99
|
+
e[0] !== l ? ({
|
|
100
|
+
className: s,
|
|
101
|
+
...a
|
|
102
|
+
} = l, e[0] = l, e[1] = s, e[2] = a) : (s = e[1], a = e[2]);
|
|
103
|
+
let o;
|
|
104
|
+
e[3] !== s ? (o = p("relative flex cursor-default gap-2 select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none data-[disabled=true]:pointer-events-none data-[selected='true']:bg-accent data-[selected=true]:text-accent-foreground data-[disabled=true]:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0", s), e[3] = s, e[4] = o) : o = e[4];
|
|
105
|
+
let m;
|
|
106
|
+
return e[5] !== a || e[6] !== t || e[7] !== o ? (m = /* @__PURE__ */ d(r.Item, { ref: t, className: o, ...a }), e[5] = a, e[6] = t, e[7] = o, e[8] = m) : m = e[8], m;
|
|
107
|
+
});
|
|
108
|
+
v.displayName = r.Item.displayName;
|
|
109
|
+
const C = (l) => {
|
|
110
|
+
const t = n(8);
|
|
111
|
+
let e, s;
|
|
112
|
+
t[0] !== l ? ({
|
|
113
|
+
className: e,
|
|
114
|
+
...s
|
|
115
|
+
} = l, t[0] = l, t[1] = e, t[2] = s) : (e = t[1], s = t[2]);
|
|
116
|
+
let a;
|
|
117
|
+
t[3] !== e ? (a = p("ml-auto text-xs tracking-widest text-muted-foreground", e), t[3] = e, t[4] = a) : a = t[4];
|
|
118
|
+
let o;
|
|
119
|
+
return t[5] !== s || t[6] !== a ? (o = /* @__PURE__ */ d("span", { className: a, ...s }), t[5] = s, t[6] = a, t[7] = o) : o = t[7], o;
|
|
120
|
+
};
|
|
121
|
+
C.displayName = "CommandShortcut";
|
|
122
|
+
export {
|
|
123
|
+
u as Command,
|
|
124
|
+
E as CommandDialog,
|
|
125
|
+
_ as CommandEmpty,
|
|
126
|
+
k as CommandGroup,
|
|
127
|
+
N as CommandInput,
|
|
128
|
+
v as CommandItem,
|
|
129
|
+
y as CommandList,
|
|
130
|
+
w as CommandSeparator,
|
|
131
|
+
C as CommandShortcut
|
|
132
|
+
};
|