UNPKG

quick-admin-vue3-core

Version:

以快(计算机执行效率、开发效率)为核心的后台管理系统开发模板

59 lines (58 loc) 2.25 kB
import { defineComponent as x, computed as d, resolveComponent as C, createElementBlock as p, createBlock as S, openBlock as r, mergeProps as g, renderSlot as v, createTextVNode as u, createCommentVNode as y, toDisplayString as l, Fragment as _, withCtx as b } from "vue"; import { u as D, i as k } from "./platform-DsTwHxm6.js"; import "./index-C0qRtkRj.js"; /* empty css */ import { u as E } from "./dict-C-wULPWV.js"; import { _ as V } from "./_plugin-vue_export-helper-CHgC5LLL.js"; const h = /* @__PURE__ */ x({ __name: "BaseTag", props: { name: { default: "D_EnableStatus" }, value: {}, pureText: { type: Boolean }, count: {}, empty: { default: D } }, setup(B) { const { getMap: T } = E(), c = B, a = d(() => { const { name: e, value: o } = c; if (k.includes(o)) return null; const t = T(e), n = t == null ? void 0 : t[o], s = typeof n; return s === "string" ? { text: n } : s === "undefined" ? { text: o } : n; }), m = d(() => { const { empty: e, value: o } = c, { text: t = o } = a.value ?? {}; return k.includes(t) ? e : t; }); return (e, o) => { var n, s, i, f; const t = C("el-tag"); return e.pureText || !a.value ? (r(), p("span", g({ key: 0, class: ["base-tag span m-2", ((s = (n = a.value) == null ? void 0 : n.attrs) == null ? void 0 : s.type) ?? "main"] }, (i = a.value) == null ? void 0 : i.attrs), [ v(e.$slots, "default", { tag: a.value }, () => [ u(l(m.value) + " ", 1), e.count ? (r(), p(_, { key: 0 }, [ u(":" + l(e.count), 1) ], 64)) : y("", !0) ], !0) ], 16)) : (r(), S(t, g({ key: 1, class: "base-tag m-2" }, (f = a.value) == null ? void 0 : f.attrs), { default: b(() => [ v(e.$slots, "default", { tag: a.value }, () => [ u(l(m.value) + " ", 1), e.count ? (r(), p(_, { key: 0 }, [ u(":" + l(e.count), 1) ], 64)) : y("", !0) ], !0) ]), _: 3 }, 16)); }; } }), j = /* @__PURE__ */ V(h, [["__scopeId", "data-v-ae9848c3"]]); export { j as default };