lecom-ui 5.2.46 → 5.2.48
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/Select/Select.js +35 -24
- package/dist/index.d.ts +3 -1
- package/package.json +1 -1
|
@@ -89,31 +89,42 @@ const SelectScrollDownButton = React.forwardRef(({ className, ...props }, ref) =
|
|
|
89
89
|
/* @__PURE__ */ React.createElement(ChevronDown, { className: "h-4 w-4" })
|
|
90
90
|
));
|
|
91
91
|
SelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;
|
|
92
|
-
const SelectContent = React.forwardRef(
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
position === "popper" && "data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",
|
|
99
|
-
className
|
|
100
|
-
),
|
|
101
|
-
position,
|
|
92
|
+
const SelectContent = React.forwardRef(
|
|
93
|
+
({
|
|
94
|
+
className,
|
|
95
|
+
children,
|
|
96
|
+
position = "popper",
|
|
97
|
+
disablePortal = false,
|
|
102
98
|
...props
|
|
103
|
-
},
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
)
|
|
99
|
+
}, ref) => {
|
|
100
|
+
const content = /* @__PURE__ */ React.createElement(
|
|
101
|
+
SelectPrimitive.Content,
|
|
102
|
+
{
|
|
103
|
+
ref,
|
|
104
|
+
className: cn(
|
|
105
|
+
"relative z-50 max-h-96 min-w-[8rem] rounded-md border bg-popover text-popover-foreground shadow-md",
|
|
106
|
+
position === "popper" && "data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",
|
|
107
|
+
className
|
|
108
|
+
),
|
|
109
|
+
position,
|
|
110
|
+
...props
|
|
111
|
+
},
|
|
112
|
+
/* @__PURE__ */ React.createElement(SelectScrollUpButton, null),
|
|
113
|
+
/* @__PURE__ */ React.createElement(
|
|
114
|
+
SelectPrimitive.Viewport,
|
|
115
|
+
{
|
|
116
|
+
className: cn(
|
|
117
|
+
"p-1 overflow-auto",
|
|
118
|
+
position === "popper" && "h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"
|
|
119
|
+
)
|
|
120
|
+
},
|
|
121
|
+
children
|
|
122
|
+
),
|
|
123
|
+
/* @__PURE__ */ React.createElement(SelectScrollDownButton, null)
|
|
124
|
+
);
|
|
125
|
+
return disablePortal ? content : /* @__PURE__ */ React.createElement(SelectPrimitive.Portal, null, content);
|
|
126
|
+
}
|
|
127
|
+
);
|
|
117
128
|
SelectContent.displayName = SelectPrimitive.Content.displayName;
|
|
118
129
|
const SelectLabel = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ React.createElement(
|
|
119
130
|
SelectPrimitive.Label,
|
package/dist/index.d.ts
CHANGED
|
@@ -910,7 +910,9 @@ declare const SelectTrigger: React$1.ForwardRefExoticComponent<Omit<SelectPrimit
|
|
|
910
910
|
} & React$1.RefAttributes<HTMLButtonElement>>;
|
|
911
911
|
declare const SelectScrollUpButton: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectScrollUpButtonProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
912
912
|
declare const SelectScrollDownButton: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectScrollDownButtonProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
913
|
-
declare const SelectContent: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectContentProps & React$1.RefAttributes<HTMLDivElement>, "ref"> &
|
|
913
|
+
declare const SelectContent: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectContentProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & {
|
|
914
|
+
disablePortal?: boolean;
|
|
915
|
+
} & React$1.RefAttributes<HTMLDivElement>>;
|
|
914
916
|
declare const SelectLabel: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectLabelProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
915
917
|
declare const SelectItem: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectItemProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
916
918
|
declare const SelectSeparator: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectSeparatorProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|