@wonderflow/react-components 3.0.0-beta.18 → 3.0.0-beta.19

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.
@@ -1,7 +1,4 @@
1
- import { ReactNode, ForwardRefExoticComponent } from 'react';
2
- import { DropdownMenuProps } from './menu/dropdown-menu';
3
- import { DropdownItemProps } from './item/dropdown-item';
4
- import { DropdownItemCheckboxProps } from './item-checkbox/dropdown-item-checkbox';
1
+ import { ReactNode } from 'react';
5
2
  import { AutoPlacement, BasePlacement, VariationPlacement } from '@popperjs/core';
6
3
  export declare type DropdownProps = PropsWithClass & {
7
4
  /**
@@ -27,10 +24,27 @@ export declare type DropdownProps = PropsWithClass & {
27
24
  */
28
25
  placement?: AutoPlacement | BasePlacement | VariationPlacement;
29
26
  };
30
- declare type DropdownComponent = ForwardRefExoticComponent<DropdownProps> & {
31
- Menu: ForwardRefExoticComponent<DropdownMenuProps>;
32
- Item: ForwardRefExoticComponent<DropdownItemProps>;
33
- ItemCheckbox: ForwardRefExoticComponent<DropdownItemCheckboxProps>;
34
- };
35
- export declare const Dropdown: DropdownComponent;
36
- export {};
27
+ export declare const Dropdown: import("react").ForwardRefExoticComponent<PropsWithClass & {
28
+ /**
29
+ * The content of the dropdown to display when the dropdown is open.
30
+ */
31
+ children: ReactNode;
32
+ /**
33
+ * The element to use as the trigger for the dropdown.
34
+ */
35
+ trigger: ReactNode;
36
+ /**
37
+ * The distance from the trigger to the dropdown.
38
+ */
39
+ offset?: number | undefined;
40
+ /**
41
+ * The placement of the dropdown. This is automatically handled based on
42
+ * scroll and viewport edges. By default the dropdown is anchored at
43
+ * the beginning of the trigger.
44
+ *
45
+ * The first key refers to the X axis, the second key refers to the Y axis.
46
+ * Eg: `auto-start` means the dropdown will be placed automatically on left or right
47
+ * based on the available space, and anchored at the top (start) of the trigger.
48
+ */
49
+ placement?: AutoPlacement | BasePlacement | VariationPlacement | undefined;
50
+ } & import("react").RefAttributes<HTMLDivElement>>;
@@ -3,9 +3,6 @@ import { useState, Children, cloneElement, useRef, forwardRef } from 'react';
3
3
  import { useKeyPress, useFocusWithin } from 'ahooks';
4
4
  import { Dropdown as DropdownClass, PopUp } from './dropdown.module.css';
5
5
  import { useUIDSeed } from 'react-uid';
6
- import { DropdownMenu } from './menu/dropdown-menu';
7
- import { DropdownItem } from './item/dropdown-item';
8
- import { DropdownItemCheckbox } from './item-checkbox/dropdown-item-checkbox';
9
6
  import { usePopperTooltip } from 'react-popper-tooltip';
10
7
  import { AnimatePresence, motion } from 'framer-motion';
11
8
  import clsx from 'clsx';
@@ -65,6 +62,3 @@ export const Dropdown = forwardRef(({ children, trigger, offset = 8, placement =
65
62
  })) }, void 0) }, seedID('tooltip-content'))) }, void 0)] }, void 0));
66
63
  });
67
64
  Dropdown.displayName = 'Dropdown';
68
- Dropdown.Menu = DropdownMenu;
69
- Dropdown.Item = DropdownItem;
70
- Dropdown.ItemCheckbox = DropdownItemCheckbox;
@@ -1,4 +1,2 @@
1
1
  export { Dropdown } from './dropdown';
2
2
  export type { DropdownProps } from './dropdown';
3
- export type { DropdownItemProps } from './item/dropdown-item';
4
- export type { DropdownItemCheckboxProps } from './item-checkbox/dropdown-item-checkbox';
package/index.d.ts CHANGED
@@ -25,7 +25,7 @@ export type { TableProps } from './table';
25
25
  export { Disclosure } from './disclosure';
26
26
  export type { DisclosureProps } from './disclosure';
27
27
  export { Dropdown } from './dropdown';
28
- export type { DropdownProps, DropdownItemProps, DropdownItemCheckboxProps } from './dropdown';
28
+ export type { DropdownProps } from './dropdown';
29
29
  export { Elevator } from './elevator';
30
30
  export type { ElevatorProps } from './elevator';
31
31
  export { Icon } from './icon';
@@ -44,6 +44,8 @@ export { Modal } from './modal';
44
44
  export type { ModalProps } from './modal';
45
45
  export { LinearProgress } from './linear-progress';
46
46
  export type { LinearProgressProps } from './linear-progress';
47
+ export { Menu } from './menu';
48
+ export type { MenuProps, MenuItemProps, MenuItemCheckboxProps } from './menu';
47
49
  export { OverlayContainer, useOverlayContext, OverlayProvider } from './overlay-container';
48
50
  export type { OverlayContainerProps } from './overlay-container';
49
51
  export { Prose } from './prose';
package/index.js CHANGED
@@ -22,6 +22,7 @@ export { List } from './list';
22
22
  export { SplitButton } from './split-button';
23
23
  export { Modal } from './modal';
24
24
  export { LinearProgress } from './linear-progress';
25
+ export { Menu } from './menu';
25
26
  export { OverlayContainer, useOverlayContext, OverlayProvider } from './overlay-container';
26
27
  export { Prose } from './prose';
27
28
  export { Pagination } from './pagination';
@@ -0,0 +1,6 @@
1
+ export { Menu } from './menu';
2
+ export type { MenuProps } from './menu';
3
+ export { MenuItem } from './menu-item/menu-item';
4
+ export type { MenuItemProps } from './menu-item/menu-item';
5
+ export { MenuItemCheckbox } from './menu-item/menu-item-checkbox';
6
+ export type { MenuItemCheckboxProps } from './menu-item/menu-item-checkbox';
package/menu/index.js ADDED
@@ -0,0 +1,3 @@
1
+ export { Menu } from './menu';
2
+ export { MenuItem } from './menu-item/menu-item';
3
+ export { MenuItemCheckbox } from './menu-item/menu-item-checkbox';
@@ -0,0 +1,11 @@
1
+ import { MenuItem, MenuItemProps } from '..';
2
+ import { Polymorphic } from '../..';
3
+ export declare type MenuItemCheckboxProps = MenuItemProps & {
4
+ /**
5
+ * Set the default checked state of the checkbox item
6
+ */
7
+ checked?: boolean;
8
+ };
9
+ declare type MenuItemCheckboxComponent = Polymorphic.ForwardRefComponent<Polymorphic.IntrinsicElement<typeof MenuItem>, Polymorphic.OwnProps<typeof MenuItem> & MenuItemCheckboxProps>;
10
+ export declare const MenuItemCheckbox: MenuItemCheckboxComponent;
11
+ export {};
@@ -0,0 +1,5 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ import { forwardRef } from 'react';
3
+ import { MenuItem } from '..';
4
+ export const MenuItemCheckbox = forwardRef(({ children, checked, ...otherProps }, forwardedRef) => (_jsx(MenuItem, { role: "menuitemcheckbox", "aria-checked": checked, ref: forwardedRef, ...otherProps, children: children }, void 0)));
5
+ MenuItemCheckbox.displayName = 'Menu.ItemCheckbox';
@@ -1,13 +1,13 @@
1
1
  import { ReactNode } from 'react';
2
2
  import { IconNames } from '../../icons/types';
3
3
  import { Polymorphic } from '../..';
4
- export declare type DropdownItemProps = {
4
+ export declare type MenuItemProps = {
5
5
  /**
6
- * Content to display in the dropdown item.
6
+ * Content to display in the menu item.
7
7
  */
8
8
  children: ReactNode;
9
9
  /**
10
- * Whether the dropdown item should have an icon
10
+ * Whether the menu item should have an icon
11
11
  */
12
12
  icon?: IconNames;
13
13
  /**
@@ -24,7 +24,7 @@ export declare type DropdownItemProps = {
24
24
  */
25
25
  onClick?(): void;
26
26
  /**
27
- * Add an extra description to the dropdown item.
27
+ * Add an extra description to the menu item.
28
28
  * This uses the `<Tooltip>` component internally.
29
29
  */
30
30
  description?: ReactNode;
@@ -33,15 +33,15 @@ export declare type DropdownItemProps = {
33
33
  */
34
34
  disabled?: boolean;
35
35
  /**
36
- * Add or remove the padding from the dropdown item.
36
+ * Add or remove the padding from the menu item.
37
37
  * This space is used to keep the content aligned across items with or without icons.
38
38
  * We suggest to not remove the padding if you have items with icons in the same menu to
39
39
  * keep a good readability.
40
40
  *
41
- * Read more: https://design.wonderflow.ai/design/recipes/dropdown/#items-with-icons
41
+ * Read more: https://design.wonderflow.ai/design/recipes/menu/#items-with-icons
42
42
  */
43
43
  padding?: boolean;
44
44
  };
45
- declare type PolymorphicDropdownItem = Polymorphic.ForwardRefComponent<'button', DropdownItemProps>;
46
- export declare const DropdownItem: PolymorphicDropdownItem;
45
+ declare type PolymorphicMenuItem = Polymorphic.ForwardRefComponent<'button', MenuItemProps>;
46
+ export declare const MenuItem: PolymorphicMenuItem;
47
47
  export {};
@@ -0,0 +1,23 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { useCallback, forwardRef, useRef, useMemo } from 'react';
3
+ import { useRovingTabIndex, useFocusEffect } from 'react-roving-tabindex';
4
+ import { MenuItem as MenuItemClass, Icon as IconClass, ItemContent } from './menu-item.module.css';
5
+ import { Tooltip, Stack, Icon } from '../..';
6
+ import clsx from 'clsx';
7
+ export const MenuItem = forwardRef(({ className, children, onClick, icon, dimension = 'regular', as: Wrapper = 'button', iconPosition = 'left', description, padding = true, disabled = false, ...otherProps }, forwardedRef) => {
8
+ const itemRef = useRef(forwardedRef);
9
+ const [tabIndex, focused, handleKeyDown, handleClick] = useRovingTabIndex(itemRef, disabled);
10
+ const isIconRight = iconPosition === 'right';
11
+ useFocusEffect(focused, itemRef);
12
+ const triggerClick = useCallback(() => {
13
+ if (onClick) {
14
+ handleClick();
15
+ onClick();
16
+ }
17
+ }, [handleClick, onClick]);
18
+ const InnerContent = useMemo(() => (_jsxs(Stack, { direction: "row", as: "span", fill: false, className: ItemContent, horizontalAlign: isIconRight ? 'space-between' : 'start', verticalAlign: "start", columnGap: 8, horizontalPadding: 16, verticalPadding: 8, "data-menu-item-icon-right": isIconRight, "data-menu-item-has-icon": Boolean(icon), "data-menu-item-padding": padding, style: { inlineSize: '100%' }, children: [icon && (_jsx(Icon, { className: IconClass, name: icon, dimension: dimension === 'small' ? 14 : 16 }, void 0)), children] }, void 0)), [children, dimension, icon, isIconRight, padding]);
19
+ return (_jsx(Wrapper, { ref: itemRef, role: "menuitem", className: clsx(MenuItemClass, className), onClick: disabled ? undefined : triggerClick, onKeyDown: disabled ? undefined : handleKeyDown, tabIndex: tabIndex, "aria-disabled": disabled, type: Wrapper === 'button' ? 'button' : undefined, "data-menu-item-dimension": dimension, ...otherProps, children: description
20
+ ? (_jsx(Tooltip, { fill: true, open: focused, placement: "right-start", interactive: true, trigger: InnerContent, children: description }, void 0))
21
+ : InnerContent }, void 0));
22
+ });
23
+ MenuItem.displayName = 'Menu.Item';
@@ -0,0 +1 @@
1
+ .MenuItem{background:none;border:0;box-sizing:border-box;color:var(--dimmed-6);cursor:pointer;font:inherit;font-size:.89rem;font-weight:600;inline-size:100%;line-height:1.2;padding:0;position:relative;text-align:start}.MenuItem[aria-checked=true]{color:var(--global-interactive-text)}.MenuItem:before{border-radius:.22rem;bottom:0;content:"";left:.44rem;opacity:60%;position:absolute;right:.44rem;top:0;z-index:0}.MenuItem:is(:hover,.focus-visible,[aria-pressed=true]):not([aria-disabled=true]){outline:none}.MenuItem:is(:hover,:focus-visible,[aria-pressed=true]):not([aria-disabled=true]){outline:none}.MenuItem:is(:hover,.focus-visible,[aria-pressed=true]):not([aria-disabled=true]):before{background-color:var(--dimmed-1)}.MenuItem:is(:hover,:focus-visible,[aria-pressed=true]):not([aria-disabled=true]):before{background-color:var(--dimmed-1)}.MenuItem[data-menu-item-dimension=small]{font-size:.78rem}.MenuItem>*{position:relative}.MenuItem[aria-disabled=true]{color:var(--global-disabled-foreground);cursor:not-allowed}.MenuItem [data-menu-item-padding=true][data-menu-item-has-icon=false][data-menu-item-icon-right=false]{padding-left:2.22rem}.MenuItem [data-menu-item-padding=true][data-menu-item-has-icon=false][data-menu-item-icon-right=true]{padding-right:2.22rem}.ItemContent{position:relative}.Icon{flex-shrink:0;margin-top:1px}[data-menu-item-icon-right=true] .Icon{order:2}
package/menu/menu.d.ts ADDED
@@ -0,0 +1,15 @@
1
+ import { ReactNode, HTMLAttributes, ForwardRefExoticComponent } from 'react';
2
+ import { MenuItemProps } from './menu-item/menu-item';
3
+ import { MenuItemCheckboxProps } from './menu-item/menu-item-checkbox';
4
+ export declare type MenuProps = HTMLAttributes<HTMLUListElement> & {
5
+ /**
6
+ * The items of the dropdown menu.
7
+ */
8
+ children: ReactNode;
9
+ };
10
+ declare type MenuComponent = ForwardRefExoticComponent<MenuProps> & {
11
+ Item: ForwardRefExoticComponent<MenuItemProps>;
12
+ ItemCheckbox: ForwardRefExoticComponent<MenuItemCheckboxProps>;
13
+ };
14
+ export declare const Menu: MenuComponent;
15
+ export {};
package/menu/menu.js ADDED
@@ -0,0 +1,17 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ import { Children, cloneElement, forwardRef } from 'react';
3
+ import { RovingTabIndexProvider } from 'react-roving-tabindex';
4
+ import { MenuItem } from './menu-item/menu-item';
5
+ import { MenuItemCheckbox } from './menu-item/menu-item-checkbox';
6
+ import { Stack, Elevator } from '..';
7
+ import { Menu as MenuClass } from './menu.module.css';
8
+ import clsx from 'clsx';
9
+ export const Menu = forwardRef(({ className, children, ...otherProps }, forwardedRef) => {
10
+ const renderedChildren = Children.toArray(children).filter(Boolean);
11
+ return (_jsx(Elevator, { resting: 2, children: _jsx(Stack, { as: "ul", ref: forwardedRef, className: clsx(MenuClass, className), role: "menu", ...otherProps, children: _jsx(RovingTabIndexProvider, { options: { direction: 'vertical', loopAround: true }, children: Children.map(renderedChildren, (child, index) => (_jsx(Stack, { as: "li", role: "none", verticalPadding: child.type?.displayName === 'Separator' ? 8 : undefined, children: cloneElement(child, {
12
+ autoFocus: index === 0 && true
13
+ }) }, void 0))) }, void 0) }, void 0) }, void 0));
14
+ });
15
+ Menu.displayName = 'Menu';
16
+ Menu.Item = MenuItem;
17
+ Menu.ItemCheckbox = MenuItemCheckbox;
@@ -0,0 +1 @@
1
+ .Menu{background-color:var(--global-background);border:1px solid var(--dimmed-1);border-radius:.44rem;list-style-type:none;overflow:hidden;padding:.44rem 0;position:relative}.Menu hr{margin:0 .44rem}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@wonderflow/react-components",
3
3
  "description": "UI components from Wonderflow's Wanda design system",
4
- "version": "3.0.0-beta.18",
4
+ "version": "3.0.0-beta.19",
5
5
  "author": "Wonderflow",
6
6
  "license": "MIT",
7
7
  "main": "index.js",
@@ -67,7 +67,7 @@
67
67
  "@wonderflow/tokens": "1.3.7",
68
68
  "ahooks": "3.1.3",
69
69
  "clsx": "1.1.1",
70
- "framer-motion": "4.1.17",
70
+ "framer-motion": "5.5.5",
71
71
  "postcss": "^8.4.5",
72
72
  "react": "^17.0",
73
73
  "react-data-table-component": "7.4.6",
package/themes/dark.css CHANGED
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * Do not edit directly
3
- * Generated on Fri, 31 Dec 2021 10:27:40 GMT
3
+ * Generated on Fri, 31 Dec 2021 13:33:54 GMT
4
4
  */
5
5
 
6
6
  :root {
package/themes/light.css CHANGED
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * Do not edit directly
3
- * Generated on Fri, 31 Dec 2021 10:27:40 GMT
3
+ * Generated on Fri, 31 Dec 2021 13:33:54 GMT
4
4
  */
5
5
 
6
6
  :root {
@@ -1,23 +0,0 @@
1
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
- import { useCallback, forwardRef, useRef, useMemo } from 'react';
3
- import { useRovingTabIndex, useFocusEffect } from 'react-roving-tabindex';
4
- import { DropdownItem as DropdownItemClass, Icon as IconClass } from './dropdown-item.module.css';
5
- import { Tooltip, Stack, Icon } from '../..';
6
- import clsx from 'clsx';
7
- export const DropdownItem = forwardRef(({ className, children, onClick, icon, dimension = 'regular', as: Wrapper = 'button', iconPosition = 'left', description, padding = true, disabled = false, ...props }, forwardedRef) => {
8
- const itemRef = useRef(forwardedRef);
9
- const [tabIndex, focused, handleKeyDown, handleClick] = useRovingTabIndex(itemRef, disabled);
10
- const isIconRight = iconPosition === 'right';
11
- useFocusEffect(focused, itemRef);
12
- const triggerClick = useCallback(() => {
13
- if (onClick) {
14
- handleClick();
15
- onClick();
16
- }
17
- }, [handleClick, onClick]);
18
- const InnerContent = useMemo(() => (_jsxs(Stack, { direction: "row", as: "span", fill: false, horizontalAlign: isIconRight ? 'space-between' : 'start', verticalAlign: "center", columnGap: 8, horizontalPadding: 16, verticalPadding: 8, "data-dropdown-icon-right": isIconRight, "data-dropdown-has-icon": Boolean(icon), "data-dropdown-padding": padding, style: { inlineSize: '100%' }, children: [icon && (_jsx(Icon, { className: IconClass, name: icon, dimension: dimension === 'small' ? 14 : 16 }, void 0)), children] }, void 0)), [children, dimension, icon, isIconRight, padding]);
19
- return (_jsx(Wrapper, { ref: itemRef, role: "menuitem", className: clsx(DropdownItemClass, className), onClick: disabled ? undefined : triggerClick, onKeyDown: disabled ? undefined : handleKeyDown, tabIndex: tabIndex, "aria-disabled": disabled, type: Wrapper === 'button' ? 'button' : undefined, "data-dropdown-item-dimension": dimension, ...props, children: description
20
- ? (_jsx(Tooltip, { fill: true, open: focused, placement: "right-start", interactive: true, trigger: InnerContent, children: description }, void 0))
21
- : InnerContent }, void 0));
22
- });
23
- DropdownItem.displayName = 'Dropdown.Item';
@@ -1 +0,0 @@
1
- .DropdownItem{background:none;border:0;box-sizing:border-box;color:var(--dimmed-6);cursor:pointer;font:inherit;font-size:.89rem;font-weight:600;inline-size:100%;line-height:1.2;position:relative;text-align:start}.DropdownItem[aria-checked=true]{color:var(--global-interactive-text)}.DropdownItem:before{border-radius:.22rem;bottom:0;content:"";left:.44rem;opacity:60%;position:absolute;right:.44rem;top:0}.DropdownItem:is(:hover,.focus-visible,[aria-pressed=true]):not([aria-disabled=true]){outline:none}.DropdownItem:is(:hover,:focus-visible,[aria-pressed=true]):not([aria-disabled=true]){outline:none}.DropdownItem:is(:hover,.focus-visible,[aria-pressed=true]):not([aria-disabled=true]):before{background-color:var(--dimmed-1)}.DropdownItem:is(:hover,:focus-visible,[aria-pressed=true]):not([aria-disabled=true]):before{background-color:var(--dimmed-1)}.DropdownItem[data-dropdown-item-dimension=small]{font-size:.78rem}.DropdownItem>*{position:relative}.DropdownItem[aria-disabled=true]{color:var(--global-disabled-foreground);cursor:not-allowed}.DropdownItem [data-dropdown-padding=true][data-dropdown-has-icon=false][data-dropdown-icon-right=false]{padding-left:2.22rem}.DropdownItem [data-dropdown-padding=true][data-dropdown-has-icon=false][data-dropdown-icon-right=true]{padding-right:2.22rem}[data-dropdown-icon-right=true] .Icon{order:2}
@@ -1,11 +0,0 @@
1
- import { DropdownItem, DropdownItemProps } from '../item/dropdown-item';
2
- import { Polymorphic } from '../..';
3
- export declare type DropdownItemCheckboxProps = DropdownItemProps & {
4
- /**
5
- * Set the default checked state of the checkbox item
6
- */
7
- checked?: boolean;
8
- };
9
- declare type PolymorphicDropdownItemCheckbox = Polymorphic.ForwardRefComponent<Polymorphic.IntrinsicElement<typeof DropdownItem>, Polymorphic.OwnProps<typeof DropdownItem> & DropdownItemCheckboxProps>;
10
- export declare const DropdownItemCheckbox: PolymorphicDropdownItemCheckbox;
11
- export {};
@@ -1,5 +0,0 @@
1
- import { jsx as _jsx } from "react/jsx-runtime";
2
- import { forwardRef } from 'react';
3
- import { DropdownItem } from '../item/dropdown-item';
4
- export const DropdownItemCheckbox = forwardRef(({ children, checked, ...props }, forwardedRef) => _jsx(DropdownItem, { role: "menuitemcheckbox", "aria-checked": checked, ref: forwardedRef, ...props, children: children }, void 0));
5
- DropdownItemCheckbox.displayName = 'Dropdown.ItemCheckbox';
@@ -1,13 +0,0 @@
1
- import { ReactNode, HTMLAttributes } from 'react';
2
- export declare type DropdownMenuProps = HTMLAttributes<HTMLUListElement> & {
3
- /**
4
- * The items of the dropdown menu.
5
- */
6
- children: ReactNode;
7
- };
8
- export declare const DropdownMenu: import("react").ForwardRefExoticComponent<HTMLAttributes<HTMLUListElement> & {
9
- /**
10
- * The items of the dropdown menu.
11
- */
12
- children: ReactNode;
13
- } & import("react").RefAttributes<HTMLUListElement>>;
@@ -1,13 +0,0 @@
1
- import { jsx as _jsx } from "react/jsx-runtime";
2
- import { Children, cloneElement, forwardRef } from 'react';
3
- import { RovingTabIndexProvider } from 'react-roving-tabindex';
4
- import { Stack, Elevator } from '../..';
5
- import clsx from 'clsx';
6
- import { DropdownMenu as DropdownMenuClass } from './dropdown-menu.module.css';
7
- export const DropdownMenu = forwardRef(({ className, children, ...otherProps }, forwardedRef) => {
8
- const renderedChildren = Children.toArray(children).filter(Boolean);
9
- return (_jsx(Elevator, { resting: 2, children: _jsx(Stack, { as: "ul", ref: forwardedRef, className: clsx(DropdownMenuClass, className), role: "menu", ...otherProps, children: _jsx(RovingTabIndexProvider, { options: { direction: 'vertical', loopAround: true }, children: Children.map(renderedChildren, (child, index) => (_jsx(Stack, { as: "li", role: "none", verticalPadding: child.type?.displayName === 'Separator' ? 8 : undefined, children: cloneElement(child, {
10
- autoFocus: index === 0 && true
11
- }) }, void 0))) }, void 0) }, void 0) }, void 0));
12
- });
13
- DropdownMenu.displayName = 'Dropdown.Menu';
@@ -1 +0,0 @@
1
- .DropdownMenu{background-color:var(--global-background);border:1px solid var(--dimmed-1);border-radius:.44rem;list-style-type:none;overflow:hidden;padding:.44rem 0;position:relative}.DropdownMenu hr{margin:0 .44rem}