const require_runtime = require("../../../../_virtual/_rolldown/runtime.js");
let react = require("react");
react = require_runtime.__toESM(react);
let _pisell_materials = require("@pisell/materials");
//#region src/components/ecocup/components/MoreDropdown/index.tsx
const MoreDropdown = (props) => {
	const { locales, onClick, buttonText, showFields = ["missing", "broken"] } = props;
	const menuItems = (0, react.useMemo)(() => {
		return [{
			key: "missing",
			label: locales.getText("pisell2.text.ecocup.action.more.missing"),
			hidden: !showFields.includes("missing")
		}, {
			key: "broken",
			label: locales.getText("pisell2.text.ecocup.action.more.broken"),
			hidden: !showFields.includes("broken")
		}];
	}, [locales, showFields]);
	return /* @__PURE__ */ react.default.createElement(_pisell_materials.Dropdown, {
		trigger: ["click", "hover"],
		menu: {
			items: menuItems.filter((item) => !item.hidden),
			onClick: (item) => {
				console.log(item, item.key, "---Dropdown");
				onClick && onClick(item.key);
			}
		}
	}, /* @__PURE__ */ react.default.createElement(_pisell_materials.Button, null, buttonText || locales.getText("pisell2.text.ecocup.action.more")));
};
//#endregion
exports.default = MoreDropdown;
