@oneplatformdev/ui 0.0.1-beta.11
Sign up to get free protection for your applications and to get access to all the features.
- package/Accordion/Accordion.d.ts +7 -0
- package/Accordion/Accordion.mjs +46 -0
- package/Accordion/index.d.ts +1 -0
- package/Accordion/index.mjs +7 -0
- package/Accordion/package.json +7 -0
- package/Alert/Alert.d.ts +7 -0
- package/Alert/Alert.mjs +37 -0
- package/Alert/alertVariants.d.ts +4 -0
- package/Alert/alertVariants.mjs +19 -0
- package/Alert/index.d.ts +1 -0
- package/Alert/index.mjs +6 -0
- package/Alert/package.json +7 -0
- package/AlertDialog/AlertDialog.d.ts +65 -0
- package/AlertDialog/AlertDialog.mjs +97 -0
- package/AlertDialog/AlertDialog.types.d.ts +53 -0
- package/AlertDialog/AlertDialogRoot.d.ts +21 -0
- package/AlertDialog/AlertDialogRoot.mjs +114 -0
- package/AlertDialog/index.d.ts +3 -0
- package/AlertDialog/index.mjs +16 -0
- package/AlertDialog/package.json +7 -0
- package/AreaChart/AreaChart.d.ts +4 -0
- package/AreaChart/AreaChart.mjs +27 -0
- package/AreaChart/AreaChart.types.d.ts +15 -0
- package/AreaChart/index.d.ts +2 -0
- package/AreaChart/index.mjs +4 -0
- package/AreaChart/package.json +7 -0
- package/Aside/Aside.d.ts +4 -0
- package/Aside/Aside.mjs +23 -0
- package/Aside/Aside.types.d.ts +18 -0
- package/Aside/AsideSidebar.d.ts +3 -0
- package/Aside/AsideSidebar.mjs +37 -0
- package/Aside/index.d.ts +3 -0
- package/Aside/index.mjs +7 -0
- package/Aside/package.json +7 -0
- package/AspectRatio/AspectRatio.d.ts +2 -0
- package/AspectRatio/AspectRatio.mjs +5 -0
- package/AspectRatio/index.d.ts +1 -0
- package/AspectRatio/index.mjs +5 -0
- package/AspectRatio/package.json +7 -0
- package/Avatar/Avatar.d.ts +5 -0
- package/Avatar/Avatar.mjs +42 -0
- package/Avatar/index.d.ts +1 -0
- package/Avatar/index.mjs +6 -0
- package/Avatar/package.json +7 -0
- package/Badge/Badge.d.ts +5 -0
- package/Badge/Badge.mjs +10 -0
- package/Badge/Badge.types.d.ts +5 -0
- package/Badge/badgeVariants.d.ts +3 -0
- package/Badge/badgeVariants.mjs +20 -0
- package/Badge/index.d.ts +3 -0
- package/Badge/index.mjs +6 -0
- package/Badge/package.json +7 -0
- package/Breadcrumb/Breadcrumb.d.ts +19 -0
- package/Breadcrumb/Breadcrumb.mjs +90 -0
- package/Breadcrumb/index.d.ts +1 -0
- package/Breadcrumb/index.mjs +10 -0
- package/Breadcrumb/package.json +7 -0
- package/Button/Button.d.ts +4 -0
- package/Button/Button.mjs +31 -0
- package/Button/Button.types.d.ts +8 -0
- package/Button/buttonVariants.d.ts +4 -0
- package/Button/buttonVariants.mjs +29 -0
- package/Button/index.d.ts +3 -0
- package/Button/index.mjs +7 -0
- package/Button/package.json +7 -0
- package/ButtonIcon/ButtonIcon.d.ts +3 -0
- package/ButtonIcon/ButtonIcon.mjs +29 -0
- package/ButtonIcon/ButtonIcon.types.d.ts +7 -0
- package/ButtonIcon/buttonIconVariants.d.ts +7 -0
- package/ButtonIcon/buttonIconVariants.mjs +139 -0
- package/ButtonIcon/index.d.ts +3 -0
- package/ButtonIcon/index.mjs +7 -0
- package/ButtonIcon/package.json +7 -0
- package/Calendar/Calendar.d.ts +8 -0
- package/Calendar/Calendar.mjs +63 -0
- package/Calendar/index.d.ts +1 -0
- package/Calendar/index.mjs +4 -0
- package/Calendar/package.json +7 -0
- package/Card/Card.d.ts +8 -0
- package/Card/Card.mjs +61 -0
- package/Card/index.d.ts +1 -0
- package/Card/index.mjs +9 -0
- package/Card/package.json +7 -0
- package/Carousel/Carousel.d.ts +18 -0
- package/Carousel/Carousel.mjs +168 -0
- package/Carousel/index.d.ts +1 -0
- package/Carousel/index.mjs +8 -0
- package/Carousel/package.json +7 -0
- package/Chart/Chart.d.ts +62 -0
- package/Chart/Chart.mjs +210 -0
- package/Chart/index.d.ts +1 -0
- package/Chart/index.mjs +9 -0
- package/Chart/package.json +7 -0
- package/Checkbox/Checkbox.d.ts +4 -0
- package/Checkbox/Checkbox.mjs +27 -0
- package/Checkbox/index.d.ts +1 -0
- package/Checkbox/index.mjs +4 -0
- package/Checkbox/package.json +7 -0
- package/Collapsible/Collapsible.d.ts +5 -0
- package/Collapsible/Collapsible.mjs +7 -0
- package/Collapsible/index.d.ts +1 -0
- package/Collapsible/index.mjs +6 -0
- package/Collapsible/package.json +7 -0
- package/Combobox/Combobox.d.ts +4 -0
- package/Combobox/Combobox.mjs +126 -0
- package/Combobox/Combobox.types.d.ts +15 -0
- package/Combobox/index.d.ts +2 -0
- package/Combobox/index.mjs +4 -0
- package/Combobox/package.json +7 -0
- package/Command/Command.d.ts +80 -0
- package/Command/Command.mjs +109 -0
- package/Command/index.d.ts +1 -0
- package/Command/index.mjs +12 -0
- package/Command/package.json +7 -0
- package/DataTable/DataTable.d.ts +4 -0
- package/DataTable/DataTable.mjs +64 -0
- package/DataTable/DataTable.types.d.ts +11 -0
- package/DataTable/index.d.ts +2 -0
- package/DataTable/index.mjs +4 -0
- package/DataTable/package.json +7 -0
- package/DataTable/useDataTable.d.ts +3 -0
- package/DataTable/useDataTable.mjs +30 -0
- package/DatePicker/DatePicker.d.ts +3 -0
- package/DatePicker/DatePicker.mjs +699 -0
- package/DatePicker/DatePicker.types.d.ts +5 -0
- package/DatePicker/index.d.ts +3 -0
- package/DatePicker/index.mjs +5 -0
- package/DatePicker/package.json +7 -0
- package/Dialog/Dialog.d.ts +19 -0
- package/Dialog/Dialog.mjs +100 -0
- package/Dialog/index.d.ts +1 -0
- package/Dialog/index.mjs +13 -0
- package/Dialog/package.json +7 -0
- package/Drawer/Drawer.d.ts +22 -0
- package/Drawer/Drawer.mjs +98 -0
- package/Drawer/index.d.ts +1 -0
- package/Drawer/index.mjs +13 -0
- package/Drawer/package.json +7 -0
- package/DropdownMenu/DropdownMenu.d.ts +27 -0
- package/DropdownMenu/DropdownMenu.mjs +144 -0
- package/DropdownMenu/index.d.ts +1 -0
- package/DropdownMenu/index.mjs +18 -0
- package/DropdownMenu/package.json +7 -0
- package/Dropzone/Dropzone.d.ts +16 -0
- package/Dropzone/Dropzone.mjs +2923 -0
- package/Dropzone/Dropzone.types.d.ts +21 -0
- package/Dropzone/FilePreview.d.ts +15 -0
- package/Dropzone/FilePreview.mjs +7 -0
- package/Dropzone/index.d.ts +2 -0
- package/Dropzone/index.mjs +7 -0
- package/Dropzone/package.json +7 -0
- package/FilePreview-C6IeuOqo.js +40 -0
- package/Form/Form.d.ts +23 -0
- package/Form/Form.mjs +95 -0
- package/Form/FormRenderControl.d.ts +5 -0
- package/Form/FormRenderControl.mjs +21 -0
- package/Form/FormRenderControl.types.d.ts +18 -0
- package/Form/index.d.ts +3 -0
- package/Form/index.mjs +13 -0
- package/Form/package.json +7 -0
- package/FormCheckbox/FormCheckbox.d.ts +5 -0
- package/FormCheckbox/FormCheckbox.mjs +30 -0
- package/FormCheckbox/FormCheckbox.types.d.ts +7 -0
- package/FormCheckbox/index.d.ts +2 -0
- package/FormCheckbox/index.mjs +4 -0
- package/FormCheckbox/package.json +7 -0
- package/FormCombobox/FormCombobox.d.ts +4 -0
- package/FormCombobox/FormCombobox.mjs +26 -0
- package/FormCombobox/FormCombobox.types.d.ts +7 -0
- package/FormCombobox/index.d.ts +2 -0
- package/FormCombobox/index.mjs +4 -0
- package/FormCombobox/package.json +7 -0
- package/FormDatePicker/FormDatePicker.d.ts +4 -0
- package/FormDatePicker/FormDatePicker.mjs +27 -0
- package/FormDatePicker/FormDatePicker.types.d.ts +7 -0
- package/FormDatePicker/index.d.ts +3 -0
- package/FormDatePicker/index.mjs +5 -0
- package/FormDatePicker/package.json +7 -0
- package/FormInput/FormInput.d.ts +5 -0
- package/FormInput/FormInput.mjs +26 -0
- package/FormInput/FormInput.types.d.ts +7 -0
- package/FormInput/index.d.ts +2 -0
- package/FormInput/index.mjs +4 -0
- package/FormInput/package.json +7 -0
- package/FormSelect/FormSelect.d.ts +5 -0
- package/FormSelect/FormSelect.mjs +38 -0
- package/FormSelect/FormSelect.types.d.ts +7 -0
- package/FormSelect/index.d.ts +2 -0
- package/FormSelect/index.mjs +4 -0
- package/FormSelect/package.json +7 -0
- package/FormTextarea/FormTextarea.d.ts +5 -0
- package/FormTextarea/FormTextarea.mjs +26 -0
- package/FormTextarea/FormTextarea.types.d.ts +7 -0
- package/FormTextarea/index.d.ts +2 -0
- package/FormTextarea/index.mjs +4 -0
- package/FormTextarea/package.json +7 -0
- package/Header/Header.d.ts +4 -0
- package/Header/Header.mjs +26 -0
- package/Header/Header.types.d.ts +3 -0
- package/Header/index.d.ts +2 -0
- package/Header/index.mjs +5 -0
- package/Header/package.json +7 -0
- package/HoverCard/HoverCard.d.ts +6 -0
- package/HoverCard/HoverCard.mjs +23 -0
- package/HoverCard/index.d.ts +1 -0
- package/HoverCard/index.mjs +6 -0
- package/HoverCard/package.json +7 -0
- package/Input/Input.d.ts +6 -0
- package/Input/Input.mjs +61 -0
- package/Input/Input.types.d.ts +13 -0
- package/Input/index.d.ts +3 -0
- package/Input/index.mjs +7 -0
- package/Input/inputVariants.d.ts +3 -0
- package/Input/inputVariants.mjs +18 -0
- package/Input/package.json +7 -0
- package/InputOTP/InputOTP.d.ts +34 -0
- package/InputOTP/InputOTP.mjs +48 -0
- package/InputOTP/index.d.ts +1 -0
- package/InputOTP/index.mjs +7 -0
- package/InputOTP/package.json +7 -0
- package/Label/Label.d.ts +5 -0
- package/Label/Label.mjs +17 -0
- package/Label/index.d.ts +2 -0
- package/Label/index.mjs +6 -0
- package/Label/labelVariants.d.ts +1 -0
- package/Label/labelVariants.mjs +7 -0
- package/Label/package.json +7 -0
- package/LazyLoader/LazyLoader.d.ts +20 -0
- package/LazyLoader/LazyLoader.mjs +7 -0
- package/LazyLoader/index.d.ts +1 -0
- package/LazyLoader/index.mjs +5 -0
- package/LazyLoader/package.json +7 -0
- package/LoadingMask/LoadingMask.d.ts +1 -0
- package/LoadingMask/LoadingMask.mjs +59 -0
- package/LoadingMask/index.d.ts +1 -0
- package/LoadingMask/index.mjs +4 -0
- package/LoadingMask/package.json +7 -0
- package/LoadingProgress/LoadingProgress.d.ts +4 -0
- package/LoadingProgress/LoadingProgress.mjs +37 -0
- package/LoadingProgress/LoadingProgress.types.d.ts +8 -0
- package/LoadingProgress/index.d.ts +3 -0
- package/LoadingProgress/index.mjs +6 -0
- package/LoadingProgress/loadingProgressVariants.d.ts +4 -0
- package/LoadingProgress/loadingProgressVariants.mjs +24 -0
- package/LoadingProgress/package.json +7 -0
- package/Menubar/Menubar.d.ts +28 -0
- package/Menubar/Menubar.mjs +175 -0
- package/Menubar/index.d.ts +1 -0
- package/Menubar/index.mjs +19 -0
- package/Menubar/package.json +7 -0
- package/NavigationMenu/NavigationMenu.d.ts +11 -0
- package/NavigationMenu/NavigationMenu.mjs +101 -0
- package/NavigationMenu/index.d.ts +2 -0
- package/NavigationMenu/index.mjs +13 -0
- package/NavigationMenu/navigationMenuVariants.d.ts +1 -0
- package/NavigationMenu/navigationMenuVariants.mjs +7 -0
- package/NavigationMenu/package.json +7 -0
- package/Pagination/Pagination.d.ts +28 -0
- package/Pagination/Pagination.mjs +106 -0
- package/Pagination/index.d.ts +1 -0
- package/Pagination/index.mjs +10 -0
- package/Pagination/package.json +7 -0
- package/Popover/Popover.d.ts +7 -0
- package/Popover/Popover.mjs +24 -0
- package/Popover/index.d.ts +1 -0
- package/Popover/index.mjs +7 -0
- package/Popover/package.json +7 -0
- package/Progress/Progress.d.ts +4 -0
- package/Progress/Progress.mjs +26 -0
- package/Progress/index.d.ts +1 -0
- package/Progress/index.mjs +4 -0
- package/Progress/package.json +7 -0
- package/README.md +33 -0
- package/RadioGroup/RadioGroup.d.ts +5 -0
- package/RadioGroup/RadioGroup.mjs +31 -0
- package/RadioGroup/index.d.ts +1 -0
- package/RadioGroup/index.mjs +5 -0
- package/RadioGroup/package.json +7 -0
- package/Resizable/Resizable.d.ts +23 -0
- package/Resizable/Resizable.mjs +36 -0
- package/Resizable/index.d.ts +1 -0
- package/Resizable/index.mjs +6 -0
- package/Resizable/package.json +7 -0
- package/ScrollArea/ScrollArea.d.ts +5 -0
- package/ScrollArea/ScrollArea.mjs +38 -0
- package/ScrollArea/index.d.ts +1 -0
- package/ScrollArea/index.mjs +5 -0
- package/ScrollArea/package.json +7 -0
- package/Search/Search.d.ts +4 -0
- package/Search/Search.mjs +30 -0
- package/Search/Search.types.d.ts +6 -0
- package/Search/index.d.ts +3 -0
- package/Search/index.mjs +5 -0
- package/Search/package.json +7 -0
- package/Select/Select.d.ts +3 -0
- package/Select/Select.mjs +72 -0
- package/Select/Select.types.d.ts +29 -0
- package/Select/SelectRoot.d.ts +13 -0
- package/Select/SelectRoot.mjs +121 -0
- package/Select/index.d.ts +3 -0
- package/Select/index.mjs +15 -0
- package/Select/package.json +7 -0
- package/Separator/Separator.d.ts +4 -0
- package/Separator/Separator.mjs +24 -0
- package/Separator/index.d.ts +1 -0
- package/Separator/index.mjs +4 -0
- package/Separator/package.json +7 -0
- package/Sheet/Sheet.d.ts +25 -0
- package/Sheet/Sheet.mjs +110 -0
- package/Sheet/index.d.ts +1 -0
- package/Sheet/index.mjs +13 -0
- package/Sheet/package.json +7 -0
- package/Sidebar/Sidebar.d.ts +66 -0
- package/Sidebar/Sidebar.mjs +543 -0
- package/Sidebar/index.d.ts +1 -0
- package/Sidebar/index.mjs +27 -0
- package/Sidebar/package.json +7 -0
- package/Skeleton/Skeleton.d.ts +4 -0
- package/Skeleton/Skeleton.mjs +17 -0
- package/Skeleton/index.d.ts +1 -0
- package/Skeleton/index.mjs +4 -0
- package/Skeleton/package.json +7 -0
- package/Slider/Slider.d.ts +4 -0
- package/Slider/Slider.mjs +23 -0
- package/Slider/index.d.ts +1 -0
- package/Slider/index.mjs +4 -0
- package/Slider/package.json +7 -0
- package/Sonner/Sonner.d.ts +5 -0
- package/Sonner/Sonner.mjs +25 -0
- package/Sonner/index.d.ts +1 -0
- package/Sonner/index.mjs +4 -0
- package/Sonner/package.json +7 -0
- package/Switch/Switch.d.ts +4 -0
- package/Switch/Switch.mjs +27 -0
- package/Switch/index.d.ts +1 -0
- package/Switch/index.mjs +4 -0
- package/Switch/package.json +7 -0
- package/Table/Table.d.ts +10 -0
- package/Table/Table.mjs +90 -0
- package/Table/index.d.ts +1 -0
- package/Table/index.mjs +11 -0
- package/Table/package.json +7 -0
- package/Tabs/Tabs.d.ts +4 -0
- package/Tabs/Tabs.mjs +9 -0
- package/Tabs/Tabs.types.d.ts +9 -0
- package/Tabs/TabsRoot.d.ts +7 -0
- package/Tabs/TabsRoot.mjs +46 -0
- package/Tabs/index.d.ts +2 -0
- package/Tabs/index.mjs +9 -0
- package/Tabs/package.json +7 -0
- package/Textarea/Textarea.d.ts +4 -0
- package/Textarea/Textarea.mjs +18 -0
- package/Textarea/Textarea.types.d.ts +4 -0
- package/Textarea/index.d.ts +2 -0
- package/Textarea/index.mjs +4 -0
- package/Textarea/package.json +7 -0
- package/Theme/ThemeModeToggle.d.ts +8 -0
- package/Theme/ThemeModeToggle.mjs +48 -0
- package/Theme/ThemeProvider.d.ts +4 -0
- package/Theme/ThemeProvider.mjs +27 -0
- package/Theme/index.d.ts +2 -0
- package/Theme/index.mjs +6 -0
- package/Theme/package.json +7 -0
- package/Toast/Toast.d.ts +13 -0
- package/Toast/Toast.mjs +80 -0
- package/Toast/Toast.types.d.ts +34 -0
- package/Toast/index.d.ts +3 -0
- package/Toast/index.mjs +15 -0
- package/Toast/package.json +7 -0
- package/Toast/toast.constants.d.ts +6 -0
- package/Toast/toast.constants.mjs +9 -0
- package/Toast/toastVariants.d.ts +3 -0
- package/Toast/toastVariants.mjs +21 -0
- package/Toast/useToast.d.ts +16 -0
- package/Toast/useToast.mjs +101 -0
- package/Toaster/Toaster.d.ts +1 -0
- package/Toaster/Toaster.mjs +22 -0
- package/Toaster/index.d.ts +1 -0
- package/Toaster/index.mjs +4 -0
- package/Toaster/package.json +7 -0
- package/Toggle/Toggle.d.ts +12 -0
- package/Toggle/Toggle.mjs +37 -0
- package/Toggle/index.d.ts +1 -0
- package/Toggle/index.mjs +5 -0
- package/Toggle/package.json +7 -0
- package/ToggleGroup/ToggleGroup.d.ts +12 -0
- package/ToggleGroup/ToggleGroup.mjs +41 -0
- package/ToggleGroup/index.d.ts +1 -0
- package/ToggleGroup/index.mjs +5 -0
- package/ToggleGroup/package.json +7 -0
- package/Tooltip/Tooltip.d.ts +4 -0
- package/Tooltip/Tooltip.mjs +12 -0
- package/Tooltip/Tooltip.types.d.ts +8 -0
- package/Tooltip/TooltipRoot.d.ts +7 -0
- package/Tooltip/TooltipRoot.mjs +23 -0
- package/Tooltip/index.d.ts +3 -0
- package/Tooltip/index.mjs +9 -0
- package/Tooltip/package.json +7 -0
- package/index.css +1 -0
- package/index.d.ts +66 -0
- package/index.mjs +358 -0
- package/package.json +103 -0
- package/tailwind.config.mjs +148 -0
@@ -0,0 +1,26 @@
|
|
1
|
+
import { jsx as o } from "react/jsx-runtime";
|
2
|
+
import * as t from "react";
|
3
|
+
import * as r from "@radix-ui/react-progress";
|
4
|
+
import { cn as i } from "@oneplatformdev/utils";
|
5
|
+
const m = t.forwardRef(({ className: a, value: l, ...e }, s) => /* @__PURE__ */ o(
|
6
|
+
r.Root,
|
7
|
+
{
|
8
|
+
ref: s,
|
9
|
+
className: i(
|
10
|
+
"relative h-2 w-full overflow-hidden rounded-full bg-primary/20",
|
11
|
+
a
|
12
|
+
),
|
13
|
+
...e,
|
14
|
+
children: /* @__PURE__ */ o(
|
15
|
+
r.Indicator,
|
16
|
+
{
|
17
|
+
className: "h-full w-full flex-1 bg-primary transition-all",
|
18
|
+
style: { transform: `translateX(-${100 - (l || 0)}%)` }
|
19
|
+
}
|
20
|
+
)
|
21
|
+
}
|
22
|
+
));
|
23
|
+
m.displayName = r.Root.displayName;
|
24
|
+
export {
|
25
|
+
m as Progress
|
26
|
+
};
|
@@ -0,0 +1 @@
|
|
1
|
+
export * from './Progress';
|
package/README.md
ADDED
@@ -0,0 +1,33 @@
|
|
1
|
+
<!-- markdownlint-disable-next-line -->
|
2
|
+
<p align="center">
|
3
|
+
<a href="https://github.com/oneplatformdev/core-web/tree/test" rel="noopener" target="_blank"><img width="150" height="133" src="https://github.com/oneplatformdev/core-web/blob/test/public/one_platform_demo_logo.png" alt="OnePlatform Dev"></a>
|
4
|
+
</p>
|
5
|
+
|
6
|
+
# @oneplatformdev/ui
|
7
|
+
|
8
|
+
## Installation
|
9
|
+
Install the package in your project directory with:
|
10
|
+
|
11
|
+
<!-- #default-branch-switch -->
|
12
|
+
npm:
|
13
|
+
```bush
|
14
|
+
npm install @oneplatformdev/ui lucide-react
|
15
|
+
```
|
16
|
+
yarn:
|
17
|
+
```bush
|
18
|
+
yarn add @oneplatformdev/ui lucide-react
|
19
|
+
```
|
20
|
+
|
21
|
+
## Documentation (currently unavailable)
|
22
|
+
|
23
|
+
## Examples (currently unavailable)
|
24
|
+
|
25
|
+
## License
|
26
|
+
This project is licensed under the terms of the
|
27
|
+
[MIT license](./LICENSE).
|
28
|
+
|
29
|
+
## Usage
|
30
|
+
```tsx
|
31
|
+
import '@oneplatformdev/ui/index.css';
|
32
|
+
import { Button } from '@oneplatformdev/ui';
|
33
|
+
```
|
@@ -0,0 +1,5 @@
|
|
1
|
+
import * as React from "react";
|
2
|
+
import * as RadioGroupPrimitive from "@radix-ui/react-radio-group";
|
3
|
+
declare const RadioGroup: React.ForwardRefExoticComponent<Omit<RadioGroupPrimitive.RadioGroupProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
4
|
+
declare const RadioGroupItem: React.ForwardRefExoticComponent<Omit<RadioGroupPrimitive.RadioGroupItemProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
5
|
+
export { RadioGroup, RadioGroupItem };
|
@@ -0,0 +1,31 @@
|
|
1
|
+
import { jsx as e } from "react/jsx-runtime";
|
2
|
+
import * as s from "react";
|
3
|
+
import * as r from "@radix-ui/react-radio-group";
|
4
|
+
import { Circle as m } from "lucide-react";
|
5
|
+
import { cn as t } from "@oneplatformdev/utils";
|
6
|
+
const d = s.forwardRef(({ className: o, ...i }, a) => /* @__PURE__ */ e(
|
7
|
+
r.Root,
|
8
|
+
{
|
9
|
+
className: t("grid gap-2", o),
|
10
|
+
...i,
|
11
|
+
ref: a
|
12
|
+
}
|
13
|
+
));
|
14
|
+
d.displayName = r.Root.displayName;
|
15
|
+
const l = s.forwardRef(({ className: o, ...i }, a) => /* @__PURE__ */ e(
|
16
|
+
r.Item,
|
17
|
+
{
|
18
|
+
ref: a,
|
19
|
+
className: t(
|
20
|
+
"aspect-square h-4 w-4 rounded-full border border-primary text-primary shadow focus:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50",
|
21
|
+
o
|
22
|
+
),
|
23
|
+
...i,
|
24
|
+
children: /* @__PURE__ */ e(r.Indicator, { className: "flex items-center justify-center", children: /* @__PURE__ */ e(m, { className: "h-3.5 w-3.5 fill-primary" }) })
|
25
|
+
}
|
26
|
+
));
|
27
|
+
l.displayName = r.Item.displayName;
|
28
|
+
export {
|
29
|
+
d as RadioGroup,
|
30
|
+
l as RadioGroupItem
|
31
|
+
};
|
@@ -0,0 +1 @@
|
|
1
|
+
export * from './RadioGroup';
|
@@ -0,0 +1,23 @@
|
|
1
|
+
import * as ResizablePrimitive from "react-resizable-panels";
|
2
|
+
declare const ResizablePanelGroup: ({ className, ...props }: React.ComponentProps<typeof ResizablePrimitive.PanelGroup>) => import("react/jsx-runtime").JSX.Element;
|
3
|
+
declare const ResizablePanel: import('react').ForwardRefExoticComponent<Omit<import('react').HTMLAttributes<HTMLDivElement | HTMLElement | HTMLObjectElement | HTMLMapElement | HTMLAnchorElement | HTMLButtonElement | HTMLFormElement | HTMLHeadingElement | HTMLImageElement | HTMLInputElement | HTMLLabelElement | HTMLLIElement | HTMLOListElement | HTMLParagraphElement | HTMLSpanElement | HTMLUListElement | HTMLAreaElement | HTMLAudioElement | HTMLBaseElement | HTMLQuoteElement | HTMLBodyElement | HTMLBRElement | HTMLCanvasElement | HTMLTableColElement | HTMLDataElement | HTMLDataListElement | HTMLModElement | HTMLDetailsElement | HTMLDialogElement | HTMLDListElement | HTMLEmbedElement | HTMLFieldSetElement | HTMLHeadElement | HTMLHRElement | HTMLHtmlElement | HTMLIFrameElement | HTMLLegendElement | HTMLLinkElement | HTMLMetaElement | HTMLMeterElement | HTMLOptGroupElement | HTMLOptionElement | HTMLOutputElement | HTMLPreElement | HTMLProgressElement | HTMLSlotElement | HTMLScriptElement | HTMLSelectElement | HTMLSourceElement | HTMLStyleElement | HTMLTableElement | HTMLTemplateElement | HTMLTableSectionElement | HTMLTableCellElement | HTMLTextAreaElement | HTMLTimeElement | HTMLTitleElement | HTMLTableRowElement | HTMLTrackElement | HTMLVideoElement | HTMLTableCaptionElement | HTMLMenuElement | HTMLPictureElement>, "id" | "onResize"> & {
|
4
|
+
className?: string | undefined;
|
5
|
+
collapsedSize?: number | undefined;
|
6
|
+
collapsible?: boolean | undefined;
|
7
|
+
defaultSize?: number | undefined;
|
8
|
+
id?: string | undefined;
|
9
|
+
maxSize?: number | undefined;
|
10
|
+
minSize?: number | undefined;
|
11
|
+
onCollapse?: ResizablePrimitive.PanelOnCollapse | undefined;
|
12
|
+
onExpand?: ResizablePrimitive.PanelOnExpand | undefined;
|
13
|
+
onResize?: ResizablePrimitive.PanelOnResize | undefined;
|
14
|
+
order?: number | undefined;
|
15
|
+
style?: object | undefined;
|
16
|
+
tagName?: keyof HTMLElementTagNameMap | undefined;
|
17
|
+
} & {
|
18
|
+
children?: import('react').ReactNode;
|
19
|
+
} & import('react').RefAttributes<ResizablePrimitive.ImperativePanelHandle>>;
|
20
|
+
declare const ResizableHandle: ({ withHandle, className, ...props }: React.ComponentProps<typeof ResizablePrimitive.PanelResizeHandle> & {
|
21
|
+
withHandle?: boolean;
|
22
|
+
}) => import("react/jsx-runtime").JSX.Element;
|
23
|
+
export { ResizablePanelGroup, ResizablePanel, ResizableHandle };
|
@@ -0,0 +1,36 @@
|
|
1
|
+
import { jsx as e } from "react/jsx-runtime";
|
2
|
+
import { GripVertical as n } from "lucide-react";
|
3
|
+
import * as t from "react-resizable-panels";
|
4
|
+
import { cn as i } from "@oneplatformdev/utils";
|
5
|
+
const f = ({
|
6
|
+
className: a,
|
7
|
+
...r
|
8
|
+
}) => /* @__PURE__ */ e(
|
9
|
+
t.PanelGroup,
|
10
|
+
{
|
11
|
+
className: i(
|
12
|
+
"flex h-full w-full data-[panel-group-direction=vertical]:flex-col",
|
13
|
+
a
|
14
|
+
),
|
15
|
+
...r
|
16
|
+
}
|
17
|
+
), d = t.Panel, p = ({
|
18
|
+
withHandle: a,
|
19
|
+
className: r,
|
20
|
+
...l
|
21
|
+
}) => /* @__PURE__ */ e(
|
22
|
+
t.PanelResizeHandle,
|
23
|
+
{
|
24
|
+
className: i(
|
25
|
+
"relative flex w-px items-center justify-center bg-border after:absolute after:inset-y-0 after:left-1/2 after:w-1 after:-translate-x-1/2 focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring focus-visible:ring-offset-1 data-[panel-group-direction=vertical]:h-px data-[panel-group-direction=vertical]:w-full data-[panel-group-direction=vertical]:after:left-0 data-[panel-group-direction=vertical]:after:h-1 data-[panel-group-direction=vertical]:after:w-full data-[panel-group-direction=vertical]:after:-translate-y-1/2 data-[panel-group-direction=vertical]:after:translate-x-0 [&[data-panel-group-direction=vertical]>div]:rotate-90",
|
26
|
+
r
|
27
|
+
),
|
28
|
+
...l,
|
29
|
+
children: a && /* @__PURE__ */ e("div", { className: "z-10 flex h-4 w-3 items-center justify-center rounded-sm border bg-border", children: /* @__PURE__ */ e(n, { className: "h-2.5 w-2.5" }) })
|
30
|
+
}
|
31
|
+
);
|
32
|
+
export {
|
33
|
+
p as ResizableHandle,
|
34
|
+
d as ResizablePanel,
|
35
|
+
f as ResizablePanelGroup
|
36
|
+
};
|
@@ -0,0 +1 @@
|
|
1
|
+
export * from './Resizable';
|
@@ -0,0 +1,5 @@
|
|
1
|
+
import * as React from "react";
|
2
|
+
import * as ScrollAreaPrimitive from "@radix-ui/react-scroll-area";
|
3
|
+
declare const ScrollArea: React.ForwardRefExoticComponent<Omit<ScrollAreaPrimitive.ScrollAreaProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
4
|
+
declare const ScrollBar: React.ForwardRefExoticComponent<Omit<ScrollAreaPrimitive.ScrollAreaScrollbarProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
5
|
+
export { ScrollArea, ScrollBar };
|
@@ -0,0 +1,38 @@
|
|
1
|
+
import { jsxs as d, jsx as e } from "react/jsx-runtime";
|
2
|
+
import * as s from "react";
|
3
|
+
import * as r from "@radix-ui/react-scroll-area";
|
4
|
+
import { cn as t } from "@oneplatformdev/utils";
|
5
|
+
const m = s.forwardRef(({ className: o, children: l, ...a }, c) => /* @__PURE__ */ d(
|
6
|
+
r.Root,
|
7
|
+
{
|
8
|
+
ref: c,
|
9
|
+
className: t("relative overflow-hidden", o),
|
10
|
+
...a,
|
11
|
+
children: [
|
12
|
+
/* @__PURE__ */ e(r.Viewport, { className: "h-full w-full rounded-[inherit]", children: l }),
|
13
|
+
/* @__PURE__ */ e(i, {}),
|
14
|
+
/* @__PURE__ */ e(r.Corner, {})
|
15
|
+
]
|
16
|
+
}
|
17
|
+
));
|
18
|
+
m.displayName = r.Root.displayName;
|
19
|
+
const i = s.forwardRef(({ className: o, orientation: l = "vertical", ...a }, c) => /* @__PURE__ */ e(
|
20
|
+
r.ScrollAreaScrollbar,
|
21
|
+
{
|
22
|
+
ref: c,
|
23
|
+
orientation: l,
|
24
|
+
className: t(
|
25
|
+
"flex touch-none select-none transition-colors",
|
26
|
+
l === "vertical" && "h-full w-2.5 border-l border-l-transparent p-[1px]",
|
27
|
+
l === "horizontal" && "h-2.5 flex-col border-t border-t-transparent p-[1px]",
|
28
|
+
o
|
29
|
+
),
|
30
|
+
...a,
|
31
|
+
children: /* @__PURE__ */ e(r.ScrollAreaThumb, { className: "relative flex-1 rounded-full bg-border" })
|
32
|
+
}
|
33
|
+
));
|
34
|
+
i.displayName = r.ScrollAreaScrollbar.displayName;
|
35
|
+
export {
|
36
|
+
m as ScrollArea,
|
37
|
+
i as ScrollBar
|
38
|
+
};
|
@@ -0,0 +1 @@
|
|
1
|
+
export * from './ScrollArea';
|
@@ -0,0 +1,30 @@
|
|
1
|
+
import { jsx as o } from "react/jsx-runtime";
|
2
|
+
import { useState as S } from "react";
|
3
|
+
import { Input as f } from "../Input/Input.mjs";
|
4
|
+
import { useDebounceCallback as v } from "@oneplatformdev/hooks";
|
5
|
+
import { cn as d } from "@oneplatformdev/utils";
|
6
|
+
const j = (t) => {
|
7
|
+
const {
|
8
|
+
search: a,
|
9
|
+
onChange: e,
|
10
|
+
onSearch: c,
|
11
|
+
placeholder: s = "Search",
|
12
|
+
className: n,
|
13
|
+
...m
|
14
|
+
} = t, [i, l] = S(a), h = v(c, 1e3), p = (r) => {
|
15
|
+
const u = r.target.value;
|
16
|
+
l(u), e == null || e(r), h(r.target.value);
|
17
|
+
};
|
18
|
+
return /* @__PURE__ */ o("div", { className: d("space-y-4", n), children: /* @__PURE__ */ o(
|
19
|
+
f,
|
20
|
+
{
|
21
|
+
placeholder: s,
|
22
|
+
value: i,
|
23
|
+
onChange: p,
|
24
|
+
...m
|
25
|
+
}
|
26
|
+
) });
|
27
|
+
};
|
28
|
+
export {
|
29
|
+
j as Search
|
30
|
+
};
|
package/Search/index.mjs
ADDED
@@ -0,0 +1,72 @@
|
|
1
|
+
import { jsxs as d, jsx as a } from "react/jsx-runtime";
|
2
|
+
import { Button as f } from "../Button/Button.mjs";
|
3
|
+
import "../Button/buttonVariants.mjs";
|
4
|
+
import { SelectRoot as p, SelectContent as h, SelectItem as u, SelectTrigger as g, SelectValue as v } from "./SelectRoot.mjs";
|
5
|
+
import { isValidReactElement as i } from "@oneplatformdev/utils";
|
6
|
+
const S = (o) => {
|
7
|
+
const { placeholder: t, renderTrigger: e } = o, n = /* @__PURE__ */ a(g, { children: /* @__PURE__ */ a(v, { placeholder: t }) });
|
8
|
+
return e && typeof e == "function" && i(e(o, n)) ? e(o, n) : n;
|
9
|
+
}, C = (o) => {
|
10
|
+
const { renderOption: t, option: e, index: n, options: l, ...c } = o, r = /* @__PURE__ */ a(u, { value: e.value, children: e.label }, e.value);
|
11
|
+
return t && typeof t == "function" && i(t(
|
12
|
+
e,
|
13
|
+
n,
|
14
|
+
l,
|
15
|
+
{ ...c, options: l },
|
16
|
+
r
|
17
|
+
)) ? i(t(
|
18
|
+
e,
|
19
|
+
n,
|
20
|
+
l,
|
21
|
+
{ ...c, options: l },
|
22
|
+
r
|
23
|
+
), u) ? i(t(
|
24
|
+
e,
|
25
|
+
n,
|
26
|
+
l,
|
27
|
+
{ ...c, options: l },
|
28
|
+
r
|
29
|
+
)) : /* @__PURE__ */ a(u, { value: e.value, children: t(
|
30
|
+
e,
|
31
|
+
n,
|
32
|
+
l,
|
33
|
+
{ ...c, options: l },
|
34
|
+
r
|
35
|
+
) }, e.value) : r;
|
36
|
+
}, T = (o) => {
|
37
|
+
const {
|
38
|
+
value: t,
|
39
|
+
options: e,
|
40
|
+
onChange: n,
|
41
|
+
nullable: l = !1,
|
42
|
+
clearLabel: c = "Clear",
|
43
|
+
disabled: r
|
44
|
+
} = o;
|
45
|
+
return /* @__PURE__ */ d(
|
46
|
+
p,
|
47
|
+
{
|
48
|
+
value: t,
|
49
|
+
onValueChange: n,
|
50
|
+
disabled: r,
|
51
|
+
children: [
|
52
|
+
/* @__PURE__ */ a(S, { ...o }),
|
53
|
+
/* @__PURE__ */ d(h, { children: [
|
54
|
+
l && /* @__PURE__ */ a(f, { className: "w-full px-2", variant: "secondary", size: "sm", onClick: () => {
|
55
|
+
n("");
|
56
|
+
}, children: c }),
|
57
|
+
e.map((s, m) => /* @__PURE__ */ a(
|
58
|
+
C,
|
59
|
+
{
|
60
|
+
...o,
|
61
|
+
option: s,
|
62
|
+
index: m
|
63
|
+
}
|
64
|
+
))
|
65
|
+
] })
|
66
|
+
]
|
67
|
+
}
|
68
|
+
);
|
69
|
+
};
|
70
|
+
export {
|
71
|
+
T as Select
|
72
|
+
};
|
@@ -0,0 +1,29 @@
|
|
1
|
+
import { ReactNode } from 'react';
|
2
|
+
|
3
|
+
export interface SelectOption<ExtendOptionData> {
|
4
|
+
value: string;
|
5
|
+
label?: ReactNode;
|
6
|
+
data?: ExtendOptionData;
|
7
|
+
}
|
8
|
+
export type SelectRenderTrigger<ExtendOptionData> = (props: Omit<SelectProps<ExtendOptionData>, 'renderTrigger'>, defaultComponent: ReactNode) => ReactNode;
|
9
|
+
export type SelectRenderOption<ExtendOptionData> = (option: SelectOption<ExtendOptionData>, index: number, options: SelectOption<ExtendOptionData>[], props: Omit<SelectProps<ExtendOptionData>, 'renderOption'>, defaultComponent: ReactNode) => ReactNode;
|
10
|
+
export interface SelectProps<ExtendOptionData> {
|
11
|
+
/** Render options. */
|
12
|
+
options: SelectOption<ExtendOptionData>[];
|
13
|
+
/** Current value. */
|
14
|
+
value?: SelectOption<ExtendOptionData>['value'];
|
15
|
+
/** Select placeholder string. */
|
16
|
+
placeholder?: string;
|
17
|
+
/** Select Root onValueChange handler. */
|
18
|
+
onChange: (value: SelectOption<ExtendOptionData>['value']) => void;
|
19
|
+
/** Show reset select item button. */
|
20
|
+
disabled?: boolean;
|
21
|
+
/** Show reset select item button. */
|
22
|
+
nullable?: boolean;
|
23
|
+
/** label for nullable button. */
|
24
|
+
clearLabel?: string;
|
25
|
+
/** Render custom trigger. */
|
26
|
+
renderTrigger?: SelectRenderTrigger<ExtendOptionData>;
|
27
|
+
/** Render custom option. */
|
28
|
+
renderOption?: SelectRenderOption<ExtendOptionData>;
|
29
|
+
}
|
@@ -0,0 +1,13 @@
|
|
1
|
+
import * as React from "react";
|
2
|
+
import * as SelectPrimitive from "@radix-ui/react-select";
|
3
|
+
declare const SelectRoot: React.FC<SelectPrimitive.SelectProps>;
|
4
|
+
declare const SelectGroup: React.ForwardRefExoticComponent<SelectPrimitive.SelectGroupProps & React.RefAttributes<HTMLDivElement>>;
|
5
|
+
declare const SelectValue: React.ForwardRefExoticComponent<SelectPrimitive.SelectValueProps & React.RefAttributes<HTMLSpanElement>>;
|
6
|
+
declare const SelectTrigger: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectTriggerProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
7
|
+
declare const SelectScrollUpButton: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectScrollUpButtonProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
8
|
+
declare const SelectScrollDownButton: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectScrollDownButtonProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
9
|
+
declare const SelectContent: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
10
|
+
declare const SelectLabel: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectLabelProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
11
|
+
declare const SelectItem: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
12
|
+
declare const SelectSeparator: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectSeparatorProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
13
|
+
export { SelectRoot, SelectGroup, SelectValue, SelectTrigger, SelectContent, SelectLabel, SelectItem, SelectSeparator, SelectScrollUpButton, SelectScrollDownButton, };
|
@@ -0,0 +1,121 @@
|
|
1
|
+
import { jsxs as n, jsx as t } from "react/jsx-runtime";
|
2
|
+
import * as l from "react";
|
3
|
+
import * as e from "@radix-ui/react-select";
|
4
|
+
import { ChevronDown as i, ChevronUp as f, Check as u } from "lucide-react";
|
5
|
+
import { cn as s } from "@oneplatformdev/utils";
|
6
|
+
const v = e.Root, R = e.Group, C = e.Value, h = l.forwardRef(({ className: o, children: r, ...a }, d) => /* @__PURE__ */ n(
|
7
|
+
e.Trigger,
|
8
|
+
{
|
9
|
+
ref: d,
|
10
|
+
className: s(
|
11
|
+
"flex h-9 w-full items-center justify-between whitespace-nowrap rounded-md border border-input bg-transparent px-3 py-2 text-sm shadow-sm ring-offset-background placeholder:text-muted-foreground focus:outline-none focus:ring-1 focus:ring-ring disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1",
|
12
|
+
o
|
13
|
+
),
|
14
|
+
...a,
|
15
|
+
children: [
|
16
|
+
r,
|
17
|
+
/* @__PURE__ */ t(e.Icon, { asChild: !0, children: /* @__PURE__ */ t(i, { className: "h-4 w-4 opacity-50" }) })
|
18
|
+
]
|
19
|
+
}
|
20
|
+
));
|
21
|
+
h.displayName = e.Trigger.displayName;
|
22
|
+
const c = l.forwardRef(({ className: o, ...r }, a) => /* @__PURE__ */ t(
|
23
|
+
e.ScrollUpButton,
|
24
|
+
{
|
25
|
+
ref: a,
|
26
|
+
className: s(
|
27
|
+
"flex cursor-default items-center justify-center py-1",
|
28
|
+
o
|
29
|
+
),
|
30
|
+
...r,
|
31
|
+
children: /* @__PURE__ */ t(f, { className: "h-4 w-4" })
|
32
|
+
}
|
33
|
+
));
|
34
|
+
c.displayName = e.ScrollUpButton.displayName;
|
35
|
+
const m = l.forwardRef(({ className: o, ...r }, a) => /* @__PURE__ */ t(
|
36
|
+
e.ScrollDownButton,
|
37
|
+
{
|
38
|
+
ref: a,
|
39
|
+
className: s(
|
40
|
+
"flex cursor-default items-center justify-center py-1",
|
41
|
+
o
|
42
|
+
),
|
43
|
+
...r,
|
44
|
+
children: /* @__PURE__ */ t(i, { className: "h-4 w-4" })
|
45
|
+
}
|
46
|
+
));
|
47
|
+
m.displayName = e.ScrollDownButton.displayName;
|
48
|
+
const w = l.forwardRef(({ className: o, children: r, position: a = "popper", ...d }, p) => /* @__PURE__ */ t(e.Portal, { children: /* @__PURE__ */ n(
|
49
|
+
e.Content,
|
50
|
+
{
|
51
|
+
ref: p,
|
52
|
+
className: s(
|
53
|
+
"relative z-50 max-h-96 min-w-[8rem] overflow-hidden rounded-md border bg-popover text-popover-foreground shadow-md data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 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",
|
54
|
+
a === "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",
|
55
|
+
o
|
56
|
+
),
|
57
|
+
position: a,
|
58
|
+
...d,
|
59
|
+
children: [
|
60
|
+
/* @__PURE__ */ t(c, {}),
|
61
|
+
/* @__PURE__ */ t(
|
62
|
+
e.Viewport,
|
63
|
+
{
|
64
|
+
className: s(
|
65
|
+
"p-1",
|
66
|
+
a === "popper" && "h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"
|
67
|
+
),
|
68
|
+
children: r
|
69
|
+
}
|
70
|
+
),
|
71
|
+
/* @__PURE__ */ t(m, {})
|
72
|
+
]
|
73
|
+
}
|
74
|
+
) }));
|
75
|
+
w.displayName = e.Content.displayName;
|
76
|
+
const y = l.forwardRef(({ className: o, ...r }, a) => /* @__PURE__ */ t(
|
77
|
+
e.Label,
|
78
|
+
{
|
79
|
+
ref: a,
|
80
|
+
className: s("px-2 py-1.5 text-sm font-semibold", o),
|
81
|
+
...r
|
82
|
+
}
|
83
|
+
));
|
84
|
+
y.displayName = e.Label.displayName;
|
85
|
+
const g = l.forwardRef(({ className: o, children: r, ...a }, d) => /* @__PURE__ */ n(
|
86
|
+
e.Item,
|
87
|
+
{
|
88
|
+
ref: d,
|
89
|
+
className: s(
|
90
|
+
"relative flex w-full cursor-default select-none items-center rounded-sm py-1.5 pl-2 pr-8 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
|
91
|
+
o
|
92
|
+
),
|
93
|
+
...a,
|
94
|
+
children: [
|
95
|
+
/* @__PURE__ */ t("span", { className: "absolute right-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ t(e.ItemIndicator, { children: /* @__PURE__ */ t(u, { className: "h-4 w-4" }) }) }),
|
96
|
+
/* @__PURE__ */ t(e.ItemText, { children: r })
|
97
|
+
]
|
98
|
+
}
|
99
|
+
));
|
100
|
+
g.displayName = e.Item.displayName;
|
101
|
+
const N = l.forwardRef(({ className: o, ...r }, a) => /* @__PURE__ */ t(
|
102
|
+
e.Separator,
|
103
|
+
{
|
104
|
+
ref: a,
|
105
|
+
className: s("-mx-1 my-1 h-px bg-muted", o),
|
106
|
+
...r
|
107
|
+
}
|
108
|
+
));
|
109
|
+
N.displayName = e.Separator.displayName;
|
110
|
+
export {
|
111
|
+
w as SelectContent,
|
112
|
+
R as SelectGroup,
|
113
|
+
g as SelectItem,
|
114
|
+
y as SelectLabel,
|
115
|
+
v as SelectRoot,
|
116
|
+
m as SelectScrollDownButton,
|
117
|
+
c as SelectScrollUpButton,
|
118
|
+
N as SelectSeparator,
|
119
|
+
h as SelectTrigger,
|
120
|
+
C as SelectValue
|
121
|
+
};
|
package/Select/index.mjs
ADDED
@@ -0,0 +1,15 @@
|
|
1
|
+
import { SelectContent as l, SelectGroup as o, SelectItem as S, SelectLabel as c, SelectRoot as r, SelectScrollDownButton as n, SelectScrollUpButton as p, SelectSeparator as a, SelectTrigger as u, SelectValue as m } from "./SelectRoot.mjs";
|
2
|
+
import { Select as g } from "./Select.mjs";
|
3
|
+
export {
|
4
|
+
g as Select,
|
5
|
+
l as SelectContent,
|
6
|
+
o as SelectGroup,
|
7
|
+
S as SelectItem,
|
8
|
+
c as SelectLabel,
|
9
|
+
r as SelectRoot,
|
10
|
+
n as SelectScrollDownButton,
|
11
|
+
p as SelectScrollUpButton,
|
12
|
+
a as SelectSeparator,
|
13
|
+
u as SelectTrigger,
|
14
|
+
m as SelectValue
|
15
|
+
};
|
@@ -0,0 +1,4 @@
|
|
1
|
+
import * as React from "react";
|
2
|
+
import * as SeparatorPrimitive from "@radix-ui/react-separator";
|
3
|
+
declare const Separator: React.ForwardRefExoticComponent<Omit<SeparatorPrimitive.SeparatorProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
4
|
+
export { Separator };
|
@@ -0,0 +1,24 @@
|
|
1
|
+
import { jsx as e } from "react/jsx-runtime";
|
2
|
+
import * as i from "react";
|
3
|
+
import * as o from "@radix-ui/react-separator";
|
4
|
+
import { cn as l } from "@oneplatformdev/utils";
|
5
|
+
const s = i.forwardRef(
|
6
|
+
({ className: a, orientation: r = "horizontal", decorative: t = !0, ...m }, p) => /* @__PURE__ */ e(
|
7
|
+
o.Root,
|
8
|
+
{
|
9
|
+
ref: p,
|
10
|
+
decorative: t,
|
11
|
+
orientation: r,
|
12
|
+
className: l(
|
13
|
+
"shrink-0 bg-border",
|
14
|
+
r === "horizontal" ? "h-[1px] w-full" : "h-full w-[1px]",
|
15
|
+
a
|
16
|
+
),
|
17
|
+
...m
|
18
|
+
}
|
19
|
+
)
|
20
|
+
);
|
21
|
+
s.displayName = o.Root.displayName;
|
22
|
+
export {
|
23
|
+
s as Separator
|
24
|
+
};
|