mrxy-yk 1.2.3 → 1.2.4-alpha.2
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/config/index.d.ts +7 -0
- package/dist/config/index.js +4 -0
- package/dist/element-plus/components/date-picker/index.js +1 -1
- package/dist/element-plus/components/upload/select-file/SelectFile.d.ts +1 -1
- package/dist/element-plus/components/upload/upload-files/UploadFiles.d.ts +1 -1
- package/dist/element-plus/components/upload/upload-images/UploadImages.d.ts +1 -1
- package/dist/utils/echarts/modules/coordinate/basic.js +2 -1
- package/dist/utils/echarts/modules/type.d.ts +2 -2
- package/dist/utils/echarts/themes/dark.js +14 -1
- package/dist/utils/echarts/utils/assignOption.js +2 -1
- package/package.json +3 -3
- package/web-types.json +1 -1
package/dist/config/index.d.ts
CHANGED
|
@@ -22,3 +22,10 @@ export interface EmptyTypeInterface {
|
|
|
22
22
|
* }
|
|
23
23
|
*/
|
|
24
24
|
export declare const EmptyStatusExtendConfig: Record<Capitalize<string>, EmptyOption>;
|
|
25
|
+
/**
|
|
26
|
+
* ECharts主题配置
|
|
27
|
+
* 配置的主题会和默认主题合并,如果需要覆盖请使用echarts.registerTheme方法注册主题
|
|
28
|
+
*/
|
|
29
|
+
export declare const EChartsThemeConfig: {
|
|
30
|
+
dark: Record<string, any>;
|
|
31
|
+
};
|
package/dist/config/index.js
CHANGED
|
@@ -28,7 +28,7 @@ class DatePickerType {
|
|
|
28
28
|
}
|
|
29
29
|
defaultDateStandardHandle(unit) {
|
|
30
30
|
if (!this.props.defaultDate) return;
|
|
31
|
-
const value = dayjs().subtract(this.props.defaultDate - 1, unit).format("YYYY-MM-DD HH:mm:ss");
|
|
31
|
+
const value = dayjs().startOf(unit).subtract(this.props.defaultDate - 1, unit).format("YYYY-MM-DD HH:mm:ss");
|
|
32
32
|
this.setModelValue(value);
|
|
33
33
|
}
|
|
34
34
|
// endregion
|
|
@@ -417,8 +417,8 @@ declare const __VLS_component: DefineComponent<__VLS_Props, {}, {}, {}, {}, Comp
|
|
|
417
417
|
onChange?: (...args: any[]) => any;
|
|
418
418
|
onError?: (...args: any[]) => any;
|
|
419
419
|
}>, {
|
|
420
|
-
maxSize: number;
|
|
421
420
|
accept: string;
|
|
421
|
+
maxSize: number;
|
|
422
422
|
}, {}, {}, {}, string, ComponentProvideOptions, true, {
|
|
423
423
|
uploadRef: {
|
|
424
424
|
$: ComponentInternalInstance;
|
|
@@ -436,10 +436,10 @@ declare const __VLS_component: DefineComponent<__VLS_Props, {
|
|
|
436
436
|
width: string;
|
|
437
437
|
height: string;
|
|
438
438
|
drag: boolean;
|
|
439
|
-
maxSize: number;
|
|
440
439
|
isJoin: boolean;
|
|
441
440
|
uploadClass: string;
|
|
442
441
|
accept: string;
|
|
442
|
+
maxSize: number;
|
|
443
443
|
limit: number;
|
|
444
444
|
}, {}, {}, {}, string, ComponentProvideOptions, false, {
|
|
445
445
|
uploadRef: {
|
|
@@ -434,10 +434,10 @@ declare const __VLS_component: DefineComponent<__VLS_Props, {
|
|
|
434
434
|
}>, {
|
|
435
435
|
width: string;
|
|
436
436
|
height: string;
|
|
437
|
-
maxSize: number;
|
|
438
437
|
isJoin: boolean;
|
|
439
438
|
uploadClass: string;
|
|
440
439
|
accept: string;
|
|
440
|
+
maxSize: number;
|
|
441
441
|
limit: number;
|
|
442
442
|
}, {}, {}, {}, string, ComponentProvideOptions, false, {
|
|
443
443
|
uploadRef: {
|
|
@@ -49,7 +49,8 @@ class EcBasicOption {
|
|
|
49
49
|
// 获取EChartOption配置
|
|
50
50
|
valueOf() {
|
|
51
51
|
const option = this.currentOption;
|
|
52
|
-
const
|
|
52
|
+
const optionSeries = option.series;
|
|
53
|
+
const series = optionSeries.map((item) => {
|
|
53
54
|
return item instanceof EcBasicSeries ? item.valueOf() : item;
|
|
54
55
|
});
|
|
55
56
|
const defaultGrid = ObjectUtil.copy(this.defaultGrid);
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { BarSeriesOption, EChartsOption, LineSeriesOption, SeriesOption } from 'echarts';
|
|
2
2
|
import { EcBasicSeries } from '.';
|
|
3
3
|
// region 根配置
|
|
4
|
-
export type EcOptionBasicOption = EChartsOption & {
|
|
5
|
-
series?: EcSeriesBasicOption[]
|
|
4
|
+
export type EcOptionBasicOption = Omit<EChartsOption, 'series'> & {
|
|
5
|
+
series?: EcSeriesBasicOption | EcSeriesBasicOption[]
|
|
6
6
|
}
|
|
7
7
|
export type EcSeriesBasicOption<T = SeriesOption> = EcBasicSeries | T
|
|
8
8
|
// endregion
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { EChartsThemeConfig } from "../../../config/index.js";
|
|
2
|
+
import { ObjectUtil } from "../../prototype/lib/ObjectUtil.js";
|
|
1
3
|
const contrastColor = "#ededf3";
|
|
2
4
|
const backgroundColor = "rgba(0, 0, 0, 0)";
|
|
3
5
|
const axisCommon = function() {
|
|
@@ -156,8 +158,16 @@ const theme = {
|
|
|
156
158
|
logAxis: axisCommon(),
|
|
157
159
|
valueAxis: axisCommon(),
|
|
158
160
|
categoryAxis: axisCommon(),
|
|
161
|
+
bar: {
|
|
162
|
+
label: {
|
|
163
|
+
color: contrastColor
|
|
164
|
+
}
|
|
165
|
+
},
|
|
159
166
|
line: {
|
|
160
|
-
symbol: "
|
|
167
|
+
symbol: "emptyCircle",
|
|
168
|
+
label: {
|
|
169
|
+
color: contrastColor
|
|
170
|
+
}
|
|
161
171
|
},
|
|
162
172
|
graph: {
|
|
163
173
|
color: colorPalette
|
|
@@ -177,6 +187,9 @@ const theme = {
|
|
|
177
187
|
}
|
|
178
188
|
};
|
|
179
189
|
theme.categoryAxis.splitLine.show = false;
|
|
190
|
+
if (EChartsThemeConfig.dark) {
|
|
191
|
+
ObjectUtil.assignDeep(theme, EChartsThemeConfig.dark);
|
|
192
|
+
}
|
|
180
193
|
export {
|
|
181
194
|
theme as default
|
|
182
195
|
};
|
|
@@ -18,7 +18,8 @@ function assignEcOptionBasicOption(target, source) {
|
|
|
18
18
|
source.series = [series];
|
|
19
19
|
}
|
|
20
20
|
if (target.series) {
|
|
21
|
-
|
|
21
|
+
const sourceSeries = source.series;
|
|
22
|
+
for (let i = 0, len = sourceSeries.length; i < len; i++) {
|
|
22
23
|
const targetItem = target.series[i];
|
|
23
24
|
const sourceItem = source.series[i];
|
|
24
25
|
if (!targetItem || sourceItem instanceof EcBasicSeries) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "mrxy-yk",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.4-alpha.2",
|
|
4
4
|
"private": false,
|
|
5
5
|
"type": "module",
|
|
6
6
|
"description": "A collection of Vue 3 components and utilities",
|
|
@@ -83,12 +83,12 @@
|
|
|
83
83
|
},
|
|
84
84
|
"peerDependencies": {
|
|
85
85
|
"element-plus": "^2.6.0",
|
|
86
|
-
"vue": "^3.5.0"
|
|
86
|
+
"vue": "^3.5.0",
|
|
87
|
+
"dayjs": "^1.11.0"
|
|
87
88
|
},
|
|
88
89
|
"dependencies": {
|
|
89
90
|
"@amap/amap-jsapi-loader": "1.0.1",
|
|
90
91
|
"@element-plus/icons-vue": "2.3.2",
|
|
91
|
-
"dayjs": "1.11.19",
|
|
92
92
|
"echarts": "6.0.0",
|
|
93
93
|
"ezuikit-js": "8.2.4",
|
|
94
94
|
"jszip": "3.10.1",
|