@lotte-innovate/ui-component-test 0.0.49 → 0.0.51
Sign up to get free protection for your applications and to get access to all the features.
- package/README.md +78 -281
- package/dist/globals.css +4 -0
- package/dist/lib/Typography/Header/index.d.ts +1 -1
- package/dist/lib/Typography/Header/{index.jsx → index.js} +4 -7
- package/dist/lib/Typography/Text/index.d.ts +1 -1
- package/dist/lib/Typography/Text/{index.jsx → index.js} +5 -8
- package/dist/lib/components/Accordion/index.d.ts +1 -1
- package/dist/lib/components/Accordion/{index.jsx → index.js} +7 -19
- package/dist/lib/components/AlertDialog/AlertDialogAction.d.ts +1 -1
- package/dist/lib/components/AlertDialog/{AlertDialogAction.jsx → AlertDialogAction.js} +5 -6
- package/dist/lib/components/AlertDialog/AlertDialogCancel.d.ts +1 -1
- package/dist/lib/components/AlertDialog/{AlertDialogCancel.jsx → AlertDialogCancel.js} +5 -6
- package/dist/lib/components/AlertDialog/{AlertDialogContent.jsx → AlertDialogContent.js} +5 -9
- package/dist/lib/components/AlertDialog/{AlertDialogDescription.jsx → AlertDialogDescription.js} +15 -5
- package/dist/lib/components/AlertDialog/AlertDialogRoot.d.ts +1 -1
- package/dist/lib/components/AlertDialog/{AlertDialogRoot.jsx → AlertDialogRoot.js} +14 -6
- package/dist/lib/components/AlertDialog/{AlertDialogTitle.jsx → AlertDialogTitle.js} +15 -5
- package/dist/lib/components/AlertDialog/AlertDialogTrigger.d.ts +1 -1
- package/dist/lib/components/AlertDialog/{AlertDialogTrigger.jsx → AlertDialogTrigger.js} +5 -6
- package/dist/lib/components/AspectRatio/{index.jsx → index.js} +5 -6
- package/dist/lib/components/Avatar/{index.jsx → index.js} +5 -9
- package/dist/lib/components/Badge/index.d.ts +1 -1
- package/dist/lib/components/Badge/{index.jsx → index.js} +5 -6
- package/dist/lib/components/BarChart/index.d.ts +2 -3
- package/dist/lib/components/BarChart/{index.jsx → index.js} +7 -6
- package/dist/lib/components/BubbleChart/index.d.ts +2 -3
- package/dist/lib/components/BubbleChart/{index.jsx → index.js} +7 -7
- package/dist/lib/components/Button/index.d.ts +1 -1
- package/dist/lib/components/Button/{index.jsx → index.js} +5 -6
- package/dist/lib/components/Callout/{CalloutIcon.jsx → CalloutIcon.js} +5 -10
- package/dist/lib/components/Callout/CalloutRoot.d.ts +1 -1
- package/dist/lib/components/Callout/{CalloutRoot.jsx → CalloutRoot.js} +5 -8
- package/dist/lib/components/Callout/{CalloutText.jsx → CalloutText.js} +15 -5
- package/dist/lib/components/Card/index.d.ts +1 -1
- package/dist/lib/components/Card/{index.jsx → index.js} +5 -6
- package/dist/lib/components/Checkbox/index.d.ts +1 -1
- package/dist/lib/components/Checkbox/{index.jsx → index.js} +6 -14
- package/dist/lib/components/CheckboxCard/index.d.ts +2 -2
- package/dist/lib/components/CheckboxCard/{index.jsx → index.js} +7 -9
- package/dist/lib/components/CheckboxGroup/CheckboxGroupItem.d.ts +1 -1
- package/dist/lib/components/CheckboxGroup/{CheckboxGroupItem.jsx → CheckboxGroupItem.js} +15 -7
- package/dist/lib/components/CheckboxGroup/CheckboxGroupRoot.d.ts +2 -2
- package/dist/lib/components/CheckboxGroup/{CheckboxGroupRoot.jsx → CheckboxGroupRoot.js} +3 -6
- package/dist/lib/components/CheckboxGroup/index.d.ts +1 -1
- package/dist/lib/components/ContextMenu/{ContextMenuCheckboxItem.jsx → ContextMenuCheckboxItem.js} +16 -9
- package/dist/lib/components/ContextMenu/{ContextMenuContent.jsx → ContextMenuContent.js} +5 -8
- package/dist/lib/components/ContextMenu/{ContextMenuGroup.jsx → ContextMenuGroup.js} +14 -4
- package/dist/lib/components/ContextMenu/{ContextMenuItem.jsx → ContextMenuItem.js} +5 -7
- package/dist/lib/components/ContextMenu/{ContextMenuItemIndicator.jsx → ContextMenuItemIndicator.js} +5 -6
- package/dist/lib/components/ContextMenu/{ContextMenuLabel.jsx → ContextMenuLabel.js} +5 -6
- package/dist/lib/components/ContextMenu/{ContextMenuRadioGroup.jsx → ContextMenuRadioGroup.js} +14 -6
- package/dist/lib/components/ContextMenu/{ContextMenuRadioItem.jsx → ContextMenuRadioItem.js} +16 -9
- package/dist/lib/components/ContextMenu/ContextMenuRoot.d.ts +1 -1
- package/dist/lib/components/ContextMenu/{ContextMenuRoot.jsx → ContextMenuRoot.js} +14 -6
- package/dist/lib/components/ContextMenu/{ContextMenuSeparator.jsx → ContextMenuSeparator.js} +15 -5
- package/dist/lib/components/ContextMenu/{ContextMenuSubContent.jsx → ContextMenuSubContent.js} +9 -12
- package/dist/lib/components/ContextMenu/{ContextMenuSubTrigger.jsx → ContextMenuSubTrigger.js} +16 -11
- package/dist/lib/components/ContextMenu/{ContextMenuTrigger.jsx → ContextMenuTrigger.js} +15 -5
- package/dist/lib/components/DataList/{DataListItem.jsx → DataListItem.js} +5 -6
- package/dist/lib/components/DataList/{DataListLabel.jsx → DataListLabel.js} +5 -6
- package/dist/lib/components/DataList/{DataListRoot.jsx → DataListRoot.js} +15 -7
- package/dist/lib/components/DataList/{DataListValue.jsx → DataListValue.js} +5 -6
- package/dist/lib/components/Dialog/{DialogAction.jsx → DialogAction.js} +16 -6
- package/dist/lib/components/Dialog/{DialogCancel.jsx → DialogCancel.js} +15 -5
- package/dist/lib/components/Dialog/{DialogContent.jsx → DialogContent.js} +5 -6
- package/dist/lib/components/Dialog/{DialogDescription.jsx → DialogDescription.js} +15 -5
- package/dist/lib/components/Dialog/DialogRoot.d.ts +1 -1
- package/dist/lib/components/Dialog/{DialogRoot.jsx → DialogRoot.js} +14 -6
- package/dist/lib/components/Dialog/{DialogSlot.jsx → DialogSlot.js} +15 -5
- package/dist/lib/components/Dialog/{DialogTitle.jsx → DialogTitle.js} +15 -5
- package/dist/lib/components/Dialog/{DialogTrigger.jsx → DialogTrigger.js} +14 -4
- package/dist/lib/components/Dialog/index.d.ts +1 -1
- package/dist/lib/components/DoughnutChart/index.d.ts +2 -3
- package/dist/lib/components/DoughnutChart/{index.jsx → index.js} +6 -6
- package/dist/lib/components/DropdownMenu/{DropdonMenuRadioGroup.jsx → DropdonMenuRadioGroup.js} +13 -3
- package/dist/lib/components/DropdownMenu/{DropdonMenuSubContent.jsx → DropdonMenuSubContent.js} +9 -12
- package/dist/lib/components/DropdownMenu/{DropdownMenuCheckboxItem.jsx → DropdownMenuCheckboxItem.js} +16 -9
- package/dist/lib/components/DropdownMenu/{DropdownMenuContent.jsx → DropdownMenuContent.js} +5 -8
- package/dist/lib/components/DropdownMenu/DropdownMenuItem.d.ts +1 -1
- package/dist/lib/components/DropdownMenu/{DropdownMenuItem.jsx → DropdownMenuItem.js} +5 -7
- package/dist/lib/components/DropdownMenu/{DropdownMenuItemIndicator.jsx → DropdownMenuItemIndicator.js} +5 -6
- package/dist/lib/components/DropdownMenu/{DropdownMenuLable.jsx → DropdownMenuLable.js} +15 -5
- package/dist/lib/components/DropdownMenu/{DropdownMenuRadioItem.jsx → DropdownMenuRadioItem.js} +16 -9
- package/dist/lib/components/DropdownMenu/DropdownMenuRoot.d.ts +2 -2
- package/dist/lib/components/DropdownMenu/{DropdownMenuRoot.jsx → DropdownMenuRoot.js} +14 -4
- package/dist/lib/components/DropdownMenu/{DropdownMenuSeparator.jsx → DropdownMenuSeparator.js} +15 -3
- package/dist/lib/components/DropdownMenu/{DropdownMenuSub.jsx → DropdownMenuSub.js} +14 -2
- package/dist/lib/components/DropdownMenu/{DropdownMenuSubTrigger.jsx → DropdownMenuSubTrigger.js} +16 -9
- package/dist/lib/components/DropdownMenu/DropdownMenuTrigger.d.ts +1 -1
- package/dist/lib/components/DropdownMenu/{DropdownMenuTrigger.jsx → DropdownMenuTrigger.js} +15 -5
- package/dist/lib/components/DropdownMenu/index.d.ts +1 -1
- package/dist/lib/components/HoverCard/{HoverCardContent.jsx → HoverCardContent.js} +5 -6
- package/dist/lib/components/HoverCard/HoverCardRoot.d.ts +1 -1
- package/dist/lib/components/HoverCard/{HoverCardRoot.jsx → HoverCardRoot.js} +14 -6
- package/dist/lib/components/HoverCard/{HoverCardTrigger.jsx → HoverCardTrigger.js} +14 -4
- package/dist/lib/components/HoverCard/index.d.ts +1 -1
- package/dist/lib/components/IconButton/index.d.ts +1 -1
- package/dist/lib/components/IconButton/{index.jsx → index.js} +4 -5
- package/dist/lib/components/Inset/{index.jsx → index.js} +5 -8
- package/dist/lib/components/Label/index.d.ts +1 -1
- package/dist/lib/components/Label/{index.jsx → index.js} +4 -5
- package/dist/lib/components/LineChart/index.d.ts +2 -3
- package/dist/lib/components/LineChart/{index.jsx → index.js} +7 -6
- package/dist/lib/components/Menubar/{MenubarCheckboxItem.jsx → MenubarCheckboxItem.js} +16 -9
- package/dist/lib/components/Menubar/{MenubarContent.jsx → MenubarContent.js} +9 -12
- package/dist/lib/components/Menubar/{MenubarItem.jsx → MenubarItem.js} +5 -7
- package/dist/lib/components/Menubar/{MenubarItemIndicator.jsx → MenubarItemIndicator.js} +5 -6
- package/dist/lib/components/Menubar/{MenubarMenu.jsx → MenubarMenu.js} +14 -2
- package/dist/lib/components/Menubar/{MenubarRadioGroup.jsx → MenubarRadioGroup.js} +14 -6
- package/dist/lib/components/Menubar/{MenubarRadioItem.jsx → MenubarRadioItem.js} +16 -9
- package/dist/lib/components/Menubar/MenubarRoot.d.ts +1 -1
- package/dist/lib/components/Menubar/{MenubarRoot.jsx → MenubarRoot.js} +5 -8
- package/dist/lib/components/Menubar/{MenubarSeparator.jsx → MenubarSeparator.js} +15 -5
- package/dist/lib/components/Menubar/{MenubarSub.jsx → MenubarSub.js} +14 -2
- package/dist/lib/components/Menubar/{MenubarSubContent.jsx → MenubarSubContent.js} +6 -7
- package/dist/lib/components/Menubar/{MenubarSubTrigger.jsx → MenubarSubTrigger.js} +16 -9
- package/dist/lib/components/Menubar/{MenubarTrigger.jsx → MenubarTrigger.js} +5 -6
- package/dist/lib/components/NavigationMenu/{NavigationMenuContent.jsx → NavigationMenuContent.js} +5 -6
- package/dist/lib/components/NavigationMenu/NavigationMenuIndicator.js +31 -0
- package/dist/lib/components/NavigationMenu/{NavigationMenuItem.jsx → NavigationMenuItem.js} +14 -4
- package/dist/lib/components/NavigationMenu/{NavigationMenuLink.jsx → NavigationMenuLink.js} +5 -6
- package/dist/lib/components/NavigationMenu/{NavigationMenuList.jsx → NavigationMenuList.js} +5 -7
- package/dist/lib/components/NavigationMenu/NavigationMenuRoot.d.ts +1 -1
- package/dist/lib/components/NavigationMenu/{NavigationMenuRoot.jsx → NavigationMenuRoot.js} +15 -7
- package/dist/lib/components/NavigationMenu/{NavigationMenuTrigger.jsx → NavigationMenuTrigger.js} +5 -7
- package/dist/lib/components/NavigationMenu/{NavigationMenuViewport.jsx → NavigationMenuViewport.js} +5 -6
- package/dist/lib/components/PieChart/index.d.ts +2 -3
- package/dist/lib/components/PieChart/{index.jsx → index.js} +6 -6
- package/dist/lib/components/Popover/{PopoverClose.jsx → PopoverClose.js} +15 -5
- package/dist/lib/components/Popover/{PopoverContent.jsx → PopoverContent.js} +5 -6
- package/dist/lib/components/Popover/PopoverRoot.d.ts +1 -1
- package/dist/lib/components/Popover/{PopoverRoot.jsx → PopoverRoot.js} +14 -6
- package/dist/lib/components/Popover/{PopoverTrigger.jsx → PopoverTrigger.js} +14 -4
- package/dist/lib/components/Popover/index.d.ts +1 -1
- package/dist/lib/components/Progress/{index.jsx → index.js} +5 -6
- package/dist/lib/components/RadarChart/index.d.ts +2 -3
- package/dist/lib/components/RadarChart/{index.jsx → index.js} +7 -7
- package/dist/lib/components/Radio/index.d.ts +1 -1
- package/dist/lib/components/Radio/{index.jsx → index.js} +15 -10
- package/dist/lib/components/RadioCards/{RadioCardsItem.jsx → RadioCardsItem.js} +15 -5
- package/dist/lib/components/RadioCards/{RadioCardsRoot.jsx → RadioCardsRoot.js} +5 -10
- package/dist/lib/components/RadioGroup/{RadioGroupItem.jsx → RadioGroupItem.js} +15 -5
- package/dist/lib/components/RadioGroup/RadioGroupRoot.d.ts +1 -1
- package/dist/lib/components/RadioGroup/{RadioGroupRoot.jsx → RadioGroupRoot.js} +15 -9
- package/dist/lib/components/ScrollArea/{index.jsx → index.js} +14 -6
- package/dist/lib/components/SegmentedControl/{SegmentedControlItem.jsx → SegmentedControlItem.js} +15 -5
- package/dist/lib/components/SegmentedControl/SegmentedControlRoot.d.ts +1 -1
- package/dist/lib/components/SegmentedControl/{SegmentedControlRoot.jsx → SegmentedControlRoot.js} +4 -7
- package/dist/lib/components/SegmentedControl/index.d.ts +1 -1
- package/dist/lib/components/Select/index.d.ts +1 -1
- package/dist/lib/components/Select/{index.jsx → index.js} +10 -27
- package/dist/lib/components/Separator/{index.jsx → index.js} +4 -7
- package/dist/lib/components/Skeleton/index.d.ts +1 -1
- package/dist/lib/components/Skeleton/{index.jsx → index.js} +4 -7
- package/dist/lib/components/Slider/index.d.ts +1 -1
- package/dist/lib/components/Slider/{index.jsx → index.js} +4 -5
- package/dist/lib/components/Spinner/index.d.ts +1 -1
- package/dist/lib/components/Spinner/{index.jsx → index.js} +4 -7
- package/dist/lib/components/TabNav/{index.jsx → index.js} +15 -9
- package/dist/lib/components/Table/index.d.ts +1 -1
- package/dist/lib/components/Table/{index.jsx → index.js} +10 -25
- package/dist/lib/components/Tabs/{index.jsx → index.js} +7 -16
- package/dist/lib/components/TextArea/index.d.ts +1 -1
- package/dist/lib/components/TextArea/{index.jsx → index.js} +4 -5
- package/dist/lib/components/TextField/index.d.ts +1 -1
- package/dist/lib/components/TextField/{index.jsx → index.js} +5 -10
- package/dist/lib/components/Toast/ToastActionButton.d.ts +1 -1
- package/dist/lib/components/Toast/{ToastActionButton.jsx → ToastActionButton.js} +6 -7
- package/dist/lib/components/Toast/ToastDescription.d.ts +1 -1
- package/dist/lib/components/Toast/{ToastDescription.jsx → ToastDescription.js} +15 -7
- package/dist/lib/components/Toast/{ToastRoot.jsx → ToastRoot.js} +5 -11
- package/dist/lib/components/Toast/ToastTitle.d.ts +1 -1
- package/dist/lib/components/Toast/{ToastTitle.jsx → ToastTitle.js} +15 -5
- package/dist/lib/components/Toggle/ToggleWithText.d.ts +1 -1
- package/dist/lib/components/Toggle/{ToggleWithText.jsx → ToggleWithText.js} +7 -9
- package/dist/lib/components/Toggle/index.d.ts +1 -1
- package/dist/lib/components/Toggle/{index.jsx → index.js} +5 -6
- package/dist/lib/components/ToggleGroup/ToggleGroupItem.d.ts +1 -1
- package/dist/lib/components/ToggleGroup/{ToggleGroupItem.jsx → ToggleGroupItem.js} +16 -6
- package/dist/lib/components/ToggleGroup/ToggleGroupRoot.d.ts +1 -1
- package/dist/lib/components/ToggleGroup/{ToggleGroupRoot.jsx → ToggleGroupRoot.js} +5 -10
- package/dist/lib/components/ToggleSwitch/{index.jsx → index.js} +5 -9
- package/dist/lib/components/Tooltip/index.d.ts +1 -1
- package/dist/lib/components/Tooltip/{index.jsx → index.js} +4 -13
- package/dist/lib/constants.js +2 -2
- package/dist/lib/index.d.ts +2 -2
- package/dist/lib/index.js +2 -2
- package/dist/lib/utils/useDarkMode.js +1 -1
- package/dist/tailwind.config.d.ts +3 -0
- package/dist/tailwind.config.js +141 -0
- package/package.json +4 -2
- package/dist/lib/components/NavigationMenu/NavigationMenuIndicator.jsx +0 -22
- /package/dist/lib/components/AlertDialog/{index.jsx → index.js} +0 -0
- /package/dist/lib/components/Callout/{index.jsx → index.js} +0 -0
- /package/dist/lib/components/CheckboxGroup/{index.jsx → index.js} +0 -0
- /package/dist/lib/components/ContextMenu/{index.jsx → index.js} +0 -0
- /package/dist/lib/components/DataList/{index.jsx → index.js} +0 -0
- /package/dist/lib/components/Dialog/{index.jsx → index.js} +0 -0
- /package/dist/lib/components/DropdownMenu/{index.jsx → index.js} +0 -0
- /package/dist/lib/components/HoverCard/{index.jsx → index.js} +0 -0
- /package/dist/lib/components/Menubar/{index.jsx → index.js} +0 -0
- /package/dist/lib/components/NavigationMenu/{index.jsx → index.js} +0 -0
- /package/dist/lib/components/Popover/{index.jsx → index.js} +0 -0
- /package/dist/lib/components/RadioCards/{index.jsx → index.js} +0 -0
- /package/dist/lib/components/RadioGroup/{index.jsx → index.js} +0 -0
- /package/dist/lib/components/SegmentedControl/{index.jsx → index.js} +0 -0
- /package/dist/lib/components/Toast/{index.jsx → index.js} +0 -0
- /package/dist/lib/components/ToggleGroup/{index.jsx → index.js} +0 -0
package/dist/lib/components/ContextMenu/{ContextMenuRadioGroup.jsx → ContextMenuRadioGroup.js}
RENAMED
@@ -1,3 +1,14 @@
|
|
1
|
+
var __assign = (this && this.__assign) || function () {
|
2
|
+
__assign = Object.assign || function(t) {
|
3
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
4
|
+
s = arguments[i];
|
5
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
6
|
+
t[p] = s[p];
|
7
|
+
}
|
8
|
+
return t;
|
9
|
+
};
|
10
|
+
return __assign.apply(this, arguments);
|
11
|
+
};
|
1
12
|
var __rest = (this && this.__rest) || function (s, e) {
|
2
13
|
var t = {};
|
3
14
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
@@ -9,15 +20,12 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
9
20
|
}
|
10
21
|
return t;
|
11
22
|
};
|
12
|
-
import
|
23
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
24
|
+
import { createContext, forwardRef } from 'react';
|
13
25
|
import * as ContextMenuPrimitive from '@radix-ui/react-context-menu';
|
14
26
|
export var RadioContext = createContext({ selectedValue: '' });
|
15
27
|
export var ContextMenuRadioGroup = forwardRef(function (_a, ref) {
|
16
28
|
var className = _a.className, children = _a.children, value = _a.value, props = __rest(_a, ["className", "children", "value"]);
|
17
|
-
return (
|
18
|
-
<RadioContext.Provider value={{ selectedValue: value !== null && value !== void 0 ? value : '' }}>
|
19
|
-
{children}
|
20
|
-
</RadioContext.Provider>
|
21
|
-
</ContextMenuPrimitive.RadioGroup>);
|
29
|
+
return (_jsx(ContextMenuPrimitive.RadioGroup, __assign({ ref: ref, className: className }, props, { children: _jsx(RadioContext.Provider, { value: { selectedValue: value !== null && value !== void 0 ? value : '' }, children: children }) })));
|
22
30
|
});
|
23
31
|
ContextMenuRadioGroup.displayName = 'ContextMenu.RadioGroup';
|
package/dist/lib/components/ContextMenu/{ContextMenuRadioItem.jsx → ContextMenuRadioItem.js}
RENAMED
@@ -1,3 +1,14 @@
|
|
1
|
+
var __assign = (this && this.__assign) || function () {
|
2
|
+
__assign = Object.assign || function(t) {
|
3
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
4
|
+
s = arguments[i];
|
5
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
6
|
+
t[p] = s[p];
|
7
|
+
}
|
8
|
+
return t;
|
9
|
+
};
|
10
|
+
return __assign.apply(this, arguments);
|
11
|
+
};
|
1
12
|
var __rest = (this && this.__rest) || function (s, e) {
|
2
13
|
var t = {};
|
3
14
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
@@ -9,11 +20,12 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
9
20
|
}
|
10
21
|
return t;
|
11
22
|
};
|
12
|
-
import
|
23
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
24
|
+
import { forwardRef, useContext } from 'react';
|
13
25
|
import * as ContextMenuPrimitive from '@radix-ui/react-context-menu';
|
14
|
-
import { cn } from 'lib/utils/utils';
|
26
|
+
import { cn } from '../../../lib/utils/utils';
|
15
27
|
import { DotFilledIcon } from '@radix-ui/react-icons';
|
16
|
-
import { menuItemAppearanceStyle } from 'lib/constants';
|
28
|
+
import { menuItemAppearanceStyle } from '../../../lib/constants';
|
17
29
|
import { useContextMenuContext } from './ContextMenuRoot';
|
18
30
|
import { contextMenuItemVariants } from './ContextMenuItem';
|
19
31
|
import { RadioContext } from './ContextMenuRadioGroup';
|
@@ -27,11 +39,6 @@ export var ContextMenuRadioItem = forwardRef(function (_a, ref) {
|
|
27
39
|
size: size,
|
28
40
|
}), 'pl-7', menuItemAppearanceStyle(appearance, color), className);
|
29
41
|
var radioGroup = useContext(RadioContext);
|
30
|
-
return (
|
31
|
-
<ContextMenuItemIndicator forceMount radius={'full'} size={size}>
|
32
|
-
{radioGroup.selectedValue === props.value && <DotFilledIcon />}
|
33
|
-
</ContextMenuItemIndicator>
|
34
|
-
{children}
|
35
|
-
</ContextMenuPrimitive.RadioItem>);
|
42
|
+
return (_jsxs(ContextMenuPrimitive.RadioItem, __assign({ ref: ref, className: itemClassName }, props, { children: [_jsx(ContextMenuItemIndicator, { forceMount: true, radius: 'full', size: size, children: radioGroup.selectedValue === props.value && _jsx(DotFilledIcon, {}) }), children] })));
|
36
43
|
});
|
37
44
|
ContextMenuRadioItem.displayName = 'ContextMenu.RadioItem';
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import React from 'react';
|
2
2
|
import * as ContextMenuPrimitive from '@radix-ui/react-context-menu';
|
3
3
|
import { VariantProps } from 'class-variance-authority';
|
4
|
-
import { IColor } from 'lib/types';
|
4
|
+
import { IColor } from '../../../lib/types';
|
5
5
|
import { contextMenuContentVariants } from './ContextMenuContent';
|
6
6
|
import { contextMenuItemVariants } from './ContextMenuItem';
|
7
7
|
export interface ContextMenuProps extends VariantProps<typeof contextMenuContentVariants>, VariantProps<typeof contextMenuItemVariants> {
|
@@ -1,3 +1,14 @@
|
|
1
|
+
var __assign = (this && this.__assign) || function () {
|
2
|
+
__assign = Object.assign || function(t) {
|
3
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
4
|
+
s = arguments[i];
|
5
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
6
|
+
t[p] = s[p];
|
7
|
+
}
|
8
|
+
return t;
|
9
|
+
};
|
10
|
+
return __assign.apply(this, arguments);
|
11
|
+
};
|
1
12
|
var __rest = (this && this.__rest) || function (s, e) {
|
2
13
|
var t = {};
|
3
14
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
@@ -9,7 +20,8 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
9
20
|
}
|
10
21
|
return t;
|
11
22
|
};
|
12
|
-
import
|
23
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
24
|
+
import { createContext, forwardRef, useContext, useMemo, } from 'react';
|
13
25
|
import * as ContextMenuPrimitive from '@radix-ui/react-context-menu';
|
14
26
|
var ContextMenuContext = createContext({
|
15
27
|
radius: 'medium',
|
@@ -24,11 +36,7 @@ export var useContextMenuContext = function () {
|
|
24
36
|
export var ContextMenuRoot = forwardRef(function (_a, ref) {
|
25
37
|
var children = _a.children, radius = _a.radius, size = _a.size, scaling = _a.scaling, color = _a.color, appearance = _a.appearance, props = __rest(_a, ["children", "radius", "size", "scaling", "color", "appearance"]);
|
26
38
|
var contextValue = useMemo(function () { return ({ radius: radius, size: size, scaling: scaling, color: color, appearance: appearance }); }, [radius, size, scaling, color, appearance]);
|
27
|
-
return (
|
28
|
-
<div ref={ref}>
|
29
|
-
<ContextMenuPrimitive.Root {...props}>{children}</ContextMenuPrimitive.Root>
|
30
|
-
</div>
|
31
|
-
</ContextMenuContext.Provider>);
|
39
|
+
return (_jsx(ContextMenuContext.Provider, { value: contextValue, children: _jsx("div", { ref: ref, children: _jsx(ContextMenuPrimitive.Root, __assign({}, props, { children: children })) }) }));
|
32
40
|
});
|
33
41
|
ContextMenuRoot.displayName = 'ContextMenu.Root';
|
34
42
|
export default ContextMenuRoot;
|
package/dist/lib/components/ContextMenu/{ContextMenuSeparator.jsx → ContextMenuSeparator.js}
RENAMED
@@ -1,3 +1,14 @@
|
|
1
|
+
var __assign = (this && this.__assign) || function () {
|
2
|
+
__assign = Object.assign || function(t) {
|
3
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
4
|
+
s = arguments[i];
|
5
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
6
|
+
t[p] = s[p];
|
7
|
+
}
|
8
|
+
return t;
|
9
|
+
};
|
10
|
+
return __assign.apply(this, arguments);
|
11
|
+
};
|
1
12
|
var __rest = (this && this.__rest) || function (s, e) {
|
2
13
|
var t = {};
|
3
14
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
@@ -9,13 +20,12 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
9
20
|
}
|
10
21
|
return t;
|
11
22
|
};
|
12
|
-
import
|
23
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
24
|
+
import { forwardRef } from 'react';
|
13
25
|
import * as ContextMenuPrimitive from '@radix-ui/react-context-menu';
|
14
|
-
import { cn } from 'lib/utils/utils';
|
26
|
+
import { cn } from '../../../lib/utils/utils';
|
15
27
|
export var ContextMenuSeparator = forwardRef(function (_a, ref) {
|
16
28
|
var className = _a.className, children = _a.children, props = __rest(_a, ["className", "children"]);
|
17
|
-
return (
|
18
|
-
{children}
|
19
|
-
</ContextMenuPrimitive.Separator>);
|
29
|
+
return (_jsx(ContextMenuPrimitive.Separator, __assign({ ref: ref, className: cn('h-[1px] m-[5px] bg-slate-6 dark:bg-slateDark-6', className) }, props, { children: children })));
|
20
30
|
});
|
21
31
|
ContextMenuSeparator.displayName = 'ContextMenu.Separator';
|
package/dist/lib/components/ContextMenu/{ContextMenuSubContent.jsx → ContextMenuSubContent.js}
RENAMED
@@ -20,11 +20,12 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
20
20
|
}
|
21
21
|
return t;
|
22
22
|
};
|
23
|
-
import
|
23
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
24
|
+
import { forwardRef } from 'react';
|
24
25
|
import * as ContextMenuPrimitive from '@radix-ui/react-context-menu';
|
25
|
-
import { cn } from 'lib/utils/utils';
|
26
|
+
import { cn } from '../../../lib/utils/utils';
|
26
27
|
import { cva } from 'class-variance-authority';
|
27
|
-
import { radiusVariants, scalingVariants } from 'lib/constants';
|
28
|
+
import { radiusVariants, scalingVariants } from '../../../lib/constants';
|
28
29
|
import { useContextMenuContext } from './ContextMenuRoot';
|
29
30
|
export var contextMenuSubContentVariants = cva("p-[5px] bg-white dark:bg-slateDark-1 will-change-[transform,opacity]\n shadow-[0px_10px_38px_-10px_rgba(22,_23,_24,_0.35),_0px_10px_20px_-15px_rgba(22,_23,_24,_0.2)] \n [animation-duration:_400ms] [animation-timing-function:_cubic-bezier(0.16,_1,_0.3,_1)]", {
|
30
31
|
variants: {
|
@@ -44,14 +45,10 @@ export var contextMenuSubContentVariants = cva("p-[5px] bg-white dark:bg-slateDa
|
|
44
45
|
export var ContextMenuSubContent = forwardRef(function (_a, ref) {
|
45
46
|
var className = _a.className, children = _a.children, props = __rest(_a, ["className", "children"]);
|
46
47
|
var _b = useContextMenuContext(), radius = _b.radius, size = _b.size, scaling = _b.scaling;
|
47
|
-
return (
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
}), className)} sideOffset={2} alignOffset={-5} {...props}>
|
53
|
-
{children}
|
54
|
-
</ContextMenuPrimitive.SubContent>
|
55
|
-
</ContextMenuPrimitive.Portal>);
|
48
|
+
return (_jsx(ContextMenuPrimitive.Portal, { children: _jsx(ContextMenuPrimitive.SubContent, __assign({ ref: ref, className: cn(contextMenuSubContentVariants({
|
49
|
+
radius: radius,
|
50
|
+
size: size,
|
51
|
+
scaling: scaling,
|
52
|
+
}), className), sideOffset: 2, alignOffset: -5 }, props, { children: children })) }));
|
56
53
|
});
|
57
54
|
ContextMenuSubContent.displayName = 'ContextMenu.SubContent';
|
package/dist/lib/components/ContextMenu/{ContextMenuSubTrigger.jsx → ContextMenuSubTrigger.js}
RENAMED
@@ -1,3 +1,14 @@
|
|
1
|
+
var __assign = (this && this.__assign) || function () {
|
2
|
+
__assign = Object.assign || function(t) {
|
3
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
4
|
+
s = arguments[i];
|
5
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
6
|
+
t[p] = s[p];
|
7
|
+
}
|
8
|
+
return t;
|
9
|
+
};
|
10
|
+
return __assign.apply(this, arguments);
|
11
|
+
};
|
1
12
|
var __rest = (this && this.__rest) || function (s, e) {
|
2
13
|
var t = {};
|
3
14
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
@@ -9,12 +20,13 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
9
20
|
}
|
10
21
|
return t;
|
11
22
|
};
|
12
|
-
import
|
23
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
24
|
+
import { forwardRef } from 'react';
|
13
25
|
import * as ContextMenuPrimitive from '@radix-ui/react-context-menu';
|
14
26
|
import { ChevronRightIcon } from '@radix-ui/react-icons';
|
15
|
-
import { cn } from 'lib/utils/utils';
|
27
|
+
import { cn } from '../../../lib/utils/utils';
|
16
28
|
import { contextMenuItemVariants } from './ContextMenuItem';
|
17
|
-
import { blackText, menuItemAppearanceStyle } from 'lib/constants';
|
29
|
+
import { blackText, menuItemAppearanceStyle } from '../../../lib/constants';
|
18
30
|
import { useContextMenuContext } from './ContextMenuRoot';
|
19
31
|
export var ContextMenuSubTrigger = forwardRef(function (_a, ref) {
|
20
32
|
var children = _a.children, className = _a.className, props = __rest(_a, ["children", "className"]);
|
@@ -23,13 +35,6 @@ export var ContextMenuSubTrigger = forwardRef(function (_a, ref) {
|
|
23
35
|
var iconClassName = cn('group-data-[disabled]:text-slate-8 ', appearance === 'solid' && blackText.includes(color)
|
24
36
|
? 'hover:fill-slate-12 dark:hover:fill-slateDark-1'
|
25
37
|
: "hover:fill-white dark:hover:fill-slateDark-12 ");
|
26
|
-
return (
|
27
|
-
<ContextMenuPrimitive.SubTrigger ref={ref} className={triggerClassName} {...props}>
|
28
|
-
{children}
|
29
|
-
<div className="ml-auto pl-5 ">
|
30
|
-
<ChevronRightIcon className={iconClassName}/>
|
31
|
-
</div>
|
32
|
-
</ContextMenuPrimitive.SubTrigger>
|
33
|
-
</ContextMenuPrimitive.Sub>);
|
38
|
+
return (_jsx(ContextMenuPrimitive.Sub, { children: _jsxs(ContextMenuPrimitive.SubTrigger, __assign({ ref: ref, className: triggerClassName }, props, { children: [children, _jsx("div", { className: "ml-auto pl-5 ", children: _jsx(ChevronRightIcon, { className: iconClassName }) })] })) }));
|
34
39
|
});
|
35
40
|
ContextMenuSubTrigger.displayName = 'ContextMenu.SubTrigger';
|
@@ -1,3 +1,14 @@
|
|
1
|
+
var __assign = (this && this.__assign) || function () {
|
2
|
+
__assign = Object.assign || function(t) {
|
3
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
4
|
+
s = arguments[i];
|
5
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
6
|
+
t[p] = s[p];
|
7
|
+
}
|
8
|
+
return t;
|
9
|
+
};
|
10
|
+
return __assign.apply(this, arguments);
|
11
|
+
};
|
1
12
|
var __rest = (this && this.__rest) || function (s, e) {
|
2
13
|
var t = {};
|
3
14
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
@@ -9,13 +20,12 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
9
20
|
}
|
10
21
|
return t;
|
11
22
|
};
|
12
|
-
import
|
23
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
24
|
+
import { forwardRef } from 'react';
|
13
25
|
import * as ContextMenuPrimitive from '@radix-ui/react-context-menu';
|
14
|
-
import { cn } from 'lib/utils/utils';
|
26
|
+
import { cn } from '../../../lib/utils/utils';
|
15
27
|
export var ContextMenuTrigger = forwardRef(function (_a, ref) {
|
16
28
|
var className = _a.className, children = _a.children, props = __rest(_a, ["className", "children"]);
|
17
|
-
return (
|
18
|
-
{children}
|
19
|
-
</ContextMenuPrimitive.Trigger>);
|
29
|
+
return (_jsx(ContextMenuPrimitive.Trigger, __assign({ ref: ref, className: cn("flex text-slate-12 dark:text-slateDark-12 text-base text-center justify-center", className) }, props, { children: children })));
|
20
30
|
});
|
21
31
|
ContextMenuTrigger.displayName = 'ContextMenu.Trigger';
|
@@ -20,11 +20,12 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
20
20
|
}
|
21
21
|
return t;
|
22
22
|
};
|
23
|
-
import
|
23
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
24
|
+
import { forwardRef } from 'react';
|
24
25
|
import { DataList as DataListTheme } from '@radix-ui/themes';
|
25
26
|
import { cva } from 'class-variance-authority';
|
26
|
-
import { cn } from 'lib/utils/utils';
|
27
|
-
import { scalingVariants } from 'lib/constants';
|
27
|
+
import { cn } from '../../../lib/utils/utils';
|
28
|
+
import { scalingVariants } from '../../../lib/constants';
|
28
29
|
import { useDataListContext } from './DataListRoot';
|
29
30
|
export var dataListItemVariants = cva('flex', {
|
30
31
|
variants: {
|
@@ -37,8 +38,6 @@ export var dataListItemVariants = cva('flex', {
|
|
37
38
|
export var DataListItem = forwardRef(function (_a, ref) {
|
38
39
|
var className = _a.className, children = _a.children, props = __rest(_a, ["className", "children"]);
|
39
40
|
var scaling = useDataListContext().scaling;
|
40
|
-
return (
|
41
|
-
{children}
|
42
|
-
</DataListTheme.Item>);
|
41
|
+
return (_jsx(DataListTheme.Item, __assign({ ref: ref }, props, { className: cn(dataListItemVariants({ scaling: scaling }), className), children: children })));
|
43
42
|
});
|
44
43
|
DataListItem.displayName = 'DataList.Item';
|
@@ -20,11 +20,12 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
20
20
|
}
|
21
21
|
return t;
|
22
22
|
};
|
23
|
-
import
|
23
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
24
|
+
import { forwardRef } from 'react';
|
24
25
|
import { DataList as DataListTheme } from '@radix-ui/themes';
|
25
26
|
import { cva } from 'class-variance-authority';
|
26
|
-
import { cn } from 'lib/utils/utils';
|
27
|
-
import { weightVariants } from 'lib/constants';
|
27
|
+
import { cn } from '../../../lib/utils/utils';
|
28
|
+
import { weightVariants } from '../../../lib/constants';
|
28
29
|
import { useDataListContext } from './DataListRoot';
|
29
30
|
export var dataListLabelVariants = cva('text-slateA-11 dark:text-slateDarkA-11 w-[120px] mb-1', {
|
30
31
|
variants: {
|
@@ -43,8 +44,6 @@ export var dataListLabelVariants = cva('text-slateA-11 dark:text-slateDarkA-11 w
|
|
43
44
|
export var DataListLabel = forwardRef(function (_a, ref) {
|
44
45
|
var children = _a.children, className = _a.className, weight = _a.weight, color = _a.color, props = __rest(_a, ["children", "className", "weight", "color"]);
|
45
46
|
var size = useDataListContext().size;
|
46
|
-
return (
|
47
|
-
<p className={cn(dataListLabelVariants({ weight: weight, size: size }), className)}>{children}</p>
|
48
|
-
</DataListTheme.Label>);
|
47
|
+
return (_jsx(DataListTheme.Label, __assign({ ref: ref }, props, { children: _jsx("p", { className: cn(dataListLabelVariants({ weight: weight, size: size }), className), children: children }) })));
|
49
48
|
});
|
50
49
|
DataListLabel.displayName = 'DataList.Label';
|
@@ -1,3 +1,14 @@
|
|
1
|
+
var __assign = (this && this.__assign) || function () {
|
2
|
+
__assign = Object.assign || function(t) {
|
3
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
4
|
+
s = arguments[i];
|
5
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
6
|
+
t[p] = s[p];
|
7
|
+
}
|
8
|
+
return t;
|
9
|
+
};
|
10
|
+
return __assign.apply(this, arguments);
|
11
|
+
};
|
1
12
|
var __rest = (this && this.__rest) || function (s, e) {
|
2
13
|
var t = {};
|
3
14
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
@@ -9,10 +20,11 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
9
20
|
}
|
10
21
|
return t;
|
11
22
|
};
|
12
|
-
import
|
23
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
24
|
+
import { createContext, forwardRef, useContext, useMemo, } from 'react';
|
13
25
|
import { DataList as DataListTheme } from '@radix-ui/themes';
|
14
26
|
import { cva } from 'class-variance-authority';
|
15
|
-
import { cn } from 'lib/utils/utils';
|
27
|
+
import { cn } from '../../../lib/utils/utils';
|
16
28
|
export var dataListVariants = cva('flex flex-col', {
|
17
29
|
variants: {
|
18
30
|
size: {
|
@@ -36,11 +48,7 @@ export var useDataListContext = function () {
|
|
36
48
|
export var DataListRoot = forwardRef(function (_a, ref) {
|
37
49
|
var children = _a.children, className = _a.className, size = _a.size, scaling = _a.scaling, color = _a.color, props = __rest(_a, ["children", "className", "size", "scaling", "color"]);
|
38
50
|
var contextValue = useMemo(function () { return ({ size: size, scaling: scaling, color: color }); }, [size, scaling, color]);
|
39
|
-
return (
|
40
|
-
<DataListTheme.Root ref={ref} {...props} className={cn(dataListVariants({ size: size }), className)}>
|
41
|
-
{children}
|
42
|
-
</DataListTheme.Root>
|
43
|
-
</DataListContext.Provider>);
|
51
|
+
return (_jsx(DataListContext.Provider, { value: contextValue, children: _jsx(DataListTheme.Root, __assign({ ref: ref }, props, { className: cn(dataListVariants({ size: size }), className), children: children })) }));
|
44
52
|
});
|
45
53
|
DataListRoot.displayName = 'DataList.Root';
|
46
54
|
export default DataListRoot;
|
@@ -20,11 +20,12 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
20
20
|
}
|
21
21
|
return t;
|
22
22
|
};
|
23
|
-
import
|
23
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
24
|
+
import { forwardRef } from 'react';
|
24
25
|
import { DataList as DataListTheme } from '@radix-ui/themes';
|
25
|
-
import { textColorStyle, weightVariants } from 'lib/constants';
|
26
|
+
import { textColorStyle, weightVariants } from '../../../lib/constants';
|
26
27
|
import { cva } from 'class-variance-authority';
|
27
|
-
import { cn } from 'lib/utils/utils';
|
28
|
+
import { cn } from '../../../lib/utils/utils';
|
28
29
|
import { useDataListContext } from './DataListRoot';
|
29
30
|
export var dataListValueVariants = cva('text-slate-12 dark:text-slateDark-12 w-[200px]', {
|
30
31
|
variants: {
|
@@ -45,8 +46,6 @@ export var dataListValueVariants = cva('text-slate-12 dark:text-slateDark-12 w-[
|
|
45
46
|
export var DataListValue = forwardRef(function (_a, ref) {
|
46
47
|
var children = _a.children, className = _a.className, weight = _a.weight, props = __rest(_a, ["children", "className", "weight"]);
|
47
48
|
var _b = useDataListContext(), size = _b.size, color = _b.color;
|
48
|
-
return (
|
49
|
-
{children}
|
50
|
-
</DataListTheme.Value>);
|
49
|
+
return (_jsx(DataListTheme.Value, __assign({ ref: ref, className: cn(dataListValueVariants({ weight: weight, size: size, color: color }), className) }, props, { children: children })));
|
51
50
|
});
|
52
51
|
DataListValue.displayName = 'DataList.Value';
|
@@ -1,3 +1,14 @@
|
|
1
|
+
var __assign = (this && this.__assign) || function () {
|
2
|
+
__assign = Object.assign || function(t) {
|
3
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
4
|
+
s = arguments[i];
|
5
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
6
|
+
t[p] = s[p];
|
7
|
+
}
|
8
|
+
return t;
|
9
|
+
};
|
10
|
+
return __assign.apply(this, arguments);
|
11
|
+
};
|
1
12
|
var __rest = (this && this.__rest) || function (s, e) {
|
2
13
|
var t = {};
|
3
14
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
@@ -9,12 +20,13 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
9
20
|
}
|
10
21
|
return t;
|
11
22
|
};
|
12
|
-
import
|
23
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
24
|
+
import { forwardRef, useContext } from 'react';
|
13
25
|
import { Dialog as DialogTheme } from '@radix-ui/themes';
|
14
26
|
import { cva } from 'class-variance-authority';
|
15
|
-
import { primaryColorStyle } from 'lib/constants';
|
27
|
+
import { primaryColorStyle } from '../../../lib/constants';
|
16
28
|
import { DialogContext } from './DialogRoot';
|
17
|
-
import { cn } from 'lib/utils/utils';
|
29
|
+
import { cn } from '../../../lib/utils/utils';
|
18
30
|
export var dialogActionVariants = cva('rounded-md inline-flex font-medium items-center justify-center px-[15px] hover:cursor-pointer', {
|
19
31
|
variants: {
|
20
32
|
radius: {
|
@@ -42,8 +54,6 @@ export var DialogAction = forwardRef(function (_a, ref) {
|
|
42
54
|
var children = _a.children, className = _a.className, props = __rest(_a, ["children", "className"]);
|
43
55
|
var _b = useContext(DialogContext), radius = _b.radius, size = _b.size, color = _b.color;
|
44
56
|
var buttonClassName = cn(dialogActionVariants({ radius: radius, size: size, color: color }), className);
|
45
|
-
return (
|
46
|
-
{children}
|
47
|
-
</DialogTheme.Close>);
|
57
|
+
return (_jsx(DialogTheme.Close, __assign({ ref: ref, className: buttonClassName }, props, { children: children })));
|
48
58
|
});
|
49
59
|
DialogAction.displayName = 'Dialog.Action';
|
@@ -1,3 +1,14 @@
|
|
1
|
+
var __assign = (this && this.__assign) || function () {
|
2
|
+
__assign = Object.assign || function(t) {
|
3
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
4
|
+
s = arguments[i];
|
5
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
6
|
+
t[p] = s[p];
|
7
|
+
}
|
8
|
+
return t;
|
9
|
+
};
|
10
|
+
return __assign.apply(this, arguments);
|
11
|
+
};
|
1
12
|
var __rest = (this && this.__rest) || function (s, e) {
|
2
13
|
var t = {};
|
3
14
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
@@ -9,11 +20,12 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
9
20
|
}
|
10
21
|
return t;
|
11
22
|
};
|
12
|
-
import
|
23
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
24
|
+
import { forwardRef, useContext } from 'react';
|
13
25
|
import { Dialog as DialogTheme } from '@radix-ui/themes';
|
14
26
|
import { cva } from 'class-variance-authority';
|
15
27
|
import { DialogContext } from './DialogRoot';
|
16
|
-
import { cn } from 'lib/utils/utils';
|
28
|
+
import { cn } from '../../../lib/utils/utils';
|
17
29
|
export var dialogCancelVariants = cva("rounded-md font-medium inline-flex justify-center items-center text-slate-11 bg-slate-3 outline-none border-none\n dark:text-slateDark-11 dark:bg-slateDark-3 dark:hover:bg-slateDarkA-4\n active:border-none hover:cursor-pointer hover:bg-slateA-4", {
|
18
30
|
variants: {
|
19
31
|
radius: {
|
@@ -38,8 +50,6 @@ export var dialogCancelVariants = cva("rounded-md font-medium inline-flex justif
|
|
38
50
|
export var DialogCancel = forwardRef(function (_a, ref) {
|
39
51
|
var children = _a.children, className = _a.className, props = __rest(_a, ["children", "className"]);
|
40
52
|
var _b = useContext(DialogContext), radius = _b.radius, size = _b.size;
|
41
|
-
return (
|
42
|
-
{children}
|
43
|
-
</DialogTheme.Close>);
|
53
|
+
return (_jsx(DialogTheme.Close, __assign({ ref: ref, className: cn(dialogCancelVariants({ radius: radius, size: size }), className) }, props, { children: children })));
|
44
54
|
});
|
45
55
|
DialogCancel.displayName = 'Dialog.Cancel';
|
@@ -20,12 +20,13 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
20
20
|
}
|
21
21
|
return t;
|
22
22
|
};
|
23
|
-
import
|
23
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
24
|
+
import { forwardRef, useContext } from 'react';
|
24
25
|
import { cva } from 'class-variance-authority';
|
25
26
|
import { Dialog as DialogTheme } from '@radix-ui/themes';
|
26
|
-
import { scalingVariants } from 'lib/constants';
|
27
|
+
import { scalingVariants } from '../../../lib/constants';
|
27
28
|
import { DialogContext } from './DialogRoot';
|
28
|
-
import { cn } from 'lib/utils/utils';
|
29
|
+
import { cn } from '../../../lib/utils/utils';
|
29
30
|
export var dialogContentVariants = cva("rounded-md focus:outline-none bg-white dark:bg-slateDark-1 \n shadow-[hsl(206_22%_7%_/_35%)_0px_10px_38px_-10px,_hsl(206_22%_7%_/_20%)_0px_10px_20px_-15px]", {
|
30
31
|
variants: {
|
31
32
|
radius: {
|
@@ -51,8 +52,6 @@ export var dialogContentVariants = cva("rounded-md focus:outline-none bg-white d
|
|
51
52
|
export var DialogContent = forwardRef(function (_a, forwardedRef) {
|
52
53
|
var children = _a.children, className = _a.className, props = __rest(_a, ["children", "className"]);
|
53
54
|
var _b = useContext(DialogContext), radius = _b.radius, size = _b.size, scaling = _b.scaling;
|
54
|
-
return (
|
55
|
-
{children}
|
56
|
-
</DialogTheme.Content>);
|
55
|
+
return (_jsx(DialogTheme.Content, __assign({ ref: forwardedRef, className: cn(dialogContentVariants({ radius: radius, scaling: scaling, size: size }), className) }, props, { children: children })));
|
57
56
|
});
|
58
57
|
DialogContent.displayName = 'Dialog.Content';
|
@@ -1,3 +1,14 @@
|
|
1
|
+
var __assign = (this && this.__assign) || function () {
|
2
|
+
__assign = Object.assign || function(t) {
|
3
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
4
|
+
s = arguments[i];
|
5
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
6
|
+
t[p] = s[p];
|
7
|
+
}
|
8
|
+
return t;
|
9
|
+
};
|
10
|
+
return __assign.apply(this, arguments);
|
11
|
+
};
|
1
12
|
var __rest = (this && this.__rest) || function (s, e) {
|
2
13
|
var t = {};
|
3
14
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
@@ -9,11 +20,12 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
9
20
|
}
|
10
21
|
return t;
|
11
22
|
};
|
12
|
-
import
|
23
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
24
|
+
import { forwardRef, useContext } from 'react';
|
13
25
|
import { cva } from 'class-variance-authority';
|
14
26
|
import { Dialog as DialogTheme } from '@radix-ui/themes';
|
15
27
|
import { DialogContext } from './DialogRoot';
|
16
|
-
import { cn } from 'lib/utils/utils';
|
28
|
+
import { cn } from '../../../lib/utils/utils';
|
17
29
|
export var dialogDescriptionVariants = cva('font-normal text-slate-12 dark:text-slateDark-12', {
|
18
30
|
variants: {
|
19
31
|
size: {
|
@@ -30,8 +42,6 @@ export var dialogDescriptionVariants = cva('font-normal text-slate-12 dark:text-
|
|
30
42
|
export var DialogDescription = forwardRef(function (_a, ref) {
|
31
43
|
var children = _a.children, className = _a.className, props = __rest(_a, ["children", "className"]);
|
32
44
|
var size = useContext(DialogContext).size;
|
33
|
-
return (
|
34
|
-
{children}
|
35
|
-
</DialogTheme.Description>);
|
45
|
+
return (_jsx(DialogTheme.Description, __assign({ mb: "4", ref: ref, className: cn(dialogDescriptionVariants({ size: size }), className) }, props, { children: children })));
|
36
46
|
});
|
37
47
|
DialogDescription.displayName = 'Dialog.Description';
|
@@ -10,6 +10,6 @@ export interface DialogProps extends VariantProps<typeof dialogContentVariants>,
|
|
10
10
|
}
|
11
11
|
export declare const DialogContext: React.Context<DialogProps>;
|
12
12
|
export declare const DialogRoot: {
|
13
|
-
({ children, radius, size, scaling, color, ...props }: ComponentPropsWithoutRef<typeof DialogTheme.Root> & DialogProps):
|
13
|
+
({ children, radius, size, scaling, color, ...props }: ComponentPropsWithoutRef<typeof DialogTheme.Root> & DialogProps): import("react/jsx-runtime").JSX.Element;
|
14
14
|
displayName: string;
|
15
15
|
};
|
@@ -1,3 +1,14 @@
|
|
1
|
+
var __assign = (this && this.__assign) || function () {
|
2
|
+
__assign = Object.assign || function(t) {
|
3
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
4
|
+
s = arguments[i];
|
5
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
6
|
+
t[p] = s[p];
|
7
|
+
}
|
8
|
+
return t;
|
9
|
+
};
|
10
|
+
return __assign.apply(this, arguments);
|
11
|
+
};
|
1
12
|
var __rest = (this && this.__rest) || function (s, e) {
|
2
13
|
var t = {};
|
3
14
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
@@ -9,7 +20,8 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
9
20
|
}
|
10
21
|
return t;
|
11
22
|
};
|
12
|
-
import
|
23
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
24
|
+
import { createContext } from 'react';
|
13
25
|
import { Theme, Dialog as DialogTheme } from '@radix-ui/themes';
|
14
26
|
export var DialogContext = createContext({
|
15
27
|
size: 'medium',
|
@@ -20,10 +32,6 @@ export var DialogContext = createContext({
|
|
20
32
|
export var DialogRoot = function (_a) {
|
21
33
|
var children = _a.children, radius = _a.radius, size = _a.size, scaling = _a.scaling, color = _a.color, props = __rest(_a, ["children", "radius", "size", "scaling", "color"]);
|
22
34
|
var contextValue = { radius: radius, size: size, scaling: scaling, color: color };
|
23
|
-
return (
|
24
|
-
<DialogContext.Provider value={contextValue}>
|
25
|
-
<DialogTheme.Root {...props}>{children}</DialogTheme.Root>
|
26
|
-
</DialogContext.Provider>
|
27
|
-
</Theme>);
|
35
|
+
return (_jsx(Theme, { accentColor: color, children: _jsx(DialogContext.Provider, { value: contextValue, children: _jsx(DialogTheme.Root, __assign({}, props, { children: children })) }) }));
|
28
36
|
};
|
29
37
|
DialogRoot.displayName = 'Dialog.Root';
|