@ecan-bi/datav 1.0.57 → 1.0.60
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/index.es.js +29 -37
- package/dist/index.es.js.map +1 -1
- package/dist/index.umd.js +29 -37
- package/dist/index.umd.js.map +1 -1
- package/dist/style.css +10 -10
- package/package.json +1 -1
- package/types/table/table/Table.vue.d.ts +2 -1
- package/types/table/table/index.d.ts +2 -1
- package/types/text/text/Text.vue.d.ts +22 -0
- package/types/text/text/index.d.ts +22 -0
- package/types/text/text/props.d.ts +12 -0
package/dist/index.es.js
CHANGED
|
@@ -2694,32 +2694,34 @@ const textProps = __spreadProps(__spreadValues({}, props), {
|
|
|
2694
2694
|
justifyContent: "center",
|
|
2695
2695
|
alignItems: "center",
|
|
2696
2696
|
variableFontSize: "14px",
|
|
2697
|
-
data: {}
|
|
2697
|
+
data: {},
|
|
2698
|
+
variableDefaultValue: ""
|
|
2698
2699
|
});
|
|
2699
2700
|
const textComponentProps = transformToComponentProps(textProps);
|
|
2700
2701
|
const textEvents = ["refreshData", "click"];
|
|
2701
|
-
var Text_vue_vue_type_style_index_0_scoped_true_lang = /* @__PURE__ */ (() => ".skeleton-wrapper[data-v-
|
|
2702
|
+
var Text_vue_vue_type_style_index_0_scoped_true_lang = /* @__PURE__ */ (() => ".skeleton-wrapper[data-v-05da96f2] {\n overflow: hidden;\n}\n.ecan-text[data-v-05da96f2] {\n overflow: hidden;\n display: flex;\n}\n")();
|
|
2702
2703
|
const _sfc_main$l = defineComponent({
|
|
2703
2704
|
name: "EcanText",
|
|
2704
2705
|
components: { Skeleton },
|
|
2705
2706
|
props: __spreadValues({}, textComponentProps),
|
|
2706
2707
|
setup(props2) {
|
|
2707
2708
|
const style2 = usePickComponentStyle(props2);
|
|
2708
|
-
const myData =
|
|
2709
|
+
const myData = computed(() => props2.data || {});
|
|
2709
2710
|
const myText = computed(() => {
|
|
2710
|
-
let text = props2.text;
|
|
2711
2711
|
const data = unref(myData);
|
|
2712
|
+
let text = props2.text;
|
|
2713
|
+
text = text == null ? void 0 : text.replace(/\n|\\n/g, "<br />");
|
|
2712
2714
|
const variables = text.match(/\{\w*\}/g);
|
|
2713
2715
|
if (variables == null || variables.length === 0)
|
|
2714
2716
|
return text;
|
|
2715
2717
|
for (let i = 0; i < variables.length; i++) {
|
|
2716
2718
|
const variable = variables[i];
|
|
2717
2719
|
const v = variable.slice(1, variable.length - 1);
|
|
2718
|
-
const usedVariables = data[v]
|
|
2720
|
+
const usedVariables = data[v];
|
|
2719
2721
|
if (usedVariables != null) {
|
|
2720
2722
|
text = text.replace(variable, `<span style="color:${props2.variableColor};font-size:${props2.variableFontSize}">${usedVariables}</span>`);
|
|
2721
2723
|
} else {
|
|
2722
|
-
text = text.replace(variable,
|
|
2724
|
+
text = text.replace(variable, props2.variableDefaultValue);
|
|
2723
2725
|
}
|
|
2724
2726
|
}
|
|
2725
2727
|
return `<span>${text}</span>`;
|
|
@@ -2784,7 +2786,7 @@ function _sfc_render$l(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
2784
2786
|
onClick: _cache[0] || (_cache[0] = (...args) => _ctx.click && _ctx.click(...args))
|
|
2785
2787
|
}, null, 12, _hoisted_1$7));
|
|
2786
2788
|
}
|
|
2787
|
-
var Text = /* @__PURE__ */ _export_sfc(_sfc_main$l, [["render", _sfc_render$l], ["__scopeId", "data-v-
|
|
2789
|
+
var Text = /* @__PURE__ */ _export_sfc(_sfc_main$l, [["render", _sfc_render$l], ["__scopeId", "data-v-05da96f2"]]);
|
|
2788
2790
|
const EcanText = withInstall(Text);
|
|
2789
2791
|
var ScrollText_vue_vue_type_style_index_0_scoped_true_lang = /* @__PURE__ */ (() => ".red[data-v-0bb717eb] {\n color: red;\n}\n")();
|
|
2790
2792
|
const _sfc_main$k = defineComponent({
|
|
@@ -3677,20 +3679,12 @@ const _sfc_main$c = defineComponent({
|
|
|
3677
3679
|
if (props2.target === "event") {
|
|
3678
3680
|
window.parent.postMessage({
|
|
3679
3681
|
type: "openPage",
|
|
3680
|
-
url:
|
|
3682
|
+
url: unref(myHref)
|
|
3681
3683
|
}, "*");
|
|
3682
3684
|
}
|
|
3683
3685
|
});
|
|
3684
3686
|
const myText = computed(() => useVariablesInText(props2.text));
|
|
3685
|
-
const myHref = computed(() =>
|
|
3686
|
-
if (props2.target === "event")
|
|
3687
|
-
return void 0;
|
|
3688
|
-
const href = props2.href;
|
|
3689
|
-
if (href) {
|
|
3690
|
-
return useVariablesInText(href);
|
|
3691
|
-
}
|
|
3692
|
-
return void 0;
|
|
3693
|
-
});
|
|
3687
|
+
const myHref = computed(() => useVariablesInText(props2.href));
|
|
3694
3688
|
const myTarget = computed(() => {
|
|
3695
3689
|
const target = props2.target;
|
|
3696
3690
|
if (target === "event") {
|
|
@@ -6035,7 +6029,7 @@ const imageProps = __spreadProps(__spreadValues({}, props), {
|
|
|
6035
6029
|
linkPage: ""
|
|
6036
6030
|
});
|
|
6037
6031
|
const imageComponentProps = transformToComponentProps(imageProps);
|
|
6038
|
-
var Image_vue_vue_type_style_index_0_scoped_true_lang = /* @__PURE__ */ (() => ".image-placeholder[data-v-
|
|
6032
|
+
var Image_vue_vue_type_style_index_0_scoped_true_lang = /* @__PURE__ */ (() => ".image-placeholder[data-v-e8534084] {\n display: grid;\n place-content: center;\n border: 1px solid #d9d9d9;\n font-size: 16px;\n color: #333;\n width: 100%;\n}\n")();
|
|
6039
6033
|
const _sfc_main$2 = defineComponent({
|
|
6040
6034
|
name: "EcanImage",
|
|
6041
6035
|
props: __spreadValues({}, imageComponentProps),
|
|
@@ -6049,7 +6043,8 @@ const _sfc_main$2 = defineComponent({
|
|
|
6049
6043
|
const linkPage = props2.linkPage || "";
|
|
6050
6044
|
const pageUrl = usePageUrl(unref(pageMode), linkPage);
|
|
6051
6045
|
const href = props2.href;
|
|
6052
|
-
|
|
6046
|
+
let url = href || pageUrl;
|
|
6047
|
+
url = useVariablesInText(url);
|
|
6053
6048
|
const target = props2.target;
|
|
6054
6049
|
if (target == null || target === "")
|
|
6055
6050
|
return;
|
|
@@ -6082,7 +6077,7 @@ function _sfc_render$2(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
6082
6077
|
style: normalizeStyle(_ctx.style)
|
|
6083
6078
|
}, " \u8BF7\u4E0A\u4F20\u56FE\u7247 ", 4));
|
|
6084
6079
|
}
|
|
6085
|
-
var Image = /* @__PURE__ */ _export_sfc(_sfc_main$2, [["render", _sfc_render$2], ["__scopeId", "data-v-
|
|
6080
|
+
var Image = /* @__PURE__ */ _export_sfc(_sfc_main$2, [["render", _sfc_render$2], ["__scopeId", "data-v-e8534084"]]);
|
|
6086
6081
|
const EcanImage = withInstall(Image);
|
|
6087
6082
|
const tableProps = __spreadProps(__spreadValues({}, props), {
|
|
6088
6083
|
zIndex: 2,
|
|
@@ -6147,16 +6142,16 @@ const tableProps = __spreadProps(__spreadValues({}, props), {
|
|
|
6147
6142
|
});
|
|
6148
6143
|
const tableComponentProps = transformToComponentProps(tableProps);
|
|
6149
6144
|
const tableEvents = ["click", "refreshData"];
|
|
6150
|
-
var Table_vue_vue_type_style_index_0_scoped_true_lang = /* @__PURE__ */ (() => `.table[data-v-
|
|
6145
|
+
var Table_vue_vue_type_style_index_0_scoped_true_lang = /* @__PURE__ */ (() => `.table[data-v-ec4475ea] {
|
|
6151
6146
|
width: 100%;
|
|
6152
6147
|
}
|
|
6153
|
-
.goUp[data-v-
|
|
6148
|
+
.goUp[data-v-ec4475ea] {
|
|
6154
6149
|
color: #FF512E;
|
|
6155
6150
|
display: flex;
|
|
6156
6151
|
align-items: center;
|
|
6157
6152
|
justify-content: center;
|
|
6158
6153
|
}
|
|
6159
|
-
.goUp[data-v-
|
|
6154
|
+
.goUp[data-v-ec4475ea]:before {
|
|
6160
6155
|
content: '';
|
|
6161
6156
|
display: block;
|
|
6162
6157
|
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAMAAADXqc3KAAAAV1BMVEUAAAD/WzT/WjP/WDD/WzT/WzP/WzT/WzT/WzT/WjT/WzT/WDT/YED/WzT/WzT/WjT/YED/WzT/WzT/WzT/XDT/WzT/WjX/WjP/XDT/XDT/WTL/Tif/WzReH8z5AAAAHHRSTlMA8RgS9W9YHbePZyME5sVjCP7bzcCxgndOQC4GFJJgKwAAAIJJREFUKM+Nkd0OgyAMRjvqcLA53fzXvv9zaokmxq8mnsue5ACFDjiy+XyjLZ7yyK35OxN5mSFZKa2QojEIKRhrZKM0QnsMQxirmJ0kBubTIZvAtUyiFAT4JFoUIYmIotZ5xjDPfyoCAV16nMPdFir8xZ16nM//tePtXw2ODOJY0V0WqQwM2rgKrU0AAAAASUVORK5CYII=");
|
|
@@ -6166,13 +6161,13 @@ var Table_vue_vue_type_style_index_0_scoped_true_lang = /* @__PURE__ */ (() => `
|
|
|
6166
6161
|
background-size: cover;
|
|
6167
6162
|
margin-right: 2px;
|
|
6168
6163
|
}
|
|
6169
|
-
.goDown[data-v-
|
|
6164
|
+
.goDown[data-v-ec4475ea] {
|
|
6170
6165
|
color: #39cf93;
|
|
6171
6166
|
display: flex;
|
|
6172
6167
|
align-items: center;
|
|
6173
6168
|
justify-content: center;
|
|
6174
6169
|
}
|
|
6175
|
-
.goDown[data-v-
|
|
6170
|
+
.goDown[data-v-ec4475ea]:before {
|
|
6176
6171
|
content: '';
|
|
6177
6172
|
display: block;
|
|
6178
6173
|
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAACXBIWXMAAAsTAAALEwEAmpwYAAAFHGlUWHRYTUw6Y29tLmFkb2JlLnhtcAAAAAAAPD94cGFja2V0IGJlZ2luPSLvu78iIGlkPSJXNU0wTXBDZWhpSHpyZVN6TlRjemtjOWQiPz4gPHg6eG1wbWV0YSB4bWxuczp4PSJhZG9iZTpuczptZXRhLyIgeDp4bXB0az0iQWRvYmUgWE1QIENvcmUgNS42LWMxNDUgNzkuMTYzNDk5LCAyMD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5kaWQ6MzZkZTc4NjEtZDc4Zi00MjRmLWEzYzktNWU5NDI5MGNkY2YxIj4gPHhtcE1NOkhpc3Rvcnk+IDxyZGY6U2VxPiA8cmRmOmxpIHN0RXZ0OmFjdGlvbj0iY3JlYXRlZCIgc3RFdnQ6aW5zdGFuY2VJRD0ieG1wLmlpZDozNmRlNzg2MS1kNzhmLTQyNGYtYTNjOS01ZTk0MjkwY2RjZjEiIHN0RXZ0OndoZW49IjIwMjItMDctMjJUMDk6MzU6MTkrMDg6MDAiIHN0RXZ0OnNvZnR3YXJlQWdlbnQ9IkFkb2JlIFBob3Rvc2hvcCBDQyAyMDE5IChXaW5kb3dzKSIvPiA8L3JkZjpTZXE+IDwveG1wTU06SGlzdG9yeT4gPC9yZGY6RGVzY3JpcHRpb24+IDwvcmRmOlJERj4gPC94OnhtcG1ldGE+IDw/eHBhY2tldCBlbmQ9InIiPz6VDI+BAAABUUlEQVRIia3WPyhGURgG8B8pi0xisStKMioZLQaLiaQMBoxiVBImCwaLf6MssloUk8Gmb7GgJFKSUvIZ7qe+bvd89+A+03uf989z3nPPPe+tK5fLqtF3tSESzRjFAJ4vemams4IaYqulCq9gEo34QGco+LcCg9hHaxW3jpsiBIZxmMp5kXQTRH1k8S4cZCxoE6//FaiXbEtThm87JjkPI+jN4E9xW4TAQoA/isjNFehCT8B3VoTAUID/xHURAn0B/g5fRQh0B/j7mOJkf2gTaKvY7YG8FsxXPe/hIVbgCTs5C+vAasU+xlooMGuLTrCVI/CDR0zVCgi9gzmUIgQmBbYmT+AdY5LjGMKWpNuaqHWKLrEY8JUkXeYi75iu4DzFfUi6ey9C4AvjeKviliTdRSHmsrvBbMU+lzNg0oidaLvox7LIK+IHdem/iqIROzL/jG+NrT1BRsXKNQAAAABJRU5ErkJggg==");
|
|
@@ -6182,11 +6177,11 @@ var Table_vue_vue_type_style_index_0_scoped_true_lang = /* @__PURE__ */ (() => `
|
|
|
6182
6177
|
background-size: cover;
|
|
6183
6178
|
margin-right: 2px;
|
|
6184
6179
|
}
|
|
6185
|
-
.action-list[data-v-
|
|
6180
|
+
.action-list[data-v-ec4475ea] {
|
|
6186
6181
|
display: flex;
|
|
6187
6182
|
width: 100%;
|
|
6188
6183
|
}
|
|
6189
|
-
.action[data-v-
|
|
6184
|
+
.action[data-v-ec4475ea] {
|
|
6190
6185
|
flex: 1;
|
|
6191
6186
|
}
|
|
6192
6187
|
`)();
|
|
@@ -6316,7 +6311,8 @@ const _sfc_main$1 = defineComponent({
|
|
|
6316
6311
|
position,
|
|
6317
6312
|
total: unref(total),
|
|
6318
6313
|
current: unref(pageNum),
|
|
6319
|
-
pageSize: unref(pageSize)
|
|
6314
|
+
pageSize: unref(pageSize),
|
|
6315
|
+
showSizeChanger: false
|
|
6320
6316
|
};
|
|
6321
6317
|
});
|
|
6322
6318
|
const formatBoolean = (value) => {
|
|
@@ -6441,12 +6437,8 @@ const _sfc_main$1 = defineComponent({
|
|
|
6441
6437
|
expose({
|
|
6442
6438
|
refreshData
|
|
6443
6439
|
});
|
|
6444
|
-
const handleHref = (
|
|
6445
|
-
|
|
6446
|
-
return void 0;
|
|
6447
|
-
} else {
|
|
6448
|
-
return useVariablesInText(href, data);
|
|
6449
|
-
}
|
|
6440
|
+
const handleHref = (href = "", data) => {
|
|
6441
|
+
return useVariablesInText(href, data);
|
|
6450
6442
|
};
|
|
6451
6443
|
const handleHrefTarget = (target) => {
|
|
6452
6444
|
if (target === "event") {
|
|
@@ -6532,14 +6524,14 @@ function _sfc_render$1(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
6532
6524
|
key: index22
|
|
6533
6525
|
}, [
|
|
6534
6526
|
createElementVNode("a", {
|
|
6535
|
-
href: _ctx.handleHref(action.
|
|
6527
|
+
href: _ctx.handleHref(action.href, record),
|
|
6536
6528
|
target: _ctx.handleHrefTarget(action.target),
|
|
6537
6529
|
style: normalizeStyle({
|
|
6538
6530
|
color: action.color,
|
|
6539
6531
|
fontSize: _ctx.fontSize,
|
|
6540
6532
|
fontWeight: _ctx.fontWeight
|
|
6541
6533
|
}),
|
|
6542
|
-
onClick: ($event) => _ctx.onTouchHrefEvent(action.target, action.href)
|
|
6534
|
+
onClick: ($event) => _ctx.onTouchHrefEvent(action.target, _ctx.handleHref(action.href, record))
|
|
6543
6535
|
}, toDisplayString(action.title), 13, _hoisted_2)
|
|
6544
6536
|
]);
|
|
6545
6537
|
}), 128))
|
|
@@ -6590,7 +6582,7 @@ function _sfc_render$1(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
6590
6582
|
}, 8, ["loading"])
|
|
6591
6583
|
], 4);
|
|
6592
6584
|
}
|
|
6593
|
-
var Table = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["render", _sfc_render$1], ["__scopeId", "data-v-
|
|
6585
|
+
var Table = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["render", _sfc_render$1], ["__scopeId", "data-v-ec4475ea"]]);
|
|
6594
6586
|
const EcanTable = withInstall(Table);
|
|
6595
6587
|
const mapProps = __spreadProps(__spreadValues({}, props), {
|
|
6596
6588
|
mapJson: null,
|