ideaz-element
Version:
<p align="center"> <a href="" target="_blank" rel="noopener noreferrer"> <img src="./docs/public/logo.svg" alt="Ideaz Element" width="180" style="width: 180px;" /> </a> </p>
32 lines (31 loc) • 1.34 kB
JavaScript
import "../../../../utils/index.mjs";
import "../../../../node_modules/.pnpm/lodash-unified@1.0.3_@types_lodash-es@4.17.12_lodash-es@4.17.21_lodash@4.17.21/node_modules/lodash-unified/import.mjs";
import { computed as d } from "vue";
import { isObject as m, isArray as n } from "../../../../utils/is.mjs";
import b from "../../../../node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/omit.mjs";
function x(t) {
const s = d(() => {
var i;
return m(t.detail) && n(t.detail.columns) ? t.detail.columns : m(t.form) && n(t.form.columns) && t.detail !== !1 ? t.form.columns.map((e) => ({
prop: e.field,
...e
})) : (i = t.columns) == null ? void 0 : i.filter((e) => e.detail || e.form && e.detail !== !1).map((e) => {
var r, l, a, o, f;
return {
label: ((r = e.detail) == null ? void 0 : r.label) || ((l = e.form) == null ? void 0 : l.label) || e.label,
prop: ((a = e.detail) == null ? void 0 : a.prop) || ((o = e.detail) == null ? void 0 : o.field) || ((f = e.form) == null ? void 0 : f.field),
...e.form,
...e.detail
};
});
}), u = d(() => ({
column: 1,
border: !0,
...b(t.detail || {}, ["columns"])
}));
return { descriptionColumns: s, descriptionProps: u };
}
export {
x as useDescriptions
};
//# sourceMappingURL=useDescriptions.mjs.map