import './pl-alert.css';/* empty css         */
import e from "../../utils/PlCloseModalBtn.js";
import { createBlock as t, createCommentVNode as n, createElementBlock as r, createElementVNode as i, defineComponent as a, normalizeClass as o, normalizeStyle as s, openBlock as c, renderSlot as l, toDisplayString as u } from "vue";
var d = {
	key: 0,
	class: "pl-alert__icon"
}, f = { class: "pl-alert__main" }, p = { key: 0 }, m = { class: "pl-alert__main__text" }, h = /* @__PURE__ */ a({
	name: "PlAlert",
	props: {
		modelValue: {
			type: Boolean,
			default: !0
		},
		type: { default: void 0 },
		label: { default: void 0 },
		icon: {
			type: Boolean,
			default: void 0
		},
		closeable: {
			type: Boolean,
			default: void 0
		},
		monospace: {
			type: Boolean,
			default: void 0
		},
		whiteSpacePre: {
			type: Boolean,
			default: void 0
		},
		maxHeight: { default: void 0 }
	},
	emits: ["update:modelValue"],
	setup(a) {
		let h = {
			success: "success",
			warn: "warning",
			info: "edit",
			error: "error"
		};
		return (g, _) => a.modelValue ? (c(), r("div", {
			key: 0,
			class: o(["pl-alert", [{
				monospace: a.monospace,
				whiteSpacePre: a.whiteSpacePre
			}, a.type ? `pl-alert__${a.type}` : ""]]),
			style: s({ maxHeight: a.maxHeight })
		}, [
			a.icon && a.type ? (c(), r("div", d, [i("div", { class: o(`icon-24 icon-${h[a.type]}`) }, null, 2)])) : n("", !0),
			i("div", f, [a.label ? (c(), r("label", p, u(a.label), 1)) : n("", !0), i("div", m, [l(g.$slots, "default")])]),
			a.closeable ? (c(), t(e, {
				key: 1,
				class: "pl-alert__close-btn",
				onClick: _[0] ||= (e) => g.$emit("update:modelValue", !1)
			})) : n("", !0)
		], 6)) : n("", !0);
	}
});
export { h as default };

//# sourceMappingURL=PlAlert.vue2.js.map