@underverse-ui/underverse 1.0.191 → 1.0.192
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/api-reference.json +1 -1
- package/dist/index.cjs +142 -93
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +14 -0
- package/dist/index.d.ts +14 -0
- package/dist/index.js +142 -93
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/api-reference.json
CHANGED
package/dist/index.cjs
CHANGED
|
@@ -3562,7 +3562,7 @@ var Textarea = (0, import_react4.forwardRef)(
|
|
|
3562
3562
|
required,
|
|
3563
3563
|
value,
|
|
3564
3564
|
maxLength,
|
|
3565
|
-
borderMode
|
|
3565
|
+
borderMode,
|
|
3566
3566
|
...props
|
|
3567
3567
|
}, ref) => {
|
|
3568
3568
|
const [isFocused, setIsFocused] = (0, import_react4.useState)(false);
|
|
@@ -6971,9 +6971,12 @@ var Modal = ({
|
|
|
6971
6971
|
noPadding = false,
|
|
6972
6972
|
fullWidth = false,
|
|
6973
6973
|
width,
|
|
6974
|
-
height
|
|
6974
|
+
height,
|
|
6975
|
+
borderMode
|
|
6975
6976
|
}) => {
|
|
6976
6977
|
const gi18n = useGlobalI18n();
|
|
6978
|
+
const globalConfig = useUnderverseUIConfig();
|
|
6979
|
+
const resolvedBorderMode = borderMode ?? globalConfig.borderMode;
|
|
6977
6980
|
const [isMounted, setIsMounted] = React22.useState(false);
|
|
6978
6981
|
const [isVisible, setIsVisible] = React22.useState(false);
|
|
6979
6982
|
const [isAnimating, setIsAnimating] = React22.useState(true);
|
|
@@ -7079,7 +7082,8 @@ var Modal = ({
|
|
|
7079
7082
|
{
|
|
7080
7083
|
ref: modalContentRef,
|
|
7081
7084
|
className: cn(
|
|
7082
|
-
"relative w-full
|
|
7085
|
+
"relative w-full border border-border/40 bg-card text-card-foreground shadow-xl",
|
|
7086
|
+
resolvedBorderMode ? getBorderRadiusClass(resolvedBorderMode) : "rounded-2xl md:rounded-3xl",
|
|
7083
7087
|
"transition-all duration-200 ease-out",
|
|
7084
7088
|
maxWidthClass,
|
|
7085
7089
|
fullWidth && "mx-0",
|
|
@@ -7587,7 +7591,8 @@ var Popover = ({
|
|
|
7587
7591
|
open,
|
|
7588
7592
|
onOpenChange,
|
|
7589
7593
|
matchTriggerWidth = false,
|
|
7590
|
-
contentWidth
|
|
7594
|
+
contentWidth,
|
|
7595
|
+
borderMode
|
|
7591
7596
|
}) => {
|
|
7592
7597
|
const isControlled = open !== void 0;
|
|
7593
7598
|
const [internalOpen, setInternalOpen] = React24.useState(false);
|
|
@@ -7596,6 +7601,8 @@ var Popover = ({
|
|
|
7596
7601
|
const panelRef = React24.useRef(null);
|
|
7597
7602
|
const lastAppliedRef = React24.useRef(null);
|
|
7598
7603
|
useShadCNAnimations();
|
|
7604
|
+
const globalConfig = useUnderverseUIConfig();
|
|
7605
|
+
const resolvedBorderMode = borderMode ?? globalConfig.popover?.borderMode ?? globalConfig.borderMode;
|
|
7599
7606
|
const isOpen = isControlled ? open : internalOpen;
|
|
7600
7607
|
const setIsOpen = React24.useCallback(
|
|
7601
7608
|
(next) => {
|
|
@@ -7776,7 +7783,8 @@ var Popover = ({
|
|
|
7776
7783
|
{
|
|
7777
7784
|
...contentProps,
|
|
7778
7785
|
className: cn(
|
|
7779
|
-
"rounded-2xl md:rounded-3xl
|
|
7786
|
+
resolvedBorderMode ? getBorderRadiusClass(resolvedBorderMode) : "rounded-2xl md:rounded-3xl",
|
|
7787
|
+
"border bg-popover text-popover-foreground shadow-md",
|
|
7780
7788
|
"backdrop-blur-sm bg-popover/95 border-border/60 p-4",
|
|
7781
7789
|
contentProps?.className,
|
|
7782
7790
|
contentClassName
|
|
@@ -8115,7 +8123,9 @@ var SlideOver = (props) => {
|
|
|
8115
8123
|
return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(Sheet, { ...props, side: "right", variant: "overlay", size: "lg" });
|
|
8116
8124
|
};
|
|
8117
8125
|
var BottomSheet = ({ snapPoints = ["25%", "50%", "90%"], defaultSnap = 1, ...props }) => {
|
|
8118
|
-
|
|
8126
|
+
const globalConfig = useUnderverseUIConfig();
|
|
8127
|
+
const isSquare = globalConfig.borderMode === "daewoo" || globalConfig.borderMode === "none";
|
|
8128
|
+
return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(Sheet, { ...props, side: "bottom", variant: "overlay", className: cn(isSquare ? "" : "rounded-t-3xl", props.className) });
|
|
8119
8129
|
};
|
|
8120
8130
|
var SidebarSheet = ({ navigation, children, ...props }) => {
|
|
8121
8131
|
return /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(Sheet, { ...props, side: "left", variant: "push", size: "md", children: [
|
|
@@ -8787,7 +8797,8 @@ var DropdownMenu = ({
|
|
|
8787
8797
|
disabled = false,
|
|
8788
8798
|
isOpen,
|
|
8789
8799
|
onOpenChange,
|
|
8790
|
-
items
|
|
8800
|
+
items,
|
|
8801
|
+
borderMode
|
|
8791
8802
|
}) => {
|
|
8792
8803
|
const [internalOpen, setInternalOpen] = (0, import_react17.useState)(false);
|
|
8793
8804
|
const open = isOpen !== void 0 ? isOpen : internalOpen;
|
|
@@ -8823,6 +8834,8 @@ var DropdownMenu = ({
|
|
|
8823
8834
|
item.scrollIntoView({ block: "nearest" });
|
|
8824
8835
|
}, [getEnabledMenuItems, setActiveIndex]);
|
|
8825
8836
|
useShadCNAnimations();
|
|
8837
|
+
const globalConfig = useUnderverseUIConfig();
|
|
8838
|
+
const resolvedBorderMode = borderMode ?? globalConfig.dropdownMenu?.borderMode ?? globalConfig.borderMode;
|
|
8826
8839
|
import_react17.default.useEffect(() => {
|
|
8827
8840
|
if (!open) return;
|
|
8828
8841
|
const handleKeyNav = (e) => {
|
|
@@ -8890,7 +8903,8 @@ var DropdownMenu = ({
|
|
|
8890
8903
|
animationDelay: open ? `${Math.min(index * 20, 200)}ms` : "0ms"
|
|
8891
8904
|
},
|
|
8892
8905
|
className: cn(
|
|
8893
|
-
"dropdown-item flex w-full items-center gap-2 px-2.5 py-1.5 text-sm
|
|
8906
|
+
"dropdown-item flex w-full items-center gap-2 px-2.5 py-1.5 text-sm",
|
|
8907
|
+
resolvedBorderMode ? getBorderRadiusClass(resolvedBorderMode) : "rounded-lg",
|
|
8894
8908
|
"outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background",
|
|
8895
8909
|
"hover:bg-accent hover:text-accent-foreground",
|
|
8896
8910
|
"focus:bg-accent focus:text-accent-foreground",
|
|
@@ -8946,6 +8960,7 @@ var DropdownMenu = ({
|
|
|
8946
8960
|
trigger: enhancedTrigger,
|
|
8947
8961
|
placement,
|
|
8948
8962
|
disabled,
|
|
8963
|
+
borderMode: resolvedBorderMode,
|
|
8949
8964
|
contentClassName: cn("p-1", contentClassName),
|
|
8950
8965
|
children: menuBody
|
|
8951
8966
|
}
|
|
@@ -8962,10 +8977,13 @@ var DropdownMenuItem = ({
|
|
|
8962
8977
|
active,
|
|
8963
8978
|
shortcut,
|
|
8964
8979
|
className,
|
|
8965
|
-
closeOnSelect
|
|
8980
|
+
closeOnSelect,
|
|
8981
|
+
borderMode
|
|
8966
8982
|
}) => {
|
|
8967
8983
|
const menu = import_react17.default.useContext(DropdownMenuContext);
|
|
8968
8984
|
const shouldCloseOnSelect = closeOnSelect ?? menu?.closeOnSelect ?? false;
|
|
8985
|
+
const globalConfig = useUnderverseUIConfig();
|
|
8986
|
+
const resolvedBorderMode = borderMode ?? globalConfig.dropdownMenu?.borderMode ?? globalConfig.borderMode;
|
|
8969
8987
|
return /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)(
|
|
8970
8988
|
"button",
|
|
8971
8989
|
{
|
|
@@ -8980,7 +8998,8 @@ var DropdownMenuItem = ({
|
|
|
8980
8998
|
"data-dropdown-menu-item": "",
|
|
8981
8999
|
tabIndex: -1,
|
|
8982
9000
|
className: cn(
|
|
8983
|
-
"flex w-full items-center gap-2 px-3 py-2 text-sm
|
|
9001
|
+
"flex w-full items-center gap-2 px-3 py-2 text-sm transition-colors group cursor-pointer",
|
|
9002
|
+
resolvedBorderMode ? getBorderRadiusClass(resolvedBorderMode) : "rounded-lg",
|
|
8984
9003
|
"hover:bg-accent hover:text-accent-foreground",
|
|
8985
9004
|
"focus:bg-accent focus:text-accent-foreground focus:outline-none",
|
|
8986
9005
|
"disabled:opacity-50 disabled:cursor-not-allowed",
|
|
@@ -9002,56 +9021,67 @@ var DropdownMenuItem = ({
|
|
|
9002
9021
|
);
|
|
9003
9022
|
};
|
|
9004
9023
|
var DropdownMenuSeparator = ({ className }) => /* @__PURE__ */ (0, import_jsx_runtime32.jsx)("div", { className: cn("h-px bg-border my-1", className) });
|
|
9005
|
-
var DropdownMenuSub = ({ label, icon: Icon, disabled, children }) =>
|
|
9006
|
-
|
|
9007
|
-
|
|
9008
|
-
|
|
9009
|
-
|
|
9010
|
-
|
|
9011
|
-
|
|
9012
|
-
|
|
9013
|
-
|
|
9014
|
-
|
|
9015
|
-
|
|
9016
|
-
|
|
9017
|
-
|
|
9018
|
-
|
|
9019
|
-
|
|
9020
|
-
|
|
9021
|
-
|
|
9022
|
-
|
|
9023
|
-
|
|
9024
|
-
|
|
9025
|
-
|
|
9026
|
-
|
|
9027
|
-
|
|
9028
|
-
|
|
9029
|
-
|
|
9030
|
-
)
|
|
9031
|
-
|
|
9032
|
-
|
|
9033
|
-
|
|
9034
|
-
|
|
9035
|
-
|
|
9036
|
-
|
|
9037
|
-
|
|
9038
|
-
|
|
9039
|
-
|
|
9040
|
-
|
|
9041
|
-
|
|
9042
|
-
|
|
9043
|
-
|
|
9044
|
-
|
|
9045
|
-
|
|
9046
|
-
|
|
9047
|
-
|
|
9048
|
-
|
|
9049
|
-
|
|
9050
|
-
|
|
9051
|
-
|
|
9052
|
-
|
|
9053
|
-
|
|
9054
|
-
)
|
|
9024
|
+
var DropdownMenuSub = ({ label, icon: Icon, disabled, borderMode, children }) => {
|
|
9025
|
+
const globalConfig = useUnderverseUIConfig();
|
|
9026
|
+
const resolvedBorderMode = borderMode ?? globalConfig.dropdownMenu?.borderMode ?? globalConfig.borderMode;
|
|
9027
|
+
return /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
|
|
9028
|
+
DropdownMenu,
|
|
9029
|
+
{
|
|
9030
|
+
trigger: /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)(
|
|
9031
|
+
"button",
|
|
9032
|
+
{
|
|
9033
|
+
type: "button",
|
|
9034
|
+
disabled,
|
|
9035
|
+
onMouseDown: (e) => e.preventDefault(),
|
|
9036
|
+
className: cn(
|
|
9037
|
+
"flex w-full items-center gap-2 px-3 py-2 text-sm transition-colors cursor-pointer",
|
|
9038
|
+
resolvedBorderMode ? getBorderRadiusClass(resolvedBorderMode) : "rounded-lg",
|
|
9039
|
+
"hover:bg-accent hover:text-accent-foreground",
|
|
9040
|
+
"focus:bg-accent focus:text-accent-foreground focus:outline-none",
|
|
9041
|
+
"disabled:opacity-50 disabled:cursor-not-allowed"
|
|
9042
|
+
),
|
|
9043
|
+
children: [
|
|
9044
|
+
Icon && /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(Icon, { className: "w-4 h-4 shrink-0 opacity-60" }),
|
|
9045
|
+
/* @__PURE__ */ (0, import_jsx_runtime32.jsx)("span", { className: "flex-1 text-left", children: label }),
|
|
9046
|
+
/* @__PURE__ */ (0, import_jsx_runtime32.jsx)(import_lucide_react14.ChevronRight, { className: "w-3 h-3 opacity-50" })
|
|
9047
|
+
]
|
|
9048
|
+
}
|
|
9049
|
+
),
|
|
9050
|
+
placement: "right",
|
|
9051
|
+
children
|
|
9052
|
+
}
|
|
9053
|
+
);
|
|
9054
|
+
};
|
|
9055
|
+
var SelectDropdown = ({ options, value, onChange, placeholder = "Select...", className, borderMode }) => {
|
|
9056
|
+
const globalConfig = useUnderverseUIConfig();
|
|
9057
|
+
const resolvedBorderMode = borderMode ?? globalConfig.dropdownMenu?.borderMode ?? globalConfig.borderMode;
|
|
9058
|
+
return /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
|
|
9059
|
+
DropdownMenu,
|
|
9060
|
+
{
|
|
9061
|
+
trigger: /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)(
|
|
9062
|
+
"button",
|
|
9063
|
+
{
|
|
9064
|
+
className: cn(
|
|
9065
|
+
"inline-flex items-center justify-between gap-2 px-3 py-2 text-sm border bg-background border-border/60",
|
|
9066
|
+
resolvedBorderMode ? getBorderRadiusClass(resolvedBorderMode) : "rounded-2xl",
|
|
9067
|
+
"hover:bg-accent/50",
|
|
9068
|
+
"focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background",
|
|
9069
|
+
className
|
|
9070
|
+
),
|
|
9071
|
+
children: [
|
|
9072
|
+
/* @__PURE__ */ (0, import_jsx_runtime32.jsx)("span", { className: "truncate max-w-64 text-foreground/90", children: value || placeholder }),
|
|
9073
|
+
/* @__PURE__ */ (0, import_jsx_runtime32.jsx)("svg", { width: "16", height: "16", viewBox: "0 0 20 20", fill: "none", className: "opacity-70", children: /* @__PURE__ */ (0, import_jsx_runtime32.jsx)("path", { d: "M6 8l4 4 4-4", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) })
|
|
9074
|
+
]
|
|
9075
|
+
}
|
|
9076
|
+
),
|
|
9077
|
+
items: options.map((option) => ({
|
|
9078
|
+
label: option,
|
|
9079
|
+
onClick: () => onChange(option)
|
|
9080
|
+
})),
|
|
9081
|
+
borderMode: resolvedBorderMode
|
|
9082
|
+
}
|
|
9083
|
+
);
|
|
9084
|
+
};
|
|
9055
9085
|
var DropdownMenu_default = DropdownMenu;
|
|
9056
9086
|
|
|
9057
9087
|
// src/components/Pagination.tsx
|
|
@@ -9136,6 +9166,9 @@ var Combobox = ({
|
|
|
9136
9166
|
maxInitialOptions,
|
|
9137
9167
|
showSearchPromptWhenEmptyQuery = false
|
|
9138
9168
|
}) => {
|
|
9169
|
+
const globalConfig = useUnderverseUIConfig();
|
|
9170
|
+
const resolvedBorderMode = borderMode ?? globalConfig.borderMode ?? "full";
|
|
9171
|
+
const radiusClass = getBorderRadiusClass(resolvedBorderMode);
|
|
9139
9172
|
const tv = useSmartTranslations("ValidationInput");
|
|
9140
9173
|
const gi18n = useGlobalI18n();
|
|
9141
9174
|
const placeholder = placeholderProp ?? gi18n.selectPlaceholder ?? "Select\u2026";
|
|
@@ -9345,7 +9378,7 @@ var Combobox = ({
|
|
|
9345
9378
|
{
|
|
9346
9379
|
"data-combobox-dropdown": true,
|
|
9347
9380
|
"data-state": open ? "open" : "closed",
|
|
9348
|
-
className: "w-full
|
|
9381
|
+
className: cn("w-full overflow-hidden", getBorderRadiusClass(resolvedBorderMode)),
|
|
9349
9382
|
children: [
|
|
9350
9383
|
enableSearch && /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("div", { className: cn("relative border-b border-border/30", size === "sm" ? "p-2" : size === "lg" ? "p-3" : "p-2.5"), children: /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)("div", { className: "relative", children: [
|
|
9351
9384
|
/* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
|
|
@@ -9487,9 +9520,6 @@ var Combobox = ({
|
|
|
9487
9520
|
filled: "border-0 bg-muted/50 hover:bg-muted/80"
|
|
9488
9521
|
};
|
|
9489
9522
|
const labelSize = size === "sm" ? "text-xs" : size === "lg" ? "text-base" : "text-sm";
|
|
9490
|
-
const globalConfig = useUnderverseUIConfig();
|
|
9491
|
-
const resolvedBorderMode = borderMode ?? globalConfig.borderMode ?? "full";
|
|
9492
|
-
const radiusClass = getBorderRadiusClass(resolvedBorderMode);
|
|
9493
9523
|
const verticalGap = size === "sm" ? "space-y-1.5" : "space-y-2";
|
|
9494
9524
|
const triggerButtonBaseProps = {
|
|
9495
9525
|
ref: triggerRef,
|
|
@@ -9620,12 +9650,13 @@ var Combobox = ({
|
|
|
9620
9650
|
placement: "bottom-start",
|
|
9621
9651
|
matchTriggerWidth: true,
|
|
9622
9652
|
className: "z-9999",
|
|
9623
|
-
|
|
9653
|
+
borderMode: resolvedBorderMode,
|
|
9654
|
+
contentClassName: "p-0 overflow-hidden",
|
|
9624
9655
|
children: dropdownBody
|
|
9625
9656
|
}
|
|
9626
9657
|
) : /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)("div", { className: "relative", children: [
|
|
9627
9658
|
triggerButtonInline,
|
|
9628
|
-
open && /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("div", { className: "absolute left-0 top-full mt-1 z-50 w-full", children: /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("div", { className: "
|
|
9659
|
+
open && /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("div", { className: "absolute left-0 top-full mt-1 z-50 w-full", children: /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("div", { className: cn("overflow-hidden border text-popover-foreground shadow-md backdrop-blur-sm bg-popover/95 border-border/60", getBorderRadiusClass(resolvedBorderMode)), children: dropdownBody }) })
|
|
9629
9660
|
] }),
|
|
9630
9661
|
(helperText || effectiveError) && /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)(
|
|
9631
9662
|
"p",
|
|
@@ -10899,10 +10930,10 @@ var DatePicker = ({
|
|
|
10899
10930
|
placement: "bottom-start",
|
|
10900
10931
|
disabled,
|
|
10901
10932
|
contentWidth: sizeStyles8[size].contentWidth,
|
|
10933
|
+
borderMode: resolvedBorderMode,
|
|
10902
10934
|
contentClassName: cn(
|
|
10903
10935
|
"p-0",
|
|
10904
10936
|
"backdrop-blur-xl bg-popover/95 border-border/40 shadow-2xl",
|
|
10905
|
-
"rounded-2xl md:rounded-3xl",
|
|
10906
10937
|
// Keep usable on small viewports (wheel scroll should stay within the popover if it overflows)
|
|
10907
10938
|
"max-w-[calc(100vw-1rem)] max-h-[calc(100vh-6rem)] overflow-auto overscroll-contain",
|
|
10908
10939
|
sizeStyles8[size].contentPadding,
|
|
@@ -11654,10 +11685,10 @@ var DateRangePicker = ({
|
|
|
11654
11685
|
placement: "bottom-start",
|
|
11655
11686
|
disabled,
|
|
11656
11687
|
contentWidth: sizeStyles8[size].contentWidth,
|
|
11688
|
+
borderMode: resolvedBorderMode,
|
|
11657
11689
|
contentClassName: cn(
|
|
11658
11690
|
"p-0",
|
|
11659
11691
|
"backdrop-blur-xl bg-popover/95 border-border/40 shadow-2xl",
|
|
11660
|
-
"rounded-2xl md:rounded-3xl",
|
|
11661
11692
|
"max-w-[calc(100vw-1rem)] max-h-[calc(100vh-6rem)] overflow-auto overscroll-contain",
|
|
11662
11693
|
sizeStyles8[size].contentPadding,
|
|
11663
11694
|
"animate-in fade-in-0 zoom-in-95 slide-in-from-top-2 duration-300"
|
|
@@ -12057,6 +12088,8 @@ var LunarDatePicker = ({
|
|
|
12057
12088
|
maxDate,
|
|
12058
12089
|
borderMode
|
|
12059
12090
|
}) => {
|
|
12091
|
+
const globalConfig = useUnderverseUIConfig();
|
|
12092
|
+
const resolvedBorderMode = borderMode ?? globalConfig.input?.borderMode ?? globalConfig.borderMode ?? "full";
|
|
12060
12093
|
const t = useSmartTranslations("DatePicker");
|
|
12061
12094
|
const tv = useSmartTranslations("ValidationInput");
|
|
12062
12095
|
const locale = useSmartLocale();
|
|
@@ -12581,12 +12614,12 @@ var LunarDatePicker = ({
|
|
|
12581
12614
|
open: isOpen,
|
|
12582
12615
|
onOpenChange: setIsOpen,
|
|
12583
12616
|
placement: "bottom-start",
|
|
12617
|
+
borderMode: resolvedBorderMode,
|
|
12584
12618
|
disabled,
|
|
12585
12619
|
contentWidth: sizeStyles8[size].contentWidth,
|
|
12586
12620
|
contentClassName: cn(
|
|
12587
12621
|
"p-0",
|
|
12588
12622
|
"backdrop-blur-xl bg-popover/95 border-border/40 shadow-2xl",
|
|
12589
|
-
"rounded-2xl md:rounded-3xl",
|
|
12590
12623
|
// Keep usable on small viewports (wheel scroll should stay within the popover if it overflows)
|
|
12591
12624
|
"max-w-[calc(100vw-1rem)] max-h-[calc(100vh-6rem)] overflow-auto overscroll-contain",
|
|
12592
12625
|
sizeStyles8[size].contentPadding,
|
|
@@ -12604,7 +12637,7 @@ var LunarDatePicker = ({
|
|
|
12604
12637
|
"aria-invalid": !!effectiveError,
|
|
12605
12638
|
className: cn(
|
|
12606
12639
|
"group flex w-full items-center justify-between border bg-background/80 backdrop-blur-sm",
|
|
12607
|
-
getBorderRadiusClass(
|
|
12640
|
+
getBorderRadiusClass(resolvedBorderMode),
|
|
12608
12641
|
sizeStyles8[size].trigger,
|
|
12609
12642
|
disabled ? "border-border/40 opacity-50 cursor-not-allowed" : [
|
|
12610
12643
|
"border-border/60 hover:border-primary/40",
|
|
@@ -13747,6 +13780,8 @@ function MonthYearPicker({
|
|
|
13747
13780
|
borderMode,
|
|
13748
13781
|
...rest
|
|
13749
13782
|
}) {
|
|
13783
|
+
const globalConfig = useUnderverseUIConfig();
|
|
13784
|
+
const resolvedBorderMode = borderMode ?? globalConfig.input?.borderMode ?? globalConfig.borderMode ?? "full";
|
|
13750
13785
|
const gi18n = useGlobalI18n();
|
|
13751
13786
|
const tv = useSmartTranslations("ValidationInput");
|
|
13752
13787
|
const now = /* @__PURE__ */ new Date();
|
|
@@ -13905,7 +13940,7 @@ function MonthYearPicker({
|
|
|
13905
13940
|
"aria-invalid": !!effectiveError,
|
|
13906
13941
|
className: cn(
|
|
13907
13942
|
"group flex w-full items-center justify-between border bg-background/80 backdrop-blur-sm",
|
|
13908
|
-
getBorderRadiusClass(
|
|
13943
|
+
getBorderRadiusClass(resolvedBorderMode),
|
|
13909
13944
|
sz.height,
|
|
13910
13945
|
sz.padding,
|
|
13911
13946
|
sz.text,
|
|
@@ -14087,7 +14122,8 @@ function MonthYearPicker({
|
|
|
14087
14122
|
{
|
|
14088
14123
|
className: cn(
|
|
14089
14124
|
panelSz.contentPadding,
|
|
14090
|
-
"rounded-2xl
|
|
14125
|
+
resolvedBorderMode ? getBorderRadiusClass(resolvedBorderMode) : "rounded-2xl md:rounded-3xl",
|
|
14126
|
+
"border bg-background/80 backdrop-blur-sm",
|
|
14091
14127
|
effectiveError ? "border-destructive/60 bg-destructive/5" : "border-border/50"
|
|
14092
14128
|
),
|
|
14093
14129
|
children: pickerContent
|
|
@@ -14128,7 +14164,8 @@ function MonthYearPicker({
|
|
|
14128
14164
|
contentWidth,
|
|
14129
14165
|
matchTriggerWidth,
|
|
14130
14166
|
disabled,
|
|
14131
|
-
|
|
14167
|
+
borderMode: resolvedBorderMode,
|
|
14168
|
+
contentClassName: cn(panelSz.contentPadding, compactPanel && "max-w-[calc(100vw-2rem)] p-4"),
|
|
14132
14169
|
children: pickerContent
|
|
14133
14170
|
}
|
|
14134
14171
|
),
|
|
@@ -15275,6 +15312,8 @@ function TimePicker({
|
|
|
15275
15312
|
}) {
|
|
15276
15313
|
const tv = useSmartTranslations("ValidationInput");
|
|
15277
15314
|
const gi18n = useGlobalI18n();
|
|
15315
|
+
const globalConfig = useUnderverseUIConfig();
|
|
15316
|
+
const resolvedBorderMode = borderMode ?? globalConfig.input?.borderMode ?? globalConfig.borderMode ?? "full";
|
|
15278
15317
|
const autoId = React38.useId();
|
|
15279
15318
|
const isControlled = value !== void 0;
|
|
15280
15319
|
const now = /* @__PURE__ */ new Date();
|
|
@@ -15612,7 +15651,7 @@ function TimePicker({
|
|
|
15612
15651
|
"aria-invalid": !!effectiveError,
|
|
15613
15652
|
className: cn(
|
|
15614
15653
|
"group flex w-full items-center justify-between border bg-background/80 backdrop-blur-sm",
|
|
15615
|
-
getBorderRadiusClass(
|
|
15654
|
+
getBorderRadiusClass(resolvedBorderMode),
|
|
15616
15655
|
sz.height,
|
|
15617
15656
|
sz.padding,
|
|
15618
15657
|
sz.text,
|
|
@@ -15993,7 +16032,8 @@ function TimePicker({
|
|
|
15993
16032
|
{
|
|
15994
16033
|
className: cn(
|
|
15995
16034
|
panelSz.contentPadding,
|
|
15996
|
-
"rounded-2xl md:rounded-3xl
|
|
16035
|
+
resolvedBorderMode ? getBorderRadiusClass(resolvedBorderMode) : "rounded-2xl md:rounded-3xl",
|
|
16036
|
+
"border bg-card/95 backdrop-blur-sm shadow-xl",
|
|
15997
16037
|
effectiveError ? "border-destructive/60 bg-destructive/5" : "border-border/60",
|
|
15998
16038
|
className
|
|
15999
16039
|
),
|
|
@@ -16049,10 +16089,11 @@ function TimePicker({
|
|
|
16049
16089
|
placement: "bottom-start",
|
|
16050
16090
|
matchTriggerWidth: shouldMatchTriggerWidth,
|
|
16051
16091
|
contentWidth: shouldMatchTriggerWidth ? void 0 : contentWidth,
|
|
16092
|
+
borderMode: resolvedBorderMode,
|
|
16052
16093
|
contentClassName: cn(
|
|
16053
16094
|
panelSz.contentPadding,
|
|
16054
|
-
compactPanel && "max-w-[calc(100vw-2rem)] p-4
|
|
16055
|
-
"
|
|
16095
|
+
compactPanel && "max-w-[calc(100vw-2rem)] p-4",
|
|
16096
|
+
"border bg-popover/98 backdrop-blur-md shadow-2xl",
|
|
16056
16097
|
effectiveError && "border-destructive/40",
|
|
16057
16098
|
success && !effectiveError && "border-success/40",
|
|
16058
16099
|
!effectiveError && !success && "border-border/60",
|
|
@@ -16095,6 +16136,8 @@ var DateTimePicker = ({
|
|
|
16095
16136
|
size = "md",
|
|
16096
16137
|
borderMode
|
|
16097
16138
|
}) => {
|
|
16139
|
+
const globalConfig = useUnderverseUIConfig();
|
|
16140
|
+
const resolvedBorderMode = borderMode ?? globalConfig.input?.borderMode ?? globalConfig.borderMode ?? "full";
|
|
16098
16141
|
const t = useSmartTranslations("DateTimePicker");
|
|
16099
16142
|
const tv = useSmartTranslations("ValidationInput");
|
|
16100
16143
|
const locale = useSmartLocale();
|
|
@@ -16274,7 +16317,7 @@ var DateTimePicker = ({
|
|
|
16274
16317
|
"aria-invalid": !!effectiveError,
|
|
16275
16318
|
className: cn(
|
|
16276
16319
|
"flex w-full items-center justify-between border border-input bg-background",
|
|
16277
|
-
getBorderRadiusClass(
|
|
16320
|
+
getBorderRadiusClass(resolvedBorderMode),
|
|
16278
16321
|
sizeStyles8[size].trigger,
|
|
16279
16322
|
"focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
|
|
16280
16323
|
disabled && "opacity-50 cursor-not-allowed",
|
|
@@ -16303,12 +16346,9 @@ var DateTimePicker = ({
|
|
|
16303
16346
|
]
|
|
16304
16347
|
}
|
|
16305
16348
|
),
|
|
16306
|
-
|
|
16307
|
-
|
|
16308
|
-
|
|
16309
|
-
"max-w-[calc(100vw-1rem)] max-h-[calc(100vh-6rem)] overflow-auto"
|
|
16310
|
-
),
|
|
16311
|
-
placement: "bottom-end",
|
|
16349
|
+
placement: "bottom-start",
|
|
16350
|
+
borderMode: resolvedBorderMode,
|
|
16351
|
+
contentClassName: "p-0 overflow-hidden w-auto flex flex-col md:flex-row max-w-[calc(100vw-1rem)] max-h-[calc(100vh-6rem)] overflow-auto",
|
|
16312
16352
|
children: [
|
|
16313
16353
|
/* @__PURE__ */ (0, import_jsx_runtime43.jsxs)("div", { className: "flex flex-col lg:flex-row divide-y lg:divide-y-0 lg:divide-x divide-border", children: [
|
|
16314
16354
|
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)("div", { className: sizeStyles8[size].padding, children: /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
|
|
@@ -19340,6 +19380,8 @@ var MultiCombobox = ({
|
|
|
19340
19380
|
maxInitialOptions,
|
|
19341
19381
|
showSearchPromptWhenEmptyQuery = false
|
|
19342
19382
|
}) => {
|
|
19383
|
+
const globalConfig = useUnderverseUIConfig();
|
|
19384
|
+
const resolvedBorderMode = borderMode ?? globalConfig.borderMode ?? "full";
|
|
19343
19385
|
const tv = useSmartTranslations("ValidationInput");
|
|
19344
19386
|
const gi18n = useGlobalI18n();
|
|
19345
19387
|
const placeholder = placeholderProp ?? gi18n.selectPlaceholder ?? "Select...";
|
|
@@ -19600,7 +19642,7 @@ var MultiCombobox = ({
|
|
|
19600
19642
|
item.value
|
|
19601
19643
|
);
|
|
19602
19644
|
};
|
|
19603
|
-
const dropdownBody = /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)("div", { "data-combobox-dropdown": true, "data-state": open ? "open" : "closed", className: "w-full
|
|
19645
|
+
const dropdownBody = /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)("div", { "data-combobox-dropdown": true, "data-state": open ? "open" : "closed", className: cn("w-full overflow-hidden", getBorderRadiusClass(resolvedBorderMode)), children: [
|
|
19604
19646
|
value.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)("div", { className: "px-3 py-2 border-b border-border/40 flex items-center justify-between bg-muted/30", children: [
|
|
19605
19647
|
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)("span", { className: "text-xs font-medium text-muted-foreground", children: maxSelected ? gi18n.selectedCountWithMax ? gi18n.selectedCountWithMax(value.length, maxSelected) : `${value.length} / ${maxSelected} max` : gi18n.itemSelectedCount ? gi18n.itemSelectedCount(value.length) : `${value.length} selected` }),
|
|
19606
19648
|
showClear && /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)(
|
|
@@ -19718,8 +19760,6 @@ var MultiCombobox = ({
|
|
|
19718
19760
|
const selectedOptions = value.map((v) => normalizedOptions.find((o) => o.value === v) ?? selectedOptionFallbackMap.get(v)).filter(Boolean);
|
|
19719
19761
|
const visibleTags = maxTagsVisible ? selectedOptions.slice(0, maxTagsVisible) : selectedOptions;
|
|
19720
19762
|
const hiddenCount = maxTagsVisible ? Math.max(0, selectedOptions.length - maxTagsVisible) : 0;
|
|
19721
|
-
const globalConfig = useUnderverseUIConfig();
|
|
19722
|
-
const resolvedBorderMode = borderMode ?? globalConfig.borderMode ?? "full";
|
|
19723
19763
|
const triggerButton = /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)(
|
|
19724
19764
|
"button",
|
|
19725
19765
|
{
|
|
@@ -19882,7 +19922,8 @@ var MultiCombobox = ({
|
|
|
19882
19922
|
placement: "bottom-start",
|
|
19883
19923
|
matchTriggerWidth: true,
|
|
19884
19924
|
className: "z-9999",
|
|
19885
|
-
|
|
19925
|
+
borderMode: resolvedBorderMode,
|
|
19926
|
+
contentClassName: "p-0 overflow-hidden",
|
|
19886
19927
|
children: dropdownBody
|
|
19887
19928
|
}
|
|
19888
19929
|
),
|
|
@@ -19937,6 +19978,8 @@ var RadioGroup = React47.forwardRef(
|
|
|
19937
19978
|
error = false,
|
|
19938
19979
|
errorMessage
|
|
19939
19980
|
}, ref) => {
|
|
19981
|
+
const globalConfig = useUnderverseUIConfig();
|
|
19982
|
+
const resolvedBorderMode = borderMode ?? globalConfig.input?.borderMode ?? globalConfig.borderMode ?? "full";
|
|
19940
19983
|
const [internalValue, setInternalValue] = React47.useState(defaultValue || "");
|
|
19941
19984
|
const isControlled = value !== void 0;
|
|
19942
19985
|
const currentValue = isControlled ? value : internalValue;
|
|
@@ -19960,7 +20003,7 @@ var RadioGroup = React47.forwardRef(
|
|
|
19960
20003
|
disabled,
|
|
19961
20004
|
size,
|
|
19962
20005
|
variant,
|
|
19963
|
-
borderMode
|
|
20006
|
+
borderMode: resolvedBorderMode
|
|
19964
20007
|
},
|
|
19965
20008
|
children: /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)("div", { className: "space-y-2", children: [
|
|
19966
20009
|
/* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
|
|
@@ -21214,6 +21257,8 @@ function CategoryTreeSelect(props) {
|
|
|
21214
21257
|
singleSelect = false,
|
|
21215
21258
|
borderMode
|
|
21216
21259
|
} = props;
|
|
21260
|
+
const globalConfig = useUnderverseUIConfig();
|
|
21261
|
+
const resolvedBorderMode = borderMode ?? globalConfig.input?.borderMode ?? globalConfig.borderMode ?? "full";
|
|
21217
21262
|
const [isOpen, setIsOpen] = (0, import_react26.useState)(false);
|
|
21218
21263
|
const [expandedNodes, setExpandedNodes] = (0, import_react26.useState)(
|
|
21219
21264
|
() => getInitialExpandedNodes(categories, { defaultExpanded, defaultExpandedIds, expandToId, viewOnly, inline })
|
|
@@ -21871,10 +21916,11 @@ function CategoryTreeSelect(props) {
|
|
|
21871
21916
|
matchTriggerWidth: true,
|
|
21872
21917
|
className: "z-9999",
|
|
21873
21918
|
contentClassName: cn(
|
|
21874
|
-
"p-0 overflow-hidden
|
|
21919
|
+
"p-0 overflow-hidden",
|
|
21875
21920
|
"border-border/40 bg-popover/95 text-popover-foreground",
|
|
21876
21921
|
"shadow-2xl backdrop-blur-xl"
|
|
21877
21922
|
),
|
|
21923
|
+
borderMode: resolvedBorderMode,
|
|
21878
21924
|
trigger: /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(
|
|
21879
21925
|
"div",
|
|
21880
21926
|
{
|
|
@@ -21901,7 +21947,7 @@ function CategoryTreeSelect(props) {
|
|
|
21901
21947
|
},
|
|
21902
21948
|
className: cn(
|
|
21903
21949
|
"group flex w-full items-center justify-between transition-all duration-200",
|
|
21904
|
-
getBorderRadiusClass(
|
|
21950
|
+
getBorderRadiusClass(resolvedBorderMode ?? "full"),
|
|
21905
21951
|
"backdrop-blur-sm",
|
|
21906
21952
|
triggerSizeStyles[size].button,
|
|
21907
21953
|
triggerVariantStyles[variant],
|
|
@@ -24492,6 +24538,8 @@ function ColorPicker({
|
|
|
24492
24538
|
borderMode,
|
|
24493
24539
|
...rest
|
|
24494
24540
|
}) {
|
|
24541
|
+
const globalConfig = useUnderverseUIConfig();
|
|
24542
|
+
const resolvedBorderMode = borderMode ?? globalConfig.input?.borderMode ?? globalConfig.borderMode ?? "full";
|
|
24495
24543
|
const gi18n = useGlobalI18n();
|
|
24496
24544
|
const isControlled = value !== void 0;
|
|
24497
24545
|
const initial = parseAnyColor(isControlled ? value : defaultValue) || { r: 79, g: 70, b: 229, a: 1 };
|
|
@@ -24589,7 +24637,7 @@ function ColorPicker({
|
|
|
24589
24637
|
disabled,
|
|
24590
24638
|
className: cn(
|
|
24591
24639
|
"w-full px-3 border border-input bg-background flex items-center justify-between",
|
|
24592
|
-
getBorderRadiusClass(
|
|
24640
|
+
getBorderRadiusClass(resolvedBorderMode),
|
|
24593
24641
|
sizeClasses2[size],
|
|
24594
24642
|
"hover:border-accent-foreground/30 transition-colors",
|
|
24595
24643
|
disabled && "opacity-50 cursor-not-allowed",
|
|
@@ -24625,8 +24673,9 @@ function ColorPicker({
|
|
|
24625
24673
|
onOpenChange: setOpen,
|
|
24626
24674
|
placement: "bottom-start",
|
|
24627
24675
|
matchTriggerWidth: variant === "minimal",
|
|
24676
|
+
borderMode: resolvedBorderMode,
|
|
24628
24677
|
contentWidth: contentWidthByVariant[variant],
|
|
24629
|
-
contentClassName: cn("p-3
|
|
24678
|
+
contentClassName: cn("p-3 border border-border/50 bg-card shadow-lg", contentClassName),
|
|
24630
24679
|
children: /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)("div", { className: "space-y-3", children: [
|
|
24631
24680
|
variant !== "minimal" && /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)("div", { className: "flex items-center gap-2", children: [
|
|
24632
24681
|
/* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
|