@deskhero/dh_ui 1.29.2 → 1.29.3
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 +59 -39
- package/dist/dh_ui.umd.js +3 -3
- package/dist/src/components/DropdownMenu.vue.d.ts +33 -0
- package/dist/style.css +1 -1
- package/package.json +1 -1
package/dist/dh_ui.es.js
CHANGED
|
@@ -70,7 +70,7 @@ const _sfc_main$i = defineComponent({
|
|
|
70
70
|
});
|
|
71
71
|
const _hoisted_1$h = { class: "dh-advanced-filter-container" };
|
|
72
72
|
const _hoisted_2$d = { class: "advance_section" };
|
|
73
|
-
const _hoisted_3$
|
|
73
|
+
const _hoisted_3$9 = {
|
|
74
74
|
key: 0,
|
|
75
75
|
class: "list-none"
|
|
76
76
|
};
|
|
@@ -91,7 +91,7 @@ function _sfc_render$8(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
91
91
|
size: 20
|
|
92
92
|
}, null, 8, ["icon-name"])
|
|
93
93
|
]),
|
|
94
|
-
_ctx.activeFilter ? (openBlock(), createElementBlock("ul", _hoisted_3$
|
|
94
|
+
_ctx.activeFilter ? (openBlock(), createElementBlock("ul", _hoisted_3$9, [
|
|
95
95
|
createElementVNode("li", null, [
|
|
96
96
|
createElementVNode("label", null, [
|
|
97
97
|
createElementVNode("input", {
|
|
@@ -10949,7 +10949,7 @@ const _hoisted_2$c = /* @__PURE__ */ createElementVNode("label", { for: "upload_
|
|
|
10949
10949
|
/* @__PURE__ */ createTextVNode(" Drag and drop file or "),
|
|
10950
10950
|
/* @__PURE__ */ createElementVNode("span", { id: "upload" }, "browse")
|
|
10951
10951
|
], -1);
|
|
10952
|
-
const _hoisted_3$
|
|
10952
|
+
const _hoisted_3$8 = {
|
|
10953
10953
|
key: 0,
|
|
10954
10954
|
class: "file__upload_items"
|
|
10955
10955
|
};
|
|
@@ -11055,7 +11055,7 @@ const _sfc_main$e = {
|
|
|
11055
11055
|
onInput: _cache[0] || (_cache[0] = ($event) => uploadFile($event))
|
|
11056
11056
|
}, null, 544)
|
|
11057
11057
|
], 32),
|
|
11058
|
-
fileSelected.value ? (openBlock(), createElementBlock("div", _hoisted_3$
|
|
11058
|
+
fileSelected.value ? (openBlock(), createElementBlock("div", _hoisted_3$8, [
|
|
11059
11059
|
(openBlock(true), createElementBlock(Fragment, null, renderList(files.value, (file, id) => {
|
|
11060
11060
|
return openBlock(), createElementBlock("div", {
|
|
11061
11061
|
key: id,
|
|
@@ -11162,7 +11162,7 @@ const _hoisted_2$b = {
|
|
|
11162
11162
|
id: "modalTitle",
|
|
11163
11163
|
class: "modal-header"
|
|
11164
11164
|
};
|
|
11165
|
-
const _hoisted_3$
|
|
11165
|
+
const _hoisted_3$7 = { class: "modal-footer" };
|
|
11166
11166
|
function _sfc_render$6(_ctx, _cache, $props, $setup, $data, $options) {
|
|
11167
11167
|
const _component_dh_icon = resolveComponent("dh-icon");
|
|
11168
11168
|
return openBlock(), createBlock(Transition, { name: "modal-fade" }, {
|
|
@@ -11208,7 +11208,7 @@ function _sfc_render$6(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
11208
11208
|
}, [
|
|
11209
11209
|
renderSlot(_ctx.$slots, "body")
|
|
11210
11210
|
], 2),
|
|
11211
|
-
createElementVNode("footer", _hoisted_3$
|
|
11211
|
+
createElementVNode("footer", _hoisted_3$7, [
|
|
11212
11212
|
_ctx.hasFooter ? renderSlot(_ctx.$slots, "footer", { key: 0 }) : createCommentVNode("", true),
|
|
11213
11213
|
_ctx.hasFooterButtonRight ? renderSlot(_ctx.$slots, "footer-button-right", { key: 1 }) : createCommentVNode("", true)
|
|
11214
11214
|
])
|
|
@@ -11303,7 +11303,7 @@ const _hoisted_1$b = /* @__PURE__ */ createElementVNode("img", {
|
|
|
11303
11303
|
const _hoisted_2$a = [
|
|
11304
11304
|
_hoisted_1$b
|
|
11305
11305
|
];
|
|
11306
|
-
const _hoisted_3$
|
|
11306
|
+
const _hoisted_3$6 = ["src"];
|
|
11307
11307
|
const _hoisted_4$4 = { class: "additional-text" };
|
|
11308
11308
|
const _hoisted_5$2 = {
|
|
11309
11309
|
key: 0,
|
|
@@ -11332,7 +11332,7 @@ function _sfc_render$5(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
11332
11332
|
createElementVNode("img", {
|
|
11333
11333
|
class: normalizeClass(`icons icons-${_ctx.status} icons-${_ctx.status}-${_ctx.notificationType}`),
|
|
11334
11334
|
src: _ctx.getIconUrl()
|
|
11335
|
-
}, null, 10, _hoisted_3$
|
|
11335
|
+
}, null, 10, _hoisted_3$6)
|
|
11336
11336
|
], 2),
|
|
11337
11337
|
createElementVNode("div", _hoisted_4$4, [
|
|
11338
11338
|
createElementVNode("div", {
|
|
@@ -23556,7 +23556,7 @@ const _sfc_main$b = {
|
|
|
23556
23556
|
};
|
|
23557
23557
|
const _hoisted_1$a = { class: "bar" };
|
|
23558
23558
|
const _hoisted_2$9 = ["min", "max", "step", "value"];
|
|
23559
|
-
const _hoisted_3$
|
|
23559
|
+
const _hoisted_3$5 = { class: "caption" };
|
|
23560
23560
|
const _hoisted_4$3 = { class: "min-caption" };
|
|
23561
23561
|
const _hoisted_5$1 = { class: "bar-inner" };
|
|
23562
23562
|
const _hoisted_6$1 = ["min", "max", "step", "value"];
|
|
@@ -23599,7 +23599,7 @@ function _sfc_render$4(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
23599
23599
|
onMousedown: _cache[2] || (_cache[2] = (...args) => $options.onLeftThumbMousedown && $options.onLeftThumbMousedown(...args)),
|
|
23600
23600
|
onTouchstart: _cache[3] || (_cache[3] = (...args) => $options.onLeftThumbMousedown && $options.onLeftThumbMousedown(...args))
|
|
23601
23601
|
}, [
|
|
23602
|
-
createElementVNode("div", _hoisted_3$
|
|
23602
|
+
createElementVNode("div", _hoisted_3$5, [
|
|
23603
23603
|
createElementVNode("span", _hoisted_4$3, toDisplayString($props.minCaption || $options.barMinVal), 1)
|
|
23604
23604
|
])
|
|
23605
23605
|
], 32),
|
|
@@ -23916,7 +23916,7 @@ const _sfc_main$a = defineComponent({
|
|
|
23916
23916
|
});
|
|
23917
23917
|
const _hoisted_1$9 = { class: "dh-range-container" };
|
|
23918
23918
|
const _hoisted_2$8 = { class: "bar-chart" };
|
|
23919
|
-
const _hoisted_3$
|
|
23919
|
+
const _hoisted_3$4 = { class: "input-group-section" };
|
|
23920
23920
|
const _hoisted_4$2 = { class: "input-group sb-input" };
|
|
23921
23921
|
const _hoisted_5 = ["disabled", "max", "value"];
|
|
23922
23922
|
const _hoisted_6 = { class: "input-group sb-input" };
|
|
@@ -23973,7 +23973,7 @@ function _sfc_render$3(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
23973
23973
|
onInput: _ctx.updateBarChart
|
|
23974
23974
|
}, null, 8, ["base-class-name", "max", "max-caption", "max-value", "min-caption", "min-value", "step", "onInput"])
|
|
23975
23975
|
]),
|
|
23976
|
-
createElementVNode("div", _hoisted_3$
|
|
23976
|
+
createElementVNode("div", _hoisted_3$4, [
|
|
23977
23977
|
createElementVNode("div", _hoisted_4$2, [
|
|
23978
23978
|
createElementVNode("label", {
|
|
23979
23979
|
class: normalizeClass(`text-2 input-to ${_ctx.validated ? "disable" : ""}`)
|
|
@@ -24055,7 +24055,7 @@ var NumberRange = /* @__PURE__ */ _export_sfc(_sfc_main$a, [["render", _sfc_rend
|
|
|
24055
24055
|
var PasswordField_vue_vue_type_style_index_0_scoped_true_lang = "";
|
|
24056
24056
|
const _hoisted_1$8 = { class: "password__panel" };
|
|
24057
24057
|
const _hoisted_2$7 = ["placeholder", "type"];
|
|
24058
|
-
const _hoisted_3$
|
|
24058
|
+
const _hoisted_3$3 = { class: "icon is-right" };
|
|
24059
24059
|
const _hoisted_4$1 = {
|
|
24060
24060
|
key: 0,
|
|
24061
24061
|
class: "password__tooltip"
|
|
@@ -24134,7 +24134,7 @@ const _sfc_main$9 = /* @__PURE__ */ defineComponent({
|
|
|
24134
24134
|
type: "button",
|
|
24135
24135
|
onClick: toggleShow
|
|
24136
24136
|
}, [
|
|
24137
|
-
createElementVNode("span", _hoisted_3$
|
|
24137
|
+
createElementVNode("span", _hoisted_3$3, [
|
|
24138
24138
|
createVNode(DhIcon, {
|
|
24139
24139
|
active: isActive.value,
|
|
24140
24140
|
"icon-name": showPassword.value ? "invisible" : "visible",
|
|
@@ -24182,7 +24182,7 @@ var PasswordField = /* @__PURE__ */ _export_sfc(_sfc_main$9, [["__scopeId", "dat
|
|
|
24182
24182
|
var RadioBox_vue_vue_type_style_index_0_scoped_true_lang = "";
|
|
24183
24183
|
const _hoisted_1$7 = { class: "radio" };
|
|
24184
24184
|
const _hoisted_2$6 = ["for"];
|
|
24185
|
-
const _hoisted_3$
|
|
24185
|
+
const _hoisted_3$2 = ["id", "type", "value"];
|
|
24186
24186
|
const _hoisted_4 = { class: "radio__label_txt" };
|
|
24187
24187
|
const _sfc_main$8 = {
|
|
24188
24188
|
__name: "RadioBox",
|
|
@@ -24215,7 +24215,7 @@ const _sfc_main$8 = {
|
|
|
24215
24215
|
type: __props.type,
|
|
24216
24216
|
value: __props.value,
|
|
24217
24217
|
onClick: _cache[0] || (_cache[0] = ($event) => emit("clickBox"))
|
|
24218
|
-
}, null, 8, _hoisted_3$
|
|
24218
|
+
}, null, 8, _hoisted_3$2),
|
|
24219
24219
|
createElementVNode("span", _hoisted_4, toDisplayString(__props.label), 1)
|
|
24220
24220
|
], 8, _hoisted_2$6)
|
|
24221
24221
|
]);
|
|
@@ -24416,7 +24416,7 @@ const _sfc_main$4 = defineComponent({
|
|
|
24416
24416
|
});
|
|
24417
24417
|
const _hoisted_1$4 = { class: "dp__options" };
|
|
24418
24418
|
const _hoisted_2$3 = { class: "dp__options_switch" };
|
|
24419
|
-
const _hoisted_3$
|
|
24419
|
+
const _hoisted_3$1 = /* @__PURE__ */ createElementVNode("span", { class: "dp__options_slider" }, null, -1);
|
|
24420
24420
|
function _sfc_render$2(_ctx, _cache, $props, $setup, $data, $options) {
|
|
24421
24421
|
return openBlock(), createElementBlock("div", _hoisted_1$4, [
|
|
24422
24422
|
createElementVNode("span", null, toDisplayString(_ctx.label), 1),
|
|
@@ -24428,7 +24428,7 @@ function _sfc_render$2(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
24428
24428
|
}, null, 512), [
|
|
24429
24429
|
[vModelCheckbox, _ctx.checkedValue]
|
|
24430
24430
|
]),
|
|
24431
|
-
_hoisted_3$
|
|
24431
|
+
_hoisted_3$1
|
|
24432
24432
|
])
|
|
24433
24433
|
]);
|
|
24434
24434
|
}
|
|
@@ -24464,7 +24464,7 @@ const _sfc_main$3 = defineComponent({
|
|
|
24464
24464
|
});
|
|
24465
24465
|
const _hoisted_1$3 = ["placement", "target", "tooltipText", "trigger"];
|
|
24466
24466
|
const _hoisted_2$2 = ["id"];
|
|
24467
|
-
const _hoisted_3
|
|
24467
|
+
const _hoisted_3 = { class: "text" };
|
|
24468
24468
|
function _sfc_render$1(_ctx, _cache, $props, $setup, $data, $options) {
|
|
24469
24469
|
return openBlock(), createElementBlock("div", {
|
|
24470
24470
|
id: "main-contain",
|
|
@@ -24483,7 +24483,7 @@ function _sfc_render$1(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
24483
24483
|
ref: _ctx.target,
|
|
24484
24484
|
class: normalizeClass(`tooltiptext ${_ctx.show}`)
|
|
24485
24485
|
}, [
|
|
24486
|
-
createElementVNode("span", _hoisted_3
|
|
24486
|
+
createElementVNode("span", _hoisted_3, toDisplayString(_ctx.tooltipText), 1)
|
|
24487
24487
|
], 10, _hoisted_2$2)
|
|
24488
24488
|
], 40, _hoisted_1$3);
|
|
24489
24489
|
}
|
|
@@ -24758,12 +24758,8 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
24758
24758
|
}
|
|
24759
24759
|
var ExpansionPanel = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["render", _sfc_render]]);
|
|
24760
24760
|
var DropdownMenu_vue_vue_type_style_index_0_scoped_true_lang = "";
|
|
24761
|
-
const _hoisted_1 =
|
|
24762
|
-
|
|
24763
|
-
"data-id": "dropdown-menu"
|
|
24764
|
-
};
|
|
24765
|
-
const _hoisted_2 = ["src"];
|
|
24766
|
-
const _hoisted_3 = {
|
|
24761
|
+
const _hoisted_1 = ["src"];
|
|
24762
|
+
const _hoisted_2 = {
|
|
24767
24763
|
key: 3,
|
|
24768
24764
|
class: "menu-item-text-wrapper"
|
|
24769
24765
|
};
|
|
@@ -24783,6 +24779,21 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
24783
24779
|
type: Number,
|
|
24784
24780
|
required: false,
|
|
24785
24781
|
default: 24
|
|
24782
|
+
},
|
|
24783
|
+
closeOnClickOutside: {
|
|
24784
|
+
type: Boolean,
|
|
24785
|
+
required: false,
|
|
24786
|
+
default: true
|
|
24787
|
+
},
|
|
24788
|
+
zIndex: {
|
|
24789
|
+
type: Number,
|
|
24790
|
+
required: false,
|
|
24791
|
+
default: 100
|
|
24792
|
+
},
|
|
24793
|
+
closeOnItemSelected: {
|
|
24794
|
+
type: Boolean,
|
|
24795
|
+
required: false,
|
|
24796
|
+
default: true
|
|
24786
24797
|
}
|
|
24787
24798
|
},
|
|
24788
24799
|
emits: ["itemSelected", "close"],
|
|
@@ -24790,25 +24801,34 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
24790
24801
|
const props = __props;
|
|
24791
24802
|
onMounted(() => {
|
|
24792
24803
|
document.addEventListener("click", (event) => {
|
|
24793
|
-
|
|
24794
|
-
const dropdownToggle = document.querySelector(".dropdown-toggle");
|
|
24795
|
-
if (dropdownMenu && !dropdownMenu.contains(event.target) && !dropdownToggle.contains(event.target)) {
|
|
24796
|
-
emit("close");
|
|
24797
|
-
}
|
|
24804
|
+
closeOnClickOutside(event);
|
|
24798
24805
|
});
|
|
24799
24806
|
});
|
|
24807
|
+
function closeOnClickOutside(event) {
|
|
24808
|
+
const target = event.target;
|
|
24809
|
+
const dropdownMenu = document.querySelector("[data-id='dropdown-menu']");
|
|
24810
|
+
if (dropdownMenu && !dropdownMenu.contains(event.target) && !target.classList.contains("dropdown-toggle") && props.closeOnClickOutside) {
|
|
24811
|
+
emit("close");
|
|
24812
|
+
}
|
|
24813
|
+
}
|
|
24800
24814
|
function itemSelected(item) {
|
|
24801
24815
|
emit("itemSelected", item);
|
|
24802
|
-
|
|
24816
|
+
if (props.closeOnItemSelected) {
|
|
24817
|
+
emit("close");
|
|
24818
|
+
}
|
|
24803
24819
|
}
|
|
24804
24820
|
return (_ctx, _cache) => {
|
|
24805
24821
|
const _component_router_link = resolveComponent("router-link");
|
|
24806
|
-
return openBlock(), createElementBlock("div",
|
|
24822
|
+
return openBlock(), createElementBlock("div", {
|
|
24823
|
+
class: "dropdown-menu",
|
|
24824
|
+
"data-id": "dropdown-menu",
|
|
24825
|
+
style: normalizeStyle({ "z-index": props.zIndex })
|
|
24826
|
+
}, [
|
|
24807
24827
|
(openBlock(true), createElementBlock(Fragment, null, renderList(__props.items, (item) => {
|
|
24808
24828
|
return openBlock(), createBlock(_component_router_link, {
|
|
24809
24829
|
key: item.iconName,
|
|
24810
24830
|
class: "menu-item",
|
|
24811
|
-
"data-e2e":
|
|
24831
|
+
"data-e2e": item.dataE2eTag,
|
|
24812
24832
|
to: { path: item.url },
|
|
24813
24833
|
onClick: ($event) => itemSelected(item)
|
|
24814
24834
|
}, {
|
|
@@ -24818,7 +24838,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
24818
24838
|
alt: "icon image",
|
|
24819
24839
|
class: "icon icon-url",
|
|
24820
24840
|
src: item.iconUrl
|
|
24821
|
-
}, null, 8,
|
|
24841
|
+
}, null, 8, _hoisted_1)) : createCommentVNode("", true),
|
|
24822
24842
|
!item.iconUrl ? (openBlock(), createBlock(DhIcon, mergeProps({
|
|
24823
24843
|
key: 1,
|
|
24824
24844
|
class: "icon"
|
|
@@ -24827,7 +24847,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
24827
24847
|
key: 2,
|
|
24828
24848
|
class: normalizeClass(["text-2", { "text-ellipsis": props.textEllipsis }])
|
|
24829
24849
|
}, toDisplayString(item.text), 3)) : createCommentVNode("", true),
|
|
24830
|
-
item.subText ? (openBlock(), createElementBlock("div",
|
|
24850
|
+
item.subText ? (openBlock(), createElementBlock("div", _hoisted_2, [
|
|
24831
24851
|
createElementVNode("span", {
|
|
24832
24852
|
class: normalizeClass(["text-4", { "text-ellipsis": props.textEllipsis }])
|
|
24833
24853
|
}, toDisplayString(item.text), 3),
|
|
@@ -24843,11 +24863,11 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
24843
24863
|
})) : createCommentVNode("", true)
|
|
24844
24864
|
]),
|
|
24845
24865
|
_: 2
|
|
24846
|
-
}, 1032, ["to", "onClick"]);
|
|
24866
|
+
}, 1032, ["data-e2e", "to", "onClick"]);
|
|
24847
24867
|
}), 128))
|
|
24848
|
-
]);
|
|
24868
|
+
], 4);
|
|
24849
24869
|
};
|
|
24850
24870
|
}
|
|
24851
24871
|
});
|
|
24852
|
-
var DropdownMenu = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-
|
|
24872
|
+
var DropdownMenu = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-3f98d032"]]);
|
|
24853
24873
|
export { AdvancedFilter as DhAdvancedFilter, _sfc_main$g as DhDatePicker, DropdownMenu as DhDropdownMenu, _sfc_main$f as DhError, ExpansionPanel as DhExpansionPanel, _sfc_main$e as DhFileUpload, DhIcon, Modal as DhModal, Notification as DhNotification, NumberRange as DhNumberRange, PasswordField as DhPasswordField, DhRadioBox, _sfc_main$7 as DhRadioBoxGroup, SearchInput as DhSearchInput, Stepper as DhStepper, Switch as DhSwitch, Tooltip as DhTooltip, VerificationCode as DhVerificationCode };
|