@touchvue/plugin 1.0.0-beta.3 → 1.0.0-beta.5
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/components/echarts-bar/src/echarts-bar.d.ts +28 -0
- package/components/echarts-bar/src/echarts-bar.vue.d.ts +46 -1
- package/components/echarts-map/src/echarts-map.d.ts +16 -0
- package/components/echarts-map/src/echarts-map.vue.d.ts +36 -0
- package/index.cjs +4 -2
- package/index.mjs +303 -166
- package/package.json +6 -2
- package/style/style.css +1 -1
package/index.mjs
CHANGED
|
@@ -5,7 +5,6 @@ var __publicField = (obj, key, value) => {
|
|
|
5
5
|
return value;
|
|
6
6
|
};
|
|
7
7
|
import { defineComponent, ref, computed, resolveComponent, resolveDirective, withDirectives, openBlock, createElementBlock, normalizeClass, normalizeStyle, createBlock, createCommentVNode, createElementVNode, renderSlot, getCurrentInstance, nextTick, render, createVNode, inject, watch, unref, withKeys, vShow, toDisplayString, Fragment, renderList, vModelSelect, createTextVNode, withCtx, withModifiers, onMounted, useSlots, onBeforeUnmount, provide, vModelText, vModelDynamic, isVNode, useAttrs, resolveDynamicComponent, mergeProps, h, isRef, reactive, createSlots, normalizeProps, guardReactiveProps, onDeactivated, onActivated, Transition, onUnmounted, useCssVars, markRaw, toRaw } from "vue";
|
|
8
|
-
import tinymce from "tinymce";
|
|
9
8
|
const withInstall = (main, extra) => {
|
|
10
9
|
main.install = (app) => {
|
|
11
10
|
for (const comp of [main, ...Object.values(extra != null ? extra : {})]) {
|
|
@@ -9437,9 +9436,10 @@ const _sfc_main$Y = /* @__PURE__ */ defineComponent({
|
|
|
9437
9436
|
title: { default: "" },
|
|
9438
9437
|
color: { default: "" },
|
|
9439
9438
|
mode: { default: "default" },
|
|
9439
|
+
link: { type: Boolean, default: false },
|
|
9440
9440
|
position: { default: "left" }
|
|
9441
9441
|
},
|
|
9442
|
-
emits: ["back"],
|
|
9442
|
+
emits: ["back", "click"],
|
|
9443
9443
|
setup(__props, { emit: __emit }) {
|
|
9444
9444
|
const instance = getCurrentInstance();
|
|
9445
9445
|
const elRef = ref(null);
|
|
@@ -9464,6 +9464,9 @@ const _sfc_main$Y = /* @__PURE__ */ defineComponent({
|
|
|
9464
9464
|
if (props.mode) {
|
|
9465
9465
|
arr.push(`mode-${props.mode}`);
|
|
9466
9466
|
}
|
|
9467
|
+
if (props.link) {
|
|
9468
|
+
arr.push(`is-link`);
|
|
9469
|
+
}
|
|
9467
9470
|
if (props.position) {
|
|
9468
9471
|
arr.push(`position-${props.position}`);
|
|
9469
9472
|
}
|
|
@@ -9477,7 +9480,8 @@ const _sfc_main$Y = /* @__PURE__ */ defineComponent({
|
|
|
9477
9480
|
return openBlock(), createElementBlock("div", {
|
|
9478
9481
|
ref_key: "elRef",
|
|
9479
9482
|
ref: elRef,
|
|
9480
|
-
class: normalizeClass(["to-header", setClass.value])
|
|
9483
|
+
class: normalizeClass(["to-header", setClass.value]),
|
|
9484
|
+
onClick: ($event) => emit("click")
|
|
9481
9485
|
}, [
|
|
9482
9486
|
unref(slots).left || Boolean(hasBack.value) && props.position === "center" ? (openBlock(), createElementBlock("div", {
|
|
9483
9487
|
key: 0,
|
|
@@ -9600,7 +9604,7 @@ const _sfc_main$Y = /* @__PURE__ */ defineComponent({
|
|
|
9600
9604
|
}, [
|
|
9601
9605
|
renderSlot(_ctx.$slots, "right")
|
|
9602
9606
|
])) : createCommentVNode("", true)
|
|
9603
|
-
],
|
|
9607
|
+
], 10, ["onClick"]);
|
|
9604
9608
|
};
|
|
9605
9609
|
}
|
|
9606
9610
|
});
|
|
@@ -9795,7 +9799,7 @@ const _sfc_main$X = /* @__PURE__ */ defineComponent({
|
|
|
9795
9799
|
default: false
|
|
9796
9800
|
}
|
|
9797
9801
|
},
|
|
9798
|
-
emits: ["update:modelValue", "click", "clear", "input", "keyup", "change", "keydown", "cut", "paste", "keypress", "focus", "blur"],
|
|
9802
|
+
emits: ["update:modelValue", "click", "clear", "input", "keyup", "change", "keydown", "cut", "paste", "keypress", "focus", "blur", "enter", "ctrlenter"],
|
|
9799
9803
|
setup(__props, { expose: __expose, emit: __emit }) {
|
|
9800
9804
|
const props = __props;
|
|
9801
9805
|
const emit = __emit;
|
|
@@ -10039,6 +10043,12 @@ const _sfc_main$X = /* @__PURE__ */ defineComponent({
|
|
|
10039
10043
|
function inputInput() {
|
|
10040
10044
|
emit("input", data.value);
|
|
10041
10045
|
}
|
|
10046
|
+
function inputEnter() {
|
|
10047
|
+
emit("enter", data.value);
|
|
10048
|
+
}
|
|
10049
|
+
function inputCtrlEnter() {
|
|
10050
|
+
emit("ctrlenter", data.value);
|
|
10051
|
+
}
|
|
10042
10052
|
function clear() {
|
|
10043
10053
|
data.value = "";
|
|
10044
10054
|
clearVisible.value = false;
|
|
@@ -10124,7 +10134,12 @@ const _sfc_main$X = /* @__PURE__ */ defineComponent({
|
|
|
10124
10134
|
readonly: __props.readonly,
|
|
10125
10135
|
tabindex: props.tabindex,
|
|
10126
10136
|
onKeyup: inputKeyup,
|
|
10127
|
-
onKeydown:
|
|
10137
|
+
onKeydown: [
|
|
10138
|
+
withModifiers(inputKeydown, ["exact"]),
|
|
10139
|
+
withKeys(withModifiers(inputEnter, ["exact"]), ["enter"]),
|
|
10140
|
+
withKeys(withModifiers(inputCtrlEnter, ["ctrl", "exact"]), ["enter"]),
|
|
10141
|
+
withKeys(withModifiers(inputCtrlEnter, ["meta", "exact"]), ["enter"])
|
|
10142
|
+
],
|
|
10128
10143
|
onCut: inputCut,
|
|
10129
10144
|
onFocus: inputFocus,
|
|
10130
10145
|
onBlur: inputBlur,
|
|
@@ -10132,7 +10147,7 @@ const _sfc_main$X = /* @__PURE__ */ defineComponent({
|
|
|
10132
10147
|
onKeypress: inputKeyPress,
|
|
10133
10148
|
onChange: inputChange,
|
|
10134
10149
|
onInput: inputInput
|
|
10135
|
-
}, null, 40, ["onUpdate:modelValue", "autocomplete", "maxlength", "placeholder", "disabled", "readonly", "tabindex"])), [
|
|
10150
|
+
}, null, 40, ["onUpdate:modelValue", "autocomplete", "maxlength", "placeholder", "disabled", "readonly", "tabindex", "onKeydown"])), [
|
|
10136
10151
|
[vModelText, data.value]
|
|
10137
10152
|
]) : props.type === "html" ? (openBlock(), createElementBlock("span", {
|
|
10138
10153
|
key: 5,
|
|
@@ -10162,7 +10177,12 @@ const _sfc_main$X = /* @__PURE__ */ defineComponent({
|
|
|
10162
10177
|
disabled: props.disabled,
|
|
10163
10178
|
readonly: __props.readonly,
|
|
10164
10179
|
onKeyup: inputKeyup,
|
|
10165
|
-
onKeydown:
|
|
10180
|
+
onKeydown: [
|
|
10181
|
+
withModifiers(inputKeydown, ["exact"]),
|
|
10182
|
+
withKeys(withModifiers(inputEnter, ["exact"]), ["enter"]),
|
|
10183
|
+
withKeys(withModifiers(inputCtrlEnter, ["ctrl", "exact"]), ["enter"]),
|
|
10184
|
+
withKeys(withModifiers(inputCtrlEnter, ["meta", "exact"]), ["enter"])
|
|
10185
|
+
],
|
|
10166
10186
|
onCut: inputCut,
|
|
10167
10187
|
onFocus: inputFocus,
|
|
10168
10188
|
onBlur: inputBlur,
|
|
@@ -10170,7 +10190,7 @@ const _sfc_main$X = /* @__PURE__ */ defineComponent({
|
|
|
10170
10190
|
onKeypress: inputKeyPress,
|
|
10171
10191
|
onChange: inputChange,
|
|
10172
10192
|
onInput: inputInput
|
|
10173
|
-
}, null, 40, ["onUpdate:modelValue", "autocomplete", "tabindex", "maxlength", "placeholder", "type", "disabled", "readonly"]), [
|
|
10193
|
+
}, null, 40, ["onUpdate:modelValue", "autocomplete", "tabindex", "maxlength", "placeholder", "type", "disabled", "readonly", "onKeydown"]), [
|
|
10174
10194
|
[vModelDynamic, data.value]
|
|
10175
10195
|
])
|
|
10176
10196
|
])),
|
|
@@ -10337,7 +10357,7 @@ const _sfc_main$W = /* @__PURE__ */ defineComponent({
|
|
|
10337
10357
|
};
|
|
10338
10358
|
}
|
|
10339
10359
|
});
|
|
10340
|
-
|
|
10360
|
+
withInstall(_sfc_main$W);
|
|
10341
10361
|
/*! @license DOMPurify 3.3.1 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.3.1/LICENSE */
|
|
10342
10362
|
const {
|
|
10343
10363
|
entries,
|
|
@@ -13790,6 +13810,7 @@ const _sfc_main$M = /* @__PURE__ */ defineComponent({
|
|
|
13790
13810
|
ref: inputBox,
|
|
13791
13811
|
"model-value": unref(datedisplay),
|
|
13792
13812
|
class: "to-date-picker",
|
|
13813
|
+
readonly: !props.inputable,
|
|
13793
13814
|
required: __props.required,
|
|
13794
13815
|
desc: __props.desc,
|
|
13795
13816
|
color: __props.color,
|
|
@@ -13893,7 +13914,7 @@ const _sfc_main$M = /* @__PURE__ */ defineComponent({
|
|
|
13893
13914
|
}, 8, ["lazy", "slide", "position", "width", "align"])
|
|
13894
13915
|
]),
|
|
13895
13916
|
_: 1
|
|
13896
|
-
}, 8, ["id", "model-value", "required", "desc", "color", "prefix", "suffix", "mode", "prop-error-type", "prop-error-tip", "fillet", "fillet-position", "placeholder", "disabled", "sp-chars", "link", "clearable", "width", "comparable", "onClear", "onInput"]);
|
|
13917
|
+
}, 8, ["id", "model-value", "readonly", "required", "desc", "color", "prefix", "suffix", "mode", "prop-error-type", "prop-error-tip", "fillet", "fillet-position", "placeholder", "disabled", "sp-chars", "link", "clearable", "width", "comparable", "onClear", "onInput"]);
|
|
13897
13918
|
};
|
|
13898
13919
|
}
|
|
13899
13920
|
});
|
|
@@ -14310,6 +14331,7 @@ const _sfc_main$J = /* @__PURE__ */ defineComponent({
|
|
|
14310
14331
|
title: { default: "" },
|
|
14311
14332
|
height: { default: "" },
|
|
14312
14333
|
changePic: { type: Boolean, default: false },
|
|
14334
|
+
align: { default: "" },
|
|
14313
14335
|
beforeChange: { type: Function, default: null },
|
|
14314
14336
|
beforeRemove: { type: Function, default: null }
|
|
14315
14337
|
},
|
|
@@ -14328,8 +14350,12 @@ const _sfc_main$J = /* @__PURE__ */ defineComponent({
|
|
|
14328
14350
|
const slot = useSlots();
|
|
14329
14351
|
watch(
|
|
14330
14352
|
() => props.modelValue,
|
|
14331
|
-
(val) => {
|
|
14332
|
-
|
|
14353
|
+
(val, old) => {
|
|
14354
|
+
if (val || val === 0) {
|
|
14355
|
+
selectValue.value = val;
|
|
14356
|
+
} else {
|
|
14357
|
+
emit("update:modelValue", old);
|
|
14358
|
+
}
|
|
14333
14359
|
},
|
|
14334
14360
|
{ immediate: true }
|
|
14335
14361
|
);
|
|
@@ -14346,12 +14372,18 @@ const _sfc_main$J = /* @__PURE__ */ defineComponent({
|
|
|
14346
14372
|
initData();
|
|
14347
14373
|
});
|
|
14348
14374
|
function initData() {
|
|
14349
|
-
if (props.data) {
|
|
14375
|
+
if (props.data && props.data.length) {
|
|
14350
14376
|
if (typeof props.data === "string") {
|
|
14351
14377
|
_data.value = props.data.split(",").map((item) => ({ label: item, value: item }));
|
|
14352
14378
|
} else if (Array.isArray(props.data) && props.data.length) {
|
|
14353
14379
|
_data.value = props.data;
|
|
14354
14380
|
}
|
|
14381
|
+
if (!selectValue.value && selectValue.value !== 0) {
|
|
14382
|
+
const hasNoOnItems = !_data.value.some((item) => item.on);
|
|
14383
|
+
if (hasNoOnItems) {
|
|
14384
|
+
selectValue.value = _data.value[0].value;
|
|
14385
|
+
}
|
|
14386
|
+
}
|
|
14355
14387
|
}
|
|
14356
14388
|
if (props.over === "control") {
|
|
14357
14389
|
nextTick(() => {
|
|
@@ -14361,16 +14393,8 @@ const _sfc_main$J = /* @__PURE__ */ defineComponent({
|
|
|
14361
14393
|
}
|
|
14362
14394
|
const setTabStyle = computed(() => {
|
|
14363
14395
|
let obj = {};
|
|
14364
|
-
if (props.itemWidth) {
|
|
14365
|
-
|
|
14366
|
-
obj.width = props.itemWidth + "em";
|
|
14367
|
-
} else {
|
|
14368
|
-
if (props.itemWidth === "avg") {
|
|
14369
|
-
obj.width = 100 / _data.value.length + "%";
|
|
14370
|
-
} else {
|
|
14371
|
-
obj.width = props.itemWidth;
|
|
14372
|
-
}
|
|
14373
|
-
}
|
|
14396
|
+
if (props.itemWidth && !isNaN(Number(props.itemWidth)) && props.itemWidth !== "avg") {
|
|
14397
|
+
obj.width = props.itemWidth + "em";
|
|
14374
14398
|
}
|
|
14375
14399
|
return obj;
|
|
14376
14400
|
});
|
|
@@ -14396,6 +14420,12 @@ const _sfc_main$J = /* @__PURE__ */ defineComponent({
|
|
|
14396
14420
|
if (props.itemDir) {
|
|
14397
14421
|
arr.push(`item-dir-${props.itemDir}`);
|
|
14398
14422
|
}
|
|
14423
|
+
if (props.itemWidth === "avg") {
|
|
14424
|
+
arr.push(`item-width-avg`);
|
|
14425
|
+
}
|
|
14426
|
+
if (props.align) {
|
|
14427
|
+
arr.push(`align-${props.align}`);
|
|
14428
|
+
}
|
|
14399
14429
|
return arr;
|
|
14400
14430
|
});
|
|
14401
14431
|
const setUlClass = computed(() => {
|
|
@@ -15961,9 +15991,10 @@ const _sfc_main$C = /* @__PURE__ */ defineComponent({
|
|
|
15961
15991
|
});
|
|
15962
15992
|
return (_ctx, _cache) => {
|
|
15963
15993
|
const _component_to_icon = resolveComponent("to-icon");
|
|
15994
|
+
const _directive_size = resolveDirective("size");
|
|
15964
15995
|
return withDirectives((openBlock(), createBlock(resolveDynamicComponent(__props.link ? "a" : "span"), {
|
|
15965
|
-
ref: "
|
|
15966
|
-
href: __props.href ? __props.href : "javscript:void(0)",
|
|
15996
|
+
ref: "$el2",
|
|
15997
|
+
href: __props.href ? __props.href : __props.link ? "javscript:void(0)" : "",
|
|
15967
15998
|
class: normalizeClass(["to-text", setClass.value]),
|
|
15968
15999
|
style: normalizeStyle(setStyle.value)
|
|
15969
16000
|
}, {
|
|
@@ -15971,7 +16002,7 @@ const _sfc_main$C = /* @__PURE__ */ defineComponent({
|
|
|
15971
16002
|
renderSlot(_ctx.$slots, "icon", {}, () => [
|
|
15972
16003
|
props.icon ? (openBlock(), createBlock(_component_to_icon, {
|
|
15973
16004
|
key: 0,
|
|
15974
|
-
|
|
16005
|
+
class: "to-text-icon",
|
|
15975
16006
|
value: props.icon
|
|
15976
16007
|
}, null, 8, ["value"])) : createCommentVNode("", true)
|
|
15977
16008
|
]),
|
|
@@ -15984,7 +16015,7 @@ const _sfc_main$C = /* @__PURE__ */ defineComponent({
|
|
|
15984
16015
|
]),
|
|
15985
16016
|
_: 3
|
|
15986
16017
|
}, 8, ["href", "class", "style"])), [
|
|
15987
|
-
[
|
|
16018
|
+
[_directive_size, __props.size]
|
|
15988
16019
|
]);
|
|
15989
16020
|
};
|
|
15990
16021
|
}
|
|
@@ -22052,10 +22083,7 @@ const _sfc_main$f = /* @__PURE__ */ defineComponent({
|
|
|
22052
22083
|
},
|
|
22053
22084
|
__name: "collapse-item",
|
|
22054
22085
|
props: {
|
|
22055
|
-
padding: { default: 1 },
|
|
22056
|
-
paddingPosition: { default: "ltrb" },
|
|
22057
22086
|
value: { default: "" },
|
|
22058
|
-
name: { default: "" },
|
|
22059
22087
|
title: { default: "" },
|
|
22060
22088
|
disabled: { type: Boolean, default: false }
|
|
22061
22089
|
},
|
|
@@ -22065,11 +22093,11 @@ const _sfc_main$f = /* @__PURE__ */ defineComponent({
|
|
|
22065
22093
|
const emit = __emit;
|
|
22066
22094
|
const isActive = ref(false);
|
|
22067
22095
|
const Store = inject("Store");
|
|
22068
|
-
Store.addChild(props.
|
|
22096
|
+
Store.addChild(props.value);
|
|
22069
22097
|
watch(
|
|
22070
22098
|
() => Store.activeValue.value,
|
|
22071
22099
|
(value) => {
|
|
22072
|
-
if (value.includes(props.
|
|
22100
|
+
if (value.includes(props.value)) {
|
|
22073
22101
|
isActive.value = true;
|
|
22074
22102
|
} else {
|
|
22075
22103
|
isActive.value = false;
|
|
@@ -22083,80 +22111,55 @@ const _sfc_main$f = /* @__PURE__ */ defineComponent({
|
|
|
22083
22111
|
let h2 = containerRef.value.clientHeight / em + "em";
|
|
22084
22112
|
return h2;
|
|
22085
22113
|
});
|
|
22086
|
-
const hasUnit = (val) => /[a-z%]+$/i.test(val);
|
|
22087
|
-
const setStyle = computed(() => {
|
|
22088
|
-
const obj = {};
|
|
22089
|
-
if (String(props.padding).trim()) {
|
|
22090
|
-
const padded = String(props.padding).trim().split(/\s+/).map((val) => {
|
|
22091
|
-
return hasUnit(val) ? val : `${val}em`;
|
|
22092
|
-
}).join(" ");
|
|
22093
|
-
obj.padding = padded;
|
|
22094
|
-
}
|
|
22095
|
-
if (!props.paddingPosition.includes("t")) {
|
|
22096
|
-
obj.paddingTop = 0;
|
|
22097
|
-
}
|
|
22098
|
-
if (!props.paddingPosition.includes("r")) {
|
|
22099
|
-
obj.paddingRight = 0;
|
|
22100
|
-
}
|
|
22101
|
-
if (!props.paddingPosition.includes("b")) {
|
|
22102
|
-
obj.paddingBottom = 0;
|
|
22103
|
-
}
|
|
22104
|
-
if (!props.paddingPosition.includes("l")) {
|
|
22105
|
-
obj.paddingLeft = 0;
|
|
22106
|
-
}
|
|
22107
|
-
return obj;
|
|
22108
|
-
});
|
|
22109
22114
|
function itemClick() {
|
|
22110
22115
|
if (!props.disabled) {
|
|
22111
|
-
Store.setActiveValues(props.
|
|
22116
|
+
Store.setActiveValues(props.value);
|
|
22112
22117
|
nextTick(() => {
|
|
22113
22118
|
emit("change", isActive.value);
|
|
22114
22119
|
});
|
|
22115
22120
|
}
|
|
22116
22121
|
}
|
|
22117
|
-
function titleClick(e) {
|
|
22118
|
-
if (!props.disabled) {
|
|
22119
|
-
emit("title-click", e);
|
|
22120
|
-
}
|
|
22121
|
-
}
|
|
22122
22122
|
return (_ctx, _cache) => {
|
|
22123
|
+
const _component_to_icon = resolveComponent("to-icon");
|
|
22124
|
+
const _component_to_header = resolveComponent("to-header");
|
|
22123
22125
|
return openBlock(), createElementBlock("div", {
|
|
22124
|
-
class: normalizeClass(["to-collapse-item", __props.disabled ? "is-
|
|
22126
|
+
class: normalizeClass(["to-collapse-item", __props.disabled ? "is-dis" : "", isActive.value ? "is-on" : ""])
|
|
22125
22127
|
}, [
|
|
22126
|
-
|
|
22127
|
-
|
|
22128
|
-
|
|
22129
|
-
|
|
22130
|
-
|
|
22131
|
-
|
|
22132
|
-
|
|
22133
|
-
|
|
22134
|
-
|
|
22135
|
-
|
|
22136
|
-
|
|
22137
|
-
|
|
22138
|
-
|
|
22139
|
-
|
|
22140
|
-
|
|
22141
|
-
createVNode(
|
|
22142
|
-
|
|
22143
|
-
|
|
22144
|
-
|
|
22128
|
+
renderSlot(_ctx.$slots, "header", {
|
|
22129
|
+
item: { isOn: isActive.value, title: __props.title, isDisabled: __props.disabled }
|
|
22130
|
+
}, () => [
|
|
22131
|
+
createVNode(_component_to_header, {
|
|
22132
|
+
link: "",
|
|
22133
|
+
class: normalizeClass(["to-collapse-item-header"]),
|
|
22134
|
+
onClick: itemClick
|
|
22135
|
+
}, {
|
|
22136
|
+
title: withCtx(() => [
|
|
22137
|
+
renderSlot(_ctx.$slots, "title", {}, () => [
|
|
22138
|
+
createTextVNode(toDisplayString(__props.title), 1)
|
|
22139
|
+
])
|
|
22140
|
+
]),
|
|
22141
|
+
default: withCtx(() => [
|
|
22142
|
+
renderSlot(_ctx.$slots, "fn"),
|
|
22143
|
+
createVNode(_component_to_icon, {
|
|
22144
|
+
value: "next",
|
|
22145
|
+
class: "to-collapse-item-arrow"
|
|
22146
|
+
})
|
|
22147
|
+
]),
|
|
22148
|
+
_: 3
|
|
22149
|
+
})
|
|
22150
|
+
]),
|
|
22145
22151
|
createElementVNode("div", {
|
|
22146
22152
|
class: "to-collapse-item-content",
|
|
22147
|
-
style: normalizeStyle({
|
|
22148
|
-
height: isActive.value ? calcHeight.value : "0px"
|
|
22149
|
-
})
|
|
22153
|
+
style: normalizeStyle({ height: isActive.value ? calcHeight.value : "0px" })
|
|
22150
22154
|
}, [
|
|
22151
22155
|
createElementVNode("div", {
|
|
22152
22156
|
ref_key: "containerRef",
|
|
22153
22157
|
ref: containerRef,
|
|
22154
|
-
class: "
|
|
22158
|
+
class: "to-collapse-item-wrapper"
|
|
22155
22159
|
}, [
|
|
22156
22160
|
renderSlot(_ctx.$slots, "default")
|
|
22157
22161
|
], 512)
|
|
22158
|
-
], 4)
|
|
22159
|
-
createVNode(unref(ToDivider))
|
|
22162
|
+
], 4)
|
|
22160
22163
|
], 2);
|
|
22161
22164
|
};
|
|
22162
22165
|
}
|
|
@@ -22193,19 +22196,19 @@ const _sfc_main$e = /* @__PURE__ */ defineComponent({
|
|
|
22193
22196
|
deep: true
|
|
22194
22197
|
}
|
|
22195
22198
|
);
|
|
22196
|
-
function addChild(
|
|
22197
|
-
allChildren.value.push(
|
|
22199
|
+
function addChild(value) {
|
|
22200
|
+
allChildren.value.push(value);
|
|
22198
22201
|
}
|
|
22199
|
-
function setActiveValues(
|
|
22200
|
-
if (activeValue.value.includes(
|
|
22201
|
-
let idx = activeValue.value.findIndex((item) => item ===
|
|
22202
|
+
function setActiveValues(value) {
|
|
22203
|
+
if (activeValue.value.includes(value)) {
|
|
22204
|
+
let idx = activeValue.value.findIndex((item) => item === value);
|
|
22202
22205
|
idx !== -1 && activeValue.value.splice(idx, 1);
|
|
22203
22206
|
} else {
|
|
22204
22207
|
if (props.accordion) {
|
|
22205
22208
|
activeValue.value = [];
|
|
22206
|
-
activeValue.value.push(
|
|
22209
|
+
activeValue.value.push(value);
|
|
22207
22210
|
} else {
|
|
22208
|
-
activeValue.value.push(
|
|
22211
|
+
activeValue.value.push(value);
|
|
22209
22212
|
}
|
|
22210
22213
|
}
|
|
22211
22214
|
}
|
|
@@ -24648,6 +24651,7 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
|
|
|
24648
24651
|
props: editorProps,
|
|
24649
24652
|
emits: editorEmits,
|
|
24650
24653
|
setup(__props, { expose: __expose, emit: __emit }) {
|
|
24654
|
+
const tinymce = window.tinymce;
|
|
24651
24655
|
const props = __props;
|
|
24652
24656
|
const emit = __emit;
|
|
24653
24657
|
const instance = getCurrentInstance();
|
|
@@ -24681,11 +24685,13 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
|
|
|
24681
24685
|
const initTinymce = () => {
|
|
24682
24686
|
if (!tinymce) {
|
|
24683
24687
|
console.warn("TinyMCE is not loaded yet, waiting...");
|
|
24684
|
-
setTimeout(initTinymce,
|
|
24688
|
+
setTimeout(initTinymce, 100);
|
|
24685
24689
|
return;
|
|
24686
24690
|
}
|
|
24687
24691
|
tinymce.init({
|
|
24688
24692
|
selector: "#" + tinymceId.value,
|
|
24693
|
+
// 关键:把工具栏渲染到自定义容器,否则在部分 TinyMCE 版本下可能不显示
|
|
24694
|
+
fixed_toolbar_container: "#" + tinymceId.value + "_toolbar-container",
|
|
24689
24695
|
language: languageTypeList[props.language],
|
|
24690
24696
|
height: getHeightWithUnit(props.height),
|
|
24691
24697
|
body_class: "panel-body ",
|
|
@@ -24695,8 +24701,9 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
|
|
|
24695
24701
|
plugins,
|
|
24696
24702
|
end_container_on_empty_block: true,
|
|
24697
24703
|
powerpaste_word_import: "clean",
|
|
24698
|
-
skin: false
|
|
24699
|
-
|
|
24704
|
+
// TinyMCE v4 使用 skin: false 容易导致 UI 样式缺失而“看起来没渲染”,改为默认皮肤
|
|
24705
|
+
skin: void 0,
|
|
24706
|
+
codesample_content_css: void 0,
|
|
24700
24707
|
code_dialog_height: 450,
|
|
24701
24708
|
code_dialog_width: 1e3,
|
|
24702
24709
|
advlist_bullet_styles: "square",
|
|
@@ -24886,7 +24893,10 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
|
|
|
24886
24893
|
createElementVNode("div", {
|
|
24887
24894
|
id: tinymceId.value + "_toolbar-container"
|
|
24888
24895
|
}, null, 8, ["id"]),
|
|
24889
|
-
createElementVNode("div", {
|
|
24896
|
+
createElementVNode("div", {
|
|
24897
|
+
id: tinymceId.value,
|
|
24898
|
+
style: { "min-height": "200px", "border": "1px solid var(--to-border-color, #dcdfe6)" }
|
|
24899
|
+
}, [
|
|
24890
24900
|
createElementVNode("p")
|
|
24891
24901
|
], 8, ["id"])
|
|
24892
24902
|
]);
|
|
@@ -25651,6 +25661,14 @@ const echartsBarProps = {
|
|
|
25651
25661
|
type: Array,
|
|
25652
25662
|
default: () => []
|
|
25653
25663
|
},
|
|
25664
|
+
chartsType: {
|
|
25665
|
+
type: String,
|
|
25666
|
+
default: "bar"
|
|
25667
|
+
},
|
|
25668
|
+
xAxisData: {
|
|
25669
|
+
type: Array,
|
|
25670
|
+
default: () => []
|
|
25671
|
+
},
|
|
25654
25672
|
color: {
|
|
25655
25673
|
type: [String, Array, Object],
|
|
25656
25674
|
default: "#03a9f4"
|
|
@@ -25671,6 +25689,10 @@ const echartsBarProps = {
|
|
|
25671
25689
|
type: Boolean,
|
|
25672
25690
|
default: false
|
|
25673
25691
|
},
|
|
25692
|
+
d3dShape: {
|
|
25693
|
+
type: String,
|
|
25694
|
+
default: "cube"
|
|
25695
|
+
},
|
|
25674
25696
|
isHorizontal: {
|
|
25675
25697
|
type: Boolean,
|
|
25676
25698
|
default: false
|
|
@@ -25743,6 +25765,14 @@ const echartsBarProps = {
|
|
|
25743
25765
|
tipFontSize: {
|
|
25744
25766
|
type: [String, Number],
|
|
25745
25767
|
default: 1
|
|
25768
|
+
},
|
|
25769
|
+
smooth: {
|
|
25770
|
+
type: [Boolean, Number],
|
|
25771
|
+
default: false
|
|
25772
|
+
},
|
|
25773
|
+
interval: {
|
|
25774
|
+
type: Number,
|
|
25775
|
+
default: 0
|
|
25746
25776
|
}
|
|
25747
25777
|
};
|
|
25748
25778
|
const echartsBarEmits = {
|
|
@@ -25804,9 +25834,9 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
25804
25834
|
const axisConfig = computed(() => {
|
|
25805
25835
|
const categoryAxis = {
|
|
25806
25836
|
type: "category",
|
|
25807
|
-
data: props.data.map((item) => item.name),
|
|
25837
|
+
data: isMultiSeries.value ? props.xAxisData : props.data.map((item) => item.name),
|
|
25808
25838
|
axisLabel: {
|
|
25809
|
-
interval:
|
|
25839
|
+
interval: props.interval,
|
|
25810
25840
|
rotate: props.rotate,
|
|
25811
25841
|
fontSize: Number(props.fontSize) * currentEm.value,
|
|
25812
25842
|
color: props.isHorizontal ? props.yAxisStyle.textColor : props.xAxisStyle.textColor
|
|
@@ -25928,12 +25958,14 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
25928
25958
|
color: props.yAxisStyle.textColor
|
|
25929
25959
|
};
|
|
25930
25960
|
};
|
|
25961
|
+
const isMultiSeries = computed(() => {
|
|
25962
|
+
return props.data.length > 0 && isArray(props.data[0].value);
|
|
25963
|
+
});
|
|
25931
25964
|
const seriesConfig = computed(() => {
|
|
25932
25965
|
if (!echartsLib)
|
|
25933
25966
|
return [];
|
|
25934
25967
|
if (!props.is3d) {
|
|
25935
25968
|
const series = [];
|
|
25936
|
-
const isMultiSeries = props.data.length > 0 && isArray(props.data[0].value);
|
|
25937
25969
|
const maxValue = Math.max(
|
|
25938
25970
|
...props.data.map((item) => {
|
|
25939
25971
|
if (isArray(item.value)) {
|
|
@@ -25942,74 +25974,40 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
25942
25974
|
return item.value;
|
|
25943
25975
|
})
|
|
25944
25976
|
);
|
|
25945
|
-
if (isMultiSeries) {
|
|
25946
|
-
|
|
25947
|
-
for (let i = 0; i < seriesCount; i++) {
|
|
25977
|
+
if (isMultiSeries.value) {
|
|
25978
|
+
props.data.forEach((item, i) => {
|
|
25948
25979
|
if (props.showShadow) {
|
|
25949
25980
|
series.push({
|
|
25950
|
-
name:
|
|
25951
|
-
type:
|
|
25952
|
-
data:
|
|
25953
|
-
value: maxValue,
|
|
25954
|
-
itemStyle: {
|
|
25955
|
-
color: new echartsLib.graphic.LinearGradient(
|
|
25956
|
-
...props.isHorizontal ? [
|
|
25957
|
-
0,
|
|
25958
|
-
0,
|
|
25959
|
-
1,
|
|
25960
|
-
0,
|
|
25961
|
-
[
|
|
25962
|
-
{ offset: 0, color: "rgba(0, 0, 0, 0.4)" },
|
|
25963
|
-
{ offset: 0.5, color: "rgba(0, 0, 0, 0.25)" },
|
|
25964
|
-
{ offset: 1, color: "rgba(0, 0, 0, 0)" }
|
|
25965
|
-
]
|
|
25966
|
-
] : [
|
|
25967
|
-
0,
|
|
25968
|
-
0,
|
|
25969
|
-
0,
|
|
25970
|
-
1,
|
|
25971
|
-
[
|
|
25972
|
-
{ offset: 0, color: "rgba(0, 0, 0, 0)" },
|
|
25973
|
-
{ offset: 0.5, color: "rgba(0, 0, 0, 0.25)" },
|
|
25974
|
-
{ offset: 1, color: "rgba(0, 0, 0, 0.4)" }
|
|
25975
|
-
]
|
|
25976
|
-
]
|
|
25977
|
-
)
|
|
25978
|
-
}
|
|
25979
|
-
})),
|
|
25981
|
+
name: item.name,
|
|
25982
|
+
type: item.type ? item.type : props.chartsType,
|
|
25983
|
+
data: item.value,
|
|
25980
25984
|
barWidth: Number(props.barSize) * currentEm.value,
|
|
25981
25985
|
barGap: "-100%",
|
|
25982
25986
|
z: 1,
|
|
25983
25987
|
silent: true,
|
|
25984
|
-
animation: false
|
|
25988
|
+
animation: false,
|
|
25989
|
+
smooth: item.smooth || props.smooth
|
|
25985
25990
|
});
|
|
25986
25991
|
}
|
|
25987
25992
|
series.push({
|
|
25988
|
-
name:
|
|
25989
|
-
type:
|
|
25990
|
-
data:
|
|
25993
|
+
name: item.name,
|
|
25994
|
+
type: item.type ? item.type : props.chartsType,
|
|
25995
|
+
data: item.value,
|
|
25991
25996
|
barWidth: Number(props.barSize) * currentEm.value,
|
|
25992
25997
|
itemStyle: {
|
|
25993
25998
|
borderRadius: Number(props.borderRadius) * currentEm.value,
|
|
25994
|
-
color:
|
|
25995
|
-
{
|
|
25996
|
-
offset: 0,
|
|
25997
|
-
color: props.color[i].start
|
|
25998
|
-
},
|
|
25999
|
-
{
|
|
26000
|
-
offset: 1,
|
|
26001
|
-
color: props.color[i].end
|
|
26002
|
-
}
|
|
26003
|
-
]) : props.color
|
|
25999
|
+
color: getItemColor(item, i)
|
|
26004
26000
|
},
|
|
26001
|
+
areaStyle: item.areaStyle ? item.areaStyle : null,
|
|
26005
26002
|
label: getSeriesLabelConfig(),
|
|
26006
|
-
z: 2
|
|
26003
|
+
z: 2,
|
|
26004
|
+
smooth: item.smooth || props.smooth
|
|
26007
26005
|
});
|
|
26008
|
-
}
|
|
26006
|
+
});
|
|
26009
26007
|
} else {
|
|
26010
26008
|
if (props.showShadow) {
|
|
26011
26009
|
series.push({
|
|
26012
|
-
type:
|
|
26010
|
+
type: props.chartsType,
|
|
26013
26011
|
data: props.data.map(() => ({
|
|
26014
26012
|
value: maxValue,
|
|
26015
26013
|
itemStyle: {
|
|
@@ -26042,16 +26040,18 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
26042
26040
|
barGap: "-100%",
|
|
26043
26041
|
z: 1,
|
|
26044
26042
|
silent: true,
|
|
26045
|
-
animation: false
|
|
26043
|
+
animation: false,
|
|
26044
|
+
smooth: props.smooth
|
|
26046
26045
|
});
|
|
26047
26046
|
}
|
|
26048
26047
|
series.push({
|
|
26049
|
-
type:
|
|
26048
|
+
type: props.chartsType,
|
|
26050
26049
|
data: props.data.map((item) => item.value),
|
|
26051
26050
|
barWidth: Number(props.barSize) * currentEm.value,
|
|
26052
26051
|
itemStyle: getItemStyle(),
|
|
26053
26052
|
label: getSeriesLabelConfig(),
|
|
26054
|
-
z: 2
|
|
26053
|
+
z: 2,
|
|
26054
|
+
smooth: props.smooth
|
|
26055
26055
|
});
|
|
26056
26056
|
}
|
|
26057
26057
|
return series;
|
|
@@ -26059,6 +26059,18 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
26059
26059
|
return get3dSeriesConfig();
|
|
26060
26060
|
}
|
|
26061
26061
|
});
|
|
26062
|
+
const getItemColor = (item, i) => {
|
|
26063
|
+
let color = null;
|
|
26064
|
+
if (isArray(props.color)) {
|
|
26065
|
+
color = props.color[i];
|
|
26066
|
+
} else {
|
|
26067
|
+
color = props.color;
|
|
26068
|
+
}
|
|
26069
|
+
if (item.linearGradient) {
|
|
26070
|
+
color = item.linearGradient;
|
|
26071
|
+
}
|
|
26072
|
+
return color;
|
|
26073
|
+
};
|
|
26062
26074
|
const tooltipConfig = computed(() => {
|
|
26063
26075
|
if (!props.showTooltip) {
|
|
26064
26076
|
return { show: false };
|
|
@@ -26417,12 +26429,107 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
26417
26429
|
});
|
|
26418
26430
|
return series;
|
|
26419
26431
|
};
|
|
26432
|
+
const getVerticalCylinder3dSeries = () => {
|
|
26433
|
+
if (!echartsLib)
|
|
26434
|
+
return [];
|
|
26435
|
+
const values = props.data.map((item) => item.value);
|
|
26436
|
+
const barWidth = Number(props.barSize) * currentEm.value * 1.25;
|
|
26437
|
+
const rx = barWidth / 2;
|
|
26438
|
+
const ry = Math.max(2, barWidth * 0.28);
|
|
26439
|
+
return [
|
|
26440
|
+
{
|
|
26441
|
+
type: "custom",
|
|
26442
|
+
renderItem: (params, api) => {
|
|
26443
|
+
const value = api.value(1);
|
|
26444
|
+
const coord = api.coord([api.value(0), value]);
|
|
26445
|
+
const x = coord[0];
|
|
26446
|
+
const yTop = coord[1];
|
|
26447
|
+
const yBottom = api.coord([api.value(0), 0])[1];
|
|
26448
|
+
const height = Math.abs(yBottom - yTop);
|
|
26449
|
+
const color = getItemStyle().color;
|
|
26450
|
+
const colorStops = typeof color === "object" && color.colorStops ? color.colorStops : [
|
|
26451
|
+
{ offset: 0, color: "#4facfe" },
|
|
26452
|
+
{ offset: 1, color: "#00f2fe" }
|
|
26453
|
+
];
|
|
26454
|
+
const topMainColor = colorStops[0].color;
|
|
26455
|
+
const bottomMainColor = colorStops[colorStops.length - 1].color;
|
|
26456
|
+
const children = [];
|
|
26457
|
+
children.push({
|
|
26458
|
+
type: "rect",
|
|
26459
|
+
shape: { x: x - rx, y: yTop, width: rx * 2, height },
|
|
26460
|
+
style: { fill: new echartsLib.graphic.LinearGradient(0, 0, 0, 1, colorStops), opacity: 0.9 },
|
|
26461
|
+
z: 2
|
|
26462
|
+
});
|
|
26463
|
+
children.push({
|
|
26464
|
+
type: "rect",
|
|
26465
|
+
shape: { x: x - rx * 0.72, y: yTop, width: rx * 0.38, height },
|
|
26466
|
+
style: {
|
|
26467
|
+
fill: new echartsLib.graphic.LinearGradient(0, 0, 1, 0, [
|
|
26468
|
+
{ offset: 0, color: "rgba(140,200,255,0.32)" },
|
|
26469
|
+
{ offset: 1, color: "rgba(140,200,255,0.04)" }
|
|
26470
|
+
])
|
|
26471
|
+
},
|
|
26472
|
+
z: 3
|
|
26473
|
+
});
|
|
26474
|
+
children.push({
|
|
26475
|
+
type: "ellipse",
|
|
26476
|
+
shape: { cx: x, cy: yTop, rx, ry },
|
|
26477
|
+
style: {
|
|
26478
|
+
fill: new echartsLib.graphic.RadialGradient(0.5, 0.42, 0.82, [
|
|
26479
|
+
{ offset: 0, color: adjustSingleColor(topMainColor, 0.35) },
|
|
26480
|
+
{ offset: 0.32, color: adjustSingleColor(topMainColor, 0.08) },
|
|
26481
|
+
{ offset: 0.72, color: topMainColor },
|
|
26482
|
+
{ offset: 1, color: adjustSingleColor(bottomMainColor, -0.22) }
|
|
26483
|
+
]),
|
|
26484
|
+
lineWidth: 1,
|
|
26485
|
+
stroke: "rgba(170,200,255,0.55)"
|
|
26486
|
+
},
|
|
26487
|
+
z: 5
|
|
26488
|
+
});
|
|
26489
|
+
children.push({
|
|
26490
|
+
type: "ellipse",
|
|
26491
|
+
shape: { cx: x, cy: yBottom - ry * 0.15, rx: rx * 1.02, ry: ry * 1.05 },
|
|
26492
|
+
style: {
|
|
26493
|
+
fill: adjustSingleColor(bottomMainColor, 0.05),
|
|
26494
|
+
opacity: 0.9,
|
|
26495
|
+
lineWidth: 1,
|
|
26496
|
+
stroke: adjustSingleColor(bottomMainColor, 0.15)
|
|
26497
|
+
},
|
|
26498
|
+
z: 6
|
|
26499
|
+
});
|
|
26500
|
+
if (props.showValue) {
|
|
26501
|
+
children.push({
|
|
26502
|
+
type: "text",
|
|
26503
|
+
style: {
|
|
26504
|
+
text: String(value),
|
|
26505
|
+
textAlign: "center",
|
|
26506
|
+
textVerticalAlign: "bottom",
|
|
26507
|
+
fontSize: Number(props.fontSize) * currentEm.value,
|
|
26508
|
+
fill: "#fff",
|
|
26509
|
+
fontWeight: "bold",
|
|
26510
|
+
x,
|
|
26511
|
+
y: yTop - ry - 8,
|
|
26512
|
+
textShadowBlur: 4,
|
|
26513
|
+
textShadowColor: "rgba(0,0,0,0.5)"
|
|
26514
|
+
},
|
|
26515
|
+
z: 6
|
|
26516
|
+
});
|
|
26517
|
+
}
|
|
26518
|
+
return { type: "group", children };
|
|
26519
|
+
},
|
|
26520
|
+
data: values.map((val, index) => [index, val]),
|
|
26521
|
+
z: 1
|
|
26522
|
+
}
|
|
26523
|
+
];
|
|
26524
|
+
};
|
|
26420
26525
|
const get3dSeriesConfig = () => {
|
|
26421
26526
|
if (props.isHorizontal) {
|
|
26422
26527
|
return getHorizontal3dSeries();
|
|
26423
|
-
} else {
|
|
26424
|
-
return getVertical3dSeries();
|
|
26425
26528
|
}
|
|
26529
|
+
if (props.d3dShape === "cylinder") {
|
|
26530
|
+
return getVerticalCylinder3dSeries();
|
|
26531
|
+
}
|
|
26532
|
+
return getVertical3dSeries();
|
|
26426
26533
|
};
|
|
26427
26534
|
const initChart = (retry = 0) => {
|
|
26428
26535
|
window.setTimeout(async () => {
|
|
@@ -26551,8 +26658,8 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
26551
26658
|
};
|
|
26552
26659
|
}
|
|
26553
26660
|
});
|
|
26554
|
-
const
|
|
26555
|
-
const EchartsBar = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["__scopeId", "data-v-
|
|
26661
|
+
const echartsBar_vue_vue_type_style_index_0_scoped_4f4fca0e_lang = "";
|
|
26662
|
+
const EchartsBar = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["__scopeId", "data-v-4f4fca0e"]]);
|
|
26556
26663
|
const ToEchartsBar = withInstall(EchartsBar);
|
|
26557
26664
|
const DEFAULT_VIEW_CONTROL = {
|
|
26558
26665
|
zoomSensitivity: 0,
|
|
@@ -26561,6 +26668,10 @@ const DEFAULT_VIEW_CONTROL = {
|
|
|
26561
26668
|
distance: 100
|
|
26562
26669
|
};
|
|
26563
26670
|
const echartsMapProps = {
|
|
26671
|
+
nameMap: {
|
|
26672
|
+
type: Object,
|
|
26673
|
+
default: () => ({})
|
|
26674
|
+
},
|
|
26564
26675
|
shadow: {
|
|
26565
26676
|
type: String,
|
|
26566
26677
|
default: ""
|
|
@@ -26688,6 +26799,18 @@ const echartsMapProps = {
|
|
|
26688
26799
|
speed: {
|
|
26689
26800
|
type: [String, Number],
|
|
26690
26801
|
default: 3e3
|
|
26802
|
+
},
|
|
26803
|
+
showOutline: {
|
|
26804
|
+
type: Boolean,
|
|
26805
|
+
default: false
|
|
26806
|
+
},
|
|
26807
|
+
outlineColor: {
|
|
26808
|
+
type: String,
|
|
26809
|
+
default: "#000"
|
|
26810
|
+
},
|
|
26811
|
+
outlineWidth: {
|
|
26812
|
+
type: [String, Number],
|
|
26813
|
+
default: 2
|
|
26691
26814
|
}
|
|
26692
26815
|
};
|
|
26693
26816
|
const echartsMapEmits = {
|
|
@@ -29218,7 +29341,10 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
29218
29341
|
show: true,
|
|
29219
29342
|
color: props.fontColor,
|
|
29220
29343
|
fontSize: Number(props.fontSize) * currentEm.value,
|
|
29221
|
-
formatter: (e) =>
|
|
29344
|
+
formatter: (e) => {
|
|
29345
|
+
var _a3, _b;
|
|
29346
|
+
return ` ${(_b = (_a3 = props.nameMap) == null ? void 0 : _a3[e.name]) != null ? _b : e.name} `;
|
|
29347
|
+
}
|
|
29222
29348
|
},
|
|
29223
29349
|
itemStyle: {
|
|
29224
29350
|
color: props.color || "#65bbff",
|
|
@@ -29257,7 +29383,10 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
29257
29383
|
show: true,
|
|
29258
29384
|
color: props.fontColor,
|
|
29259
29385
|
fontSize: Number(props.fontSize) * currentEm.value,
|
|
29260
|
-
formatter: (e) =>
|
|
29386
|
+
formatter: (e) => {
|
|
29387
|
+
var _a3, _b;
|
|
29388
|
+
return ` ${(_b = (_a3 = props.nameMap) == null ? void 0 : _a3[e.name]) != null ? _b : e.name} `;
|
|
29389
|
+
}
|
|
29261
29390
|
},
|
|
29262
29391
|
itemStyle: {
|
|
29263
29392
|
shadowBlur: itemShadowParts[0] ? Number(itemShadowParts[0]) * currentEm.value : 0,
|
|
@@ -29294,6 +29423,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
29294
29423
|
};
|
|
29295
29424
|
const getOption = (geoName, mapData) => {
|
|
29296
29425
|
var _a2;
|
|
29426
|
+
const baseSeries = getBaseSeries(geoName, mapData);
|
|
29297
29427
|
const shadowParts = parseShadow(props.shadow);
|
|
29298
29428
|
const { min, max: max2 } = getMinMax(mapData);
|
|
29299
29429
|
return {
|
|
@@ -29306,16 +29436,23 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
29306
29436
|
}
|
|
29307
29437
|
},
|
|
29308
29438
|
geo: {
|
|
29309
|
-
|
|
29439
|
+
// 轮廓线与底部阴影共用 geo:
|
|
29440
|
+
// - shadow:用 geo 的 areaColor 作为底部投影层
|
|
29441
|
+
// - showOutline:用 geo 的 borderColor/borderWidth 画最外围轮廓线
|
|
29442
|
+
show: Boolean(props.shadow) || props.showOutline,
|
|
29310
29443
|
map: geoName,
|
|
29311
29444
|
roam: false,
|
|
29312
|
-
top: shadowParts[0] ? Number(shadowParts[0]) * currentEm.value : currentEm.value,
|
|
29445
|
+
top: props.shadow ? shadowParts[0] ? Number(shadowParts[0]) * currentEm.value : currentEm.value : 0,
|
|
29313
29446
|
bottom: 0,
|
|
29314
29447
|
silent: true,
|
|
29315
29448
|
label: { show: false },
|
|
29316
29449
|
itemStyle: {
|
|
29317
|
-
areaColor: (_a2 = shadowParts[1]) != null ? _a2 : "rgba(0,0,0,0.3)",
|
|
29318
|
-
|
|
29450
|
+
areaColor: props.shadow ? (_a2 = shadowParts[1]) != null ? _a2 : "rgba(0,0,0,0.3)" : "transparent",
|
|
29451
|
+
borderColor: props.showOutline ? props.outlineColor : "transparent",
|
|
29452
|
+
borderWidth: props.showOutline ? Number(props.outlineWidth) : 0,
|
|
29453
|
+
// 避免粗描边在尖锐拐角处产生 miter 尖刺
|
|
29454
|
+
borderJoin: "round",
|
|
29455
|
+
borderMiterLimit: 2
|
|
29319
29456
|
}
|
|
29320
29457
|
},
|
|
29321
29458
|
visualMap: showVisualMap() ? {
|
|
@@ -29340,7 +29477,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
29340
29477
|
color: props.colorRange.length ? props.colorRange : [props.colorStart, props.colorEnd]
|
|
29341
29478
|
}
|
|
29342
29479
|
} : { show: false },
|
|
29343
|
-
series: [
|
|
29480
|
+
series: [baseSeries, ...props.flag || []]
|
|
29344
29481
|
};
|
|
29345
29482
|
};
|
|
29346
29483
|
const renderTooltip = (params) => {
|