import ButtonIcon from "../ButtonIcon/index.js";
import PopoverContent from "./PopoverContent.js";
import React, { useMemo } from "react";
import { Popover } from "antd";
import Rows01 from "@pisell/icon/es/Rows01";
//#region src/components/table/Actions/component/Group/index.tsx
const Group = (props) => {
	const { value, onChange, setting } = props;
	const { list } = setting;
	const content = useMemo(() => {
		return /* @__PURE__ */ React.createElement(PopoverContent, {
			columns: list,
			onChange,
			value
		});
	}, [list, value]);
	return /* @__PURE__ */ React.createElement(Popover, {
		content,
		arrow: false,
		placement: "bottomRight",
		trigger: "click"
	}, /* @__PURE__ */ React.createElement(ButtonIcon, { isActive: !!(value === null || value === void 0 ? void 0 : value.length) }, /* @__PURE__ */ React.createElement(Rows01, { style: {
		cursor: "pointer",
		fontSize: 18
	} })));
};
//#endregion
export { Group as default };
