UNPKG

@aplus-frontend/ui

Version:

30 lines (29 loc) 677 B
import { useSlots as n, computed as s } from "vue"; import { genRealChildren as l } from "../../ap-form/item-group/helper.mjs"; function u(o) { if (o && typeof o == "object") return { ...o, showCollapsibleIcon: o.showCollapsibleIcon === void 0 ? "auto" : o.showCollapsibleIcon }; const t = !!o || o === ""; return { start: t, end: t, showCollapsibleIcon: "auto" }; } const d = () => { const o = n(); return s(() => o.default ? l(o.default()).map((e) => { const { props: r } = e; return { ...r, collapsible: u(r?.collapsible), _child: e.children.default?.() }; }) : []); }; export { d as useItems };