import { j as jsxRuntimeExports } from '../../node_modules/.pnpm/react@18.2.0/node_modules/react/jsx-runtime.js';
import { MenuGroupLabel } from '../../node_modules/.pnpm/@ariakit_react-core@0.4.16_react-dom@18.3.1_react@18.2.0__react@18.2.0/node_modules/@ariakit/react-core/esm/menu/menu-group-label.js';
import { MenuGroup } from '../../node_modules/.pnpm/@ariakit_react-core@0.4.16_react-dom@18.3.1_react@18.2.0__react@18.2.0/node_modules/@ariakit/react-core/esm/menu/menu-group.js';
import { MenuSeparator } from '../../node_modules/.pnpm/@ariakit_react-core@0.4.16_react-dom@18.3.1_react@18.2.0__react@18.2.0/node_modules/@ariakit/react-core/esm/menu/menu-separator.js';
import { cx } from '../../node_modules/.pnpm/class-variance-authority@0.7.1/node_modules/class-variance-authority/dist/index.js';
import { forwardRef, Fragment } from 'react';
import { useDropdownContext } from './dropdown-menu-root.js';
import styles from './dropdown-menu.module.css.js';
import { Root as Slot } from '../../node_modules/.pnpm/@radix-ui_react-slot@1.2.3_@types_react@18.2.12_react@18.2.0/node_modules/@radix-ui/react-slot/dist/index.js';

const DropdownMenuGroup = forwardRef(({ className, asChild, ...props }, ref) => {
    const { shouldFilter } = useDropdownContext();
    return (jsxRuntimeExports.jsx(MenuGroup, { ref: ref, className: cx(styles.menugroup, className), render: shouldFilter ? jsxRuntimeExports.jsx(Fragment, {}) : asChild ? jsxRuntimeExports.jsx(Slot, {}) : undefined, ...props }));
});
const DropdownMenuLabel = forwardRef(({ className, asChild, ...props }, ref) => {
    const { shouldFilter } = useDropdownContext();
    if (shouldFilter) {
        return null;
    }
    return (jsxRuntimeExports.jsx(MenuGroupLabel, { ref: ref, className: cx(styles.label, className), render: asChild ? jsxRuntimeExports.jsx(Slot, {}) : undefined, ...props }));
});
const DropdownMenuSeparator = forwardRef(({ className, asChild, ...props }, ref) => {
    const { shouldFilter } = useDropdownContext();
    if (shouldFilter) {
        return null;
    }
    return (jsxRuntimeExports.jsx(MenuSeparator, { ref: ref, className: cx(styles.separator, className), render: asChild ? jsxRuntimeExports.jsx(Slot, {}) : undefined, ...props }));
});
const DropdownMenuEmptyState = forwardRef(({ className, children, ...props }, ref) => (jsxRuntimeExports.jsx("div", { ref: ref, className: cx(styles.empty, className), ...props, children: children })));

export { DropdownMenuEmptyState, DropdownMenuGroup, DropdownMenuLabel, DropdownMenuSeparator };
//# sourceMappingURL=dropdown-menu-misc.js.map
