import e from "./StackedRow.js";
import t from "./Legends.js";
import { computed as n, createBlock as r, createCommentVNode as i, createElementBlock as a, createVNode as o, defineComponent as s, normalizeClass as c, openBlock as l, toDisplayString as u } from "vue";
var d = /* @__PURE__ */ s({
	__name: "PlChartStackedBar",
	props: { settings: {} },
	setup(s) {
		let d = s, f = n(() => d.settings.showLegends ?? !0), p = n(() => d.settings.data ?? []), m = n(() => p.value.map((e) => ({
			color: e.color,
			text: e.label
		})));
		return (n, d) => (l(), a("div", { class: c(n.$style.component) }, [
			s.settings.title ? (l(), a("div", {
				key: 0,
				class: c(n.$style.title)
			}, u(s.settings.title), 3)) : i("", !0),
			o(e, { value: p.value }, null, 8, ["value"]),
			f.value && m.value.length ? (l(), r(t, {
				key: 1,
				legends: m.value,
				"max-in-column": s.settings.maxLegendsInColumn
			}, null, 8, ["legends", "max-in-column"])) : i("", !0)
		], 2));
	}
});
export { d as default };

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