const require_runtime = require("../../_virtual/_rolldown/runtime.js");
const require_index = require("../pisellCard/index.js");
const require_index$1 = require("../icon/index.js");
const require_index$2 = require("../pisellTags/index.js");
const require_index$3 = require("../pisellAvatar/index.js");
let react = require("react");
react = require_runtime.__toESM(react);
let antd = require("antd");
let classnames = require("classnames");
classnames = require_runtime.__toESM(classnames);
require("./PisellAppCard.less");
//#region src/components/pisellAppCard/PisellAppCard.tsx
const PisellAppCard = ({ className, style, avatar, tags, title, description, bottomButtons, moreActions, icon }) => {
	return /* @__PURE__ */ react.default.createElement(require_index.default, {
		className: (0, classnames.default)("pisell-lowcode-app-card", className),
		style
	}, /* @__PURE__ */ react.default.createElement("div", { className: "pisell-lowcode-app-card-header" }, /* @__PURE__ */ react.default.createElement("div", { className: "pisell-lowcode-app-card-header-left" }, (avatar || icon) && /* @__PURE__ */ react.default.createElement(require_index$3.default, {
		icon: icon && /* @__PURE__ */ react.default.createElement(require_index$1.default, { type: icon }),
		src: avatar || void 0,
		alt: title,
		size: "xl",
		shape: "square",
		style: { border: "none" },
		borderRadius: 10
	})), /* @__PURE__ */ react.default.createElement("div", null, moreActions && moreActions.length > 0 && /* @__PURE__ */ react.default.createElement(antd.Dropdown, {
		menu: { items: moreActions.map((action, index) => ({
			key: index,
			label: action.label,
			onClick: action.onClick
		})) },
		placement: "bottomRight",
		trigger: ["click"]
	}, /* @__PURE__ */ react.default.createElement(antd.Button, {
		icon: /* @__PURE__ */ react.default.createElement(require_index$1.default, { type: "pisell2-dots-vertical" }),
		size: "large"
	})))), /* @__PURE__ */ react.default.createElement("div", { className: "pisell-lowcode-app-card-content" }, tags && tags.length > 0 && /* @__PURE__ */ react.default.createElement("div", { className: "pisell-lowcode-app-card-content-tags" }, tags.map((tag, index) => /* @__PURE__ */ react.default.createElement(require_index$2.default, {
		key: index,
		type: tag.type,
		color: tag.color
	}, tag.label))), /* @__PURE__ */ react.default.createElement("div", null, /* @__PURE__ */ react.default.createElement("div", { className: "pisell-lowcode-app-card-content-title" }, title), description && /* @__PURE__ */ react.default.createElement("div", { className: "pisell-lowcode-app-card-content-description" }, description))), bottomButtons && bottomButtons.length > 0 && /* @__PURE__ */ react.default.createElement("div", { className: "pisell-lowcode-app-card-footer" }, bottomButtons.map((button, index) => !button.hidden && /* @__PURE__ */ react.default.createElement(antd.Button, {
		type: button.type,
		onClick: button.onClick,
		key: index,
		size: "large"
	}, button.label))));
};
//#endregion
exports.default = PisellAppCard;
