@easyv/config 1.0.53 → 1.1.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/CHANGELOG.md +8 -0
- package/lib/animation.js +71 -36
- package/lib/series.js +3 -2
- package/package.json +8 -4
- package/src/animation.js +61 -30
- package/src/series.js +2 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,14 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
|
4
4
|
|
|
5
|
+
## [1.1.0](https://gitlab.prod.dtstack.cn:10022/visdev/visApplication/easyv-config/compare/v1.0.53...v1.1.0) (2022-04-27)
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
### Features
|
|
9
|
+
|
|
10
|
+
* **animation.js:** 增加数据动画配置项 ([aae17b3](https://gitlab.prod.dtstack.cn:10022/visdev/visApplication/easyv-config/commit/aae17b34bf57b6cd4055ee622c6830dd8d2d1dab))
|
|
11
|
+
* **animation.js:** interval配置项可选 ([8d49a7a](https://gitlab.prod.dtstack.cn:10022/visdev/visApplication/easyv-config/commit/8d49a7a7cefde401eb2ccf23ef68e97105baf729))
|
|
12
|
+
|
|
5
13
|
### [1.0.53](https://gitlab.prod.dtstack.cn:10022/visdev/visApplication/easyv-config/compare/v1.0.52...v1.0.53) (2022-04-08)
|
|
6
14
|
|
|
7
15
|
### [1.0.52](https://gitlab.prod.dtstack.cn:10022/visdev/visApplication/easyv-config/compare/v1.0.51...v1.0.52) (2022-04-02)
|
package/lib/animation.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.animationOfCarousel = exports.animationOfPie = exports["default"] = void 0;
|
|
6
|
+
exports.animationOfCarousel = exports.animationOfPie = exports.dataAnimation = exports["default"] = void 0;
|
|
7
7
|
|
|
8
8
|
var _ = require("./");
|
|
9
9
|
|
|
@@ -55,6 +55,41 @@ var _default = function _default() {
|
|
|
55
55
|
};
|
|
56
56
|
|
|
57
57
|
exports["default"] = _default;
|
|
58
|
+
var defaultDataAnimation = {
|
|
59
|
+
show: false,
|
|
60
|
+
duration: 3
|
|
61
|
+
};
|
|
62
|
+
|
|
63
|
+
var dataAnimation = function dataAnimation() {
|
|
64
|
+
var _ref2 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : defaultDataAnimation,
|
|
65
|
+
_ref2$show = _ref2.show,
|
|
66
|
+
show = _ref2$show === void 0 ? defaultDataAnimation.show : _ref2$show,
|
|
67
|
+
_ref2$duration = _ref2.duration,
|
|
68
|
+
duration = _ref2$duration === void 0 ? defaultDataAnimation.duration : _ref2$duration;
|
|
69
|
+
|
|
70
|
+
return {
|
|
71
|
+
name: 'dataAnimation',
|
|
72
|
+
displayName: '数据动画',
|
|
73
|
+
value: [{
|
|
74
|
+
name: 'show',
|
|
75
|
+
displayName: '打开',
|
|
76
|
+
value: show,
|
|
77
|
+
type: 'boolean'
|
|
78
|
+
}, {
|
|
79
|
+
rule: [['show', '$eq', true]],
|
|
80
|
+
name: 'duration',
|
|
81
|
+
displayName: '滚动时长',
|
|
82
|
+
value: duration,
|
|
83
|
+
type: 'number',
|
|
84
|
+
config: {
|
|
85
|
+
span: 12,
|
|
86
|
+
suffix: 's'
|
|
87
|
+
}
|
|
88
|
+
}]
|
|
89
|
+
};
|
|
90
|
+
};
|
|
91
|
+
|
|
92
|
+
exports.dataAnimation = dataAnimation;
|
|
58
93
|
var defaultAnimationOfPie = {
|
|
59
94
|
show: true,
|
|
60
95
|
current: {
|
|
@@ -66,20 +101,20 @@ var defaultAnimationOfPie = {
|
|
|
66
101
|
};
|
|
67
102
|
|
|
68
103
|
var animationOfPie = function animationOfPie() {
|
|
69
|
-
var
|
|
70
|
-
|
|
71
|
-
show =
|
|
72
|
-
|
|
104
|
+
var _ref3 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : defaultAnimationOfPie,
|
|
105
|
+
_ref3$show = _ref3.show,
|
|
106
|
+
show = _ref3$show === void 0 ? defaultAnimationOfPie.show : _ref3$show,
|
|
107
|
+
_ref3$current = _ref3.current;
|
|
73
108
|
|
|
74
|
-
|
|
75
|
-
var
|
|
76
|
-
heighten =
|
|
77
|
-
|
|
78
|
-
opacity =
|
|
79
|
-
|
|
80
|
-
interval =
|
|
81
|
-
|
|
82
|
-
interactive =
|
|
109
|
+
_ref3$current = _ref3$current === void 0 ? defaultAnimationOfPie.current : _ref3$current;
|
|
110
|
+
var _ref3$current$heighte = _ref3$current.heighten,
|
|
111
|
+
heighten = _ref3$current$heighte === void 0 ? defaultAnimationOfPie.current.heighten : _ref3$current$heighte,
|
|
112
|
+
_ref3$current$opacity = _ref3$current.opacity,
|
|
113
|
+
opacity = _ref3$current$opacity === void 0 ? defaultAnimationOfPie.current.opacity : _ref3$current$opacity,
|
|
114
|
+
_ref3$interval = _ref3.interval,
|
|
115
|
+
interval = _ref3$interval === void 0 ? defaultAnimationOfPie.interval : _ref3$interval,
|
|
116
|
+
_ref3$interactive = _ref3.interactive,
|
|
117
|
+
interactive = _ref3$interactive === void 0 ? defaultAnimationOfPie.interactive : _ref3$interactive;
|
|
83
118
|
return {
|
|
84
119
|
name: 'animation',
|
|
85
120
|
displayName: '轮播动画',
|
|
@@ -158,26 +193,26 @@ var defaultAnimationOfCarousel = {
|
|
|
158
193
|
};
|
|
159
194
|
|
|
160
195
|
var animationOfCarousel = function animationOfCarousel() {
|
|
161
|
-
var
|
|
162
|
-
|
|
163
|
-
show =
|
|
164
|
-
|
|
196
|
+
var _ref4 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : defaultAnimationOfCarousel,
|
|
197
|
+
_ref4$show = _ref4.show,
|
|
198
|
+
show = _ref4$show === void 0 ? defaultAnimationOfCarousel.show : _ref4$show,
|
|
199
|
+
_ref4$current = _ref4.current;
|
|
165
200
|
|
|
166
|
-
|
|
167
|
-
var
|
|
168
|
-
width =
|
|
169
|
-
|
|
170
|
-
color =
|
|
171
|
-
|
|
172
|
-
textStyle =
|
|
173
|
-
|
|
174
|
-
gap =
|
|
175
|
-
|
|
176
|
-
interval =
|
|
177
|
-
|
|
178
|
-
rotate =
|
|
179
|
-
|
|
180
|
-
interactive =
|
|
201
|
+
_ref4$current = _ref4$current === void 0 ? defaultAnimationOfCarousel.current : _ref4$current;
|
|
202
|
+
var _ref4$current$width = _ref4$current.width,
|
|
203
|
+
width = _ref4$current$width === void 0 ? defaultAnimationOfCarousel.current.width : _ref4$current$width,
|
|
204
|
+
_ref4$current$color = _ref4$current.color,
|
|
205
|
+
color = _ref4$current$color === void 0 ? defaultAnimationOfCarousel.current.color : _ref4$current$color,
|
|
206
|
+
_ref4$current$textSty = _ref4$current.textStyle,
|
|
207
|
+
textStyle = _ref4$current$textSty === void 0 ? defaultAnimationOfCarousel.current.font : _ref4$current$textSty,
|
|
208
|
+
_ref4$current$gap = _ref4$current.gap,
|
|
209
|
+
gap = _ref4$current$gap === void 0 ? defaultAnimationOfCarousel.current.gap : _ref4$current$gap,
|
|
210
|
+
_ref4$interval = _ref4.interval,
|
|
211
|
+
interval = _ref4$interval === void 0 ? defaultAnimationOfCarousel.interval : _ref4$interval,
|
|
212
|
+
_ref4$rotate = _ref4.rotate,
|
|
213
|
+
rotate = _ref4$rotate === void 0 ? defaultAnimationOfCarousel.rotate : _ref4$rotate,
|
|
214
|
+
_ref4$interactive = _ref4.interactive,
|
|
215
|
+
interactive = _ref4$interactive === void 0 ? defaultAnimationOfCarousel.interactive : _ref4$interactive;
|
|
181
216
|
return {
|
|
182
217
|
name: 'animation',
|
|
183
218
|
displayName: '轮播动画',
|
|
@@ -204,7 +239,7 @@ var animationOfCarousel = function animationOfCarousel() {
|
|
|
204
239
|
name: 'textStyle',
|
|
205
240
|
displayName: '类目文本样式',
|
|
206
241
|
value: (0, _.font)(textStyle),
|
|
207
|
-
type:
|
|
242
|
+
type: 'textStyle',
|
|
208
243
|
markColorType: 'textColor'
|
|
209
244
|
}, {
|
|
210
245
|
name: 'gap',
|
|
@@ -212,7 +247,7 @@ var animationOfCarousel = function animationOfCarousel() {
|
|
|
212
247
|
value: gap,
|
|
213
248
|
type: 'number',
|
|
214
249
|
config: {
|
|
215
|
-
suffix:
|
|
250
|
+
suffix: 'px'
|
|
216
251
|
}
|
|
217
252
|
}],
|
|
218
253
|
config: {
|
|
@@ -242,7 +277,7 @@ var animationOfCarousel = function animationOfCarousel() {
|
|
|
242
277
|
name: 'interactive',
|
|
243
278
|
displayName: '点击交互',
|
|
244
279
|
value: interactive,
|
|
245
|
-
type:
|
|
280
|
+
type: 'boolean'
|
|
246
281
|
}]
|
|
247
282
|
};
|
|
248
283
|
};
|
package/lib/series.js
CHANGED
|
@@ -333,7 +333,7 @@ var defaultLineSeries = {
|
|
|
333
333
|
};
|
|
334
334
|
var defaultIcon = {
|
|
335
335
|
show: true,
|
|
336
|
-
mode: '
|
|
336
|
+
mode: 'single',
|
|
337
337
|
inner: {
|
|
338
338
|
color: '#83C4FF',
|
|
339
339
|
radius: 3
|
|
@@ -596,7 +596,8 @@ var icon = function icon() {
|
|
|
596
596
|
name: 'color',
|
|
597
597
|
displayName: '颜色',
|
|
598
598
|
value: color,
|
|
599
|
-
type: 'color'
|
|
599
|
+
type: 'color',
|
|
600
|
+
markColorType: 'palette'
|
|
600
601
|
}, {
|
|
601
602
|
rule: [['show', '$eq', true], ['mode', '$eq', 'single']],
|
|
602
603
|
name: 'radius',
|
package/package.json
CHANGED
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@easyv/config",
|
|
3
|
-
"version": "1.0
|
|
3
|
+
"version": "1.1.0",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"scripts": {
|
|
7
7
|
"make": "babel src -d lib",
|
|
8
|
-
"release": "standard-version"
|
|
9
|
-
"publish": "npm run make && npm run release && npm publish --access public"
|
|
8
|
+
"release": "standard-version"
|
|
10
9
|
},
|
|
11
10
|
"keywords": [],
|
|
12
11
|
"author": "",
|
|
@@ -23,5 +22,10 @@
|
|
|
23
22
|
"babel-plugin-transform-import-styles": "0.0.11",
|
|
24
23
|
"babel-preset-env": "^1.7.0",
|
|
25
24
|
"standard-version": "^9.3.2"
|
|
25
|
+
},
|
|
26
|
+
"standard-version": {
|
|
27
|
+
"skip": {
|
|
28
|
+
"commit": true
|
|
29
|
+
}
|
|
26
30
|
}
|
|
27
|
-
}
|
|
31
|
+
}
|
package/src/animation.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { multiColor,font } from './';
|
|
1
|
+
import { multiColor, font } from './';
|
|
2
2
|
const animation = {
|
|
3
3
|
show: false,
|
|
4
4
|
duration: 3,
|
|
@@ -43,6 +43,37 @@ export default ({
|
|
|
43
43
|
],
|
|
44
44
|
});
|
|
45
45
|
|
|
46
|
+
const defaultDataAnimation = {
|
|
47
|
+
show: false,
|
|
48
|
+
duration: 3,
|
|
49
|
+
};
|
|
50
|
+
export const dataAnimation = ({
|
|
51
|
+
show = defaultDataAnimation.show,
|
|
52
|
+
duration = defaultDataAnimation.duration,
|
|
53
|
+
} = defaultDataAnimation) => ({
|
|
54
|
+
name: 'dataAnimation',
|
|
55
|
+
displayName: '数据动画',
|
|
56
|
+
value: [
|
|
57
|
+
{
|
|
58
|
+
name: 'show',
|
|
59
|
+
displayName: '打开',
|
|
60
|
+
value: show,
|
|
61
|
+
type: 'boolean',
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
rule: [['show', '$eq', true]],
|
|
65
|
+
name: 'duration',
|
|
66
|
+
displayName: '滚动时长',
|
|
67
|
+
value: duration,
|
|
68
|
+
type: 'number',
|
|
69
|
+
config: {
|
|
70
|
+
span: 12,
|
|
71
|
+
suffix: 's',
|
|
72
|
+
},
|
|
73
|
+
},
|
|
74
|
+
],
|
|
75
|
+
});
|
|
76
|
+
|
|
46
77
|
const defaultAnimationOfPie = {
|
|
47
78
|
show: true,
|
|
48
79
|
current: { heighten: 10, opacity: 60 },
|
|
@@ -62,10 +93,10 @@ export const animationOfPie = ({
|
|
|
62
93
|
displayName: '轮播动画',
|
|
63
94
|
value: [
|
|
64
95
|
{
|
|
65
|
-
name: 'on',
|
|
66
|
-
displayName: '开启',
|
|
67
|
-
value: show,
|
|
68
|
-
type: 'boolean'
|
|
96
|
+
name: 'on',
|
|
97
|
+
displayName: '开启',
|
|
98
|
+
value: show,
|
|
99
|
+
type: 'boolean',
|
|
69
100
|
},
|
|
70
101
|
{
|
|
71
102
|
rule: [['on', '$eq', true]],
|
|
@@ -84,8 +115,8 @@ export const animationOfPie = ({
|
|
|
84
115
|
value: opacity,
|
|
85
116
|
type: 'range',
|
|
86
117
|
config: {
|
|
87
|
-
min:0,
|
|
88
|
-
max:100,
|
|
118
|
+
min: 0,
|
|
119
|
+
max: 100,
|
|
89
120
|
suffix: '%',
|
|
90
121
|
},
|
|
91
122
|
},
|
|
@@ -122,38 +153,38 @@ export const animationOfPie = ({
|
|
|
122
153
|
],
|
|
123
154
|
});
|
|
124
155
|
|
|
125
|
-
const defaultAnimationOfCarousel= {
|
|
156
|
+
const defaultAnimationOfCarousel = {
|
|
126
157
|
show: true,
|
|
127
|
-
current: {
|
|
128
|
-
width: 0.1,
|
|
158
|
+
current: {
|
|
159
|
+
width: 0.1,
|
|
129
160
|
color: multiColor(),
|
|
130
|
-
font:font(),
|
|
131
|
-
gap: 15
|
|
161
|
+
font: font(),
|
|
162
|
+
gap: 15,
|
|
132
163
|
},
|
|
133
164
|
interval: 3,
|
|
134
165
|
rotate: 30,
|
|
135
166
|
interactive: true,
|
|
136
167
|
};
|
|
137
|
-
export const animationOfCarousel= ({
|
|
168
|
+
export const animationOfCarousel = ({
|
|
138
169
|
show = defaultAnimationOfCarousel.show,
|
|
139
170
|
current: {
|
|
140
171
|
width = defaultAnimationOfCarousel.current.width,
|
|
141
172
|
color = defaultAnimationOfCarousel.current.color,
|
|
142
173
|
textStyle = defaultAnimationOfCarousel.current.font,
|
|
143
|
-
gap = defaultAnimationOfCarousel.current.gap
|
|
174
|
+
gap = defaultAnimationOfCarousel.current.gap,
|
|
144
175
|
} = defaultAnimationOfCarousel.current,
|
|
145
176
|
interval = defaultAnimationOfCarousel.interval,
|
|
146
177
|
rotate = defaultAnimationOfCarousel.rotate,
|
|
147
|
-
interactive = defaultAnimationOfCarousel.interactive
|
|
178
|
+
interactive = defaultAnimationOfCarousel.interactive,
|
|
148
179
|
} = defaultAnimationOfCarousel) => ({
|
|
149
180
|
name: 'animation',
|
|
150
181
|
displayName: '轮播动画',
|
|
151
182
|
value: [
|
|
152
183
|
{
|
|
153
|
-
name: 'on',
|
|
154
|
-
displayName: '开启',
|
|
155
|
-
value: show,
|
|
156
|
-
type: 'boolean'
|
|
184
|
+
name: 'on',
|
|
185
|
+
displayName: '开启',
|
|
186
|
+
value: show,
|
|
187
|
+
type: 'boolean',
|
|
157
188
|
},
|
|
158
189
|
{
|
|
159
190
|
rule: [['on', '$eq', true]],
|
|
@@ -175,19 +206,19 @@ export const animationOfCarousel= ({
|
|
|
175
206
|
{
|
|
176
207
|
name: 'textStyle',
|
|
177
208
|
displayName: '类目文本样式',
|
|
178
|
-
value:font(textStyle),
|
|
179
|
-
type:
|
|
180
|
-
markColorType: 'textColor'
|
|
209
|
+
value: font(textStyle),
|
|
210
|
+
type: 'textStyle',
|
|
211
|
+
markColorType: 'textColor',
|
|
181
212
|
},
|
|
182
213
|
{
|
|
183
214
|
name: 'gap',
|
|
184
215
|
displayName: '类目文本间距',
|
|
185
216
|
value: gap,
|
|
186
217
|
type: 'number',
|
|
187
|
-
config:{
|
|
188
|
-
suffix:
|
|
189
|
-
}
|
|
190
|
-
}
|
|
218
|
+
config: {
|
|
219
|
+
suffix: 'px',
|
|
220
|
+
},
|
|
221
|
+
},
|
|
191
222
|
],
|
|
192
223
|
config: {
|
|
193
224
|
defaultOpen: true,
|
|
@@ -210,8 +241,8 @@ export const animationOfCarousel= ({
|
|
|
210
241
|
value: rotate,
|
|
211
242
|
type: 'number',
|
|
212
243
|
config: {
|
|
213
|
-
min:0,
|
|
214
|
-
max:360,
|
|
244
|
+
min: 0,
|
|
245
|
+
max: 360,
|
|
215
246
|
suffix: '°',
|
|
216
247
|
},
|
|
217
248
|
},
|
|
@@ -219,7 +250,7 @@ export const animationOfCarousel= ({
|
|
|
219
250
|
name: 'interactive',
|
|
220
251
|
displayName: '点击交互',
|
|
221
252
|
value: interactive,
|
|
222
|
-
type:
|
|
223
|
-
}
|
|
253
|
+
type: 'boolean',
|
|
254
|
+
},
|
|
224
255
|
],
|
|
225
256
|
});
|
package/src/series.js
CHANGED
|
@@ -284,7 +284,7 @@ const defaultLineSeries = {
|
|
|
284
284
|
};
|
|
285
285
|
const defaultIcon = {
|
|
286
286
|
show: true,
|
|
287
|
-
mode: '
|
|
287
|
+
mode: 'single',
|
|
288
288
|
inner: { color: '#83C4FF', radius: 3 },
|
|
289
289
|
outer: { color: 'rgba(24,144,255,0.4)', radius: 6 },
|
|
290
290
|
color: '#1283E3',
|
|
@@ -567,6 +567,7 @@ const icon = ({
|
|
|
567
567
|
displayName: '颜色',
|
|
568
568
|
value: color,
|
|
569
569
|
type: 'color',
|
|
570
|
+
markColorType: 'palette',
|
|
570
571
|
},
|
|
571
572
|
{
|
|
572
573
|
rule: [
|