import { jsx as u } from "react/jsx-runtime";
import { MenuItem as M } from "./index-MenuItem.js";
import "react";
import j from "./index-Menu.module.scss.js";
import z from "./index-Menu2.js";
const k = ({
  testId: c,
  items: p,
  children: f,
  width: r,
  height: s,
  maxWidth: t,
  maxHeight: e,
  ...o
}) => {
  var n, m, a;
  const l = r || s || t || e ? {
    width: r,
    height: s,
    maxWidth: t,
    maxHeight: e
  } : void 0, P = l ? {
    paper: {
      style: {
        ...l,
        ...(m = (n = o.slotProps) == null ? void 0 : n.paper) == null ? void 0 : m.style
      },
      ...(a = o.slotProps) == null ? void 0 : a.paper
    }
  } : o.slotProps;
  return u(z, {
    "data-testid": c,
    ...o,
    slotProps: P,
    className: j.menu,
    children: p ? p.map(({
      key: i,
      ...y
    }, d) => u(M, {
      ...y
    }, i ?? d)) : f
  });
};
export {
  k as Menu
};
