@easyv/charts 1.6.5 → 1.6.6
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.
|
@@ -38,10 +38,11 @@ var _default = /*#__PURE__*/(0, _react.memo)(function (_ref) {
|
|
|
38
38
|
lineHeight = _ref$config$tip$data$2.lineHeight,
|
|
39
39
|
dataGap = _ref$config$tip$data$2.gap,
|
|
40
40
|
iconSize = _ref$config$tip$data$2.iconSize,
|
|
41
|
-
|
|
41
|
+
dataBg = _ref$config$tip$data$2.background,
|
|
42
42
|
name = _ref$config$tip$data$2.name,
|
|
43
43
|
value = _ref$config$tip$data$2.value,
|
|
44
44
|
suffix = _ref$config$tip$data$2.suffix,
|
|
45
|
+
bgType = _ref$config$tip.bgType,
|
|
45
46
|
bgColor = _ref$config$tip.bgColor,
|
|
46
47
|
image = _ref$config$tip.image,
|
|
47
48
|
margin = _ref$config$tip.margin,
|
|
@@ -81,7 +82,7 @@ var _default = /*#__PURE__*/(0, _react.memo)(function (_ref) {
|
|
|
81
82
|
width: tipWidth,
|
|
82
83
|
minHeight: tipHeight,
|
|
83
84
|
padding: (0, _utils.getMargin)(margin),
|
|
84
|
-
background: image ? '50% 50% / 100% 100% no-repeat url(' + window.appConfig.ASSETS_URL + image + ')' : bgColor
|
|
85
|
+
background: bgType == "image" ? image ? '50% 50% / 100% 100% no-repeat url(' + window.appConfig.ASSETS_URL + image + ')' : "transparent" : bgColor
|
|
85
86
|
}, (0, _utils.getFontStyle)(font))
|
|
86
87
|
}, formatter ? formatter({
|
|
87
88
|
series: series,
|
|
@@ -93,19 +94,28 @@ var _default = /*#__PURE__*/(0, _react.memo)(function (_ref) {
|
|
|
93
94
|
data: data,
|
|
94
95
|
config: dataConfig
|
|
95
96
|
}
|
|
96
|
-
}) : /*#__PURE__*/React.createElement("
|
|
97
|
+
}) : /*#__PURE__*/React.createElement("div", {
|
|
97
98
|
style: {
|
|
98
99
|
display: 'flex',
|
|
99
100
|
flexDirection: 'column',
|
|
100
101
|
justifyContent: 'space-between',
|
|
102
|
+
gap: gap,
|
|
101
103
|
height: '100%'
|
|
102
104
|
}
|
|
103
|
-
}, /*#__PURE__*/React.createElement("
|
|
105
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
104
106
|
style: _objectSpread({
|
|
105
107
|
textAlign: align,
|
|
106
|
-
transform: (0, _utils.getTranslate3d)(translateXAxis)
|
|
108
|
+
transform: (0, _utils.getTranslate3d)(translateXAxis),
|
|
109
|
+
background: background ? "url(".concat(window.appConfig.ASSETS_URL + background, ") 0 0/100% 100%") : "transparent"
|
|
107
110
|
}, font)
|
|
108
|
-
}, x),
|
|
111
|
+
}, x), /*#__PURE__*/React.createElement("div", {
|
|
112
|
+
style: {
|
|
113
|
+
display: "flex",
|
|
114
|
+
flexFlow: "column nowrap",
|
|
115
|
+
gap: dataGap,
|
|
116
|
+
background: dataBg ? "url(".concat(window.appConfig.ASSETS_URL + dataBg, ") 0 0/100% 100%") : "transparent"
|
|
117
|
+
}
|
|
118
|
+
}, data.map(function (_ref2, index) {
|
|
109
119
|
var showY = _ref2.showY,
|
|
110
120
|
s = _ref2.s;
|
|
111
121
|
|
|
@@ -156,7 +166,7 @@ var _default = /*#__PURE__*/(0, _react.memo)(function (_ref) {
|
|
|
156
166
|
transform: (0, _utils.getTranslate3d)(suffixTranslate)
|
|
157
167
|
})
|
|
158
168
|
}, tmp.get(s))));
|
|
159
|
-
})));
|
|
169
|
+
}))));
|
|
160
170
|
});
|
|
161
171
|
|
|
162
172
|
exports["default"] = _default;
|
package/package.json
CHANGED
|
@@ -20,6 +20,7 @@ export default memo(
|
|
|
20
20
|
data: dataConfig,
|
|
21
21
|
data: { lineHeight, gap:dataGap, iconSize, background:dataBg, name, value, suffix },
|
|
22
22
|
},
|
|
23
|
+
bgType,
|
|
23
24
|
bgColor,
|
|
24
25
|
image,
|
|
25
26
|
margin,
|
|
@@ -70,12 +71,12 @@ export default memo(
|
|
|
70
71
|
width: tipWidth,
|
|
71
72
|
minHeight: tipHeight,
|
|
72
73
|
padding: getMargin(margin),
|
|
73
|
-
background: image
|
|
74
|
+
background: bgType=="image"?image
|
|
74
75
|
? '50% 50% / 100% 100% no-repeat url(' +
|
|
75
76
|
window.appConfig.ASSETS_URL +
|
|
76
77
|
image +
|
|
77
78
|
')'
|
|
78
|
-
: bgColor,
|
|
79
|
+
: "transparent":bgColor,
|
|
79
80
|
...getFontStyle(font),
|
|
80
81
|
}}
|
|
81
82
|
>
|