v-dashkit
Version:
This template should help get you started developing with Vue 3 in Vite.
62 lines (61 loc) • 1.68 kB
JavaScript
import { B as i, s as p } from "./basecomponent.esm-3611fa56.js";
import { openBlock as r, createElementBlock as o, mergeProps as s, createBlock as l, resolveDynamicComponent as c, createCommentVNode as t, renderSlot as u, createElementVNode as d, toDisplayString as v } from "vue";
var g = {
root: function(a) {
var n = a.props;
return ["p-tag p-component", {
"p-tag-info": n.severity === "info",
"p-tag-success": n.severity === "success",
"p-tag-warning": n.severity === "warning",
"p-tag-danger": n.severity === "danger",
"p-tag-secondary": n.severity === "secondary",
"p-tag-contrast": n.severity === "contrast",
"p-tag-rounded": n.rounded
}];
},
icon: "p-tag-icon",
value: "p-tag-value"
}, m = i.extend({
name: "tag",
classes: g
}), y = {
name: "BaseTag",
extends: p,
props: {
value: null,
severity: null,
rounded: Boolean,
icon: String
},
style: m,
provide: function() {
return {
$parentInstance: this
};
}
}, f = {
name: "Tag",
extends: y,
inheritAttrs: !1
};
function $(e, a, n, B, k, S) {
return r(), o("span", s({
class: e.cx("root")
}, e.ptmi("root")), [e.$slots.icon ? (r(), l(c(e.$slots.icon), s({
key: 0,
class: e.cx("icon")
}, e.ptm("icon")), null, 16, ["class"])) : e.icon ? (r(), o("span", s({
key: 1,
class: [e.cx("icon"), e.icon]
}, e.ptm("icon")), null, 16)) : t("", !0), e.value || e.$slots.default ? u(e.$slots, "default", {
key: 2
}, function() {
return [d("span", s({
class: e.cx("value")
}, e.ptm("value")), v(e.value), 17)];
}) : t("", !0)], 16);
}
f.render = $;
export {
f as s
};