@radix-ui/react-dropdown-menu 0.1.7-rc.9 → 1.0.1-rc.1

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/index.d.ts CHANGED
@@ -2,11 +2,7 @@ import * as React from "react";
2
2
  import * as Radix from "@radix-ui/react-primitive";
3
3
  import { Primitive } from "@radix-ui/react-primitive";
4
4
  import * as MenuPrimitive from "@radix-ui/react-menu";
5
- import { Scope } from "@radix-ui/react-context";
6
5
  type Direction = 'ltr' | 'rtl';
7
- type ScopedProps<P> = P & {
8
- __scopeDropdownMenu?: Scope;
9
- };
10
6
  export const createDropdownMenuScope: import("@radix-ui/react-context").CreateScope;
11
7
  export interface DropdownMenuProps {
12
8
  children?: React.ReactNode;
@@ -21,12 +17,14 @@ type PrimitiveButtonProps = Radix.ComponentPropsWithoutRef<typeof Primitive.butt
21
17
  export interface DropdownMenuTriggerProps extends PrimitiveButtonProps {
22
18
  }
23
19
  export const DropdownMenuTrigger: React.ForwardRefExoticComponent<DropdownMenuTriggerProps & React.RefAttributes<HTMLButtonElement>>;
20
+ type MenuPortalProps = React.ComponentPropsWithoutRef<typeof MenuPrimitive.Portal>;
21
+ export interface DropdownMenuPortalProps extends MenuPortalProps {
22
+ }
23
+ export const DropdownMenuPortal: React.FC<DropdownMenuPortalProps>;
24
24
  type MenuContentProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Content>;
25
- export interface DropdownMenuContentProps extends DropdownMenuRootContentProps, MenuContentProps {
25
+ export interface DropdownMenuContentProps extends MenuContentProps {
26
26
  }
27
27
  export const DropdownMenuContent: React.ForwardRefExoticComponent<DropdownMenuContentProps & React.RefAttributes<HTMLDivElement>>;
28
- interface DropdownMenuRootContentProps extends ScopedProps<MenuContentProps> {
29
- }
30
28
  type MenuGroupProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Group>;
31
29
  export interface DropdownMenuGroupProps extends MenuGroupProps {
32
30
  }
@@ -39,10 +37,6 @@ type MenuItemProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Item>;
39
37
  export interface DropdownMenuItemProps extends MenuItemProps {
40
38
  }
41
39
  export const DropdownMenuItem: React.ForwardRefExoticComponent<DropdownMenuItemProps & React.RefAttributes<HTMLDivElement>>;
42
- type MenuSubTriggerProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.SubTrigger>;
43
- export interface DropdownMenuTriggerItemProps extends MenuSubTriggerProps {
44
- }
45
- export const DropdownMenuTriggerItem: React.ForwardRefExoticComponent<DropdownMenuTriggerItemProps & React.RefAttributes<HTMLDivElement>>;
46
40
  type MenuCheckboxItemProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.CheckboxItem>;
47
41
  export interface DropdownMenuCheckboxItemProps extends MenuCheckboxItemProps {
48
42
  }
@@ -67,18 +61,36 @@ type MenuArrowProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Arrow>
67
61
  export interface DropdownMenuArrowProps extends MenuArrowProps {
68
62
  }
69
63
  export const DropdownMenuArrow: React.ForwardRefExoticComponent<DropdownMenuArrowProps & React.RefAttributes<SVGSVGElement>>;
64
+ export interface DropdownMenuSubProps {
65
+ children?: React.ReactNode;
66
+ open?: boolean;
67
+ defaultOpen?: boolean;
68
+ onOpenChange?(open: boolean): void;
69
+ }
70
+ export const DropdownMenuSub: React.FC<DropdownMenuSubProps>;
71
+ type MenuSubTriggerProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.SubTrigger>;
72
+ export interface DropdownMenuSubTriggerProps extends MenuSubTriggerProps {
73
+ }
74
+ export const DropdownMenuSubTrigger: React.ForwardRefExoticComponent<DropdownMenuSubTriggerProps & React.RefAttributes<HTMLDivElement>>;
75
+ type MenuSubContentProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.SubContent>;
76
+ export interface DropdownMenuSubContentProps extends MenuSubContentProps {
77
+ }
78
+ export const DropdownMenuSubContent: React.ForwardRefExoticComponent<DropdownMenuSubContentProps & React.RefAttributes<HTMLDivElement>>;
70
79
  export const Root: React.FC<DropdownMenuProps>;
71
80
  export const Trigger: React.ForwardRefExoticComponent<DropdownMenuTriggerProps & React.RefAttributes<HTMLButtonElement>>;
81
+ export const Portal: React.FC<DropdownMenuPortalProps>;
72
82
  export const Content: React.ForwardRefExoticComponent<DropdownMenuContentProps & React.RefAttributes<HTMLDivElement>>;
73
83
  export const Group: React.ForwardRefExoticComponent<DropdownMenuGroupProps & React.RefAttributes<HTMLDivElement>>;
74
84
  export const Label: React.ForwardRefExoticComponent<DropdownMenuLabelProps & React.RefAttributes<HTMLDivElement>>;
75
85
  export const Item: React.ForwardRefExoticComponent<DropdownMenuItemProps & React.RefAttributes<HTMLDivElement>>;
76
- export const TriggerItem: React.ForwardRefExoticComponent<DropdownMenuTriggerItemProps & React.RefAttributes<HTMLDivElement>>;
77
86
  export const CheckboxItem: React.ForwardRefExoticComponent<DropdownMenuCheckboxItemProps & React.RefAttributes<HTMLDivElement>>;
78
87
  export const RadioGroup: React.ForwardRefExoticComponent<DropdownMenuRadioGroupProps & React.RefAttributes<HTMLDivElement>>;
79
88
  export const RadioItem: React.ForwardRefExoticComponent<DropdownMenuRadioItemProps & React.RefAttributes<HTMLDivElement>>;
80
89
  export const ItemIndicator: React.ForwardRefExoticComponent<DropdownMenuItemIndicatorProps & React.RefAttributes<HTMLSpanElement>>;
81
90
  export const Separator: React.ForwardRefExoticComponent<DropdownMenuSeparatorProps & React.RefAttributes<HTMLDivElement>>;
82
91
  export const Arrow: React.ForwardRefExoticComponent<DropdownMenuArrowProps & React.RefAttributes<SVGSVGElement>>;
92
+ export const Sub: React.FC<DropdownMenuSubProps>;
93
+ export const SubTrigger: React.ForwardRefExoticComponent<DropdownMenuSubTriggerProps & React.RefAttributes<HTMLDivElement>>;
94
+ export const SubContent: React.ForwardRefExoticComponent<DropdownMenuSubContentProps & React.RefAttributes<HTMLDivElement>>;
83
95
 
84
96
  //# sourceMappingURL=index.d.ts.map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C,CAAC;AAC1C,OAAA,MAAM,4GAAiC,CAAC;AACxC,OAAA,MAAM,qHAAyC,CAAC;AAChD,OAAA,MAAM,4GAAiC,CAAC;AACxC,OAAA,MAAM,mGAAyB,CAAC","sources":["packages/react/dropdown-menu/src/packages/react/dropdown-menu/src/DropdownMenu.tsx","packages/react/dropdown-menu/src/packages/react/dropdown-menu/src/index.ts","packages/react/dropdown-menu/src/index.ts"],"sourcesContent":[null,null,"export * from './DropdownMenu';\n"],"names":[],"version":3,"file":"index.d.ts.map"}
1
+ {"mappings":";;;;AAaA,iBAAiB,KAAK,GAAG,KAAK,CAAC;AAS/B,OAAA,8FAGC,CAAC;AAgBF;IACE,QAAQ,CAAC,EAAE,MAAM,SAAS,CAAC;IAC3B,GAAG,CAAC,EAAE,SAAS,CAAC;IAChB,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,YAAY,CAAC,CAAC,IAAI,EAAE,OAAO,GAAG,IAAI,CAAC;IACnC,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB;AAED,OAAA,MAAM,cAAc,MAAM,EAAE,CAAC,iBAAiB,CAkC7C,CAAC;AAWF,4BAA4B,MAAM,wBAAwB,CAAC,OAAO,UAAU,MAAM,CAAC,CAAC;AACpF,yCAAmC,SAAQ,oBAAoB;CAAG;AAElE,OAAA,MAAM,uHAuCL,CAAC;AAUF,uBAAuB,MAAM,wBAAwB,CAAC,OAAO,cAAc,MAAM,CAAC,CAAC;AACnF,wCAAkC,SAAQ,eAAe;CAAG;AAE5D,OAAA,MAAM,oBAAoB,MAAM,EAAE,CAAC,uBAAuB,CAMzD,CAAC;AAWF,wBAAwB,MAAM,wBAAwB,CAAC,OAAO,cAAc,OAAO,CAAC,CAAC;AACrF,yCAAmC,SAAQ,gBAAgB;CAAG;AAE9D,OAAA,MAAM,oHAmCL,CAAC;AAWF,sBAAsB,MAAM,wBAAwB,CAAC,OAAO,cAAc,KAAK,CAAC,CAAC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AAE,OAAO,CAAC;IACtB,YAAY,CAAC,CAAC,IAAI,EAAE,OAAO,GAAG,IAAI,CAAC;CACpC;AAED,OAAA,MAAM,iBAAiB,MAAM,EAAE,CAAC,oBAAoB,CAgBnD,CAAC;AASF,2BAA2B,MAAM,wBAAwB,CAAC,OAAO,cAAc,UAAU,CAAC,CAAC;AAC3F,4CAAsC,SAAQ,mBAAmB;CAAG;AAEpE,OAAA,MAAM,0HAOJ,CAAC;AAWH,2BAA2B,MAAM,wBAAwB,CAAC,OAAO,cAAc,UAAU,CAAC,CAAC;AAC3F,4CAAsC,SAAQ,mBAAmB;CAAG;AAEpE,OAAA,MAAM,0HAoBJ,CAAC;AAMH,OAAA,MAAM,iCAAmB,CAAC;AAC1B,OAAA,MAAM,2GAA6B,CAAC;AACpC,OAAA,MAAM,yCAA2B,CAAC;AAClC,OAAA,MAAM,wGAA6B,CAAC;AACpC,OAAA,MAAM,oGAAyB,CAAC;AAChC,OAAA,MAAM,oGAAyB,CAAC;AAChC,OAAA,MAAM,kGAAuB,CAAC;AAC9B,OAAA,MAAM,kHAAuC,CAAC;AAC9C,OAAA,MAAM,8GAAmC,CAAC;AAC1C,OAAA,MAAM,4GAAiC,CAAC;AACxC,OAAA,MAAM,qHAAyC,CAAC;AAChD,OAAA,MAAM,4GAAiC,CAAC;AACxC,OAAA,MAAM,mGAAyB,CAAC;AAChC,OAAA,MAAM,mCAAqB,CAAC;AAC5B,OAAA,MAAM,8GAAmC,CAAC;AAC1C,OAAA,MAAM,8GAAmC,CAAC","sources":["packages/react/dropdown-menu/src/packages/react/dropdown-menu/src/DropdownMenu.tsx","packages/react/dropdown-menu/src/packages/react/dropdown-menu/src/index.ts","packages/react/dropdown-menu/src/index.ts"],"sourcesContent":[null,null,"export {\n createDropdownMenuScope,\n //\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuPortal,\n DropdownMenuContent,\n DropdownMenuGroup,\n DropdownMenuLabel,\n DropdownMenuItem,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioGroup,\n DropdownMenuRadioItem,\n DropdownMenuItemIndicator,\n DropdownMenuSeparator,\n DropdownMenuArrow,\n DropdownMenuSub,\n DropdownMenuSubTrigger,\n DropdownMenuSubContent,\n //\n Root,\n Trigger,\n Portal,\n Content,\n Group,\n Label,\n Item,\n CheckboxItem,\n RadioGroup,\n RadioItem,\n ItemIndicator,\n Separator,\n Arrow,\n Sub,\n SubTrigger,\n SubContent,\n} from './DropdownMenu';\nexport type {\n DropdownMenuProps,\n DropdownMenuTriggerProps,\n DropdownMenuPortalProps,\n DropdownMenuContentProps,\n DropdownMenuGroupProps,\n DropdownMenuLabelProps,\n DropdownMenuItemProps,\n DropdownMenuCheckboxItemProps,\n DropdownMenuRadioGroupProps,\n DropdownMenuRadioItemProps,\n DropdownMenuItemIndicatorProps,\n DropdownMenuSeparatorProps,\n DropdownMenuArrowProps,\n DropdownMenuSubProps,\n DropdownMenuSubTriggerProps,\n DropdownMenuSubContentProps,\n} from './DropdownMenu';\n"],"names":[],"version":3,"file":"index.d.ts.map"}
package/dist/index.js CHANGED
@@ -8,57 +8,46 @@ var $7dQ7Q$radixuireactprimitive = require("@radix-ui/react-primitive");
8
8
  var $7dQ7Q$radixuireactmenu = require("@radix-ui/react-menu");
9
9
  var $7dQ7Q$radixuireactid = require("@radix-ui/react-id");
10
10
 
11
- function $parcel$exportWildcard(dest, source) {
12
- Object.keys(source).forEach(function(key) {
13
- if (key === 'default' || key === '__esModule' || dest.hasOwnProperty(key)) {
14
- return;
15
- }
16
-
17
- Object.defineProperty(dest, key, {
18
- enumerable: true,
19
- get: function get() {
20
- return source[key];
21
- }
22
- });
23
- });
24
-
25
- return dest;
11
+ function $parcel$export(e, n, v, s) {
12
+ Object.defineProperty(e, n, {get: v, set: s, enumerable: true, configurable: true});
26
13
  }
27
14
  function $parcel$interopDefault(a) {
28
15
  return a && a.__esModule ? a.default : a;
29
16
  }
30
- function $parcel$export(e, n, v, s) {
31
- Object.defineProperty(e, n, {get: v, set: s, enumerable: true, configurable: true});
32
- }
33
- var $d1bf075a6b218014$exports = {};
34
17
 
35
- $parcel$export($d1bf075a6b218014$exports, "createDropdownMenuScope", () => $d1bf075a6b218014$export$c0623cd925aeb687);
36
- $parcel$export($d1bf075a6b218014$exports, "DropdownMenu", () => $d1bf075a6b218014$export$e44a253a59704894);
37
- $parcel$export($d1bf075a6b218014$exports, "DropdownMenuTrigger", () => $d1bf075a6b218014$export$d2469213b3befba9);
38
- $parcel$export($d1bf075a6b218014$exports, "DropdownMenuContent", () => $d1bf075a6b218014$export$6e76d93a37c01248);
39
- $parcel$export($d1bf075a6b218014$exports, "DropdownMenuGroup", () => $d1bf075a6b218014$export$246bebaba3a2f70e);
40
- $parcel$export($d1bf075a6b218014$exports, "DropdownMenuLabel", () => $d1bf075a6b218014$export$76e48c5b57f24495);
41
- $parcel$export($d1bf075a6b218014$exports, "DropdownMenuItem", () => $d1bf075a6b218014$export$ed97964d1871885d);
42
- $parcel$export($d1bf075a6b218014$exports, "DropdownMenuTriggerItem", () => $d1bf075a6b218014$export$eb7a5647860df79a);
43
- $parcel$export($d1bf075a6b218014$exports, "DropdownMenuCheckboxItem", () => $d1bf075a6b218014$export$53a69729da201fa9);
44
- $parcel$export($d1bf075a6b218014$exports, "DropdownMenuRadioGroup", () => $d1bf075a6b218014$export$3323ad73d55f587e);
45
- $parcel$export($d1bf075a6b218014$exports, "DropdownMenuRadioItem", () => $d1bf075a6b218014$export$e4f69b41b1637536);
46
- $parcel$export($d1bf075a6b218014$exports, "DropdownMenuItemIndicator", () => $d1bf075a6b218014$export$42355ae145153fb6);
47
- $parcel$export($d1bf075a6b218014$exports, "DropdownMenuSeparator", () => $d1bf075a6b218014$export$da160178fd3bc7e9);
48
- $parcel$export($d1bf075a6b218014$exports, "DropdownMenuArrow", () => $d1bf075a6b218014$export$34b8980744021ec5);
49
- $parcel$export($d1bf075a6b218014$exports, "Root", () => $d1bf075a6b218014$export$be92b6f5f03c0fe9);
50
- $parcel$export($d1bf075a6b218014$exports, "Trigger", () => $d1bf075a6b218014$export$41fb9f06171c75f4);
51
- $parcel$export($d1bf075a6b218014$exports, "Content", () => $d1bf075a6b218014$export$7c6e2c02157bb7d2);
52
- $parcel$export($d1bf075a6b218014$exports, "Group", () => $d1bf075a6b218014$export$eb2fcfdbd7ba97d4);
53
- $parcel$export($d1bf075a6b218014$exports, "Label", () => $d1bf075a6b218014$export$b04be29aa201d4f5);
54
- $parcel$export($d1bf075a6b218014$exports, "Item", () => $d1bf075a6b218014$export$6d08773d2e66f8f2);
55
- $parcel$export($d1bf075a6b218014$exports, "TriggerItem", () => $d1bf075a6b218014$export$6d0911d397e3b965);
56
- $parcel$export($d1bf075a6b218014$exports, "CheckboxItem", () => $d1bf075a6b218014$export$16ce288f89fa631c);
57
- $parcel$export($d1bf075a6b218014$exports, "RadioGroup", () => $d1bf075a6b218014$export$a98f0dcb43a68a25);
58
- $parcel$export($d1bf075a6b218014$exports, "RadioItem", () => $d1bf075a6b218014$export$371ab307eab489c0);
59
- $parcel$export($d1bf075a6b218014$exports, "ItemIndicator", () => $d1bf075a6b218014$export$c3468e2714d175fa);
60
- $parcel$export($d1bf075a6b218014$exports, "Separator", () => $d1bf075a6b218014$export$1ff3c3f08ae963c0);
61
- $parcel$export($d1bf075a6b218014$exports, "Arrow", () => $d1bf075a6b218014$export$21b07c8f274aebd5);
18
+ $parcel$export(module.exports, "createDropdownMenuScope", () => $d1bf075a6b218014$export$c0623cd925aeb687);
19
+ $parcel$export(module.exports, "DropdownMenu", () => $d1bf075a6b218014$export$e44a253a59704894);
20
+ $parcel$export(module.exports, "DropdownMenuTrigger", () => $d1bf075a6b218014$export$d2469213b3befba9);
21
+ $parcel$export(module.exports, "DropdownMenuPortal", () => $d1bf075a6b218014$export$cd369b4d4d54efc9);
22
+ $parcel$export(module.exports, "DropdownMenuContent", () => $d1bf075a6b218014$export$6e76d93a37c01248);
23
+ $parcel$export(module.exports, "DropdownMenuGroup", () => $d1bf075a6b218014$export$246bebaba3a2f70e);
24
+ $parcel$export(module.exports, "DropdownMenuLabel", () => $d1bf075a6b218014$export$76e48c5b57f24495);
25
+ $parcel$export(module.exports, "DropdownMenuItem", () => $d1bf075a6b218014$export$ed97964d1871885d);
26
+ $parcel$export(module.exports, "DropdownMenuCheckboxItem", () => $d1bf075a6b218014$export$53a69729da201fa9);
27
+ $parcel$export(module.exports, "DropdownMenuRadioGroup", () => $d1bf075a6b218014$export$3323ad73d55f587e);
28
+ $parcel$export(module.exports, "DropdownMenuRadioItem", () => $d1bf075a6b218014$export$e4f69b41b1637536);
29
+ $parcel$export(module.exports, "DropdownMenuItemIndicator", () => $d1bf075a6b218014$export$42355ae145153fb6);
30
+ $parcel$export(module.exports, "DropdownMenuSeparator", () => $d1bf075a6b218014$export$da160178fd3bc7e9);
31
+ $parcel$export(module.exports, "DropdownMenuArrow", () => $d1bf075a6b218014$export$34b8980744021ec5);
32
+ $parcel$export(module.exports, "DropdownMenuSub", () => $d1bf075a6b218014$export$2f307d81a64f5442);
33
+ $parcel$export(module.exports, "DropdownMenuSubTrigger", () => $d1bf075a6b218014$export$21dcb7ec56f874cf);
34
+ $parcel$export(module.exports, "DropdownMenuSubContent", () => $d1bf075a6b218014$export$f34ec8bc2482cc5f);
35
+ $parcel$export(module.exports, "Root", () => $d1bf075a6b218014$export$be92b6f5f03c0fe9);
36
+ $parcel$export(module.exports, "Trigger", () => $d1bf075a6b218014$export$41fb9f06171c75f4);
37
+ $parcel$export(module.exports, "Portal", () => $d1bf075a6b218014$export$602eac185826482c);
38
+ $parcel$export(module.exports, "Content", () => $d1bf075a6b218014$export$7c6e2c02157bb7d2);
39
+ $parcel$export(module.exports, "Group", () => $d1bf075a6b218014$export$eb2fcfdbd7ba97d4);
40
+ $parcel$export(module.exports, "Label", () => $d1bf075a6b218014$export$b04be29aa201d4f5);
41
+ $parcel$export(module.exports, "Item", () => $d1bf075a6b218014$export$6d08773d2e66f8f2);
42
+ $parcel$export(module.exports, "CheckboxItem", () => $d1bf075a6b218014$export$16ce288f89fa631c);
43
+ $parcel$export(module.exports, "RadioGroup", () => $d1bf075a6b218014$export$a98f0dcb43a68a25);
44
+ $parcel$export(module.exports, "RadioItem", () => $d1bf075a6b218014$export$371ab307eab489c0);
45
+ $parcel$export(module.exports, "ItemIndicator", () => $d1bf075a6b218014$export$c3468e2714d175fa);
46
+ $parcel$export(module.exports, "Separator", () => $d1bf075a6b218014$export$1ff3c3f08ae963c0);
47
+ $parcel$export(module.exports, "Arrow", () => $d1bf075a6b218014$export$21b07c8f274aebd5);
48
+ $parcel$export(module.exports, "Sub", () => $d1bf075a6b218014$export$d7a01e11500dfb6f);
49
+ $parcel$export(module.exports, "SubTrigger", () => $d1bf075a6b218014$export$2ea8a7a591ac5eac);
50
+ $parcel$export(module.exports, "SubContent", () => $d1bf075a6b218014$export$6d4de93b380beddf);
62
51
 
63
52
 
64
53
 
@@ -78,58 +67,37 @@ const [$d1bf075a6b218014$var$createDropdownMenuContext, $d1bf075a6b218014$export
78
67
  const $d1bf075a6b218014$var$useMenuScope = $7dQ7Q$radixuireactmenu.createMenuScope();
79
68
  const [$d1bf075a6b218014$var$DropdownMenuProvider, $d1bf075a6b218014$var$useDropdownMenuContext] = $d1bf075a6b218014$var$createDropdownMenuContext($d1bf075a6b218014$var$DROPDOWN_MENU_NAME);
80
69
  const $d1bf075a6b218014$export$e44a253a59704894 = (props)=>{
81
- const { __scopeDropdownMenu: __scopeDropdownMenu , children: children , open: openProp , defaultOpen: defaultOpen , onOpenChange: onOpenChange } = props;
82
- const contentContext = $d1bf075a6b218014$var$useContentContext($d1bf075a6b218014$var$DROPDOWN_MENU_NAME, __scopeDropdownMenu);
70
+ const { __scopeDropdownMenu: __scopeDropdownMenu , children: children , dir: dir , open: openProp , defaultOpen: defaultOpen , onOpenChange: onOpenChange , modal: modal = true } = props;
83
71
  const menuScope = $d1bf075a6b218014$var$useMenuScope(__scopeDropdownMenu);
72
+ const triggerRef = $7dQ7Q$react.useRef(null);
84
73
  const [open = false, setOpen] = $7dQ7Q$radixuireactusecontrollablestate.useControllableState({
85
74
  prop: openProp,
86
75
  defaultProp: defaultOpen,
87
76
  onChange: onOpenChange
88
77
  });
89
- const handleOpenToggle = $7dQ7Q$react.useCallback(()=>setOpen((prevOpen)=>!prevOpen
90
- )
91
- , [
92
- setOpen
93
- ]);
94
- return contentContext.isInsideContent ? /*#__PURE__*/ $7dQ7Q$react.createElement($d1bf075a6b218014$var$DropdownMenuProvider, {
95
- scope: __scopeDropdownMenu,
96
- isRootMenu: false,
97
- open: open,
98
- onOpenChange: setOpen,
99
- onOpenToggle: handleOpenToggle
100
- }, /*#__PURE__*/ $7dQ7Q$react.createElement($7dQ7Q$radixuireactmenu.Sub, ($parcel$interopDefault($7dQ7Q$babelruntimehelpersextends))({}, menuScope, {
101
- open: open,
102
- onOpenChange: setOpen
103
- }), children)) : /*#__PURE__*/ $7dQ7Q$react.createElement($d1bf075a6b218014$var$DropdownMenuRoot, ($parcel$interopDefault($7dQ7Q$babelruntimehelpersextends))({}, props, {
104
- open: open,
105
- onOpenChange: setOpen,
106
- onOpenToggle: handleOpenToggle
107
- }), children);
108
- };
109
- /*#__PURE__*/ Object.assign($d1bf075a6b218014$export$e44a253a59704894, {
110
- displayName: $d1bf075a6b218014$var$DROPDOWN_MENU_NAME
111
- });
112
- /* ---------------------------------------------------------------------------------------------- */ const $d1bf075a6b218014$var$DropdownMenuRoot = (props)=>{
113
- const { __scopeDropdownMenu: __scopeDropdownMenu , children: children , dir: dir , open: open , onOpenChange: onOpenChange , onOpenToggle: onOpenToggle , modal: modal = true } = props;
114
- const menuScope = $d1bf075a6b218014$var$useMenuScope(__scopeDropdownMenu);
115
- const triggerRef = $7dQ7Q$react.useRef(null);
116
78
  return /*#__PURE__*/ $7dQ7Q$react.createElement($d1bf075a6b218014$var$DropdownMenuProvider, {
117
79
  scope: __scopeDropdownMenu,
118
- isRootMenu: true,
119
80
  triggerId: $7dQ7Q$radixuireactid.useId(),
120
81
  triggerRef: triggerRef,
121
82
  contentId: $7dQ7Q$radixuireactid.useId(),
122
83
  open: open,
123
- onOpenChange: onOpenChange,
124
- onOpenToggle: onOpenToggle,
84
+ onOpenChange: setOpen,
85
+ onOpenToggle: $7dQ7Q$react.useCallback(()=>setOpen((prevOpen)=>!prevOpen
86
+ )
87
+ , [
88
+ setOpen
89
+ ]),
125
90
  modal: modal
126
91
  }, /*#__PURE__*/ $7dQ7Q$react.createElement($7dQ7Q$radixuireactmenu.Root, ($parcel$interopDefault($7dQ7Q$babelruntimehelpersextends))({}, menuScope, {
127
92
  open: open,
128
- onOpenChange: onOpenChange,
93
+ onOpenChange: setOpen,
129
94
  dir: dir,
130
95
  modal: modal
131
96
  }), children));
132
97
  };
98
+ /*#__PURE__*/ Object.assign($d1bf075a6b218014$export$e44a253a59704894, {
99
+ displayName: $d1bf075a6b218014$var$DROPDOWN_MENU_NAME
100
+ });
133
101
  /* -------------------------------------------------------------------------------------------------
134
102
  * DropdownMenuTrigger
135
103
  * -----------------------------------------------------------------------------------------------*/ const $d1bf075a6b218014$var$TRIGGER_NAME = 'DropdownMenuTrigger';
@@ -137,7 +105,7 @@ const $d1bf075a6b218014$export$d2469213b3befba9 = /*#__PURE__*/ $7dQ7Q$react.for
137
105
  const { __scopeDropdownMenu: __scopeDropdownMenu , disabled: disabled = false , ...triggerProps } = props;
138
106
  const context = $d1bf075a6b218014$var$useDropdownMenuContext($d1bf075a6b218014$var$TRIGGER_NAME, __scopeDropdownMenu);
139
107
  const menuScope = $d1bf075a6b218014$var$useMenuScope(__scopeDropdownMenu);
140
- return context.isRootMenu ? /*#__PURE__*/ $7dQ7Q$react.createElement($7dQ7Q$radixuireactmenu.Anchor, ($parcel$interopDefault($7dQ7Q$babelruntimehelpersextends))({
108
+ return /*#__PURE__*/ $7dQ7Q$react.createElement($7dQ7Q$radixuireactmenu.Anchor, ($parcel$interopDefault($7dQ7Q$babelruntimehelpersextends))({
141
109
  asChild: true
142
110
  }, menuScope), /*#__PURE__*/ $7dQ7Q$react.createElement($7dQ7Q$radixuireactprimitive.Primitive.button, ($parcel$interopDefault($7dQ7Q$babelruntimehelpersextends))({
143
111
  type: "button",
@@ -154,10 +122,9 @@ const $d1bf075a6b218014$export$d2469213b3befba9 = /*#__PURE__*/ $7dQ7Q$react.for
154
122
  // only call handler if it's the left button (mousedown gets triggered by all mouse buttons)
155
123
  // but not when the control key is pressed (avoiding MacOS right click)
156
124
  if (!disabled && event.button === 0 && event.ctrlKey === false) {
157
- // prevent trigger focusing when opening
125
+ context.onOpenToggle(); // prevent trigger focusing when opening
158
126
  // this allows the content to be given focus without competition
159
127
  if (!context.open) event.preventDefault();
160
- context.onOpenToggle();
161
128
  }
162
129
  }),
163
130
  onKeyDown: $7dQ7Q$radixuiprimitive.composeEventHandlers(props.onKeyDown, (event)=>{
@@ -172,54 +139,35 @@ const $d1bf075a6b218014$export$d2469213b3befba9 = /*#__PURE__*/ $7dQ7Q$react.for
172
139
  'ArrowDown'
173
140
  ].includes(event.key)) event.preventDefault();
174
141
  })
175
- }))) : null;
142
+ })));
176
143
  });
177
144
  /*#__PURE__*/ Object.assign($d1bf075a6b218014$export$d2469213b3befba9, {
178
145
  displayName: $d1bf075a6b218014$var$TRIGGER_NAME
179
146
  });
147
+ /* -------------------------------------------------------------------------------------------------
148
+ * DropdownMenuPortal
149
+ * -----------------------------------------------------------------------------------------------*/ const $d1bf075a6b218014$var$PORTAL_NAME = 'DropdownMenuPortal';
150
+ const $d1bf075a6b218014$export$cd369b4d4d54efc9 = (props)=>{
151
+ const { __scopeDropdownMenu: __scopeDropdownMenu , ...portalProps } = props;
152
+ const menuScope = $d1bf075a6b218014$var$useMenuScope(__scopeDropdownMenu);
153
+ return /*#__PURE__*/ $7dQ7Q$react.createElement($7dQ7Q$radixuireactmenu.Portal, ($parcel$interopDefault($7dQ7Q$babelruntimehelpersextends))({}, menuScope, portalProps));
154
+ };
155
+ /*#__PURE__*/ Object.assign($d1bf075a6b218014$export$cd369b4d4d54efc9, {
156
+ displayName: $d1bf075a6b218014$var$PORTAL_NAME
157
+ });
180
158
  /* -------------------------------------------------------------------------------------------------
181
159
  * DropdownMenuContent
182
160
  * -----------------------------------------------------------------------------------------------*/ const $d1bf075a6b218014$var$CONTENT_NAME = 'DropdownMenuContent';
183
- const [$d1bf075a6b218014$var$ContentProvider, $d1bf075a6b218014$var$useContentContext] = $d1bf075a6b218014$var$createDropdownMenuContext($d1bf075a6b218014$var$CONTENT_NAME, {
184
- isInsideContent: false
185
- });
186
161
  const $d1bf075a6b218014$export$6e76d93a37c01248 = /*#__PURE__*/ $7dQ7Q$react.forwardRef((props, forwardedRef)=>{
187
162
  const { __scopeDropdownMenu: __scopeDropdownMenu , ...contentProps } = props;
188
163
  const context = $d1bf075a6b218014$var$useDropdownMenuContext($d1bf075a6b218014$var$CONTENT_NAME, __scopeDropdownMenu);
189
164
  const menuScope = $d1bf075a6b218014$var$useMenuScope(__scopeDropdownMenu);
190
- const commonProps = {
191
- ...contentProps,
192
- style: {
193
- ...props.style,
194
- // re-namespace exposed content custom property
195
- ['--radix-dropdown-menu-content-transform-origin']: 'var(--radix-popper-transform-origin)'
196
- }
197
- };
198
- return /*#__PURE__*/ $7dQ7Q$react.createElement($d1bf075a6b218014$var$ContentProvider, {
199
- scope: __scopeDropdownMenu,
200
- isInsideContent: true
201
- }, context.isRootMenu ? /*#__PURE__*/ $7dQ7Q$react.createElement($d1bf075a6b218014$var$DropdownMenuRootContent, ($parcel$interopDefault($7dQ7Q$babelruntimehelpersextends))({
202
- __scopeDropdownMenu: __scopeDropdownMenu
203
- }, commonProps, {
204
- ref: forwardedRef
205
- })) : /*#__PURE__*/ $7dQ7Q$react.createElement($7dQ7Q$radixuireactmenu.Content, ($parcel$interopDefault($7dQ7Q$babelruntimehelpersextends))({}, menuScope, commonProps, {
206
- ref: forwardedRef
207
- })));
208
- });
209
- /*#__PURE__*/ Object.assign($d1bf075a6b218014$export$6e76d93a37c01248, {
210
- displayName: $d1bf075a6b218014$var$CONTENT_NAME
211
- });
212
- /* ---------------------------------------------------------------------------------------------- */ const $d1bf075a6b218014$var$DropdownMenuRootContent = /*#__PURE__*/ $7dQ7Q$react.forwardRef((props, forwardedRef)=>{
213
- const { __scopeDropdownMenu: __scopeDropdownMenu , portalled: portalled = true , ...contentProps } = props;
214
- const context = $d1bf075a6b218014$var$useDropdownMenuContext($d1bf075a6b218014$var$CONTENT_NAME, __scopeDropdownMenu);
215
- const menuScope = $d1bf075a6b218014$var$useMenuScope(__scopeDropdownMenu);
216
165
  const hasInteractedOutsideRef = $7dQ7Q$react.useRef(false);
217
- return context.isRootMenu ? /*#__PURE__*/ $7dQ7Q$react.createElement($7dQ7Q$radixuireactmenu.Content, ($parcel$interopDefault($7dQ7Q$babelruntimehelpersextends))({
166
+ return /*#__PURE__*/ $7dQ7Q$react.createElement($7dQ7Q$radixuireactmenu.Content, ($parcel$interopDefault($7dQ7Q$babelruntimehelpersextends))({
218
167
  id: context.contentId,
219
168
  "aria-labelledby": context.triggerId
220
169
  }, menuScope, contentProps, {
221
170
  ref: forwardedRef,
222
- portalled: portalled,
223
171
  onCloseAutoFocus: $7dQ7Q$radixuiprimitive.composeEventHandlers(props.onCloseAutoFocus, (event)=>{
224
172
  var _context$triggerRef$c;
225
173
  if (!hasInteractedOutsideRef.current) (_context$triggerRef$c = context.triggerRef.current) === null || _context$triggerRef$c === void 0 || _context$triggerRef$c.focus();
@@ -231,8 +179,16 @@ const $d1bf075a6b218014$export$6e76d93a37c01248 = /*#__PURE__*/ $7dQ7Q$react.for
231
179
  const ctrlLeftClick = originalEvent.button === 0 && originalEvent.ctrlKey === true;
232
180
  const isRightClick = originalEvent.button === 2 || ctrlLeftClick;
233
181
  if (!context.modal || isRightClick) hasInteractedOutsideRef.current = true;
234
- })
235
- })) : null;
182
+ }),
183
+ style: {
184
+ ...props.style,
185
+ // re-namespace exposed content custom property
186
+ ['--radix-dropdown-menu-content-transform-origin']: 'var(--radix-popper-transform-origin)'
187
+ }
188
+ }));
189
+ });
190
+ /*#__PURE__*/ Object.assign($d1bf075a6b218014$export$6e76d93a37c01248, {
191
+ displayName: $d1bf075a6b218014$var$CONTENT_NAME
236
192
  });
237
193
  /* -------------------------------------------------------------------------------------------------
238
194
  * DropdownMenuGroup
@@ -273,19 +229,6 @@ const $d1bf075a6b218014$export$ed97964d1871885d = /*#__PURE__*/ $7dQ7Q$react.for
273
229
  /*#__PURE__*/ Object.assign($d1bf075a6b218014$export$ed97964d1871885d, {
274
230
  displayName: $d1bf075a6b218014$var$ITEM_NAME
275
231
  });
276
- /* -------------------------------------------------------------------------------------------------
277
- * DropdownMenuTriggerItem
278
- * -----------------------------------------------------------------------------------------------*/ const $d1bf075a6b218014$var$TRIGGER_ITEM_NAME = 'DropdownMenuTriggerItem';
279
- const $d1bf075a6b218014$export$eb7a5647860df79a = /*#__PURE__*/ $7dQ7Q$react.forwardRef((props, forwardedRef)=>{
280
- const { __scopeDropdownMenu: __scopeDropdownMenu , ...triggerItemProps } = props;
281
- const menuScope = $d1bf075a6b218014$var$useMenuScope(__scopeDropdownMenu);
282
- return /*#__PURE__*/ $7dQ7Q$react.createElement($7dQ7Q$radixuireactmenu.SubTrigger, ($parcel$interopDefault($7dQ7Q$babelruntimehelpersextends))({}, menuScope, triggerItemProps, {
283
- ref: forwardedRef
284
- }));
285
- });
286
- /*#__PURE__*/ Object.assign($d1bf075a6b218014$export$eb7a5647860df79a, {
287
- displayName: $d1bf075a6b218014$var$TRIGGER_ITEM_NAME
288
- });
289
232
  /* -------------------------------------------------------------------------------------------------
290
233
  * DropdownMenuCheckboxItem
291
234
  * -----------------------------------------------------------------------------------------------*/ const $d1bf075a6b218014$var$CHECKBOX_ITEM_NAME = 'DropdownMenuCheckboxItem';
@@ -364,22 +307,70 @@ const $d1bf075a6b218014$export$34b8980744021ec5 = /*#__PURE__*/ $7dQ7Q$react.for
364
307
  /*#__PURE__*/ Object.assign($d1bf075a6b218014$export$34b8980744021ec5, {
365
308
  displayName: $d1bf075a6b218014$var$ARROW_NAME
366
309
  });
310
+ /* -------------------------------------------------------------------------------------------------
311
+ * DropdownMenuSub
312
+ * -----------------------------------------------------------------------------------------------*/ const $d1bf075a6b218014$export$2f307d81a64f5442 = (props)=>{
313
+ const { __scopeDropdownMenu: __scopeDropdownMenu , children: children , open: openProp , onOpenChange: onOpenChange , defaultOpen: defaultOpen } = props;
314
+ const menuScope = $d1bf075a6b218014$var$useMenuScope(__scopeDropdownMenu);
315
+ const [open = false, setOpen] = $7dQ7Q$radixuireactusecontrollablestate.useControllableState({
316
+ prop: openProp,
317
+ defaultProp: defaultOpen,
318
+ onChange: onOpenChange
319
+ });
320
+ return /*#__PURE__*/ $7dQ7Q$react.createElement($7dQ7Q$radixuireactmenu.Sub, ($parcel$interopDefault($7dQ7Q$babelruntimehelpersextends))({}, menuScope, {
321
+ open: open,
322
+ onOpenChange: setOpen
323
+ }), children);
324
+ };
325
+ /* -------------------------------------------------------------------------------------------------
326
+ * DropdownMenuSubTrigger
327
+ * -----------------------------------------------------------------------------------------------*/ const $d1bf075a6b218014$var$SUB_TRIGGER_NAME = 'DropdownMenuSubTrigger';
328
+ const $d1bf075a6b218014$export$21dcb7ec56f874cf = /*#__PURE__*/ $7dQ7Q$react.forwardRef((props, forwardedRef)=>{
329
+ const { __scopeDropdownMenu: __scopeDropdownMenu , ...subTriggerProps } = props;
330
+ const menuScope = $d1bf075a6b218014$var$useMenuScope(__scopeDropdownMenu);
331
+ return /*#__PURE__*/ $7dQ7Q$react.createElement($7dQ7Q$radixuireactmenu.SubTrigger, ($parcel$interopDefault($7dQ7Q$babelruntimehelpersextends))({}, menuScope, subTriggerProps, {
332
+ ref: forwardedRef
333
+ }));
334
+ });
335
+ /*#__PURE__*/ Object.assign($d1bf075a6b218014$export$21dcb7ec56f874cf, {
336
+ displayName: $d1bf075a6b218014$var$SUB_TRIGGER_NAME
337
+ });
338
+ /* -------------------------------------------------------------------------------------------------
339
+ * DropdownMenuSubContent
340
+ * -----------------------------------------------------------------------------------------------*/ const $d1bf075a6b218014$var$SUB_CONTENT_NAME = 'DropdownMenuSubContent';
341
+ const $d1bf075a6b218014$export$f34ec8bc2482cc5f = /*#__PURE__*/ $7dQ7Q$react.forwardRef((props, forwardedRef)=>{
342
+ const { __scopeDropdownMenu: __scopeDropdownMenu , ...subContentProps } = props;
343
+ const menuScope = $d1bf075a6b218014$var$useMenuScope(__scopeDropdownMenu);
344
+ return /*#__PURE__*/ $7dQ7Q$react.createElement($7dQ7Q$radixuireactmenu.SubContent, ($parcel$interopDefault($7dQ7Q$babelruntimehelpersextends))({}, menuScope, subContentProps, {
345
+ ref: forwardedRef,
346
+ style: {
347
+ ...props.style,
348
+ // re-namespace exposed content custom property
349
+ ['--radix-dropdown-menu-content-transform-origin']: 'var(--radix-popper-transform-origin)'
350
+ }
351
+ }));
352
+ });
353
+ /*#__PURE__*/ Object.assign($d1bf075a6b218014$export$f34ec8bc2482cc5f, {
354
+ displayName: $d1bf075a6b218014$var$SUB_CONTENT_NAME
355
+ });
367
356
  /* -----------------------------------------------------------------------------------------------*/ const $d1bf075a6b218014$export$be92b6f5f03c0fe9 = $d1bf075a6b218014$export$e44a253a59704894;
368
357
  const $d1bf075a6b218014$export$41fb9f06171c75f4 = $d1bf075a6b218014$export$d2469213b3befba9;
358
+ const $d1bf075a6b218014$export$602eac185826482c = $d1bf075a6b218014$export$cd369b4d4d54efc9;
369
359
  const $d1bf075a6b218014$export$7c6e2c02157bb7d2 = $d1bf075a6b218014$export$6e76d93a37c01248;
370
360
  const $d1bf075a6b218014$export$eb2fcfdbd7ba97d4 = $d1bf075a6b218014$export$246bebaba3a2f70e;
371
361
  const $d1bf075a6b218014$export$b04be29aa201d4f5 = $d1bf075a6b218014$export$76e48c5b57f24495;
372
362
  const $d1bf075a6b218014$export$6d08773d2e66f8f2 = $d1bf075a6b218014$export$ed97964d1871885d;
373
- const $d1bf075a6b218014$export$6d0911d397e3b965 = $d1bf075a6b218014$export$eb7a5647860df79a;
374
363
  const $d1bf075a6b218014$export$16ce288f89fa631c = $d1bf075a6b218014$export$53a69729da201fa9;
375
364
  const $d1bf075a6b218014$export$a98f0dcb43a68a25 = $d1bf075a6b218014$export$3323ad73d55f587e;
376
365
  const $d1bf075a6b218014$export$371ab307eab489c0 = $d1bf075a6b218014$export$e4f69b41b1637536;
377
366
  const $d1bf075a6b218014$export$c3468e2714d175fa = $d1bf075a6b218014$export$42355ae145153fb6;
378
367
  const $d1bf075a6b218014$export$1ff3c3f08ae963c0 = $d1bf075a6b218014$export$da160178fd3bc7e9;
379
368
  const $d1bf075a6b218014$export$21b07c8f274aebd5 = $d1bf075a6b218014$export$34b8980744021ec5;
369
+ const $d1bf075a6b218014$export$d7a01e11500dfb6f = $d1bf075a6b218014$export$2f307d81a64f5442;
370
+ const $d1bf075a6b218014$export$2ea8a7a591ac5eac = $d1bf075a6b218014$export$21dcb7ec56f874cf;
371
+ const $d1bf075a6b218014$export$6d4de93b380beddf = $d1bf075a6b218014$export$f34ec8bc2482cc5f;
380
372
 
381
373
 
382
- $parcel$exportWildcard(module.exports, $d1bf075a6b218014$exports);
383
374
 
384
375
 
385
376
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;A;;;;;;;;;;ACeA;;oGAEA,CAEA,MAAMS,wCAAkB,GAAG,cAA3B,AAAA;AAGA,MAAM,CAACC,+CAAD,EAA4BC,yCAA5B,CAAA,GAAuDR,6CAAkB,CAC7EM,wCAD6E,EAE7E;IAACF,uCAAD;CAF6E,CAA/E,AAAA;AAIA,MAAMK,kCAAY,GAAGL,uCAAe,EAApC,AAAA;AAoBA,MAAM,CAACM,0CAAD,EAAuBC,4CAAvB,CAAA,GAAiDJ,+CAAyB,CAE9ED,wCAF8E,CAAhF,AAAA;AAaA,MAAMM,yCAAyC,GAAIC,CAAAA,KAAD,GAA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AAa,GAAGlB,yCAAtB,AAAA;AACA,MAAMmB,yCAAS,GAAGhB,yCAAlB,AAAA;AACA,MAAMiB,yCAAK,GAAGd,yCAAd,AAAA;;ADrfA","sources":["packages/react/dropdown-menu/src/index.ts","packages/react/dropdown-menu/src/DropdownMenu.tsx"],"sourcesContent":["export * from './DropdownMenu';\n","import * as React from 'react';\nimport { composeEventHandlers } from '@radix-ui/primitive';\nimport { composeRefs } from '@radix-ui/react-compose-refs';\nimport { createContextScope } from '@radix-ui/react-context';\nimport { useControllableState } from '@radix-ui/react-use-controllable-state';\nimport { Primitive } from '@radix-ui/react-primitive';\nimport * as MenuPrimitive from '@radix-ui/react-menu';\nimport { createMenuScope } from '@radix-ui/react-menu';\nimport { useId } from '@radix-ui/react-id';\n\nimport type * as Radix from '@radix-ui/react-primitive';\nimport type { Scope } from '@radix-ui/react-context';\n\ntype Direction = 'ltr' | 'rtl';\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenu\n * -----------------------------------------------------------------------------------------------*/\n\nconst DROPDOWN_MENU_NAME = 'DropdownMenu';\n\ntype ScopedProps<P> = P & { __scopeDropdownMenu?: Scope };\nconst [createDropdownMenuContext, createDropdownMenuScope] = createContextScope(\n DROPDOWN_MENU_NAME,\n [createMenuScope]\n);\nconst useMenuScope = createMenuScope();\n\ntype DropdownMenuRootContextValue = {\n isRootMenu: true;\n triggerId: string;\n triggerRef: React.RefObject<HTMLButtonElement>;\n contentId: string;\n open: boolean;\n onOpenChange(open: boolean): void;\n onOpenToggle(): void;\n modal: boolean;\n};\n\ntype DropdownMenuSubContextValue = {\n isRootMenu: false;\n open: boolean;\n onOpenChange(open: boolean): void;\n onOpenToggle(): void;\n};\n\nconst [DropdownMenuProvider, useDropdownMenuContext] = createDropdownMenuContext<\n DropdownMenuRootContextValue | DropdownMenuSubContextValue\n>(DROPDOWN_MENU_NAME);\n\ninterface DropdownMenuProps {\n children?: React.ReactNode;\n dir?: Direction;\n open?: boolean;\n defaultOpen?: boolean;\n onOpenChange?(open: boolean): void;\n modal?: boolean;\n}\n\nconst DropdownMenu: React.FC<DropdownMenuProps> = (props: ScopedProps<DropdownMenuProps>) => {\n const { __scopeDropdownMenu, children, open: openProp, defaultOpen, onOpenChange } = props;\n const contentContext = useContentContext(DROPDOWN_MENU_NAME, __scopeDropdownMenu);\n const menuScope = useMenuScope(__scopeDropdownMenu);\n const [open = false, setOpen] = useControllableState({\n prop: openProp,\n defaultProp: defaultOpen,\n onChange: onOpenChange,\n });\n\n const handleOpenToggle = React.useCallback(() => setOpen((prevOpen) => !prevOpen), [setOpen]);\n\n return contentContext.isInsideContent ? (\n <DropdownMenuProvider\n scope={__scopeDropdownMenu}\n isRootMenu={false}\n open={open}\n onOpenChange={setOpen}\n onOpenToggle={handleOpenToggle}\n >\n <MenuPrimitive.Sub {...menuScope} open={open} onOpenChange={setOpen}>\n {children}\n </MenuPrimitive.Sub>\n </DropdownMenuProvider>\n ) : (\n <DropdownMenuRoot {...props} open={open} onOpenChange={setOpen} onOpenToggle={handleOpenToggle}>\n {children}\n </DropdownMenuRoot>\n );\n};\n\nDropdownMenu.displayName = DROPDOWN_MENU_NAME;\n\n/* ---------------------------------------------------------------------------------------------- */\n\ninterface DropdownMenuRootProps {\n children?: React.ReactNode;\n dir?: Direction;\n open: boolean;\n onOpenChange(open: boolean): void;\n onOpenToggle(): void;\n modal?: boolean;\n}\n\nconst DropdownMenuRoot: React.FC<DropdownMenuRootProps> = (\n props: ScopedProps<DropdownMenuRootProps>\n) => {\n const {\n __scopeDropdownMenu,\n children,\n dir,\n open,\n onOpenChange,\n onOpenToggle,\n modal = true,\n } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n const triggerRef = React.useRef<HTMLButtonElement>(null);\n return (\n <DropdownMenuProvider\n scope={__scopeDropdownMenu}\n isRootMenu={true}\n triggerId={useId()}\n triggerRef={triggerRef}\n contentId={useId()}\n open={open}\n onOpenChange={onOpenChange}\n onOpenToggle={onOpenToggle}\n modal={modal}\n >\n <MenuPrimitive.Root\n {...menuScope}\n open={open}\n onOpenChange={onOpenChange}\n dir={dir}\n modal={modal}\n >\n {children}\n </MenuPrimitive.Root>\n </DropdownMenuProvider>\n );\n};\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuTrigger\n * -----------------------------------------------------------------------------------------------*/\n\nconst TRIGGER_NAME = 'DropdownMenuTrigger';\n\ntype DropdownMenuTriggerElement = React.ElementRef<typeof Primitive.button>;\ntype PrimitiveButtonProps = Radix.ComponentPropsWithoutRef<typeof Primitive.button>;\ninterface DropdownMenuTriggerProps extends PrimitiveButtonProps {}\n\nconst DropdownMenuTrigger = React.forwardRef<DropdownMenuTriggerElement, DropdownMenuTriggerProps>(\n (props: ScopedProps<DropdownMenuTriggerProps>, forwardedRef) => {\n const { __scopeDropdownMenu, disabled = false, ...triggerProps } = props;\n const context = useDropdownMenuContext(TRIGGER_NAME, __scopeDropdownMenu);\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return context.isRootMenu ? (\n <MenuPrimitive.Anchor asChild {...menuScope}>\n <Primitive.button\n type=\"button\"\n id={context.triggerId}\n aria-haspopup=\"menu\"\n aria-expanded={context.open ? true : undefined}\n aria-controls={context.open ? context.contentId : undefined}\n data-state={context.open ? 'open' : 'closed'}\n data-disabled={disabled ? '' : undefined}\n disabled={disabled}\n {...triggerProps}\n ref={composeRefs(forwardedRef, context.triggerRef)}\n onPointerDown={composeEventHandlers(props.onPointerDown, (event) => {\n // only call handler if it's the left button (mousedown gets triggered by all mouse buttons)\n // but not when the control key is pressed (avoiding MacOS right click)\n if (!disabled && event.button === 0 && event.ctrlKey === false) {\n // prevent trigger focusing when opening\n // this allows the content to be given focus without competition\n if (!context.open) event.preventDefault();\n context.onOpenToggle();\n }\n })}\n onKeyDown={composeEventHandlers(props.onKeyDown, (event) => {\n if (disabled) return;\n if (['Enter', ' '].includes(event.key)) context.onOpenToggle();\n if (event.key === 'ArrowDown') context.onOpenChange(true);\n // prevent keypresses from scrolling window\n if ([' ', 'ArrowDown'].includes(event.key)) event.preventDefault();\n })}\n />\n </MenuPrimitive.Anchor>\n ) : null;\n }\n);\n\nDropdownMenuTrigger.displayName = TRIGGER_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuContent\n * -----------------------------------------------------------------------------------------------*/\n\nconst CONTENT_NAME = 'DropdownMenuContent';\n\nconst [ContentProvider, useContentContext] = createDropdownMenuContext(CONTENT_NAME, {\n isInsideContent: false,\n});\n\ntype DropdownMenuContentElement =\n | DropdownMenuRootContentElement\n | React.ElementRef<typeof MenuPrimitive.Content>;\ntype MenuContentProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Content>;\ninterface DropdownMenuContentProps extends DropdownMenuRootContentProps, MenuContentProps {}\n\nconst DropdownMenuContent = React.forwardRef<DropdownMenuContentElement, DropdownMenuContentProps>(\n (props: ScopedProps<DropdownMenuContentProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...contentProps } = props;\n const context = useDropdownMenuContext(CONTENT_NAME, __scopeDropdownMenu);\n const menuScope = useMenuScope(__scopeDropdownMenu);\n const commonProps = {\n ...contentProps,\n style: {\n ...props.style,\n // re-namespace exposed content custom property\n ['--radix-dropdown-menu-content-transform-origin' as any]:\n 'var(--radix-popper-transform-origin)',\n },\n };\n\n return (\n <ContentProvider scope={__scopeDropdownMenu} isInsideContent={true}>\n {context.isRootMenu ? (\n <DropdownMenuRootContent\n __scopeDropdownMenu={__scopeDropdownMenu}\n {...commonProps}\n ref={forwardedRef}\n />\n ) : (\n <MenuPrimitive.Content {...menuScope} {...commonProps} ref={forwardedRef} />\n )}\n </ContentProvider>\n );\n }\n);\n\nDropdownMenuContent.displayName = CONTENT_NAME;\n\n/* ---------------------------------------------------------------------------------------------- */\n\ntype DropdownMenuRootContentElement = React.ElementRef<typeof MenuPrimitive.Content>;\ninterface DropdownMenuRootContentProps extends ScopedProps<MenuContentProps> {}\n\nconst DropdownMenuRootContent = React.forwardRef<\n DropdownMenuRootContentElement,\n DropdownMenuRootContentProps\n>((props, forwardedRef) => {\n const { __scopeDropdownMenu, portalled = true, ...contentProps } = props;\n const context = useDropdownMenuContext(CONTENT_NAME, __scopeDropdownMenu);\n const menuScope = useMenuScope(__scopeDropdownMenu);\n const hasInteractedOutsideRef = React.useRef(false);\n return context.isRootMenu ? (\n <MenuPrimitive.Content\n id={context.contentId}\n aria-labelledby={context.triggerId}\n {...menuScope}\n {...contentProps}\n ref={forwardedRef}\n portalled={portalled}\n onCloseAutoFocus={composeEventHandlers(props.onCloseAutoFocus, (event) => {\n if (!hasInteractedOutsideRef.current) context.triggerRef.current?.focus();\n hasInteractedOutsideRef.current = false;\n // Always prevent auto focus because we either focus manually or want user agent focus\n event.preventDefault();\n })}\n onInteractOutside={composeEventHandlers(props.onInteractOutside, (event) => {\n const originalEvent = event.detail.originalEvent as PointerEvent;\n const ctrlLeftClick = originalEvent.button === 0 && originalEvent.ctrlKey === true;\n const isRightClick = originalEvent.button === 2 || ctrlLeftClick;\n if (!context.modal || isRightClick) hasInteractedOutsideRef.current = true;\n })}\n />\n ) : null;\n});\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuGroup\n * -----------------------------------------------------------------------------------------------*/\n\nconst GROUP_NAME = 'DropdownMenuGroup';\n\ntype DropdownMenuGroupElement = React.ElementRef<typeof MenuPrimitive.Group>;\ntype MenuGroupProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Group>;\ninterface DropdownMenuGroupProps extends MenuGroupProps {}\n\nconst DropdownMenuGroup = React.forwardRef<DropdownMenuGroupElement, DropdownMenuGroupProps>(\n (props: ScopedProps<DropdownMenuGroupProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...groupProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.Group {...menuScope} {...groupProps} ref={forwardedRef} />;\n }\n);\n\nDropdownMenuGroup.displayName = GROUP_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuLabel\n * -----------------------------------------------------------------------------------------------*/\n\nconst LABEL_NAME = 'DropdownMenuLabel';\n\ntype DropdownMenuLabelElement = React.ElementRef<typeof MenuPrimitive.Label>;\ntype MenuLabelProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Label>;\ninterface DropdownMenuLabelProps extends MenuLabelProps {}\n\nconst DropdownMenuLabel = React.forwardRef<DropdownMenuLabelElement, DropdownMenuLabelProps>(\n (props: ScopedProps<DropdownMenuLabelProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...labelProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.Label {...menuScope} {...labelProps} ref={forwardedRef} />;\n }\n);\n\nDropdownMenuLabel.displayName = LABEL_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuItem\n * -----------------------------------------------------------------------------------------------*/\n\nconst ITEM_NAME = 'DropdownMenuItem';\n\ntype DropdownMenuItemElement = React.ElementRef<typeof MenuPrimitive.Item>;\ntype MenuItemProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Item>;\ninterface DropdownMenuItemProps extends MenuItemProps {}\n\nconst DropdownMenuItem = React.forwardRef<DropdownMenuItemElement, DropdownMenuItemProps>(\n (props: ScopedProps<DropdownMenuItemProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...itemProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.Item {...menuScope} {...itemProps} ref={forwardedRef} />;\n }\n);\n\nDropdownMenuItem.displayName = ITEM_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuTriggerItem\n * -----------------------------------------------------------------------------------------------*/\n\nconst TRIGGER_ITEM_NAME = 'DropdownMenuTriggerItem';\n\ntype DropdownMenuTriggerItemElement = React.ElementRef<typeof MenuPrimitive.SubTrigger>;\ntype MenuSubTriggerProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.SubTrigger>;\ninterface DropdownMenuTriggerItemProps extends MenuSubTriggerProps {}\n\nconst DropdownMenuTriggerItem = React.forwardRef<\n DropdownMenuTriggerItemElement,\n DropdownMenuTriggerItemProps\n>((props: ScopedProps<DropdownMenuTriggerItemProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...triggerItemProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.SubTrigger {...menuScope} {...triggerItemProps} ref={forwardedRef} />;\n});\n\nDropdownMenuTriggerItem.displayName = TRIGGER_ITEM_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuCheckboxItem\n * -----------------------------------------------------------------------------------------------*/\n\nconst CHECKBOX_ITEM_NAME = 'DropdownMenuCheckboxItem';\n\ntype DropdownMenuCheckboxItemElement = React.ElementRef<typeof MenuPrimitive.CheckboxItem>;\ntype MenuCheckboxItemProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.CheckboxItem>;\ninterface DropdownMenuCheckboxItemProps extends MenuCheckboxItemProps {}\n\nconst DropdownMenuCheckboxItem = React.forwardRef<\n DropdownMenuCheckboxItemElement,\n DropdownMenuCheckboxItemProps\n>((props: ScopedProps<DropdownMenuCheckboxItemProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...checkboxItemProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.CheckboxItem {...menuScope} {...checkboxItemProps} ref={forwardedRef} />;\n});\n\nDropdownMenuCheckboxItem.displayName = CHECKBOX_ITEM_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuRadioGroup\n * -----------------------------------------------------------------------------------------------*/\n\nconst RADIO_GROUP_NAME = 'DropdownMenuRadioGroup';\n\ntype DropdownMenuRadioGroupElement = React.ElementRef<typeof MenuPrimitive.RadioGroup>;\ntype MenuRadioGroupProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.RadioGroup>;\ninterface DropdownMenuRadioGroupProps extends MenuRadioGroupProps {}\n\nconst DropdownMenuRadioGroup = React.forwardRef<\n DropdownMenuRadioGroupElement,\n DropdownMenuRadioGroupProps\n>((props: ScopedProps<DropdownMenuRadioGroupProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...radioGroupProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.RadioGroup {...menuScope} {...radioGroupProps} ref={forwardedRef} />;\n});\n\nDropdownMenuRadioGroup.displayName = RADIO_GROUP_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuRadioItem\n * -----------------------------------------------------------------------------------------------*/\n\nconst RADIO_ITEM_NAME = 'DropdownMenuRadioItem';\n\ntype DropdownMenuRadioItemElement = React.ElementRef<typeof MenuPrimitive.RadioItem>;\ntype MenuRadioItemProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.RadioItem>;\ninterface DropdownMenuRadioItemProps extends MenuRadioItemProps {}\n\nconst DropdownMenuRadioItem = React.forwardRef<\n DropdownMenuRadioItemElement,\n DropdownMenuRadioItemProps\n>((props: ScopedProps<DropdownMenuRadioItemProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...radioItemProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.RadioItem {...menuScope} {...radioItemProps} ref={forwardedRef} />;\n});\n\nDropdownMenuRadioItem.displayName = RADIO_ITEM_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuItemIndicator\n * -----------------------------------------------------------------------------------------------*/\n\nconst INDICATOR_NAME = 'DropdownMenuItemIndicator';\n\ntype DropdownMenuItemIndicatorElement = React.ElementRef<typeof MenuPrimitive.ItemIndicator>;\ntype MenuItemIndicatorProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.ItemIndicator>;\ninterface DropdownMenuItemIndicatorProps extends MenuItemIndicatorProps {}\n\nconst DropdownMenuItemIndicator = React.forwardRef<\n DropdownMenuItemIndicatorElement,\n DropdownMenuItemIndicatorProps\n>((props: ScopedProps<DropdownMenuItemIndicatorProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...itemIndicatorProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.ItemIndicator {...menuScope} {...itemIndicatorProps} ref={forwardedRef} />;\n});\n\nDropdownMenuItemIndicator.displayName = INDICATOR_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuSeparator\n * -----------------------------------------------------------------------------------------------*/\n\nconst SEPARATOR_NAME = 'DropdownMenuSeparator';\n\ntype DropdownMenuSeparatorElement = React.ElementRef<typeof MenuPrimitive.Separator>;\ntype MenuSeparatorProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Separator>;\ninterface DropdownMenuSeparatorProps extends MenuSeparatorProps {}\n\nconst DropdownMenuSeparator = React.forwardRef<\n DropdownMenuSeparatorElement,\n DropdownMenuSeparatorProps\n>((props: ScopedProps<DropdownMenuSeparatorProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...separatorProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.Separator {...menuScope} {...separatorProps} ref={forwardedRef} />;\n});\n\nDropdownMenuSeparator.displayName = SEPARATOR_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuArrow\n * -----------------------------------------------------------------------------------------------*/\n\nconst ARROW_NAME = 'DropdownMenuArrow';\n\ntype DropdownMenuArrowElement = React.ElementRef<typeof MenuPrimitive.Arrow>;\ntype MenuArrowProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Arrow>;\ninterface DropdownMenuArrowProps extends MenuArrowProps {}\n\nconst DropdownMenuArrow = React.forwardRef<DropdownMenuArrowElement, DropdownMenuArrowProps>(\n (props: ScopedProps<DropdownMenuArrowProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...arrowProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.Arrow {...menuScope} {...arrowProps} ref={forwardedRef} />;\n }\n);\n\nDropdownMenuArrow.displayName = ARROW_NAME;\n\n/* -----------------------------------------------------------------------------------------------*/\n\nconst Root = DropdownMenu;\nconst Trigger = DropdownMenuTrigger;\nconst Content = DropdownMenuContent;\nconst Group = DropdownMenuGroup;\nconst Label = DropdownMenuLabel;\nconst Item = DropdownMenuItem;\nconst TriggerItem = DropdownMenuTriggerItem;\nconst CheckboxItem = DropdownMenuCheckboxItem;\nconst RadioGroup = DropdownMenuRadioGroup;\nconst RadioItem = DropdownMenuRadioItem;\nconst ItemIndicator = DropdownMenuItemIndicator;\nconst Separator = DropdownMenuSeparator;\nconst Arrow = DropdownMenuArrow;\n\nexport {\n createDropdownMenuScope,\n //\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuGroup,\n DropdownMenuLabel,\n DropdownMenuItem,\n DropdownMenuTriggerItem,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioGroup,\n DropdownMenuRadioItem,\n DropdownMenuItemIndicator,\n DropdownMenuSeparator,\n DropdownMenuArrow,\n //\n Root,\n Trigger,\n Content,\n Group,\n Label,\n Item,\n TriggerItem,\n CheckboxItem,\n RadioGroup,\n RadioItem,\n ItemIndicator,\n Separator,\n Arrow,\n};\nexport type {\n DropdownMenuProps,\n DropdownMenuTriggerProps,\n DropdownMenuContentProps,\n DropdownMenuGroupProps,\n DropdownMenuLabelProps,\n DropdownMenuItemProps,\n DropdownMenuTriggerItemProps,\n DropdownMenuCheckboxItemProps,\n DropdownMenuRadioGroupProps,\n DropdownMenuRadioItemProps,\n DropdownMenuItemIndicatorProps,\n DropdownMenuSeparatorProps,\n DropdownMenuArrowProps,\n};\n"],"names":["React","composeEventHandlers","composeRefs","createContextScope","useControllableState","Primitive","MenuPrimitive","createMenuScope","useId","DROPDOWN_MENU_NAME","createDropdownMenuContext","createDropdownMenuScope","useMenuScope","DropdownMenuProvider","useDropdownMenuContext","DropdownMenu","props","__scopeDropdownMenu","children","open","openProp","defaultOpen","onOpenChange","contentContext","useContentContext","menuScope","setOpen","prop","defaultProp","onChange","handleOpenToggle","useCallback","prevOpen","isInsideContent","DropdownMenuRoot","dir","onOpenToggle","modal","triggerRef","useRef","TRIGGER_NAME","DropdownMenuTrigger","forwardRef","forwardedRef","disabled","triggerProps","context","isRootMenu","triggerId","undefined","contentId","onPointerDown","event","button","ctrlKey","preventDefault","onKeyDown","includes","key","CONTENT_NAME","ContentProvider","DropdownMenuContent","contentProps","commonProps","style","DropdownMenuRootContent","portalled","hasInteractedOutsideRef","onCloseAutoFocus","current","focus","onInteractOutside","originalEvent","detail","ctrlLeftClick","isRightClick","GROUP_NAME","DropdownMenuGroup","groupProps","LABEL_NAME","DropdownMenuLabel","labelProps","ITEM_NAME","DropdownMenuItem","itemProps","TRIGGER_ITEM_NAME","DropdownMenuTriggerItem","triggerItemProps","CHECKBOX_ITEM_NAME","DropdownMenuCheckboxItem","checkboxItemProps","RADIO_GROUP_NAME","DropdownMenuRadioGroup","radioGroupProps","RADIO_ITEM_NAME","DropdownMenuRadioItem","radioItemProps","INDICATOR_NAME","DropdownMenuItemIndicator","itemIndicatorProps","SEPARATOR_NAME","DropdownMenuSeparator","separatorProps","ARROW_NAME","DropdownMenuArrow","arrowProps","Root","Trigger","Content","Group","Label","Item","TriggerItem","CheckboxItem","RadioGroup","RadioItem","ItemIndicator","Separator","Arrow"],"version":3,"file":"index.js.map"}
1
+ {"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;A;;;;;;;;;;ACeA;;oGAEA,CAEA,MAAM0C,wCAAkB,GAAG,cAA3B,AAAA;AAGA,MAAM,CAACC,+CAAD,EAA4B3C,yCAA5B,CAAA,GAAuDoC,6CAAkB,CAC7EM,wCAD6E,EAE7E;IAACF,uCAAD;CAF6E,CAA/E,AAAA;AAIA,MAAMI,kCAAY,GAAGJ,uCAAe,EAApC,AAAA;AAYA,MAAM,CAACK,0CAAD,EAAuBC,4CAAvB,CAAA,GACJH,+CAAyB,CAA2BD,wCAA3B,CAD3B,AAAA;AAYA,MAAMzC,yC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DropdownMenu.tsx"],"sourcesContent":["export {\n createDropdownMenuScope,\n //\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuPortal,\n DropdownMenuContent,\n DropdownMenuGroup,\n DropdownMenuLabel,\n DropdownMenuItem,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioGroup,\n DropdownMenuRadioItem,\n DropdownMenuItemIndicator,\n DropdownMenuSeparator,\n DropdownMenuArrow,\n DropdownMenuSub,\n DropdownMenuSubTrigger,\n DropdownMenuSubContent,\n //\n Root,\n Trigger,\n Portal,\n Content,\n Group,\n Label,\n Item,\n CheckboxItem,\n RadioGroup,\n RadioItem,\n ItemIndicator,\n Separator,\n Arrow,\n Sub,\n SubTrigger,\n SubContent,\n} from './DropdownMenu';\nexport type {\n DropdownMenuProps,\n DropdownMenuTriggerProps,\n DropdownMenuPortalProps,\n DropdownMenuContentProps,\n DropdownMenuGroupProps,\n DropdownMenuLabelProps,\n DropdownMenuItemProps,\n DropdownMenuCheckboxItemProps,\n DropdownMenuRadioGroupProps,\n DropdownMenuRadioItemProps,\n DropdownMenuItemIndicatorProps,\n DropdownMenuSeparatorProps,\n DropdownMenuArrowProps,\n DropdownMenuSubProps,\n DropdownMenuSubTriggerProps,\n DropdownMenuSubContentProps,\n} from './DropdownMenu';\n","import * as React from 'react';\nimport { composeEventHandlers } from '@radix-ui/primitive';\nimport { composeRefs } from '@radix-ui/react-compose-refs';\nimport { createContextScope } from '@radix-ui/react-context';\nimport { useControllableState } from '@radix-ui/react-use-controllable-state';\nimport { Primitive } from '@radix-ui/react-primitive';\nimport * as MenuPrimitive from '@radix-ui/react-menu';\nimport { createMenuScope } from '@radix-ui/react-menu';\nimport { useId } from '@radix-ui/react-id';\n\nimport type * as Radix from '@radix-ui/react-primitive';\nimport type { Scope } from '@radix-ui/react-context';\n\ntype Direction = 'ltr' | 'rtl';\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenu\n * -----------------------------------------------------------------------------------------------*/\n\nconst DROPDOWN_MENU_NAME = 'DropdownMenu';\n\ntype ScopedProps<P> = P & { __scopeDropdownMenu?: Scope };\nconst [createDropdownMenuContext, createDropdownMenuScope] = createContextScope(\n DROPDOWN_MENU_NAME,\n [createMenuScope]\n);\nconst useMenuScope = createMenuScope();\n\ntype DropdownMenuContextValue = {\n triggerId: string;\n triggerRef: React.RefObject<HTMLButtonElement>;\n contentId: string;\n open: boolean;\n onOpenChange(open: boolean): void;\n onOpenToggle(): void;\n modal: boolean;\n};\n\nconst [DropdownMenuProvider, useDropdownMenuContext] =\n createDropdownMenuContext<DropdownMenuContextValue>(DROPDOWN_MENU_NAME);\n\ninterface DropdownMenuProps {\n children?: React.ReactNode;\n dir?: Direction;\n open?: boolean;\n defaultOpen?: boolean;\n onOpenChange?(open: boolean): void;\n modal?: boolean;\n}\n\nconst DropdownMenu: React.FC<DropdownMenuProps> = (props: ScopedProps<DropdownMenuProps>) => {\n const {\n __scopeDropdownMenu,\n children,\n dir,\n open: openProp,\n defaultOpen,\n onOpenChange,\n modal = true,\n } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n const triggerRef = React.useRef<HTMLButtonElement>(null);\n const [open = false, setOpen] = useControllableState({\n prop: openProp,\n defaultProp: defaultOpen,\n onChange: onOpenChange,\n });\n\n return (\n <DropdownMenuProvider\n scope={__scopeDropdownMenu}\n triggerId={useId()}\n triggerRef={triggerRef}\n contentId={useId()}\n open={open}\n onOpenChange={setOpen}\n onOpenToggle={React.useCallback(() => setOpen((prevOpen) => !prevOpen), [setOpen])}\n modal={modal}\n >\n <MenuPrimitive.Root {...menuScope} open={open} onOpenChange={setOpen} dir={dir} modal={modal}>\n {children}\n </MenuPrimitive.Root>\n </DropdownMenuProvider>\n );\n};\n\nDropdownMenu.displayName = DROPDOWN_MENU_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuTrigger\n * -----------------------------------------------------------------------------------------------*/\n\nconst TRIGGER_NAME = 'DropdownMenuTrigger';\n\ntype DropdownMenuTriggerElement = React.ElementRef<typeof Primitive.button>;\ntype PrimitiveButtonProps = Radix.ComponentPropsWithoutRef<typeof Primitive.button>;\ninterface DropdownMenuTriggerProps extends PrimitiveButtonProps {}\n\nconst DropdownMenuTrigger = React.forwardRef<DropdownMenuTriggerElement, DropdownMenuTriggerProps>(\n (props: ScopedProps<DropdownMenuTriggerProps>, forwardedRef) => {\n const { __scopeDropdownMenu, disabled = false, ...triggerProps } = props;\n const context = useDropdownMenuContext(TRIGGER_NAME, __scopeDropdownMenu);\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return (\n <MenuPrimitive.Anchor asChild {...menuScope}>\n <Primitive.button\n type=\"button\"\n id={context.triggerId}\n aria-haspopup=\"menu\"\n aria-expanded={context.open ? true : undefined}\n aria-controls={context.open ? context.contentId : undefined}\n data-state={context.open ? 'open' : 'closed'}\n data-disabled={disabled ? '' : undefined}\n disabled={disabled}\n {...triggerProps}\n ref={composeRefs(forwardedRef, context.triggerRef)}\n onPointerDown={composeEventHandlers(props.onPointerDown, (event) => {\n // only call handler if it's the left button (mousedown gets triggered by all mouse buttons)\n // but not when the control key is pressed (avoiding MacOS right click)\n if (!disabled && event.button === 0 && event.ctrlKey === false) {\n context.onOpenToggle();\n // prevent trigger focusing when opening\n // this allows the content to be given focus without competition\n if (!context.open) event.preventDefault();\n }\n })}\n onKeyDown={composeEventHandlers(props.onKeyDown, (event) => {\n if (disabled) return;\n if (['Enter', ' '].includes(event.key)) context.onOpenToggle();\n if (event.key === 'ArrowDown') context.onOpenChange(true);\n // prevent keypresses from scrolling window\n if ([' ', 'ArrowDown'].includes(event.key)) event.preventDefault();\n })}\n />\n </MenuPrimitive.Anchor>\n );\n }\n);\n\nDropdownMenuTrigger.displayName = TRIGGER_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuPortal\n * -----------------------------------------------------------------------------------------------*/\n\nconst PORTAL_NAME = 'DropdownMenuPortal';\n\ntype MenuPortalProps = React.ComponentPropsWithoutRef<typeof MenuPrimitive.Portal>;\ninterface DropdownMenuPortalProps extends MenuPortalProps {}\n\nconst DropdownMenuPortal: React.FC<DropdownMenuPortalProps> = (\n props: ScopedProps<DropdownMenuPortalProps>\n) => {\n const { __scopeDropdownMenu, ...portalProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.Portal {...menuScope} {...portalProps} />;\n};\n\nDropdownMenuPortal.displayName = PORTAL_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuContent\n * -----------------------------------------------------------------------------------------------*/\n\nconst CONTENT_NAME = 'DropdownMenuContent';\n\ntype DropdownMenuContentElement = React.ElementRef<typeof MenuPrimitive.Content>;\ntype MenuContentProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Content>;\ninterface DropdownMenuContentProps extends MenuContentProps {}\n\nconst DropdownMenuContent = React.forwardRef<DropdownMenuContentElement, DropdownMenuContentProps>(\n (props: ScopedProps<DropdownMenuContentProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...contentProps } = props;\n const context = useDropdownMenuContext(CONTENT_NAME, __scopeDropdownMenu);\n const menuScope = useMenuScope(__scopeDropdownMenu);\n const hasInteractedOutsideRef = React.useRef(false);\n\n return (\n <MenuPrimitive.Content\n id={context.contentId}\n aria-labelledby={context.triggerId}\n {...menuScope}\n {...contentProps}\n ref={forwardedRef}\n onCloseAutoFocus={composeEventHandlers(props.onCloseAutoFocus, (event) => {\n if (!hasInteractedOutsideRef.current) context.triggerRef.current?.focus();\n hasInteractedOutsideRef.current = false;\n // Always prevent auto focus because we either focus manually or want user agent focus\n event.preventDefault();\n })}\n onInteractOutside={composeEventHandlers(props.onInteractOutside, (event) => {\n const originalEvent = event.detail.originalEvent as PointerEvent;\n const ctrlLeftClick = originalEvent.button === 0 && originalEvent.ctrlKey === true;\n const isRightClick = originalEvent.button === 2 || ctrlLeftClick;\n if (!context.modal || isRightClick) hasInteractedOutsideRef.current = true;\n })}\n style={{\n ...props.style,\n // re-namespace exposed content custom property\n ['--radix-dropdown-menu-content-transform-origin' as any]:\n 'var(--radix-popper-transform-origin)',\n }}\n />\n );\n }\n);\n\nDropdownMenuContent.displayName = CONTENT_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuGroup\n * -----------------------------------------------------------------------------------------------*/\n\nconst GROUP_NAME = 'DropdownMenuGroup';\n\ntype DropdownMenuGroupElement = React.ElementRef<typeof MenuPrimitive.Group>;\ntype MenuGroupProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Group>;\ninterface DropdownMenuGroupProps extends MenuGroupProps {}\n\nconst DropdownMenuGroup = React.forwardRef<DropdownMenuGroupElement, DropdownMenuGroupProps>(\n (props: ScopedProps<DropdownMenuGroupProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...groupProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.Group {...menuScope} {...groupProps} ref={forwardedRef} />;\n }\n);\n\nDropdownMenuGroup.displayName = GROUP_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuLabel\n * -----------------------------------------------------------------------------------------------*/\n\nconst LABEL_NAME = 'DropdownMenuLabel';\n\ntype DropdownMenuLabelElement = React.ElementRef<typeof MenuPrimitive.Label>;\ntype MenuLabelProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Label>;\ninterface DropdownMenuLabelProps extends MenuLabelProps {}\n\nconst DropdownMenuLabel = React.forwardRef<DropdownMenuLabelElement, DropdownMenuLabelProps>(\n (props: ScopedProps<DropdownMenuLabelProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...labelProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.Label {...menuScope} {...labelProps} ref={forwardedRef} />;\n }\n);\n\nDropdownMenuLabel.displayName = LABEL_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuItem\n * -----------------------------------------------------------------------------------------------*/\n\nconst ITEM_NAME = 'DropdownMenuItem';\n\ntype DropdownMenuItemElement = React.ElementRef<typeof MenuPrimitive.Item>;\ntype MenuItemProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Item>;\ninterface DropdownMenuItemProps extends MenuItemProps {}\n\nconst DropdownMenuItem = React.forwardRef<DropdownMenuItemElement, DropdownMenuItemProps>(\n (props: ScopedProps<DropdownMenuItemProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...itemProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.Item {...menuScope} {...itemProps} ref={forwardedRef} />;\n }\n);\n\nDropdownMenuItem.displayName = ITEM_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuCheckboxItem\n * -----------------------------------------------------------------------------------------------*/\n\nconst CHECKBOX_ITEM_NAME = 'DropdownMenuCheckboxItem';\n\ntype DropdownMenuCheckboxItemElement = React.ElementRef<typeof MenuPrimitive.CheckboxItem>;\ntype MenuCheckboxItemProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.CheckboxItem>;\ninterface DropdownMenuCheckboxItemProps extends MenuCheckboxItemProps {}\n\nconst DropdownMenuCheckboxItem = React.forwardRef<\n DropdownMenuCheckboxItemElement,\n DropdownMenuCheckboxItemProps\n>((props: ScopedProps<DropdownMenuCheckboxItemProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...checkboxItemProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.CheckboxItem {...menuScope} {...checkboxItemProps} ref={forwardedRef} />;\n});\n\nDropdownMenuCheckboxItem.displayName = CHECKBOX_ITEM_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuRadioGroup\n * -----------------------------------------------------------------------------------------------*/\n\nconst RADIO_GROUP_NAME = 'DropdownMenuRadioGroup';\n\ntype DropdownMenuRadioGroupElement = React.ElementRef<typeof MenuPrimitive.RadioGroup>;\ntype MenuRadioGroupProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.RadioGroup>;\ninterface DropdownMenuRadioGroupProps extends MenuRadioGroupProps {}\n\nconst DropdownMenuRadioGroup = React.forwardRef<\n DropdownMenuRadioGroupElement,\n DropdownMenuRadioGroupProps\n>((props: ScopedProps<DropdownMenuRadioGroupProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...radioGroupProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.RadioGroup {...menuScope} {...radioGroupProps} ref={forwardedRef} />;\n});\n\nDropdownMenuRadioGroup.displayName = RADIO_GROUP_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuRadioItem\n * -----------------------------------------------------------------------------------------------*/\n\nconst RADIO_ITEM_NAME = 'DropdownMenuRadioItem';\n\ntype DropdownMenuRadioItemElement = React.ElementRef<typeof MenuPrimitive.RadioItem>;\ntype MenuRadioItemProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.RadioItem>;\ninterface DropdownMenuRadioItemProps extends MenuRadioItemProps {}\n\nconst DropdownMenuRadioItem = React.forwardRef<\n DropdownMenuRadioItemElement,\n DropdownMenuRadioItemProps\n>((props: ScopedProps<DropdownMenuRadioItemProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...radioItemProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.RadioItem {...menuScope} {...radioItemProps} ref={forwardedRef} />;\n});\n\nDropdownMenuRadioItem.displayName = RADIO_ITEM_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuItemIndicator\n * -----------------------------------------------------------------------------------------------*/\n\nconst INDICATOR_NAME = 'DropdownMenuItemIndicator';\n\ntype DropdownMenuItemIndicatorElement = React.ElementRef<typeof MenuPrimitive.ItemIndicator>;\ntype MenuItemIndicatorProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.ItemIndicator>;\ninterface DropdownMenuItemIndicatorProps extends MenuItemIndicatorProps {}\n\nconst DropdownMenuItemIndicator = React.forwardRef<\n DropdownMenuItemIndicatorElement,\n DropdownMenuItemIndicatorProps\n>((props: ScopedProps<DropdownMenuItemIndicatorProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...itemIndicatorProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.ItemIndicator {...menuScope} {...itemIndicatorProps} ref={forwardedRef} />;\n});\n\nDropdownMenuItemIndicator.displayName = INDICATOR_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuSeparator\n * -----------------------------------------------------------------------------------------------*/\n\nconst SEPARATOR_NAME = 'DropdownMenuSeparator';\n\ntype DropdownMenuSeparatorElement = React.ElementRef<typeof MenuPrimitive.Separator>;\ntype MenuSeparatorProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Separator>;\ninterface DropdownMenuSeparatorProps extends MenuSeparatorProps {}\n\nconst DropdownMenuSeparator = React.forwardRef<\n DropdownMenuSeparatorElement,\n DropdownMenuSeparatorProps\n>((props: ScopedProps<DropdownMenuSeparatorProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...separatorProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.Separator {...menuScope} {...separatorProps} ref={forwardedRef} />;\n});\n\nDropdownMenuSeparator.displayName = SEPARATOR_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuArrow\n * -----------------------------------------------------------------------------------------------*/\n\nconst ARROW_NAME = 'DropdownMenuArrow';\n\ntype DropdownMenuArrowElement = React.ElementRef<typeof MenuPrimitive.Arrow>;\ntype MenuArrowProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Arrow>;\ninterface DropdownMenuArrowProps extends MenuArrowProps {}\n\nconst DropdownMenuArrow = React.forwardRef<DropdownMenuArrowElement, DropdownMenuArrowProps>(\n (props: ScopedProps<DropdownMenuArrowProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...arrowProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.Arrow {...menuScope} {...arrowProps} ref={forwardedRef} />;\n }\n);\n\nDropdownMenuArrow.displayName = ARROW_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuSub\n * -----------------------------------------------------------------------------------------------*/\n\ninterface DropdownMenuSubProps {\n children?: React.ReactNode;\n open?: boolean;\n defaultOpen?: boolean;\n onOpenChange?(open: boolean): void;\n}\n\nconst DropdownMenuSub: React.FC<DropdownMenuSubProps> = (\n props: ScopedProps<DropdownMenuSubProps>\n) => {\n const { __scopeDropdownMenu, children, open: openProp, onOpenChange, defaultOpen } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n const [open = false, setOpen] = useControllableState({\n prop: openProp,\n defaultProp: defaultOpen,\n onChange: onOpenChange,\n });\n\n return (\n <MenuPrimitive.Sub {...menuScope} open={open} onOpenChange={setOpen}>\n {children}\n </MenuPrimitive.Sub>\n );\n};\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuSubTrigger\n * -----------------------------------------------------------------------------------------------*/\n\nconst SUB_TRIGGER_NAME = 'DropdownMenuSubTrigger';\n\ntype DropdownMenuSubTriggerElement = React.ElementRef<typeof MenuPrimitive.SubTrigger>;\ntype MenuSubTriggerProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.SubTrigger>;\ninterface DropdownMenuSubTriggerProps extends MenuSubTriggerProps {}\n\nconst DropdownMenuSubTrigger = React.forwardRef<\n DropdownMenuSubTriggerElement,\n DropdownMenuSubTriggerProps\n>((props: ScopedProps<DropdownMenuSubTriggerProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...subTriggerProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.SubTrigger {...menuScope} {...subTriggerProps} ref={forwardedRef} />;\n});\n\nDropdownMenuSubTrigger.displayName = SUB_TRIGGER_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuSubContent\n * -----------------------------------------------------------------------------------------------*/\n\nconst SUB_CONTENT_NAME = 'DropdownMenuSubContent';\n\ntype DropdownMenuSubContentElement = React.ElementRef<typeof MenuPrimitive.Content>;\ntype MenuSubContentProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.SubContent>;\ninterface DropdownMenuSubContentProps extends MenuSubContentProps {}\n\nconst DropdownMenuSubContent = React.forwardRef<\n DropdownMenuSubContentElement,\n DropdownMenuSubContentProps\n>((props: ScopedProps<DropdownMenuSubContentProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...subContentProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n\n return (\n <MenuPrimitive.SubContent\n {...menuScope}\n {...subContentProps}\n ref={forwardedRef}\n style={{\n ...props.style,\n // re-namespace exposed content custom property\n ['--radix-dropdown-menu-content-transform-origin' as any]:\n 'var(--radix-popper-transform-origin)',\n }}\n />\n );\n});\n\nDropdownMenuSubContent.displayName = SUB_CONTENT_NAME;\n\n/* -----------------------------------------------------------------------------------------------*/\n\nconst Root = DropdownMenu;\nconst Trigger = DropdownMenuTrigger;\nconst Portal = DropdownMenuPortal;\nconst Content = DropdownMenuContent;\nconst Group = DropdownMenuGroup;\nconst Label = DropdownMenuLabel;\nconst Item = DropdownMenuItem;\nconst CheckboxItem = DropdownMenuCheckboxItem;\nconst RadioGroup = DropdownMenuRadioGroup;\nconst RadioItem = DropdownMenuRadioItem;\nconst ItemIndicator = DropdownMenuItemIndicator;\nconst Separator = DropdownMenuSeparator;\nconst Arrow = DropdownMenuArrow;\nconst Sub = DropdownMenuSub;\nconst SubTrigger = DropdownMenuSubTrigger;\nconst SubContent = DropdownMenuSubContent;\n\nexport {\n createDropdownMenuScope,\n //\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuPortal,\n DropdownMenuContent,\n DropdownMenuGroup,\n DropdownMenuLabel,\n DropdownMenuItem,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioGroup,\n DropdownMenuRadioItem,\n DropdownMenuItemIndicator,\n DropdownMenuSeparator,\n DropdownMenuArrow,\n DropdownMenuSub,\n DropdownMenuSubTrigger,\n DropdownMenuSubContent,\n //\n Root,\n Trigger,\n Portal,\n Content,\n Group,\n Label,\n Item,\n CheckboxItem,\n RadioGroup,\n RadioItem,\n ItemIndicator,\n Separator,\n Arrow,\n Sub,\n SubTrigger,\n SubContent,\n};\nexport type {\n DropdownMenuProps,\n DropdownMenuTriggerProps,\n DropdownMenuPortalProps,\n DropdownMenuContentProps,\n DropdownMenuGroupProps,\n DropdownMenuLabelProps,\n DropdownMenuItemProps,\n DropdownMenuCheckboxItemProps,\n DropdownMenuRadioGroupProps,\n DropdownMenuRadioItemProps,\n DropdownMenuItemIndicatorProps,\n DropdownMenuSeparatorProps,\n DropdownMenuArrowProps,\n DropdownMenuSubProps,\n DropdownMenuSubTriggerProps,\n DropdownMenuSubContentProps,\n};\n"],"names":["createDropdownMenuScope","DropdownMenu","DropdownMenuTrigger","DropdownMenuPortal","DropdownMenuContent","DropdownMenuGroup","DropdownMenuLabel","DropdownMenuItem","DropdownMenuCheckboxItem","DropdownMenuRadioGroup","DropdownMenuRadioItem","DropdownMenuItemIndicator","DropdownMenuSeparator","DropdownMenuArrow","DropdownMenuSub","DropdownMenuSubTrigger","DropdownMenuSubContent","Root","Trigger","Portal","Content","Group","Label","Item","CheckboxItem","RadioGroup","RadioItem","ItemIndicator","Separator","Arrow","Sub","SubTrigger","SubContent","React","composeEventHandlers","composeRefs","createContextScope","useControllableState","Primitive","MenuPrimitive","createMenuScope","useId","DROPDOWN_MENU_NAME","createDropdownMenuContext","useMenuScope","DropdownMenuProvider","useDropdownMenuContext","props","__scopeDropdownMenu","children","dir","open","openProp","defaultOpen","onOpenChange","modal","menuScope","triggerRef","useRef","setOpen","prop","defaultProp","onChange","useCallback","prevOpen","TRIGGER_NAME","forwardRef","forwardedRef","disabled","triggerProps","context","triggerId","undefined","contentId","onPointerDown","event","button","ctrlKey","onOpenToggle","preventDefault","onKeyDown","includes","key","PORTAL_NAME","portalProps","CONTENT_NAME","contentProps","hasInteractedOutsideRef","onCloseAutoFocus","current","focus","onInteractOutside","originalEvent","detail","ctrlLeftClick","isRightClick","style","GROUP_NAME","groupProps","LABEL_NAME","labelProps","ITEM_NAME","itemProps","CHECKBOX_ITEM_NAME","checkboxItemProps","RADIO_GROUP_NAME","radioGroupProps","RADIO_ITEM_NAME","radioItemProps","INDICATOR_NAME","itemIndicatorProps","SEPARATOR_NAME","separatorProps","ARROW_NAME","arrowProps","SUB_TRIGGER_NAME","subTriggerProps","SUB_CONTENT_NAME","subContentProps"],"version":3,"file":"index.js.map"}
@@ -1,45 +1,13 @@
1
1
  import $9kmUS$babelruntimehelpersesmextends from "@babel/runtime/helpers/esm/extends";
2
- import {useCallback as $9kmUS$useCallback, createElement as $9kmUS$createElement, useRef as $9kmUS$useRef, forwardRef as $9kmUS$forwardRef} from "react";
2
+ import {useRef as $9kmUS$useRef, createElement as $9kmUS$createElement, useCallback as $9kmUS$useCallback, forwardRef as $9kmUS$forwardRef} from "react";
3
3
  import {composeEventHandlers as $9kmUS$composeEventHandlers} from "@radix-ui/primitive";
4
4
  import {composeRefs as $9kmUS$composeRefs} from "@radix-ui/react-compose-refs";
5
5
  import {createContextScope as $9kmUS$createContextScope} from "@radix-ui/react-context";
6
6
  import {useControllableState as $9kmUS$useControllableState} from "@radix-ui/react-use-controllable-state";
7
7
  import {Primitive as $9kmUS$Primitive} from "@radix-ui/react-primitive";
8
- import {createMenuScope as $9kmUS$createMenuScope, Sub as $9kmUS$Sub, Root as $9kmUS$Root, Anchor as $9kmUS$Anchor, Content as $9kmUS$Content, Group as $9kmUS$Group, Label as $9kmUS$Label, Item as $9kmUS$Item, SubTrigger as $9kmUS$SubTrigger, CheckboxItem as $9kmUS$CheckboxItem, RadioGroup as $9kmUS$RadioGroup, RadioItem as $9kmUS$RadioItem, ItemIndicator as $9kmUS$ItemIndicator, Separator as $9kmUS$Separator, Arrow as $9kmUS$Arrow} from "@radix-ui/react-menu";
8
+ import {createMenuScope as $9kmUS$createMenuScope, Root as $9kmUS$Root, Anchor as $9kmUS$Anchor, Portal as $9kmUS$Portal, Content as $9kmUS$Content, Group as $9kmUS$Group, Label as $9kmUS$Label, Item as $9kmUS$Item, CheckboxItem as $9kmUS$CheckboxItem, RadioGroup as $9kmUS$RadioGroup, RadioItem as $9kmUS$RadioItem, ItemIndicator as $9kmUS$ItemIndicator, Separator as $9kmUS$Separator, Arrow as $9kmUS$Arrow, Sub as $9kmUS$Sub, SubTrigger as $9kmUS$SubTrigger, SubContent as $9kmUS$SubContent} from "@radix-ui/react-menu";
9
9
  import {useId as $9kmUS$useId} from "@radix-ui/react-id";
10
10
 
11
- function $parcel$export(e, n, v, s) {
12
- Object.defineProperty(e, n, {get: v, set: s, enumerable: true, configurable: true});
13
- }
14
- var $d08ef79370b62062$exports = {};
15
-
16
- $parcel$export($d08ef79370b62062$exports, "createDropdownMenuScope", () => $d08ef79370b62062$export$c0623cd925aeb687);
17
- $parcel$export($d08ef79370b62062$exports, "DropdownMenu", () => $d08ef79370b62062$export$e44a253a59704894);
18
- $parcel$export($d08ef79370b62062$exports, "DropdownMenuTrigger", () => $d08ef79370b62062$export$d2469213b3befba9);
19
- $parcel$export($d08ef79370b62062$exports, "DropdownMenuContent", () => $d08ef79370b62062$export$6e76d93a37c01248);
20
- $parcel$export($d08ef79370b62062$exports, "DropdownMenuGroup", () => $d08ef79370b62062$export$246bebaba3a2f70e);
21
- $parcel$export($d08ef79370b62062$exports, "DropdownMenuLabel", () => $d08ef79370b62062$export$76e48c5b57f24495);
22
- $parcel$export($d08ef79370b62062$exports, "DropdownMenuItem", () => $d08ef79370b62062$export$ed97964d1871885d);
23
- $parcel$export($d08ef79370b62062$exports, "DropdownMenuTriggerItem", () => $d08ef79370b62062$export$eb7a5647860df79a);
24
- $parcel$export($d08ef79370b62062$exports, "DropdownMenuCheckboxItem", () => $d08ef79370b62062$export$53a69729da201fa9);
25
- $parcel$export($d08ef79370b62062$exports, "DropdownMenuRadioGroup", () => $d08ef79370b62062$export$3323ad73d55f587e);
26
- $parcel$export($d08ef79370b62062$exports, "DropdownMenuRadioItem", () => $d08ef79370b62062$export$e4f69b41b1637536);
27
- $parcel$export($d08ef79370b62062$exports, "DropdownMenuItemIndicator", () => $d08ef79370b62062$export$42355ae145153fb6);
28
- $parcel$export($d08ef79370b62062$exports, "DropdownMenuSeparator", () => $d08ef79370b62062$export$da160178fd3bc7e9);
29
- $parcel$export($d08ef79370b62062$exports, "DropdownMenuArrow", () => $d08ef79370b62062$export$34b8980744021ec5);
30
- $parcel$export($d08ef79370b62062$exports, "Root", () => $d08ef79370b62062$export$be92b6f5f03c0fe9);
31
- $parcel$export($d08ef79370b62062$exports, "Trigger", () => $d08ef79370b62062$export$41fb9f06171c75f4);
32
- $parcel$export($d08ef79370b62062$exports, "Content", () => $d08ef79370b62062$export$7c6e2c02157bb7d2);
33
- $parcel$export($d08ef79370b62062$exports, "Group", () => $d08ef79370b62062$export$eb2fcfdbd7ba97d4);
34
- $parcel$export($d08ef79370b62062$exports, "Label", () => $d08ef79370b62062$export$b04be29aa201d4f5);
35
- $parcel$export($d08ef79370b62062$exports, "Item", () => $d08ef79370b62062$export$6d08773d2e66f8f2);
36
- $parcel$export($d08ef79370b62062$exports, "TriggerItem", () => $d08ef79370b62062$export$6d0911d397e3b965);
37
- $parcel$export($d08ef79370b62062$exports, "CheckboxItem", () => $d08ef79370b62062$export$16ce288f89fa631c);
38
- $parcel$export($d08ef79370b62062$exports, "RadioGroup", () => $d08ef79370b62062$export$a98f0dcb43a68a25);
39
- $parcel$export($d08ef79370b62062$exports, "RadioItem", () => $d08ef79370b62062$export$371ab307eab489c0);
40
- $parcel$export($d08ef79370b62062$exports, "ItemIndicator", () => $d08ef79370b62062$export$c3468e2714d175fa);
41
- $parcel$export($d08ef79370b62062$exports, "Separator", () => $d08ef79370b62062$export$1ff3c3f08ae963c0);
42
- $parcel$export($d08ef79370b62062$exports, "Arrow", () => $d08ef79370b62062$export$21b07c8f274aebd5);
43
11
 
44
12
 
45
13
 
@@ -59,58 +27,37 @@ const [$d08ef79370b62062$var$createDropdownMenuContext, $d08ef79370b62062$export
59
27
  const $d08ef79370b62062$var$useMenuScope = $9kmUS$createMenuScope();
60
28
  const [$d08ef79370b62062$var$DropdownMenuProvider, $d08ef79370b62062$var$useDropdownMenuContext] = $d08ef79370b62062$var$createDropdownMenuContext($d08ef79370b62062$var$DROPDOWN_MENU_NAME);
61
29
  const $d08ef79370b62062$export$e44a253a59704894 = (props)=>{
62
- const { __scopeDropdownMenu: __scopeDropdownMenu , children: children , open: openProp , defaultOpen: defaultOpen , onOpenChange: onOpenChange } = props;
63
- const contentContext = $d08ef79370b62062$var$useContentContext($d08ef79370b62062$var$DROPDOWN_MENU_NAME, __scopeDropdownMenu);
30
+ const { __scopeDropdownMenu: __scopeDropdownMenu , children: children , dir: dir , open: openProp , defaultOpen: defaultOpen , onOpenChange: onOpenChange , modal: modal = true } = props;
64
31
  const menuScope = $d08ef79370b62062$var$useMenuScope(__scopeDropdownMenu);
32
+ const triggerRef = $9kmUS$useRef(null);
65
33
  const [open = false, setOpen] = $9kmUS$useControllableState({
66
34
  prop: openProp,
67
35
  defaultProp: defaultOpen,
68
36
  onChange: onOpenChange
69
37
  });
70
- const handleOpenToggle = $9kmUS$useCallback(()=>setOpen((prevOpen)=>!prevOpen
71
- )
72
- , [
73
- setOpen
74
- ]);
75
- return contentContext.isInsideContent ? /*#__PURE__*/ $9kmUS$createElement($d08ef79370b62062$var$DropdownMenuProvider, {
76
- scope: __scopeDropdownMenu,
77
- isRootMenu: false,
78
- open: open,
79
- onOpenChange: setOpen,
80
- onOpenToggle: handleOpenToggle
81
- }, /*#__PURE__*/ $9kmUS$createElement($9kmUS$Sub, $9kmUS$babelruntimehelpersesmextends({}, menuScope, {
82
- open: open,
83
- onOpenChange: setOpen
84
- }), children)) : /*#__PURE__*/ $9kmUS$createElement($d08ef79370b62062$var$DropdownMenuRoot, $9kmUS$babelruntimehelpersesmextends({}, props, {
85
- open: open,
86
- onOpenChange: setOpen,
87
- onOpenToggle: handleOpenToggle
88
- }), children);
89
- };
90
- /*#__PURE__*/ Object.assign($d08ef79370b62062$export$e44a253a59704894, {
91
- displayName: $d08ef79370b62062$var$DROPDOWN_MENU_NAME
92
- });
93
- /* ---------------------------------------------------------------------------------------------- */ const $d08ef79370b62062$var$DropdownMenuRoot = (props)=>{
94
- const { __scopeDropdownMenu: __scopeDropdownMenu , children: children , dir: dir , open: open , onOpenChange: onOpenChange , onOpenToggle: onOpenToggle , modal: modal = true } = props;
95
- const menuScope = $d08ef79370b62062$var$useMenuScope(__scopeDropdownMenu);
96
- const triggerRef = $9kmUS$useRef(null);
97
38
  return /*#__PURE__*/ $9kmUS$createElement($d08ef79370b62062$var$DropdownMenuProvider, {
98
39
  scope: __scopeDropdownMenu,
99
- isRootMenu: true,
100
40
  triggerId: $9kmUS$useId(),
101
41
  triggerRef: triggerRef,
102
42
  contentId: $9kmUS$useId(),
103
43
  open: open,
104
- onOpenChange: onOpenChange,
105
- onOpenToggle: onOpenToggle,
44
+ onOpenChange: setOpen,
45
+ onOpenToggle: $9kmUS$useCallback(()=>setOpen((prevOpen)=>!prevOpen
46
+ )
47
+ , [
48
+ setOpen
49
+ ]),
106
50
  modal: modal
107
51
  }, /*#__PURE__*/ $9kmUS$createElement($9kmUS$Root, $9kmUS$babelruntimehelpersesmextends({}, menuScope, {
108
52
  open: open,
109
- onOpenChange: onOpenChange,
53
+ onOpenChange: setOpen,
110
54
  dir: dir,
111
55
  modal: modal
112
56
  }), children));
113
57
  };
58
+ /*#__PURE__*/ Object.assign($d08ef79370b62062$export$e44a253a59704894, {
59
+ displayName: $d08ef79370b62062$var$DROPDOWN_MENU_NAME
60
+ });
114
61
  /* -------------------------------------------------------------------------------------------------
115
62
  * DropdownMenuTrigger
116
63
  * -----------------------------------------------------------------------------------------------*/ const $d08ef79370b62062$var$TRIGGER_NAME = 'DropdownMenuTrigger';
@@ -118,7 +65,7 @@ const $d08ef79370b62062$export$d2469213b3befba9 = /*#__PURE__*/ $9kmUS$forwardRe
118
65
  const { __scopeDropdownMenu: __scopeDropdownMenu , disabled: disabled = false , ...triggerProps } = props;
119
66
  const context = $d08ef79370b62062$var$useDropdownMenuContext($d08ef79370b62062$var$TRIGGER_NAME, __scopeDropdownMenu);
120
67
  const menuScope = $d08ef79370b62062$var$useMenuScope(__scopeDropdownMenu);
121
- return context.isRootMenu ? /*#__PURE__*/ $9kmUS$createElement($9kmUS$Anchor, $9kmUS$babelruntimehelpersesmextends({
68
+ return /*#__PURE__*/ $9kmUS$createElement($9kmUS$Anchor, $9kmUS$babelruntimehelpersesmextends({
122
69
  asChild: true
123
70
  }, menuScope), /*#__PURE__*/ $9kmUS$createElement($9kmUS$Primitive.button, $9kmUS$babelruntimehelpersesmextends({
124
71
  type: "button",
@@ -135,10 +82,9 @@ const $d08ef79370b62062$export$d2469213b3befba9 = /*#__PURE__*/ $9kmUS$forwardRe
135
82
  // only call handler if it's the left button (mousedown gets triggered by all mouse buttons)
136
83
  // but not when the control key is pressed (avoiding MacOS right click)
137
84
  if (!disabled && event.button === 0 && event.ctrlKey === false) {
138
- // prevent trigger focusing when opening
85
+ context.onOpenToggle(); // prevent trigger focusing when opening
139
86
  // this allows the content to be given focus without competition
140
87
  if (!context.open) event.preventDefault();
141
- context.onOpenToggle();
142
88
  }
143
89
  }),
144
90
  onKeyDown: $9kmUS$composeEventHandlers(props.onKeyDown, (event)=>{
@@ -153,54 +99,35 @@ const $d08ef79370b62062$export$d2469213b3befba9 = /*#__PURE__*/ $9kmUS$forwardRe
153
99
  'ArrowDown'
154
100
  ].includes(event.key)) event.preventDefault();
155
101
  })
156
- }))) : null;
102
+ })));
157
103
  });
158
104
  /*#__PURE__*/ Object.assign($d08ef79370b62062$export$d2469213b3befba9, {
159
105
  displayName: $d08ef79370b62062$var$TRIGGER_NAME
160
106
  });
107
+ /* -------------------------------------------------------------------------------------------------
108
+ * DropdownMenuPortal
109
+ * -----------------------------------------------------------------------------------------------*/ const $d08ef79370b62062$var$PORTAL_NAME = 'DropdownMenuPortal';
110
+ const $d08ef79370b62062$export$cd369b4d4d54efc9 = (props)=>{
111
+ const { __scopeDropdownMenu: __scopeDropdownMenu , ...portalProps } = props;
112
+ const menuScope = $d08ef79370b62062$var$useMenuScope(__scopeDropdownMenu);
113
+ return /*#__PURE__*/ $9kmUS$createElement($9kmUS$Portal, $9kmUS$babelruntimehelpersesmextends({}, menuScope, portalProps));
114
+ };
115
+ /*#__PURE__*/ Object.assign($d08ef79370b62062$export$cd369b4d4d54efc9, {
116
+ displayName: $d08ef79370b62062$var$PORTAL_NAME
117
+ });
161
118
  /* -------------------------------------------------------------------------------------------------
162
119
  * DropdownMenuContent
163
120
  * -----------------------------------------------------------------------------------------------*/ const $d08ef79370b62062$var$CONTENT_NAME = 'DropdownMenuContent';
164
- const [$d08ef79370b62062$var$ContentProvider, $d08ef79370b62062$var$useContentContext] = $d08ef79370b62062$var$createDropdownMenuContext($d08ef79370b62062$var$CONTENT_NAME, {
165
- isInsideContent: false
166
- });
167
121
  const $d08ef79370b62062$export$6e76d93a37c01248 = /*#__PURE__*/ $9kmUS$forwardRef((props, forwardedRef)=>{
168
122
  const { __scopeDropdownMenu: __scopeDropdownMenu , ...contentProps } = props;
169
123
  const context = $d08ef79370b62062$var$useDropdownMenuContext($d08ef79370b62062$var$CONTENT_NAME, __scopeDropdownMenu);
170
124
  const menuScope = $d08ef79370b62062$var$useMenuScope(__scopeDropdownMenu);
171
- const commonProps = {
172
- ...contentProps,
173
- style: {
174
- ...props.style,
175
- // re-namespace exposed content custom property
176
- ['--radix-dropdown-menu-content-transform-origin']: 'var(--radix-popper-transform-origin)'
177
- }
178
- };
179
- return /*#__PURE__*/ $9kmUS$createElement($d08ef79370b62062$var$ContentProvider, {
180
- scope: __scopeDropdownMenu,
181
- isInsideContent: true
182
- }, context.isRootMenu ? /*#__PURE__*/ $9kmUS$createElement($d08ef79370b62062$var$DropdownMenuRootContent, $9kmUS$babelruntimehelpersesmextends({
183
- __scopeDropdownMenu: __scopeDropdownMenu
184
- }, commonProps, {
185
- ref: forwardedRef
186
- })) : /*#__PURE__*/ $9kmUS$createElement($9kmUS$Content, $9kmUS$babelruntimehelpersesmextends({}, menuScope, commonProps, {
187
- ref: forwardedRef
188
- })));
189
- });
190
- /*#__PURE__*/ Object.assign($d08ef79370b62062$export$6e76d93a37c01248, {
191
- displayName: $d08ef79370b62062$var$CONTENT_NAME
192
- });
193
- /* ---------------------------------------------------------------------------------------------- */ const $d08ef79370b62062$var$DropdownMenuRootContent = /*#__PURE__*/ $9kmUS$forwardRef((props, forwardedRef)=>{
194
- const { __scopeDropdownMenu: __scopeDropdownMenu , portalled: portalled = true , ...contentProps } = props;
195
- const context = $d08ef79370b62062$var$useDropdownMenuContext($d08ef79370b62062$var$CONTENT_NAME, __scopeDropdownMenu);
196
- const menuScope = $d08ef79370b62062$var$useMenuScope(__scopeDropdownMenu);
197
125
  const hasInteractedOutsideRef = $9kmUS$useRef(false);
198
- return context.isRootMenu ? /*#__PURE__*/ $9kmUS$createElement($9kmUS$Content, $9kmUS$babelruntimehelpersesmextends({
126
+ return /*#__PURE__*/ $9kmUS$createElement($9kmUS$Content, $9kmUS$babelruntimehelpersesmextends({
199
127
  id: context.contentId,
200
128
  "aria-labelledby": context.triggerId
201
129
  }, menuScope, contentProps, {
202
130
  ref: forwardedRef,
203
- portalled: portalled,
204
131
  onCloseAutoFocus: $9kmUS$composeEventHandlers(props.onCloseAutoFocus, (event)=>{
205
132
  var _context$triggerRef$c;
206
133
  if (!hasInteractedOutsideRef.current) (_context$triggerRef$c = context.triggerRef.current) === null || _context$triggerRef$c === void 0 || _context$triggerRef$c.focus();
@@ -212,8 +139,16 @@ const $d08ef79370b62062$export$6e76d93a37c01248 = /*#__PURE__*/ $9kmUS$forwardRe
212
139
  const ctrlLeftClick = originalEvent.button === 0 && originalEvent.ctrlKey === true;
213
140
  const isRightClick = originalEvent.button === 2 || ctrlLeftClick;
214
141
  if (!context.modal || isRightClick) hasInteractedOutsideRef.current = true;
215
- })
216
- })) : null;
142
+ }),
143
+ style: {
144
+ ...props.style,
145
+ // re-namespace exposed content custom property
146
+ ['--radix-dropdown-menu-content-transform-origin']: 'var(--radix-popper-transform-origin)'
147
+ }
148
+ }));
149
+ });
150
+ /*#__PURE__*/ Object.assign($d08ef79370b62062$export$6e76d93a37c01248, {
151
+ displayName: $d08ef79370b62062$var$CONTENT_NAME
217
152
  });
218
153
  /* -------------------------------------------------------------------------------------------------
219
154
  * DropdownMenuGroup
@@ -254,19 +189,6 @@ const $d08ef79370b62062$export$ed97964d1871885d = /*#__PURE__*/ $9kmUS$forwardRe
254
189
  /*#__PURE__*/ Object.assign($d08ef79370b62062$export$ed97964d1871885d, {
255
190
  displayName: $d08ef79370b62062$var$ITEM_NAME
256
191
  });
257
- /* -------------------------------------------------------------------------------------------------
258
- * DropdownMenuTriggerItem
259
- * -----------------------------------------------------------------------------------------------*/ const $d08ef79370b62062$var$TRIGGER_ITEM_NAME = 'DropdownMenuTriggerItem';
260
- const $d08ef79370b62062$export$eb7a5647860df79a = /*#__PURE__*/ $9kmUS$forwardRef((props, forwardedRef)=>{
261
- const { __scopeDropdownMenu: __scopeDropdownMenu , ...triggerItemProps } = props;
262
- const menuScope = $d08ef79370b62062$var$useMenuScope(__scopeDropdownMenu);
263
- return /*#__PURE__*/ $9kmUS$createElement($9kmUS$SubTrigger, $9kmUS$babelruntimehelpersesmextends({}, menuScope, triggerItemProps, {
264
- ref: forwardedRef
265
- }));
266
- });
267
- /*#__PURE__*/ Object.assign($d08ef79370b62062$export$eb7a5647860df79a, {
268
- displayName: $d08ef79370b62062$var$TRIGGER_ITEM_NAME
269
- });
270
192
  /* -------------------------------------------------------------------------------------------------
271
193
  * DropdownMenuCheckboxItem
272
194
  * -----------------------------------------------------------------------------------------------*/ const $d08ef79370b62062$var$CHECKBOX_ITEM_NAME = 'DropdownMenuCheckboxItem';
@@ -345,22 +267,71 @@ const $d08ef79370b62062$export$34b8980744021ec5 = /*#__PURE__*/ $9kmUS$forwardRe
345
267
  /*#__PURE__*/ Object.assign($d08ef79370b62062$export$34b8980744021ec5, {
346
268
  displayName: $d08ef79370b62062$var$ARROW_NAME
347
269
  });
270
+ /* -------------------------------------------------------------------------------------------------
271
+ * DropdownMenuSub
272
+ * -----------------------------------------------------------------------------------------------*/ const $d08ef79370b62062$export$2f307d81a64f5442 = (props)=>{
273
+ const { __scopeDropdownMenu: __scopeDropdownMenu , children: children , open: openProp , onOpenChange: onOpenChange , defaultOpen: defaultOpen } = props;
274
+ const menuScope = $d08ef79370b62062$var$useMenuScope(__scopeDropdownMenu);
275
+ const [open = false, setOpen] = $9kmUS$useControllableState({
276
+ prop: openProp,
277
+ defaultProp: defaultOpen,
278
+ onChange: onOpenChange
279
+ });
280
+ return /*#__PURE__*/ $9kmUS$createElement($9kmUS$Sub, $9kmUS$babelruntimehelpersesmextends({}, menuScope, {
281
+ open: open,
282
+ onOpenChange: setOpen
283
+ }), children);
284
+ };
285
+ /* -------------------------------------------------------------------------------------------------
286
+ * DropdownMenuSubTrigger
287
+ * -----------------------------------------------------------------------------------------------*/ const $d08ef79370b62062$var$SUB_TRIGGER_NAME = 'DropdownMenuSubTrigger';
288
+ const $d08ef79370b62062$export$21dcb7ec56f874cf = /*#__PURE__*/ $9kmUS$forwardRef((props, forwardedRef)=>{
289
+ const { __scopeDropdownMenu: __scopeDropdownMenu , ...subTriggerProps } = props;
290
+ const menuScope = $d08ef79370b62062$var$useMenuScope(__scopeDropdownMenu);
291
+ return /*#__PURE__*/ $9kmUS$createElement($9kmUS$SubTrigger, $9kmUS$babelruntimehelpersesmextends({}, menuScope, subTriggerProps, {
292
+ ref: forwardedRef
293
+ }));
294
+ });
295
+ /*#__PURE__*/ Object.assign($d08ef79370b62062$export$21dcb7ec56f874cf, {
296
+ displayName: $d08ef79370b62062$var$SUB_TRIGGER_NAME
297
+ });
298
+ /* -------------------------------------------------------------------------------------------------
299
+ * DropdownMenuSubContent
300
+ * -----------------------------------------------------------------------------------------------*/ const $d08ef79370b62062$var$SUB_CONTENT_NAME = 'DropdownMenuSubContent';
301
+ const $d08ef79370b62062$export$f34ec8bc2482cc5f = /*#__PURE__*/ $9kmUS$forwardRef((props, forwardedRef)=>{
302
+ const { __scopeDropdownMenu: __scopeDropdownMenu , ...subContentProps } = props;
303
+ const menuScope = $d08ef79370b62062$var$useMenuScope(__scopeDropdownMenu);
304
+ return /*#__PURE__*/ $9kmUS$createElement($9kmUS$SubContent, $9kmUS$babelruntimehelpersesmextends({}, menuScope, subContentProps, {
305
+ ref: forwardedRef,
306
+ style: {
307
+ ...props.style,
308
+ // re-namespace exposed content custom property
309
+ ['--radix-dropdown-menu-content-transform-origin']: 'var(--radix-popper-transform-origin)'
310
+ }
311
+ }));
312
+ });
313
+ /*#__PURE__*/ Object.assign($d08ef79370b62062$export$f34ec8bc2482cc5f, {
314
+ displayName: $d08ef79370b62062$var$SUB_CONTENT_NAME
315
+ });
348
316
  /* -----------------------------------------------------------------------------------------------*/ const $d08ef79370b62062$export$be92b6f5f03c0fe9 = $d08ef79370b62062$export$e44a253a59704894;
349
317
  const $d08ef79370b62062$export$41fb9f06171c75f4 = $d08ef79370b62062$export$d2469213b3befba9;
318
+ const $d08ef79370b62062$export$602eac185826482c = $d08ef79370b62062$export$cd369b4d4d54efc9;
350
319
  const $d08ef79370b62062$export$7c6e2c02157bb7d2 = $d08ef79370b62062$export$6e76d93a37c01248;
351
320
  const $d08ef79370b62062$export$eb2fcfdbd7ba97d4 = $d08ef79370b62062$export$246bebaba3a2f70e;
352
321
  const $d08ef79370b62062$export$b04be29aa201d4f5 = $d08ef79370b62062$export$76e48c5b57f24495;
353
322
  const $d08ef79370b62062$export$6d08773d2e66f8f2 = $d08ef79370b62062$export$ed97964d1871885d;
354
- const $d08ef79370b62062$export$6d0911d397e3b965 = $d08ef79370b62062$export$eb7a5647860df79a;
355
323
  const $d08ef79370b62062$export$16ce288f89fa631c = $d08ef79370b62062$export$53a69729da201fa9;
356
324
  const $d08ef79370b62062$export$a98f0dcb43a68a25 = $d08ef79370b62062$export$3323ad73d55f587e;
357
325
  const $d08ef79370b62062$export$371ab307eab489c0 = $d08ef79370b62062$export$e4f69b41b1637536;
358
326
  const $d08ef79370b62062$export$c3468e2714d175fa = $d08ef79370b62062$export$42355ae145153fb6;
359
327
  const $d08ef79370b62062$export$1ff3c3f08ae963c0 = $d08ef79370b62062$export$da160178fd3bc7e9;
360
328
  const $d08ef79370b62062$export$21b07c8f274aebd5 = $d08ef79370b62062$export$34b8980744021ec5;
329
+ const $d08ef79370b62062$export$d7a01e11500dfb6f = $d08ef79370b62062$export$2f307d81a64f5442;
330
+ const $d08ef79370b62062$export$2ea8a7a591ac5eac = $d08ef79370b62062$export$21dcb7ec56f874cf;
331
+ const $d08ef79370b62062$export$6d4de93b380beddf = $d08ef79370b62062$export$f34ec8bc2482cc5f;
361
332
 
362
333
 
363
334
 
364
335
 
365
- export {$d08ef79370b62062$export$c0623cd925aeb687 as createDropdownMenuScope, $d08ef79370b62062$export$e44a253a59704894 as DropdownMenu, $d08ef79370b62062$export$d2469213b3befba9 as DropdownMenuTrigger, $d08ef79370b62062$export$6e76d93a37c01248 as DropdownMenuContent, $d08ef79370b62062$export$246bebaba3a2f70e as DropdownMenuGroup, $d08ef79370b62062$export$76e48c5b57f24495 as DropdownMenuLabel, $d08ef79370b62062$export$ed97964d1871885d as DropdownMenuItem, $d08ef79370b62062$export$eb7a5647860df79a as DropdownMenuTriggerItem, $d08ef79370b62062$export$53a69729da201fa9 as DropdownMenuCheckboxItem, $d08ef79370b62062$export$3323ad73d55f587e as DropdownMenuRadioGroup, $d08ef79370b62062$export$e4f69b41b1637536 as DropdownMenuRadioItem, $d08ef79370b62062$export$42355ae145153fb6 as DropdownMenuItemIndicator, $d08ef79370b62062$export$da160178fd3bc7e9 as DropdownMenuSeparator, $d08ef79370b62062$export$34b8980744021ec5 as DropdownMenuArrow, $d08ef79370b62062$export$be92b6f5f03c0fe9 as Root, $d08ef79370b62062$export$41fb9f06171c75f4 as Trigger, $d08ef79370b62062$export$7c6e2c02157bb7d2 as Content, $d08ef79370b62062$export$eb2fcfdbd7ba97d4 as Group, $d08ef79370b62062$export$b04be29aa201d4f5 as Label, $d08ef79370b62062$export$6d08773d2e66f8f2 as Item, $d08ef79370b62062$export$6d0911d397e3b965 as TriggerItem, $d08ef79370b62062$export$16ce288f89fa631c as CheckboxItem, $d08ef79370b62062$export$a98f0dcb43a68a25 as RadioGroup, $d08ef79370b62062$export$371ab307eab489c0 as RadioItem, $d08ef79370b62062$export$c3468e2714d175fa as ItemIndicator, $d08ef79370b62062$export$1ff3c3f08ae963c0 as Separator, $d08ef79370b62062$export$21b07c8f274aebd5 as Arrow};
336
+ export {$d08ef79370b62062$export$c0623cd925aeb687 as createDropdownMenuScope, $d08ef79370b62062$export$e44a253a59704894 as DropdownMenu, $d08ef79370b62062$export$d2469213b3befba9 as DropdownMenuTrigger, $d08ef79370b62062$export$cd369b4d4d54efc9 as DropdownMenuPortal, $d08ef79370b62062$export$6e76d93a37c01248 as DropdownMenuContent, $d08ef79370b62062$export$246bebaba3a2f70e as DropdownMenuGroup, $d08ef79370b62062$export$76e48c5b57f24495 as DropdownMenuLabel, $d08ef79370b62062$export$ed97964d1871885d as DropdownMenuItem, $d08ef79370b62062$export$53a69729da201fa9 as DropdownMenuCheckboxItem, $d08ef79370b62062$export$3323ad73d55f587e as DropdownMenuRadioGroup, $d08ef79370b62062$export$e4f69b41b1637536 as DropdownMenuRadioItem, $d08ef79370b62062$export$42355ae145153fb6 as DropdownMenuItemIndicator, $d08ef79370b62062$export$da160178fd3bc7e9 as DropdownMenuSeparator, $d08ef79370b62062$export$34b8980744021ec5 as DropdownMenuArrow, $d08ef79370b62062$export$2f307d81a64f5442 as DropdownMenuSub, $d08ef79370b62062$export$21dcb7ec56f874cf as DropdownMenuSubTrigger, $d08ef79370b62062$export$f34ec8bc2482cc5f as DropdownMenuSubContent, $d08ef79370b62062$export$be92b6f5f03c0fe9 as Root, $d08ef79370b62062$export$41fb9f06171c75f4 as Trigger, $d08ef79370b62062$export$602eac185826482c as Portal, $d08ef79370b62062$export$7c6e2c02157bb7d2 as Content, $d08ef79370b62062$export$eb2fcfdbd7ba97d4 as Group, $d08ef79370b62062$export$b04be29aa201d4f5 as Label, $d08ef79370b62062$export$6d08773d2e66f8f2 as Item, $d08ef79370b62062$export$16ce288f89fa631c as CheckboxItem, $d08ef79370b62062$export$a98f0dcb43a68a25 as RadioGroup, $d08ef79370b62062$export$371ab307eab489c0 as RadioItem, $d08ef79370b62062$export$c3468e2714d175fa as ItemIndicator, $d08ef79370b62062$export$1ff3c3f08ae963c0 as Separator, $d08ef79370b62062$export$21b07c8f274aebd5 as Arrow, $d08ef79370b62062$export$d7a01e11500dfb6f as Sub, $d08ef79370b62062$export$2ea8a7a591ac5eac as SubTrigger, $d08ef79370b62062$export$6d4de93b380beddf as SubContent};
366
337
  //# sourceMappingURL=index.module.js.map
@@ -1 +1 @@
1
- {"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;A;;;;;;;;;;ACeA;;oGAEA,CAEA,MAAMS,wCAAkB,GAAG,cAA3B,AAAA;AAGA,MAAM,CAACC,+CAAD,EAA4BC,yCAA5B,CAAA,GAAuDR,yBAAkB,CAC7EM,wCAD6E,EAE7E;IAACF,sBAAD;CAF6E,CAA/E,AAAA;AAIA,MAAMK,kCAAY,GAAGL,sBAAe,EAApC,AAAA;AAoBA,MAAM,CAACM,0CAAD,EAAuBC,4CAAvB,CAAA,GAAiDJ,+CAAyB,CAE9ED,wCAF8E,CAAhF,AAAA;AAaA,MAAMM,yCAAyC,GAAIC,CAAAA,KAAD,GAA2C;IAC3F,MAAM,E,qBAAEC,mBAAF,CAAA,E,UAAuBC,QAAvB,CAAA,EAAiCC,IAAI,EAAEC,QAAvC,CAAA,E,aAAiDC,WAAjD,CAAA,E,cAA8DC,YAAAA,CAAAA,EAA9D,GAA+EN,KAArF,AAA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ent":["export * from './DropdownMenu';\n","import * as React from 'react';\nimport { composeEventHandlers } from '@radix-ui/primitive';\nimport { composeRefs } from '@radix-ui/react-compose-refs';\nimport { createContextScope } from '@radix-ui/react-context';\nimport { useControllableState } from '@radix-ui/react-use-controllable-state';\nimport { Primitive } from '@radix-ui/react-primitive';\nimport * as MenuPrimitive from '@radix-ui/react-menu';\nimport { createMenuScope } from '@radix-ui/react-menu';\nimport { useId } from '@radix-ui/react-id';\n\nimport type * as Radix from '@radix-ui/react-primitive';\nimport type { Scope } from '@radix-ui/react-context';\n\ntype Direction = 'ltr' | 'rtl';\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenu\n * -----------------------------------------------------------------------------------------------*/\n\nconst DROPDOWN_MENU_NAME = 'DropdownMenu';\n\ntype ScopedProps<P> = P & { __scopeDropdownMenu?: Scope };\nconst [createDropdownMenuContext, createDropdownMenuScope] = createContextScope(\n DROPDOWN_MENU_NAME,\n [createMenuScope]\n);\nconst useMenuScope = createMenuScope();\n\ntype DropdownMenuRootContextValue = {\n isRootMenu: true;\n triggerId: string;\n triggerRef: React.RefObject<HTMLButtonElement>;\n contentId: string;\n open: boolean;\n onOpenChange(open: boolean): void;\n onOpenToggle(): void;\n modal: boolean;\n};\n\ntype DropdownMenuSubContextValue = {\n isRootMenu: false;\n open: boolean;\n onOpenChange(open: boolean): void;\n onOpenToggle(): void;\n};\n\nconst [DropdownMenuProvider, useDropdownMenuContext] = createDropdownMenuContext<\n DropdownMenuRootContextValue | DropdownMenuSubContextValue\n>(DROPDOWN_MENU_NAME);\n\ninterface DropdownMenuProps {\n children?: React.ReactNode;\n dir?: Direction;\n open?: boolean;\n defaultOpen?: boolean;\n onOpenChange?(open: boolean): void;\n modal?: boolean;\n}\n\nconst DropdownMenu: React.FC<DropdownMenuProps> = (props: ScopedProps<DropdownMenuProps>) => {\n const { __scopeDropdownMenu, children, open: openProp, defaultOpen, onOpenChange } = props;\n const contentContext = useContentContext(DROPDOWN_MENU_NAME, __scopeDropdownMenu);\n const menuScope = useMenuScope(__scopeDropdownMenu);\n const [open = false, setOpen] = useControllableState({\n prop: openProp,\n defaultProp: defaultOpen,\n onChange: onOpenChange,\n });\n\n const handleOpenToggle = React.useCallback(() => setOpen((prevOpen) => !prevOpen), [setOpen]);\n\n return contentContext.isInsideContent ? (\n <DropdownMenuProvider\n scope={__scopeDropdownMenu}\n isRootMenu={false}\n open={open}\n onOpenChange={setOpen}\n onOpenToggle={handleOpenToggle}\n >\n <MenuPrimitive.Sub {...menuScope} open={open} onOpenChange={setOpen}>\n {children}\n </MenuPrimitive.Sub>\n </DropdownMenuProvider>\n ) : (\n <DropdownMenuRoot {...props} open={open} onOpenChange={setOpen} onOpenToggle={handleOpenToggle}>\n {children}\n </DropdownMenuRoot>\n );\n};\n\nDropdownMenu.displayName = DROPDOWN_MENU_NAME;\n\n/* ---------------------------------------------------------------------------------------------- */\n\ninterface DropdownMenuRootProps {\n children?: React.ReactNode;\n dir?: Direction;\n open: boolean;\n onOpenChange(open: boolean): void;\n onOpenToggle(): void;\n modal?: boolean;\n}\n\nconst DropdownMenuRoot: React.FC<DropdownMenuRootProps> = (\n props: ScopedProps<DropdownMenuRootProps>\n) => {\n const {\n __scopeDropdownMenu,\n children,\n dir,\n open,\n onOpenChange,\n onOpenToggle,\n modal = true,\n } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n const triggerRef = React.useRef<HTMLButtonElement>(null);\n return (\n <DropdownMenuProvider\n scope={__scopeDropdownMenu}\n isRootMenu={true}\n triggerId={useId()}\n triggerRef={triggerRef}\n contentId={useId()}\n open={open}\n onOpenChange={onOpenChange}\n onOpenToggle={onOpenToggle}\n modal={modal}\n >\n <MenuPrimitive.Root\n {...menuScope}\n open={open}\n onOpenChange={onOpenChange}\n dir={dir}\n modal={modal}\n >\n {children}\n </MenuPrimitive.Root>\n </DropdownMenuProvider>\n );\n};\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuTrigger\n * -----------------------------------------------------------------------------------------------*/\n\nconst TRIGGER_NAME = 'DropdownMenuTrigger';\n\ntype DropdownMenuTriggerElement = React.ElementRef<typeof Primitive.button>;\ntype PrimitiveButtonProps = Radix.ComponentPropsWithoutRef<typeof Primitive.button>;\ninterface DropdownMenuTriggerProps extends PrimitiveButtonProps {}\n\nconst DropdownMenuTrigger = React.forwardRef<DropdownMenuTriggerElement, DropdownMenuTriggerProps>(\n (props: ScopedProps<DropdownMenuTriggerProps>, forwardedRef) => {\n const { __scopeDropdownMenu, disabled = false, ...triggerProps } = props;\n const context = useDropdownMenuContext(TRIGGER_NAME, __scopeDropdownMenu);\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return context.isRootMenu ? (\n <MenuPrimitive.Anchor asChild {...menuScope}>\n <Primitive.button\n type=\"button\"\n id={context.triggerId}\n aria-haspopup=\"menu\"\n aria-expanded={context.open ? true : undefined}\n aria-controls={context.open ? context.contentId : undefined}\n data-state={context.open ? 'open' : 'closed'}\n data-disabled={disabled ? '' : undefined}\n disabled={disabled}\n {...triggerProps}\n ref={composeRefs(forwardedRef, context.triggerRef)}\n onPointerDown={composeEventHandlers(props.onPointerDown, (event) => {\n // only call handler if it's the left button (mousedown gets triggered by all mouse buttons)\n // but not when the control key is pressed (avoiding MacOS right click)\n if (!disabled && event.button === 0 && event.ctrlKey === false) {\n // prevent trigger focusing when opening\n // this allows the content to be given focus without competition\n if (!context.open) event.preventDefault();\n context.onOpenToggle();\n }\n })}\n onKeyDown={composeEventHandlers(props.onKeyDown, (event) => {\n if (disabled) return;\n if (['Enter', ' '].includes(event.key)) context.onOpenToggle();\n if (event.key === 'ArrowDown') context.onOpenChange(true);\n // prevent keypresses from scrolling window\n if ([' ', 'ArrowDown'].includes(event.key)) event.preventDefault();\n })}\n />\n </MenuPrimitive.Anchor>\n ) : null;\n }\n);\n\nDropdownMenuTrigger.displayName = TRIGGER_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuContent\n * -----------------------------------------------------------------------------------------------*/\n\nconst CONTENT_NAME = 'DropdownMenuContent';\n\nconst [ContentProvider, useContentContext] = createDropdownMenuContext(CONTENT_NAME, {\n isInsideContent: false,\n});\n\ntype DropdownMenuContentElement =\n | DropdownMenuRootContentElement\n | React.ElementRef<typeof MenuPrimitive.Content>;\ntype MenuContentProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Content>;\ninterface DropdownMenuContentProps extends DropdownMenuRootContentProps, MenuContentProps {}\n\nconst DropdownMenuContent = React.forwardRef<DropdownMenuContentElement, DropdownMenuContentProps>(\n (props: ScopedProps<DropdownMenuContentProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...contentProps } = props;\n const context = useDropdownMenuContext(CONTENT_NAME, __scopeDropdownMenu);\n const menuScope = useMenuScope(__scopeDropdownMenu);\n const commonProps = {\n ...contentProps,\n style: {\n ...props.style,\n // re-namespace exposed content custom property\n ['--radix-dropdown-menu-content-transform-origin' as any]:\n 'var(--radix-popper-transform-origin)',\n },\n };\n\n return (\n <ContentProvider scope={__scopeDropdownMenu} isInsideContent={true}>\n {context.isRootMenu ? (\n <DropdownMenuRootContent\n __scopeDropdownMenu={__scopeDropdownMenu}\n {...commonProps}\n ref={forwardedRef}\n />\n ) : (\n <MenuPrimitive.Content {...menuScope} {...commonProps} ref={forwardedRef} />\n )}\n </ContentProvider>\n );\n }\n);\n\nDropdownMenuContent.displayName = CONTENT_NAME;\n\n/* ---------------------------------------------------------------------------------------------- */\n\ntype DropdownMenuRootContentElement = React.ElementRef<typeof MenuPrimitive.Content>;\ninterface DropdownMenuRootContentProps extends ScopedProps<MenuContentProps> {}\n\nconst DropdownMenuRootContent = React.forwardRef<\n DropdownMenuRootContentElement,\n DropdownMenuRootContentProps\n>((props, forwardedRef) => {\n const { __scopeDropdownMenu, portalled = true, ...contentProps } = props;\n const context = useDropdownMenuContext(CONTENT_NAME, __scopeDropdownMenu);\n const menuScope = useMenuScope(__scopeDropdownMenu);\n const hasInteractedOutsideRef = React.useRef(false);\n return context.isRootMenu ? (\n <MenuPrimitive.Content\n id={context.contentId}\n aria-labelledby={context.triggerId}\n {...menuScope}\n {...contentProps}\n ref={forwardedRef}\n portalled={portalled}\n onCloseAutoFocus={composeEventHandlers(props.onCloseAutoFocus, (event) => {\n if (!hasInteractedOutsideRef.current) context.triggerRef.current?.focus();\n hasInteractedOutsideRef.current = false;\n // Always prevent auto focus because we either focus manually or want user agent focus\n event.preventDefault();\n })}\n onInteractOutside={composeEventHandlers(props.onInteractOutside, (event) => {\n const originalEvent = event.detail.originalEvent as PointerEvent;\n const ctrlLeftClick = originalEvent.button === 0 && originalEvent.ctrlKey === true;\n const isRightClick = originalEvent.button === 2 || ctrlLeftClick;\n if (!context.modal || isRightClick) hasInteractedOutsideRef.current = true;\n })}\n />\n ) : null;\n});\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuGroup\n * -----------------------------------------------------------------------------------------------*/\n\nconst GROUP_NAME = 'DropdownMenuGroup';\n\ntype DropdownMenuGroupElement = React.ElementRef<typeof MenuPrimitive.Group>;\ntype MenuGroupProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Group>;\ninterface DropdownMenuGroupProps extends MenuGroupProps {}\n\nconst DropdownMenuGroup = React.forwardRef<DropdownMenuGroupElement, DropdownMenuGroupProps>(\n (props: ScopedProps<DropdownMenuGroupProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...groupProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.Group {...menuScope} {...groupProps} ref={forwardedRef} />;\n }\n);\n\nDropdownMenuGroup.displayName = GROUP_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuLabel\n * -----------------------------------------------------------------------------------------------*/\n\nconst LABEL_NAME = 'DropdownMenuLabel';\n\ntype DropdownMenuLabelElement = React.ElementRef<typeof MenuPrimitive.Label>;\ntype MenuLabelProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Label>;\ninterface DropdownMenuLabelProps extends MenuLabelProps {}\n\nconst DropdownMenuLabel = React.forwardRef<DropdownMenuLabelElement, DropdownMenuLabelProps>(\n (props: ScopedProps<DropdownMenuLabelProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...labelProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.Label {...menuScope} {...labelProps} ref={forwardedRef} />;\n }\n);\n\nDropdownMenuLabel.displayName = LABEL_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuItem\n * -----------------------------------------------------------------------------------------------*/\n\nconst ITEM_NAME = 'DropdownMenuItem';\n\ntype DropdownMenuItemElement = React.ElementRef<typeof MenuPrimitive.Item>;\ntype MenuItemProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Item>;\ninterface DropdownMenuItemProps extends MenuItemProps {}\n\nconst DropdownMenuItem = React.forwardRef<DropdownMenuItemElement, DropdownMenuItemProps>(\n (props: ScopedProps<DropdownMenuItemProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...itemProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.Item {...menuScope} {...itemProps} ref={forwardedRef} />;\n }\n);\n\nDropdownMenuItem.displayName = ITEM_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuTriggerItem\n * -----------------------------------------------------------------------------------------------*/\n\nconst TRIGGER_ITEM_NAME = 'DropdownMenuTriggerItem';\n\ntype DropdownMenuTriggerItemElement = React.ElementRef<typeof MenuPrimitive.SubTrigger>;\ntype MenuSubTriggerProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.SubTrigger>;\ninterface DropdownMenuTriggerItemProps extends MenuSubTriggerProps {}\n\nconst DropdownMenuTriggerItem = React.forwardRef<\n DropdownMenuTriggerItemElement,\n DropdownMenuTriggerItemProps\n>((props: ScopedProps<DropdownMenuTriggerItemProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...triggerItemProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.SubTrigger {...menuScope} {...triggerItemProps} ref={forwardedRef} />;\n});\n\nDropdownMenuTriggerItem.displayName = TRIGGER_ITEM_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuCheckboxItem\n * -----------------------------------------------------------------------------------------------*/\n\nconst CHECKBOX_ITEM_NAME = 'DropdownMenuCheckboxItem';\n\ntype DropdownMenuCheckboxItemElement = React.ElementRef<typeof MenuPrimitive.CheckboxItem>;\ntype MenuCheckboxItemProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.CheckboxItem>;\ninterface DropdownMenuCheckboxItemProps extends MenuCheckboxItemProps {}\n\nconst DropdownMenuCheckboxItem = React.forwardRef<\n DropdownMenuCheckboxItemElement,\n DropdownMenuCheckboxItemProps\n>((props: ScopedProps<DropdownMenuCheckboxItemProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...checkboxItemProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.CheckboxItem {...menuScope} {...checkboxItemProps} ref={forwardedRef} />;\n});\n\nDropdownMenuCheckboxItem.displayName = CHECKBOX_ITEM_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuRadioGroup\n * -----------------------------------------------------------------------------------------------*/\n\nconst RADIO_GROUP_NAME = 'DropdownMenuRadioGroup';\n\ntype DropdownMenuRadioGroupElement = React.ElementRef<typeof MenuPrimitive.RadioGroup>;\ntype MenuRadioGroupProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.RadioGroup>;\ninterface DropdownMenuRadioGroupProps extends MenuRadioGroupProps {}\n\nconst DropdownMenuRadioGroup = React.forwardRef<\n DropdownMenuRadioGroupElement,\n DropdownMenuRadioGroupProps\n>((props: ScopedProps<DropdownMenuRadioGroupProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...radioGroupProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.RadioGroup {...menuScope} {...radioGroupProps} ref={forwardedRef} />;\n});\n\nDropdownMenuRadioGroup.displayName = RADIO_GROUP_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuRadioItem\n * -----------------------------------------------------------------------------------------------*/\n\nconst RADIO_ITEM_NAME = 'DropdownMenuRadioItem';\n\ntype DropdownMenuRadioItemElement = React.ElementRef<typeof MenuPrimitive.RadioItem>;\ntype MenuRadioItemProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.RadioItem>;\ninterface DropdownMenuRadioItemProps extends MenuRadioItemProps {}\n\nconst DropdownMenuRadioItem = React.forwardRef<\n DropdownMenuRadioItemElement,\n DropdownMenuRadioItemProps\n>((props: ScopedProps<DropdownMenuRadioItemProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...radioItemProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.RadioItem {...menuScope} {...radioItemProps} ref={forwardedRef} />;\n});\n\nDropdownMenuRadioItem.displayName = RADIO_ITEM_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuItemIndicator\n * -----------------------------------------------------------------------------------------------*/\n\nconst INDICATOR_NAME = 'DropdownMenuItemIndicator';\n\ntype DropdownMenuItemIndicatorElement = React.ElementRef<typeof MenuPrimitive.ItemIndicator>;\ntype MenuItemIndicatorProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.ItemIndicator>;\ninterface DropdownMenuItemIndicatorProps extends MenuItemIndicatorProps {}\n\nconst DropdownMenuItemIndicator = React.forwardRef<\n DropdownMenuItemIndicatorElement,\n DropdownMenuItemIndicatorProps\n>((props: ScopedProps<DropdownMenuItemIndicatorProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...itemIndicatorProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.ItemIndicator {...menuScope} {...itemIndicatorProps} ref={forwardedRef} />;\n});\n\nDropdownMenuItemIndicator.displayName = INDICATOR_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuSeparator\n * -----------------------------------------------------------------------------------------------*/\n\nconst SEPARATOR_NAME = 'DropdownMenuSeparator';\n\ntype DropdownMenuSeparatorElement = React.ElementRef<typeof MenuPrimitive.Separator>;\ntype MenuSeparatorProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Separator>;\ninterface DropdownMenuSeparatorProps extends MenuSeparatorProps {}\n\nconst DropdownMenuSeparator = React.forwardRef<\n DropdownMenuSeparatorElement,\n DropdownMenuSeparatorProps\n>((props: ScopedProps<DropdownMenuSeparatorProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...separatorProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.Separator {...menuScope} {...separatorProps} ref={forwardedRef} />;\n});\n\nDropdownMenuSeparator.displayName = SEPARATOR_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuArrow\n * -----------------------------------------------------------------------------------------------*/\n\nconst ARROW_NAME = 'DropdownMenuArrow';\n\ntype DropdownMenuArrowElement = React.ElementRef<typeof MenuPrimitive.Arrow>;\ntype MenuArrowProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Arrow>;\ninterface DropdownMenuArrowProps extends MenuArrowProps {}\n\nconst DropdownMenuArrow = React.forwardRef<DropdownMenuArrowElement, DropdownMenuArrowProps>(\n (props: ScopedProps<DropdownMenuArrowProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...arrowProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.Arrow {...menuScope} {...arrowProps} ref={forwardedRef} />;\n }\n);\n\nDropdownMenuArrow.displayName = ARROW_NAME;\n\n/* -----------------------------------------------------------------------------------------------*/\n\nconst Root = DropdownMenu;\nconst Trigger = DropdownMenuTrigger;\nconst Content = DropdownMenuContent;\nconst Group = DropdownMenuGroup;\nconst Label = DropdownMenuLabel;\nconst Item = DropdownMenuItem;\nconst TriggerItem = DropdownMenuTriggerItem;\nconst CheckboxItem = DropdownMenuCheckboxItem;\nconst RadioGroup = DropdownMenuRadioGroup;\nconst RadioItem = DropdownMenuRadioItem;\nconst ItemIndicator = DropdownMenuItemIndicator;\nconst Separator = DropdownMenuSeparator;\nconst Arrow = DropdownMenuArrow;\n\nexport {\n createDropdownMenuScope,\n //\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuGroup,\n DropdownMenuLabel,\n DropdownMenuItem,\n DropdownMenuTriggerItem,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioGroup,\n DropdownMenuRadioItem,\n DropdownMenuItemIndicator,\n DropdownMenuSeparator,\n DropdownMenuArrow,\n //\n Root,\n Trigger,\n Content,\n Group,\n Label,\n Item,\n TriggerItem,\n CheckboxItem,\n RadioGroup,\n RadioItem,\n ItemIndicator,\n Separator,\n Arrow,\n};\nexport type {\n DropdownMenuProps,\n DropdownMenuTriggerProps,\n DropdownMenuContentProps,\n DropdownMenuGroupProps,\n DropdownMenuLabelProps,\n DropdownMenuItemProps,\n DropdownMenuTriggerItemProps,\n DropdownMenuCheckboxItemProps,\n DropdownMenuRadioGroupProps,\n DropdownMenuRadioItemProps,\n DropdownMenuItemIndicatorProps,\n DropdownMenuSeparatorProps,\n DropdownMenuArrowProps,\n};\n"],"names":["React","composeEventHandlers","composeRefs","createContextScope","useControllableState","Primitive","MenuPrimitive","createMenuScope","useId","DROPDOWN_MENU_NAME","createDropdownMenuContext","createDropdownMenuScope","useMenuScope","DropdownMenuProvider","useDropdownMenuContext","DropdownMenu","props","__scopeDropdownMenu","children","open","openProp","defaultOpen","onOpenChange","contentContext","useContentContext","menuScope","setOpen","prop","defaultProp","onChange","handleOpenToggle","useCallback","prevOpen","isInsideContent","DropdownMenuRoot","dir","onOpenToggle","modal","triggerRef","useRef","TRIGGER_NAME","DropdownMenuTrigger","forwardRef","forwardedRef","disabled","triggerProps","context","isRootMenu","triggerId","undefined","contentId","onPointerDown","event","button","ctrlKey","preventDefault","onKeyDown","includes","key","CONTENT_NAME","ContentProvider","DropdownMenuContent","contentProps","commonProps","style","DropdownMenuRootContent","portalled","hasInteractedOutsideRef","onCloseAutoFocus","current","focus","onInteractOutside","originalEvent","detail","ctrlLeftClick","isRightClick","GROUP_NAME","DropdownMenuGroup","groupProps","LABEL_NAME","DropdownMenuLabel","labelProps","ITEM_NAME","DropdownMenuItem","itemProps","TRIGGER_ITEM_NAME","DropdownMenuTriggerItem","triggerItemProps","CHECKBOX_ITEM_NAME","DropdownMenuCheckboxItem","checkboxItemProps","RADIO_GROUP_NAME","DropdownMenuRadioGroup","radioGroupProps","RADIO_ITEM_NAME","DropdownMenuRadioItem","radioItemProps","INDICATOR_NAME","DropdownMenuItemIndicator","itemIndicatorProps","SEPARATOR_NAME","DropdownMenuSeparator","separatorProps","ARROW_NAME","DropdownMenuArrow","arrowProps","Root","Trigger","Content","Group","Label","Item","TriggerItem","CheckboxItem","RadioGroup","RadioItem","ItemIndicator","Separator","Arrow"],"version":3,"file":"index.module.js.map"}
1
+ {"mappings":";;;;;;;;;;A;;;;;;;;;;ACeA;;oGAEA,CAEA,MAAM0C,wCAAkB,GAAG,cAA3B,AAAA;AAGA,MAAM,CAACC,+CAAD,EAA4B3C,yCAA5B,CAAA,GAAuDoC,yBAAkB,CAC7EM,wCAD6E,EAE7E;IAACF,sBAAD;CAF6E,CAA/E,AAAA;AAIA,MAAMI,kCAAY,GAAGJ,sBAAe,EAApC,AAAA;AAYA,MAAM,CAACK,0CAAD,EAAuBC,4CAAvB,CAAA,GACJH,+CAAyB,CAA2BD,wCAA3B,CAD3B,AAAA;AAYA,MAAMzC,yCAAyC,GAAI8C,CAAAA,KAAD,GAA2C;IAC3F,MAAM,E,qBACJC,mBADI,CAAA,E,UAEJC,QAFI,CAAA,E,KAGJC,GAHI,CAAA,EAIJC,IAAI,EAAEC,QAJF,CAAA,E,aAKJC,WALI,CAAA,E,cAMJC,YANI,CAAA,SAOJC,KAAK,GAAG,IAARA,GAPI,GAQFR,KARJ,AAAM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ACL,GAAGpB,KAAK,CAACiD,KADJ;YAEL,+CAAA;YACA,CAAC,gDAAD,CAAA,EACE,sCADF;SAHK;KAJT,CAAA,CADF,CACE;CAR2B,CAA/B,AAoBC;AAED,aAAA,CAAA,MAAA,CAAA,MAAA,CAAA,yCAAA,EAAA;IAAA,WAAA,EAAA,sCAAA;CAAA,CAAA,CAAA;AAEA,oGAAA,CAEA,MAAM/E,yCAAI,GAAGhB,yCAAb,AAAA;AACA,MAAMiB,yCAAO,GAAGhB,yCAAhB,AAAA;AACA,MAAMiB,yCAAM,GAAGhB,yCAAf,AAAA;AACA,MAAMiB,yCAAO,GAAGhB,yCAAhB,AAAA;AACA,MAAMiB,yCAAK,GAAGhB,yCAAd,AAAA;AACA,MAAMiB,yCAAK,GAAGhB,yCAAd,AAAA;AACA,MAAMiB,yCAAI,GAAGhB,yCAAb,AAAA;AACA,MAAMiB,yCAAY,GAAGhB,yCAArB,AAAA;AACA,MAAMiB,yCAAU,GAAGhB,yCAAnB,AAAA;AACA,MAAMiB,yCAAS,GAAGhB,yCAAlB,AAAA;AACA,MAAMiB,yCAAa,GAAGhB,yCAAtB,AAAA;AACA,MAAMiB,yCAAS,GAAGhB,yCAAlB,AAAA;AACA,MAAMiB,yCAAK,GAAGhB,yCAAd,AAAA;AACA,MAAMiB,yCAAG,GAAGhB,yCAAZ,AAAA;AACA,MAAMiB,yCAAU,GAAGhB,yCAAnB,AAAA;AACA,MAAMiB,yCAAU,GAAGhB,yCAAnB,AAAA;;AD/eA","sources":["packages/react/dropdown-menu/src/index.ts","packages/react/dropdown-menu/src/DropdownMenu.tsx"],"sourcesContent":["export {\n createDropdownMenuScope,\n //\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuPortal,\n DropdownMenuContent,\n DropdownMenuGroup,\n DropdownMenuLabel,\n DropdownMenuItem,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioGroup,\n DropdownMenuRadioItem,\n DropdownMenuItemIndicator,\n DropdownMenuSeparator,\n DropdownMenuArrow,\n DropdownMenuSub,\n DropdownMenuSubTrigger,\n DropdownMenuSubContent,\n //\n Root,\n Trigger,\n Portal,\n Content,\n Group,\n Label,\n Item,\n CheckboxItem,\n RadioGroup,\n RadioItem,\n ItemIndicator,\n Separator,\n Arrow,\n Sub,\n SubTrigger,\n SubContent,\n} from './DropdownMenu';\nexport type {\n DropdownMenuProps,\n DropdownMenuTriggerProps,\n DropdownMenuPortalProps,\n DropdownMenuContentProps,\n DropdownMenuGroupProps,\n DropdownMenuLabelProps,\n DropdownMenuItemProps,\n DropdownMenuCheckboxItemProps,\n DropdownMenuRadioGroupProps,\n DropdownMenuRadioItemProps,\n DropdownMenuItemIndicatorProps,\n DropdownMenuSeparatorProps,\n DropdownMenuArrowProps,\n DropdownMenuSubProps,\n DropdownMenuSubTriggerProps,\n DropdownMenuSubContentProps,\n} from './DropdownMenu';\n","import * as React from 'react';\nimport { composeEventHandlers } from '@radix-ui/primitive';\nimport { composeRefs } from '@radix-ui/react-compose-refs';\nimport { createContextScope } from '@radix-ui/react-context';\nimport { useControllableState } from '@radix-ui/react-use-controllable-state';\nimport { Primitive } from '@radix-ui/react-primitive';\nimport * as MenuPrimitive from '@radix-ui/react-menu';\nimport { createMenuScope } from '@radix-ui/react-menu';\nimport { useId } from '@radix-ui/react-id';\n\nimport type * as Radix from '@radix-ui/react-primitive';\nimport type { Scope } from '@radix-ui/react-context';\n\ntype Direction = 'ltr' | 'rtl';\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenu\n * -----------------------------------------------------------------------------------------------*/\n\nconst DROPDOWN_MENU_NAME = 'DropdownMenu';\n\ntype ScopedProps<P> = P & { __scopeDropdownMenu?: Scope };\nconst [createDropdownMenuContext, createDropdownMenuScope] = createContextScope(\n DROPDOWN_MENU_NAME,\n [createMenuScope]\n);\nconst useMenuScope = createMenuScope();\n\ntype DropdownMenuContextValue = {\n triggerId: string;\n triggerRef: React.RefObject<HTMLButtonElement>;\n contentId: string;\n open: boolean;\n onOpenChange(open: boolean): void;\n onOpenToggle(): void;\n modal: boolean;\n};\n\nconst [DropdownMenuProvider, useDropdownMenuContext] =\n createDropdownMenuContext<DropdownMenuContextValue>(DROPDOWN_MENU_NAME);\n\ninterface DropdownMenuProps {\n children?: React.ReactNode;\n dir?: Direction;\n open?: boolean;\n defaultOpen?: boolean;\n onOpenChange?(open: boolean): void;\n modal?: boolean;\n}\n\nconst DropdownMenu: React.FC<DropdownMenuProps> = (props: ScopedProps<DropdownMenuProps>) => {\n const {\n __scopeDropdownMenu,\n children,\n dir,\n open: openProp,\n defaultOpen,\n onOpenChange,\n modal = true,\n } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n const triggerRef = React.useRef<HTMLButtonElement>(null);\n const [open = false, setOpen] = useControllableState({\n prop: openProp,\n defaultProp: defaultOpen,\n onChange: onOpenChange,\n });\n\n return (\n <DropdownMenuProvider\n scope={__scopeDropdownMenu}\n triggerId={useId()}\n triggerRef={triggerRef}\n contentId={useId()}\n open={open}\n onOpenChange={setOpen}\n onOpenToggle={React.useCallback(() => setOpen((prevOpen) => !prevOpen), [setOpen])}\n modal={modal}\n >\n <MenuPrimitive.Root {...menuScope} open={open} onOpenChange={setOpen} dir={dir} modal={modal}>\n {children}\n </MenuPrimitive.Root>\n </DropdownMenuProvider>\n );\n};\n\nDropdownMenu.displayName = DROPDOWN_MENU_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuTrigger\n * -----------------------------------------------------------------------------------------------*/\n\nconst TRIGGER_NAME = 'DropdownMenuTrigger';\n\ntype DropdownMenuTriggerElement = React.ElementRef<typeof Primitive.button>;\ntype PrimitiveButtonProps = Radix.ComponentPropsWithoutRef<typeof Primitive.button>;\ninterface DropdownMenuTriggerProps extends PrimitiveButtonProps {}\n\nconst DropdownMenuTrigger = React.forwardRef<DropdownMenuTriggerElement, DropdownMenuTriggerProps>(\n (props: ScopedProps<DropdownMenuTriggerProps>, forwardedRef) => {\n const { __scopeDropdownMenu, disabled = false, ...triggerProps } = props;\n const context = useDropdownMenuContext(TRIGGER_NAME, __scopeDropdownMenu);\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return (\n <MenuPrimitive.Anchor asChild {...menuScope}>\n <Primitive.button\n type=\"button\"\n id={context.triggerId}\n aria-haspopup=\"menu\"\n aria-expanded={context.open ? true : undefined}\n aria-controls={context.open ? context.contentId : undefined}\n data-state={context.open ? 'open' : 'closed'}\n data-disabled={disabled ? '' : undefined}\n disabled={disabled}\n {...triggerProps}\n ref={composeRefs(forwardedRef, context.triggerRef)}\n onPointerDown={composeEventHandlers(props.onPointerDown, (event) => {\n // only call handler if it's the left button (mousedown gets triggered by all mouse buttons)\n // but not when the control key is pressed (avoiding MacOS right click)\n if (!disabled && event.button === 0 && event.ctrlKey === false) {\n context.onOpenToggle();\n // prevent trigger focusing when opening\n // this allows the content to be given focus without competition\n if (!context.open) event.preventDefault();\n }\n })}\n onKeyDown={composeEventHandlers(props.onKeyDown, (event) => {\n if (disabled) return;\n if (['Enter', ' '].includes(event.key)) context.onOpenToggle();\n if (event.key === 'ArrowDown') context.onOpenChange(true);\n // prevent keypresses from scrolling window\n if ([' ', 'ArrowDown'].includes(event.key)) event.preventDefault();\n })}\n />\n </MenuPrimitive.Anchor>\n );\n }\n);\n\nDropdownMenuTrigger.displayName = TRIGGER_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuPortal\n * -----------------------------------------------------------------------------------------------*/\n\nconst PORTAL_NAME = 'DropdownMenuPortal';\n\ntype MenuPortalProps = React.ComponentPropsWithoutRef<typeof MenuPrimitive.Portal>;\ninterface DropdownMenuPortalProps extends MenuPortalProps {}\n\nconst DropdownMenuPortal: React.FC<DropdownMenuPortalProps> = (\n props: ScopedProps<DropdownMenuPortalProps>\n) => {\n const { __scopeDropdownMenu, ...portalProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.Portal {...menuScope} {...portalProps} />;\n};\n\nDropdownMenuPortal.displayName = PORTAL_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuContent\n * -----------------------------------------------------------------------------------------------*/\n\nconst CONTENT_NAME = 'DropdownMenuContent';\n\ntype DropdownMenuContentElement = React.ElementRef<typeof MenuPrimitive.Content>;\ntype MenuContentProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Content>;\ninterface DropdownMenuContentProps extends MenuContentProps {}\n\nconst DropdownMenuContent = React.forwardRef<DropdownMenuContentElement, DropdownMenuContentProps>(\n (props: ScopedProps<DropdownMenuContentProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...contentProps } = props;\n const context = useDropdownMenuContext(CONTENT_NAME, __scopeDropdownMenu);\n const menuScope = useMenuScope(__scopeDropdownMenu);\n const hasInteractedOutsideRef = React.useRef(false);\n\n return (\n <MenuPrimitive.Content\n id={context.contentId}\n aria-labelledby={context.triggerId}\n {...menuScope}\n {...contentProps}\n ref={forwardedRef}\n onCloseAutoFocus={composeEventHandlers(props.onCloseAutoFocus, (event) => {\n if (!hasInteractedOutsideRef.current) context.triggerRef.current?.focus();\n hasInteractedOutsideRef.current = false;\n // Always prevent auto focus because we either focus manually or want user agent focus\n event.preventDefault();\n })}\n onInteractOutside={composeEventHandlers(props.onInteractOutside, (event) => {\n const originalEvent = event.detail.originalEvent as PointerEvent;\n const ctrlLeftClick = originalEvent.button === 0 && originalEvent.ctrlKey === true;\n const isRightClick = originalEvent.button === 2 || ctrlLeftClick;\n if (!context.modal || isRightClick) hasInteractedOutsideRef.current = true;\n })}\n style={{\n ...props.style,\n // re-namespace exposed content custom property\n ['--radix-dropdown-menu-content-transform-origin' as any]:\n 'var(--radix-popper-transform-origin)',\n }}\n />\n );\n }\n);\n\nDropdownMenuContent.displayName = CONTENT_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuGroup\n * -----------------------------------------------------------------------------------------------*/\n\nconst GROUP_NAME = 'DropdownMenuGroup';\n\ntype DropdownMenuGroupElement = React.ElementRef<typeof MenuPrimitive.Group>;\ntype MenuGroupProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Group>;\ninterface DropdownMenuGroupProps extends MenuGroupProps {}\n\nconst DropdownMenuGroup = React.forwardRef<DropdownMenuGroupElement, DropdownMenuGroupProps>(\n (props: ScopedProps<DropdownMenuGroupProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...groupProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.Group {...menuScope} {...groupProps} ref={forwardedRef} />;\n }\n);\n\nDropdownMenuGroup.displayName = GROUP_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuLabel\n * -----------------------------------------------------------------------------------------------*/\n\nconst LABEL_NAME = 'DropdownMenuLabel';\n\ntype DropdownMenuLabelElement = React.ElementRef<typeof MenuPrimitive.Label>;\ntype MenuLabelProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Label>;\ninterface DropdownMenuLabelProps extends MenuLabelProps {}\n\nconst DropdownMenuLabel = React.forwardRef<DropdownMenuLabelElement, DropdownMenuLabelProps>(\n (props: ScopedProps<DropdownMenuLabelProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...labelProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.Label {...menuScope} {...labelProps} ref={forwardedRef} />;\n }\n);\n\nDropdownMenuLabel.displayName = LABEL_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuItem\n * -----------------------------------------------------------------------------------------------*/\n\nconst ITEM_NAME = 'DropdownMenuItem';\n\ntype DropdownMenuItemElement = React.ElementRef<typeof MenuPrimitive.Item>;\ntype MenuItemProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Item>;\ninterface DropdownMenuItemProps extends MenuItemProps {}\n\nconst DropdownMenuItem = React.forwardRef<DropdownMenuItemElement, DropdownMenuItemProps>(\n (props: ScopedProps<DropdownMenuItemProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...itemProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.Item {...menuScope} {...itemProps} ref={forwardedRef} />;\n }\n);\n\nDropdownMenuItem.displayName = ITEM_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuCheckboxItem\n * -----------------------------------------------------------------------------------------------*/\n\nconst CHECKBOX_ITEM_NAME = 'DropdownMenuCheckboxItem';\n\ntype DropdownMenuCheckboxItemElement = React.ElementRef<typeof MenuPrimitive.CheckboxItem>;\ntype MenuCheckboxItemProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.CheckboxItem>;\ninterface DropdownMenuCheckboxItemProps extends MenuCheckboxItemProps {}\n\nconst DropdownMenuCheckboxItem = React.forwardRef<\n DropdownMenuCheckboxItemElement,\n DropdownMenuCheckboxItemProps\n>((props: ScopedProps<DropdownMenuCheckboxItemProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...checkboxItemProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.CheckboxItem {...menuScope} {...checkboxItemProps} ref={forwardedRef} />;\n});\n\nDropdownMenuCheckboxItem.displayName = CHECKBOX_ITEM_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuRadioGroup\n * -----------------------------------------------------------------------------------------------*/\n\nconst RADIO_GROUP_NAME = 'DropdownMenuRadioGroup';\n\ntype DropdownMenuRadioGroupElement = React.ElementRef<typeof MenuPrimitive.RadioGroup>;\ntype MenuRadioGroupProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.RadioGroup>;\ninterface DropdownMenuRadioGroupProps extends MenuRadioGroupProps {}\n\nconst DropdownMenuRadioGroup = React.forwardRef<\n DropdownMenuRadioGroupElement,\n DropdownMenuRadioGroupProps\n>((props: ScopedProps<DropdownMenuRadioGroupProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...radioGroupProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.RadioGroup {...menuScope} {...radioGroupProps} ref={forwardedRef} />;\n});\n\nDropdownMenuRadioGroup.displayName = RADIO_GROUP_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuRadioItem\n * -----------------------------------------------------------------------------------------------*/\n\nconst RADIO_ITEM_NAME = 'DropdownMenuRadioItem';\n\ntype DropdownMenuRadioItemElement = React.ElementRef<typeof MenuPrimitive.RadioItem>;\ntype MenuRadioItemProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.RadioItem>;\ninterface DropdownMenuRadioItemProps extends MenuRadioItemProps {}\n\nconst DropdownMenuRadioItem = React.forwardRef<\n DropdownMenuRadioItemElement,\n DropdownMenuRadioItemProps\n>((props: ScopedProps<DropdownMenuRadioItemProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...radioItemProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.RadioItem {...menuScope} {...radioItemProps} ref={forwardedRef} />;\n});\n\nDropdownMenuRadioItem.displayName = RADIO_ITEM_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuItemIndicator\n * -----------------------------------------------------------------------------------------------*/\n\nconst INDICATOR_NAME = 'DropdownMenuItemIndicator';\n\ntype DropdownMenuItemIndicatorElement = React.ElementRef<typeof MenuPrimitive.ItemIndicator>;\ntype MenuItemIndicatorProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.ItemIndicator>;\ninterface DropdownMenuItemIndicatorProps extends MenuItemIndicatorProps {}\n\nconst DropdownMenuItemIndicator = React.forwardRef<\n DropdownMenuItemIndicatorElement,\n DropdownMenuItemIndicatorProps\n>((props: ScopedProps<DropdownMenuItemIndicatorProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...itemIndicatorProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.ItemIndicator {...menuScope} {...itemIndicatorProps} ref={forwardedRef} />;\n});\n\nDropdownMenuItemIndicator.displayName = INDICATOR_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuSeparator\n * -----------------------------------------------------------------------------------------------*/\n\nconst SEPARATOR_NAME = 'DropdownMenuSeparator';\n\ntype DropdownMenuSeparatorElement = React.ElementRef<typeof MenuPrimitive.Separator>;\ntype MenuSeparatorProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Separator>;\ninterface DropdownMenuSeparatorProps extends MenuSeparatorProps {}\n\nconst DropdownMenuSeparator = React.forwardRef<\n DropdownMenuSeparatorElement,\n DropdownMenuSeparatorProps\n>((props: ScopedProps<DropdownMenuSeparatorProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...separatorProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.Separator {...menuScope} {...separatorProps} ref={forwardedRef} />;\n});\n\nDropdownMenuSeparator.displayName = SEPARATOR_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuArrow\n * -----------------------------------------------------------------------------------------------*/\n\nconst ARROW_NAME = 'DropdownMenuArrow';\n\ntype DropdownMenuArrowElement = React.ElementRef<typeof MenuPrimitive.Arrow>;\ntype MenuArrowProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.Arrow>;\ninterface DropdownMenuArrowProps extends MenuArrowProps {}\n\nconst DropdownMenuArrow = React.forwardRef<DropdownMenuArrowElement, DropdownMenuArrowProps>(\n (props: ScopedProps<DropdownMenuArrowProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...arrowProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.Arrow {...menuScope} {...arrowProps} ref={forwardedRef} />;\n }\n);\n\nDropdownMenuArrow.displayName = ARROW_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuSub\n * -----------------------------------------------------------------------------------------------*/\n\ninterface DropdownMenuSubProps {\n children?: React.ReactNode;\n open?: boolean;\n defaultOpen?: boolean;\n onOpenChange?(open: boolean): void;\n}\n\nconst DropdownMenuSub: React.FC<DropdownMenuSubProps> = (\n props: ScopedProps<DropdownMenuSubProps>\n) => {\n const { __scopeDropdownMenu, children, open: openProp, onOpenChange, defaultOpen } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n const [open = false, setOpen] = useControllableState({\n prop: openProp,\n defaultProp: defaultOpen,\n onChange: onOpenChange,\n });\n\n return (\n <MenuPrimitive.Sub {...menuScope} open={open} onOpenChange={setOpen}>\n {children}\n </MenuPrimitive.Sub>\n );\n};\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuSubTrigger\n * -----------------------------------------------------------------------------------------------*/\n\nconst SUB_TRIGGER_NAME = 'DropdownMenuSubTrigger';\n\ntype DropdownMenuSubTriggerElement = React.ElementRef<typeof MenuPrimitive.SubTrigger>;\ntype MenuSubTriggerProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.SubTrigger>;\ninterface DropdownMenuSubTriggerProps extends MenuSubTriggerProps {}\n\nconst DropdownMenuSubTrigger = React.forwardRef<\n DropdownMenuSubTriggerElement,\n DropdownMenuSubTriggerProps\n>((props: ScopedProps<DropdownMenuSubTriggerProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...subTriggerProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n return <MenuPrimitive.SubTrigger {...menuScope} {...subTriggerProps} ref={forwardedRef} />;\n});\n\nDropdownMenuSubTrigger.displayName = SUB_TRIGGER_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DropdownMenuSubContent\n * -----------------------------------------------------------------------------------------------*/\n\nconst SUB_CONTENT_NAME = 'DropdownMenuSubContent';\n\ntype DropdownMenuSubContentElement = React.ElementRef<typeof MenuPrimitive.Content>;\ntype MenuSubContentProps = Radix.ComponentPropsWithoutRef<typeof MenuPrimitive.SubContent>;\ninterface DropdownMenuSubContentProps extends MenuSubContentProps {}\n\nconst DropdownMenuSubContent = React.forwardRef<\n DropdownMenuSubContentElement,\n DropdownMenuSubContentProps\n>((props: ScopedProps<DropdownMenuSubContentProps>, forwardedRef) => {\n const { __scopeDropdownMenu, ...subContentProps } = props;\n const menuScope = useMenuScope(__scopeDropdownMenu);\n\n return (\n <MenuPrimitive.SubContent\n {...menuScope}\n {...subContentProps}\n ref={forwardedRef}\n style={{\n ...props.style,\n // re-namespace exposed content custom property\n ['--radix-dropdown-menu-content-transform-origin' as any]:\n 'var(--radix-popper-transform-origin)',\n }}\n />\n );\n});\n\nDropdownMenuSubContent.displayName = SUB_CONTENT_NAME;\n\n/* -----------------------------------------------------------------------------------------------*/\n\nconst Root = DropdownMenu;\nconst Trigger = DropdownMenuTrigger;\nconst Portal = DropdownMenuPortal;\nconst Content = DropdownMenuContent;\nconst Group = DropdownMenuGroup;\nconst Label = DropdownMenuLabel;\nconst Item = DropdownMenuItem;\nconst CheckboxItem = DropdownMenuCheckboxItem;\nconst RadioGroup = DropdownMenuRadioGroup;\nconst RadioItem = DropdownMenuRadioItem;\nconst ItemIndicator = DropdownMenuItemIndicator;\nconst Separator = DropdownMenuSeparator;\nconst Arrow = DropdownMenuArrow;\nconst Sub = DropdownMenuSub;\nconst SubTrigger = DropdownMenuSubTrigger;\nconst SubContent = DropdownMenuSubContent;\n\nexport {\n createDropdownMenuScope,\n //\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuPortal,\n DropdownMenuContent,\n DropdownMenuGroup,\n DropdownMenuLabel,\n DropdownMenuItem,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioGroup,\n DropdownMenuRadioItem,\n DropdownMenuItemIndicator,\n DropdownMenuSeparator,\n DropdownMenuArrow,\n DropdownMenuSub,\n DropdownMenuSubTrigger,\n DropdownMenuSubContent,\n //\n Root,\n Trigger,\n Portal,\n Content,\n Group,\n Label,\n Item,\n CheckboxItem,\n RadioGroup,\n RadioItem,\n ItemIndicator,\n Separator,\n Arrow,\n Sub,\n SubTrigger,\n SubContent,\n};\nexport type {\n DropdownMenuProps,\n DropdownMenuTriggerProps,\n DropdownMenuPortalProps,\n DropdownMenuContentProps,\n DropdownMenuGroupProps,\n DropdownMenuLabelProps,\n DropdownMenuItemProps,\n DropdownMenuCheckboxItemProps,\n DropdownMenuRadioGroupProps,\n DropdownMenuRadioItemProps,\n DropdownMenuItemIndicatorProps,\n DropdownMenuSeparatorProps,\n DropdownMenuArrowProps,\n DropdownMenuSubProps,\n DropdownMenuSubTriggerProps,\n DropdownMenuSubContentProps,\n};\n"],"names":["createDropdownMenuScope","DropdownMenu","DropdownMenuTrigger","DropdownMenuPortal","DropdownMenuContent","DropdownMenuGroup","DropdownMenuLabel","DropdownMenuItem","DropdownMenuCheckboxItem","DropdownMenuRadioGroup","DropdownMenuRadioItem","DropdownMenuItemIndicator","DropdownMenuSeparator","DropdownMenuArrow","DropdownMenuSub","DropdownMenuSubTrigger","DropdownMenuSubContent","Root","Trigger","Portal","Content","Group","Label","Item","CheckboxItem","RadioGroup","RadioItem","ItemIndicator","Separator","Arrow","Sub","SubTrigger","SubContent","React","composeEventHandlers","composeRefs","createContextScope","useControllableState","Primitive","MenuPrimitive","createMenuScope","useId","DROPDOWN_MENU_NAME","createDropdownMenuContext","useMenuScope","DropdownMenuProvider","useDropdownMenuContext","props","__scopeDropdownMenu","children","dir","open","openProp","defaultOpen","onOpenChange","modal","menuScope","triggerRef","useRef","setOpen","prop","defaultProp","onChange","useCallback","prevOpen","TRIGGER_NAME","forwardRef","forwardedRef","disabled","triggerProps","context","triggerId","undefined","contentId","onPointerDown","event","button","ctrlKey","onOpenToggle","preventDefault","onKeyDown","includes","key","PORTAL_NAME","portalProps","CONTENT_NAME","contentProps","hasInteractedOutsideRef","onCloseAutoFocus","current","focus","onInteractOutside","originalEvent","detail","ctrlLeftClick","isRightClick","style","GROUP_NAME","groupProps","LABEL_NAME","labelProps","ITEM_NAME","itemProps","CHECKBOX_ITEM_NAME","checkboxItemProps","RADIO_GROUP_NAME","radioGroupProps","RADIO_ITEM_NAME","radioItemProps","INDICATOR_NAME","itemIndicatorProps","SEPARATOR_NAME","separatorProps","ARROW_NAME","arrowProps","SUB_TRIGGER_NAME","subTriggerProps","SUB_CONTENT_NAME","subContentProps"],"version":3,"file":"index.module.js.map"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@radix-ui/react-dropdown-menu",
3
- "version": "0.1.7-rc.9",
3
+ "version": "1.0.1-rc.1",
4
4
  "license": "MIT",
5
5
  "source": "src/index.ts",
6
6
  "main": "dist/index.js",
@@ -17,13 +17,13 @@
17
17
  },
18
18
  "dependencies": {
19
19
  "@babel/runtime": "^7.13.10",
20
- "@radix-ui/primitive": "0.1.0",
21
- "@radix-ui/react-compose-refs": "0.1.1-rc.6",
22
- "@radix-ui/react-context": "0.1.2-rc.6",
23
- "@radix-ui/react-id": "0.1.6-rc.6",
24
- "@radix-ui/react-menu": "0.1.7-rc.9",
25
- "@radix-ui/react-primitive": "0.1.5-rc.6",
26
- "@radix-ui/react-use-controllable-state": "0.1.1-rc.6"
20
+ "@radix-ui/primitive": "1.0.0",
21
+ "@radix-ui/react-compose-refs": "1.0.0",
22
+ "@radix-ui/react-context": "1.0.0",
23
+ "@radix-ui/react-id": "1.0.0",
24
+ "@radix-ui/react-menu": "1.0.1-rc.1",
25
+ "@radix-ui/react-primitive": "1.0.0",
26
+ "@radix-ui/react-use-controllable-state": "1.0.0"
27
27
  },
28
28
  "peerDependencies": {
29
29
  "react": "^16.8 || ^17.0 || ^18.0",
@@ -37,5 +37,5 @@
37
37
  "bugs": {
38
38
  "url": "https://github.com/radix-ui/primitives/issues"
39
39
  },
40
- "stableVersion": "0.1.6"
40
+ "stableVersion": "1.0.0"
41
41
  }