@deskhero/dh_ui 1.53.3 → 1.54.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/dh_ui.es.js +22 -6
- package/dist/dh_ui.umd.js +1 -1
- package/dist/src/components/Button.vue.d.ts +11 -0
- package/dist/style.css +1 -1
- package/package.json +1 -1
package/dist/dh_ui.es.js
CHANGED
|
@@ -23891,6 +23891,11 @@ const _sfc_main$m = /* @__PURE__ */ defineComponent({
|
|
|
23891
23891
|
type: Boolean,
|
|
23892
23892
|
required: false,
|
|
23893
23893
|
default: false
|
|
23894
|
+
},
|
|
23895
|
+
icon: {
|
|
23896
|
+
type: String,
|
|
23897
|
+
required: false,
|
|
23898
|
+
default: ""
|
|
23894
23899
|
}
|
|
23895
23900
|
},
|
|
23896
23901
|
setup(__props) {
|
|
@@ -23913,6 +23918,9 @@ const _sfc_main$m = /* @__PURE__ */ defineComponent({
|
|
|
23913
23918
|
const isSuccess = computed(() => {
|
|
23914
23919
|
return props.color === "success";
|
|
23915
23920
|
});
|
|
23921
|
+
const isGhost = computed(() => {
|
|
23922
|
+
return props.color === "ghost";
|
|
23923
|
+
});
|
|
23916
23924
|
return (_ctx, _cache) => {
|
|
23917
23925
|
return openBlock(), createElementBlock("button", {
|
|
23918
23926
|
class: normalizeClass({
|
|
@@ -23921,25 +23929,33 @@ const _sfc_main$m = /* @__PURE__ */ defineComponent({
|
|
|
23921
23929
|
"dh-btn-secondary": unref(isSecondary),
|
|
23922
23930
|
"dh-btn-danger": unref(isDanger),
|
|
23923
23931
|
"dh-btn-success": unref(isSuccess),
|
|
23932
|
+
"dh-btn-ghost": unref(isGhost),
|
|
23924
23933
|
"dh-btn-large": unref(isLarge),
|
|
23925
23934
|
"dh-btn-small": unref(isSmall),
|
|
23935
|
+
"dh-btn-icon": __props.icon,
|
|
23926
23936
|
disabled: __props.disabled
|
|
23927
23937
|
}),
|
|
23928
23938
|
disabled: __props.disabled || __props.loading
|
|
23929
23939
|
}, [
|
|
23930
|
-
__props.loading
|
|
23940
|
+
__props.loading ? (openBlock(), createBlock(DhIcon, {
|
|
23931
23941
|
key: 0,
|
|
23932
23942
|
class: normalizeClass({
|
|
23933
23943
|
"loading-spinner": true,
|
|
23934
23944
|
"loading-spinner-danger": unref(isDanger),
|
|
23935
23945
|
"loading-spinner-success": unref(isSuccess),
|
|
23936
|
-
"loading-spinner-secondary": unref(isSecondary)
|
|
23946
|
+
"loading-spinner-secondary": unref(isSecondary) || unref(isGhost)
|
|
23937
23947
|
}),
|
|
23938
23948
|
iconName: "loader"
|
|
23939
|
-
}, null, 8, ["class"])) : (
|
|
23949
|
+
}, null, 8, ["class"])) : createCommentVNode("", true),
|
|
23950
|
+
!__props.loading ? (openBlock(), createElementBlock("div", _hoisted_2$l, [
|
|
23940
23951
|
renderSlot(_ctx.$slots, "prepend-icon", {}, void 0, true)
|
|
23941
|
-
])),
|
|
23942
|
-
renderSlot(_ctx.$slots, "default", {}, void 0, true),
|
|
23952
|
+
])) : createCommentVNode("", true),
|
|
23953
|
+
!__props.icon ? renderSlot(_ctx.$slots, "default", { key: 2 }, void 0, true) : createCommentVNode("", true),
|
|
23954
|
+
__props.icon && !__props.loading ? (openBlock(), createBlock(DhIcon, {
|
|
23955
|
+
key: 3,
|
|
23956
|
+
"icon-name": __props.icon,
|
|
23957
|
+
size: 24
|
|
23958
|
+
}, null, 8, ["icon-name"])) : createCommentVNode("", true),
|
|
23943
23959
|
createElementVNode("div", _hoisted_3$c, [
|
|
23944
23960
|
renderSlot(_ctx.$slots, "append-icon", {}, void 0, true)
|
|
23945
23961
|
])
|
|
@@ -23947,7 +23963,7 @@ const _sfc_main$m = /* @__PURE__ */ defineComponent({
|
|
|
23947
23963
|
};
|
|
23948
23964
|
}
|
|
23949
23965
|
});
|
|
23950
|
-
var DhButton = /* @__PURE__ */ _export_sfc(_sfc_main$m, [["__scopeId", "data-v-
|
|
23966
|
+
var DhButton = /* @__PURE__ */ _export_sfc(_sfc_main$m, [["__scopeId", "data-v-1ec95209"]]);
|
|
23951
23967
|
const _sfc_main$l = defineComponent({
|
|
23952
23968
|
props: {
|
|
23953
23969
|
target: { type: String, required: true },
|