import { iconMap } from "../AppearanceEdit/constants.js";
import React, { useMemo } from "react";
import "./index.less";
//#region src/components/workSpaceList/components/AppearanceShow/index.tsx
const AppearanceShow = (props) => {
	const { color, icon, size = 20, fontSize = 14, name } = props;
	const Icon = useMemo(() => {
		return iconMap[icon];
	}, [icon]);
	return /* @__PURE__ */ React.createElement("div", {
		className: "appearance-wrap",
		style: {
			background: color || "#7F56D9",
			height: size,
			width: size,
			fontSize
		}
	}, Icon ? /* @__PURE__ */ React.createElement(Icon, null) : name === null || name === void 0 ? void 0 : name.slice(0, 2));
};
//#endregion
export { AppearanceShow as default };
