@visactor/vseed 0.1.31 → 0.1.33
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/cjs/index.cjs +3 -3
- package/dist/cjs/index.cjs.map +1 -1
- package/dist/esm/builder/builder/builder.d.ts +6238 -0
- package/dist/esm/pipeline/advanced/table/pipes/default/defaultMeasureName.js +1 -1
- package/dist/esm/pipeline/advanced/table/pipes/default/defaultMeasureName.js.map +1 -1
- package/dist/esm/pipeline/spec/chart/pipes/annotation/annotationArea.js +10 -7
- package/dist/esm/pipeline/spec/chart/pipes/annotation/annotationArea.js.map +1 -1
- package/dist/esm/pipeline/spec/chart/pipes/annotation/annotationAreaBand.js +19 -7
- package/dist/esm/pipeline/spec/chart/pipes/annotation/annotationAreaBand.js.map +1 -1
- package/dist/esm/pipeline/spec/chart/pipes/annotation/annotationHorizontalLine.js +20 -9
- package/dist/esm/pipeline/spec/chart/pipes/annotation/annotationHorizontalLine.js.map +1 -1
- package/dist/esm/pipeline/spec/chart/pipes/annotation/annotationPoint.js +4 -3
- package/dist/esm/pipeline/spec/chart/pipes/annotation/annotationPoint.js.map +1 -1
- package/dist/esm/pipeline/spec/chart/pipes/annotation/annotationVerticalLine.js +20 -8
- package/dist/esm/pipeline/spec/chart/pipes/annotation/annotationVerticalLine.js.map +1 -1
- package/dist/esm/pipeline/spec/chart/pipes/axes/xBand.js +2 -1
- package/dist/esm/pipeline/spec/chart/pipes/axes/xBand.js.map +1 -1
- package/dist/esm/pipeline/spec/chart/pipes/axes/xLinear.js +2 -1
- package/dist/esm/pipeline/spec/chart/pipes/axes/xLinear.js.map +1 -1
- package/dist/esm/pipeline/spec/chart/pipes/axes/yBand.js +2 -1
- package/dist/esm/pipeline/spec/chart/pipes/axes/yBand.js.map +1 -1
- package/dist/esm/pipeline/spec/chart/pipes/axes/yLinear.js +2 -1
- package/dist/esm/pipeline/spec/chart/pipes/axes/yLinear.js.map +1 -1
- package/dist/esm/pipeline/spec/chart/pipes/axes/yLinearPrimary.js +2 -1
- package/dist/esm/pipeline/spec/chart/pipes/axes/yLinearPrimary.js.map +1 -1
- package/dist/esm/pipeline/spec/chart/pipes/axes/yLinearSecondary.js +2 -1
- package/dist/esm/pipeline/spec/chart/pipes/axes/yLinearSecondary.js.map +1 -1
- package/dist/esm/pipeline/spec/chart/pipes/crosshair/horizontalCrosshairLine.js +1 -1
- package/dist/esm/pipeline/spec/chart/pipes/crosshair/horizontalCrosshairLine.js.map +1 -1
- package/dist/esm/pipeline/spec/chart/pipes/crosshair/verticalCrosshairLine.js +1 -1
- package/dist/esm/pipeline/spec/chart/pipes/crosshair/verticalCrosshairLine.js.map +1 -1
- package/dist/esm/pipeline/spec/chart/pipes/markStyle/pieStyle.js +11 -13
- package/dist/esm/pipeline/spec/chart/pipes/markStyle/pieStyle.js.map +1 -1
- package/dist/esm/theme/common/annotaion.d.ts +22 -0
- package/dist/esm/theme/common/annotaion.js +114 -0
- package/dist/esm/theme/common/annotaion.js.map +1 -0
- package/dist/esm/theme/common/axes.js +22 -6
- package/dist/esm/theme/common/axes.js.map +1 -1
- package/dist/esm/theme/common/crosshair.js +5 -5
- package/dist/esm/theme/common/crosshair.js.map +1 -1
- package/dist/esm/theme/dark/dark.js +23 -11
- package/dist/esm/theme/dark/dark.js.map +1 -1
- package/dist/esm/theme/light/light.js +23 -11
- package/dist/esm/theme/light/light.js.map +1 -1
- package/dist/esm/types/advancedVSeed.d.ts +2288 -0
- package/dist/esm/types/chartType/area/zArea.d.ts +5 -0
- package/dist/esm/types/chartType/areaPercent/zAreaPercent.d.ts +5 -0
- package/dist/esm/types/chartType/bar/zBar.d.ts +4 -0
- package/dist/esm/types/chartType/barParallel/zBarParallel.d.ts +4 -0
- package/dist/esm/types/chartType/barPercent/zBarPercent.d.ts +4 -0
- package/dist/esm/types/chartType/column/zColumn.d.ts +4 -0
- package/dist/esm/types/chartType/columnParallel/zColumnParallel.d.ts +4 -0
- package/dist/esm/types/chartType/columnPercent/zColumnPercent.d.ts +4 -0
- package/dist/esm/types/chartType/dualAxis/zDualAxis.d.ts +7 -0
- package/dist/esm/types/chartType/line/zLine.d.ts +5 -0
- package/dist/esm/types/chartType/scatter/zScatter.d.ts +5 -0
- package/dist/esm/types/properties/annotation/annotation.d.ts +2 -0
- package/dist/esm/types/properties/annotation/annotationArea.d.ts +6 -1
- package/dist/esm/types/properties/annotation/zAnnotationArea.d.ts +1 -0
- package/dist/esm/types/properties/annotation/zAnnotationArea.js +1 -0
- package/dist/esm/types/properties/annotation/zAnnotationArea.js.map +1 -1
- package/dist/esm/types/properties/config/annotation/annotation.d.ts +76 -0
- package/dist/esm/types/properties/config/annotation/annotation.js +0 -0
- package/dist/esm/types/properties/config/annotation/index.d.ts +2 -0
- package/dist/esm/types/properties/config/annotation/index.js +1 -0
- package/dist/esm/types/properties/config/annotation/zAnnotaion.d.ts +169 -0
- package/dist/esm/types/properties/config/annotation/zAnnotaion.js +58 -0
- package/dist/esm/types/properties/config/annotation/zAnnotaion.js.map +1 -0
- package/dist/esm/types/properties/config/axes/bandAxis.d.ts +4 -0
- package/dist/esm/types/properties/config/axes/linearAxis.d.ts +4 -0
- package/dist/esm/types/properties/config/axes/zBandAxis.d.ts +2 -0
- package/dist/esm/types/properties/config/axes/zBandAxis.js +2 -1
- package/dist/esm/types/properties/config/axes/zBandAxis.js.map +1 -1
- package/dist/esm/types/properties/config/axes/zLinearAxis.d.ts +2 -0
- package/dist/esm/types/properties/config/axes/zLinearAxis.js +2 -1
- package/dist/esm/types/properties/config/axes/zLinearAxis.js.map +1 -1
- package/dist/esm/types/properties/config/config.d.ts +2286 -0
- package/dist/esm/types/properties/config/config.js +15 -7
- package/dist/esm/types/properties/config/config.js.map +1 -1
- package/dist/esm/types/properties/config/crosshair/zCrosshair.d.ts +1 -0
- package/dist/esm/types/properties/config/crosshair/zCrosshair.js +2 -1
- package/dist/esm/types/properties/config/crosshair/zCrosshair.js.map +1 -1
- package/dist/esm/types/properties/theme/customTheme.d.ts +2286 -0
- package/dist/esm/types/zVseed.d.ts +51 -0
- package/dist/umd/index.js +526 -274
- package/dist/umd/index.js.map +1 -1
- package/package.json +4 -4
package/dist/umd/index.js
CHANGED
|
@@ -1340,7 +1340,7 @@
|
|
|
1340
1340
|
if (measures.length > 1 && !result.dimensions?.some((dim)=>dim.id === MeasureName)) result.dimensions?.push({
|
|
1341
1341
|
id: MeasureName,
|
|
1342
1342
|
alias: intl.i18n`指标名称`,
|
|
1343
|
-
encoding: '
|
|
1343
|
+
encoding: 'row'
|
|
1344
1344
|
});
|
|
1345
1345
|
return result;
|
|
1346
1346
|
};
|
|
@@ -2737,7 +2737,8 @@
|
|
|
2737
2737
|
visible: grid?.visible,
|
|
2738
2738
|
style: {
|
|
2739
2739
|
lineWidth: grid?.gridWidth,
|
|
2740
|
-
stroke: grid?.gridColor
|
|
2740
|
+
stroke: grid?.gridColor,
|
|
2741
|
+
lineDash: grid?.gridLineDash
|
|
2741
2742
|
}
|
|
2742
2743
|
},
|
|
2743
2744
|
domainLine: {
|
|
@@ -2832,7 +2833,8 @@
|
|
|
2832
2833
|
visible: grid?.visible,
|
|
2833
2834
|
style: {
|
|
2834
2835
|
lineWidth: grid?.gridWidth,
|
|
2835
|
-
stroke: grid?.gridColor
|
|
2836
|
+
stroke: grid?.gridColor,
|
|
2837
|
+
lineDash: grid?.gridLineDash
|
|
2836
2838
|
}
|
|
2837
2839
|
},
|
|
2838
2840
|
domainLine: {
|
|
@@ -2875,7 +2877,7 @@
|
|
|
2875
2877
|
lineWidth: 1,
|
|
2876
2878
|
opacity: 1,
|
|
2877
2879
|
stroke: lineColor,
|
|
2878
|
-
lineDash: [
|
|
2880
|
+
lineDash: config.lineDash ?? [
|
|
2879
2881
|
4,
|
|
2880
2882
|
2
|
|
2881
2883
|
]
|
|
@@ -3558,9 +3560,10 @@
|
|
|
3558
3560
|
return true;
|
|
3559
3561
|
});
|
|
3560
3562
|
const annotationPoint_annotationPoint = (spec, context)=>{
|
|
3561
|
-
const { advancedVSeed } = context;
|
|
3562
|
-
const { annotation } = advancedVSeed;
|
|
3563
|
+
const { advancedVSeed, vseed } = context;
|
|
3564
|
+
const { annotation, config } = advancedVSeed;
|
|
3563
3565
|
if (!annotation || !annotation.annotationPoint) return spec;
|
|
3566
|
+
const theme = config?.[vseed.chartType]?.annotation?.annotationPoint;
|
|
3564
3567
|
const { annotationPoint } = annotation;
|
|
3565
3568
|
const annotationPointList = Array.isArray(annotationPoint) ? annotationPoint : [
|
|
3566
3569
|
annotationPoint
|
|
@@ -3574,7 +3577,7 @@
|
|
|
3574
3577
|
textBaseline: 'top'
|
|
3575
3578
|
};
|
|
3576
3579
|
const markPoint = annotationPointList.flatMap((annotationPoint)=>{
|
|
3577
|
-
const { selector: selectorPoint, text = '', textColor = '#ffffff', textFontSize = 12, textFontWeight = 400, textAlign = defaultStyle.textAlign, textBaseline = defaultStyle.textBaseline, textBackgroundBorderColor, textBackgroundBorderRadius = 4, textBackgroundBorderWidth = 1, textBackgroundColor = '#212121', textBackgroundPadding = 2, textBackgroundVisible = true, offsetX = 0, offsetY = 0 } = annotationPoint;
|
|
3580
|
+
const { selector: selectorPoint, text = '', textColor = theme?.textColor ?? '#ffffff', textFontSize = theme?.textFontSize ?? 12, textFontWeight = theme?.textFontWeight ?? 400, textAlign = defaultStyle.textAlign, textBaseline = defaultStyle.textBaseline, textBackgroundBorderColor = theme?.textBackgroundBorderColor, textBackgroundBorderRadius = theme?.textBackgroundBorderRadius ?? 4, textBackgroundBorderWidth = theme?.textBackgroundBorderWidth ?? 1, textBackgroundColor = theme?.textBackgroundColor ?? '#212121', textBackgroundPadding = theme?.textBackgroundPadding ?? 2, textBackgroundVisible = theme?.textBackgroundVisible ?? true, offsetX = theme?.offsetX ?? 0, offsetY = theme?.offsetY ?? 0 } = annotationPoint;
|
|
3578
3581
|
const dataset = advancedVSeed.dataset.flat();
|
|
3579
3582
|
const selectedData = selectorPoint ? dataset.filter((datum)=>selector_selector(datum, selectorPoint)) : [];
|
|
3580
3583
|
const dx = -10 - (isHorizontalBar ? textFontSize : 0);
|
|
@@ -3629,10 +3632,11 @@
|
|
|
3629
3632
|
return Array.isArray(r);
|
|
3630
3633
|
}
|
|
3631
3634
|
const annotationVerticalLine_annotationVerticalLine = (spec, context)=>{
|
|
3632
|
-
const { advancedVSeed } = context;
|
|
3633
|
-
const { annotation, datasetReshapeInfo } = advancedVSeed;
|
|
3635
|
+
const { advancedVSeed, vseed } = context;
|
|
3636
|
+
const { annotation, datasetReshapeInfo, config } = advancedVSeed;
|
|
3634
3637
|
const { unfoldInfo, foldInfo } = datasetReshapeInfo[0];
|
|
3635
3638
|
if (!annotation || !annotation.annotationVerticalLine) return spec;
|
|
3639
|
+
const theme = config?.[vseed.chartType]?.annotation?.annotationVerticalLine;
|
|
3636
3640
|
const { annotationVerticalLine } = annotation;
|
|
3637
3641
|
const annotationVerticalLineList = Array.isArray(annotationVerticalLine) ? annotationVerticalLine : [
|
|
3638
3642
|
annotationVerticalLine
|
|
@@ -3646,7 +3650,7 @@
|
|
|
3646
3650
|
insideEnd: 'insideEndTop'
|
|
3647
3651
|
};
|
|
3648
3652
|
const markLine = annotationVerticalLineList.flatMap((annotationVerticalLine)=>{
|
|
3649
|
-
const { selector: selectorPoint, xValue, text = '', textPosition = 'insideEnd', textColor = '#ffffff', textFontSize = 12, textFontWeight = 400, textAlign = '
|
|
3653
|
+
const { selector: selectorPoint, xValue, text = '', textPosition = 'insideEnd', textColor = theme?.textColor ?? '#ffffff', textFontSize = theme?.textFontSize ?? 12, textFontWeight = theme?.textFontWeight ?? 400, textAlign = 'center', textBaseline = 'top', lineColor = theme?.lineColor ?? '#212121', lineStyle = theme?.lineStyle ?? 'dashed', lineVisible = theme?.lineStyle ?? true, lineWidth = theme?.lineWidth ?? 1, textBackgroundVisible = theme?.textBackgroundVisible ?? true, textBackgroundColor = theme?.textBackgroundColor ?? '#212121', textBackgroundBorderColor = theme?.textBackgroundBorderColor ?? '#212121', textBackgroundBorderRadius = theme?.textBackgroundBorderRadius ?? 4, textBackgroundBorderWidth = theme?.textBackgroundBorderWidth ?? 1, textBackgroundPadding = theme?.textBackgroundPadding ?? 2 } = annotationVerticalLine;
|
|
3650
3654
|
const dataset = advancedVSeed.dataset.flat();
|
|
3651
3655
|
const generateOneMarkLine = (x)=>({
|
|
3652
3656
|
x: x,
|
|
@@ -3672,6 +3676,7 @@
|
|
|
3672
3676
|
text: text,
|
|
3673
3677
|
position: positionMap[textPosition || 'insideEnd'],
|
|
3674
3678
|
style: {
|
|
3679
|
+
dx: 5,
|
|
3675
3680
|
visible: true,
|
|
3676
3681
|
stroke: textBackgroundColor,
|
|
3677
3682
|
lineWidth: 1,
|
|
@@ -3679,23 +3684,33 @@
|
|
|
3679
3684
|
textBaseline: textBaseline,
|
|
3680
3685
|
fill: textColor,
|
|
3681
3686
|
fontSize: textFontSize,
|
|
3682
|
-
fontWeight: textFontWeight
|
|
3683
|
-
dy: textFontSize
|
|
3687
|
+
fontWeight: textFontWeight
|
|
3684
3688
|
},
|
|
3685
3689
|
labelBackground: {
|
|
3686
3690
|
visible: textBackgroundVisible,
|
|
3687
3691
|
padding: textBackgroundPadding,
|
|
3688
3692
|
style: {
|
|
3689
|
-
|
|
3690
|
-
cornerRadius: textBackgroundBorderRadius
|
|
3693
|
+
dx: 5,
|
|
3694
|
+
cornerRadius: textBackgroundBorderRadius,
|
|
3691
3695
|
fill: textBackgroundColor,
|
|
3696
|
+
fillOpacity: 1,
|
|
3692
3697
|
stroke: textBackgroundBorderColor,
|
|
3693
3698
|
lineWidth: textBackgroundBorderWidth
|
|
3694
3699
|
}
|
|
3695
3700
|
}
|
|
3696
3701
|
},
|
|
3702
|
+
startSymbol: {
|
|
3703
|
+
visible: theme?.startSymbolVisible ?? true,
|
|
3704
|
+
symbolType: theme?.startSymbolType ?? 'triangleDown',
|
|
3705
|
+
size: 5 + (lineWidth || 1),
|
|
3706
|
+
style: {
|
|
3707
|
+
dy: -3,
|
|
3708
|
+
fill: lineColor
|
|
3709
|
+
}
|
|
3710
|
+
},
|
|
3697
3711
|
endSymbol: {
|
|
3698
|
-
visible:
|
|
3712
|
+
visible: theme?.endSymbolVisible ?? false,
|
|
3713
|
+
symbolType: theme?.endSymbolType ?? 'arrow',
|
|
3699
3714
|
size: 10 + (lineWidth || 1),
|
|
3700
3715
|
style: {
|
|
3701
3716
|
dy: 4,
|
|
@@ -3727,10 +3742,11 @@
|
|
|
3727
3742
|
};
|
|
3728
3743
|
};
|
|
3729
3744
|
const annotationHorizontalLine_annotationHorizontalLine = (spec, context)=>{
|
|
3730
|
-
const { advancedVSeed } = context;
|
|
3731
|
-
const { annotation, datasetReshapeInfo } = advancedVSeed;
|
|
3745
|
+
const { advancedVSeed, vseed } = context;
|
|
3746
|
+
const { annotation, datasetReshapeInfo, config } = advancedVSeed;
|
|
3732
3747
|
const { foldInfo, unfoldInfo } = datasetReshapeInfo[0];
|
|
3733
3748
|
if (!annotation || !annotation.annotationHorizontalLine) return spec;
|
|
3749
|
+
const theme = config?.[vseed.chartType]?.annotation?.annotationHorizontalLine;
|
|
3734
3750
|
const { annotationHorizontalLine } = annotation;
|
|
3735
3751
|
const annotationHorizontalLineList = Array.isArray(annotationHorizontalLine) ? annotationHorizontalLine : [
|
|
3736
3752
|
annotationHorizontalLine
|
|
@@ -3744,7 +3760,7 @@
|
|
|
3744
3760
|
insideEnd: 'insideEndTop'
|
|
3745
3761
|
};
|
|
3746
3762
|
const markLine = annotationHorizontalLineList.flatMap((annotationHorizontalLine)=>{
|
|
3747
|
-
const { selector: selectorPoint, yValue, text = '', textPosition = 'insideEnd', textColor = '#ffffff', textFontSize = 12, textFontWeight = 400, textAlign = 'right', textBaseline = '
|
|
3763
|
+
const { selector: selectorPoint, yValue, text = '', textPosition = 'insideEnd', textColor = theme?.textColor ?? '#ffffff', textFontSize = theme?.textFontSize ?? 12, textFontWeight = theme?.textFontWeight ?? 400, textAlign = 'right', textBaseline = 'bottom', lineColor = theme?.lineColor ?? '#212121', lineStyle = theme?.lineStyle ?? 'dashed', lineVisible = theme?.lineStyle ?? true, lineWidth = theme?.lineWidth ?? 1, textBackgroundVisible = theme?.textBackgroundVisible ?? true, textBackgroundColor = theme?.textBackgroundColor ?? '#212121', textBackgroundBorderColor = theme?.textBackgroundBorderColor ?? '#212121', textBackgroundBorderRadius = theme?.textBackgroundBorderRadius ?? 4, textBackgroundBorderWidth = theme?.textBackgroundBorderWidth ?? 1, textBackgroundPadding = theme?.textBackgroundPadding ?? 2 } = annotationHorizontalLine;
|
|
3748
3764
|
const dataset = advancedVSeed.dataset.flat();
|
|
3749
3765
|
const generateOneMarkLine = (y)=>({
|
|
3750
3766
|
y,
|
|
@@ -3753,7 +3769,6 @@
|
|
|
3753
3769
|
style: {
|
|
3754
3770
|
visible: lineVisible,
|
|
3755
3771
|
stroke: lineColor,
|
|
3756
|
-
lineStyle: lineStyle,
|
|
3757
3772
|
lineWidth: lineWidth,
|
|
3758
3773
|
lineDash: 'dashed' === lineStyle ? [
|
|
3759
3774
|
5,
|
|
@@ -3771,7 +3786,7 @@
|
|
|
3771
3786
|
position: positionMap[textPosition || 'insideEnd'],
|
|
3772
3787
|
style: {
|
|
3773
3788
|
visible: true,
|
|
3774
|
-
dy:
|
|
3789
|
+
dy: 4,
|
|
3775
3790
|
stroke: textBackgroundColor,
|
|
3776
3791
|
lineWidth: 1,
|
|
3777
3792
|
textAlign: textAlign,
|
|
@@ -3784,16 +3799,27 @@
|
|
|
3784
3799
|
visible: textBackgroundVisible,
|
|
3785
3800
|
padding: textBackgroundPadding,
|
|
3786
3801
|
style: {
|
|
3787
|
-
dy:
|
|
3788
|
-
cornerRadius: textBackgroundBorderRadius
|
|
3802
|
+
dy: 4,
|
|
3803
|
+
cornerRadius: textBackgroundBorderRadius,
|
|
3789
3804
|
fill: textBackgroundColor,
|
|
3790
3805
|
stroke: textBackgroundBorderColor,
|
|
3791
|
-
lineWidth: textBackgroundBorderWidth
|
|
3806
|
+
lineWidth: textBackgroundBorderWidth,
|
|
3807
|
+
fillOpacity: 1
|
|
3792
3808
|
}
|
|
3793
3809
|
}
|
|
3794
3810
|
},
|
|
3811
|
+
startSymbol: {
|
|
3812
|
+
visible: theme?.startSymbolVisible ?? true,
|
|
3813
|
+
symbolType: theme?.startSymbolType ?? 'triangleDown',
|
|
3814
|
+
size: 5,
|
|
3815
|
+
style: {
|
|
3816
|
+
dx: 0,
|
|
3817
|
+
fill: lineColor
|
|
3818
|
+
}
|
|
3819
|
+
},
|
|
3795
3820
|
endSymbol: {
|
|
3796
|
-
visible:
|
|
3821
|
+
visible: theme?.endSymbolVisible ?? false,
|
|
3822
|
+
symbolType: theme?.endSymbolType ?? 'arrow',
|
|
3797
3823
|
size: 10 + (lineWidth || 1),
|
|
3798
3824
|
style: {
|
|
3799
3825
|
dx: -4,
|
|
@@ -3825,9 +3851,10 @@
|
|
|
3825
3851
|
};
|
|
3826
3852
|
};
|
|
3827
3853
|
const annotationArea_annotationArea = (spec, context)=>{
|
|
3828
|
-
const { advancedVSeed } = context;
|
|
3829
|
-
const { annotation } = advancedVSeed;
|
|
3854
|
+
const { advancedVSeed, vseed } = context;
|
|
3855
|
+
const { annotation, config } = advancedVSeed;
|
|
3830
3856
|
if (!annotation || !annotation.annotationArea) return spec;
|
|
3857
|
+
const theme = config?.[vseed.chartType]?.annotation?.annotationArea;
|
|
3831
3858
|
const { annotationArea } = annotation;
|
|
3832
3859
|
const annotationAreaList = Array.isArray(annotationArea) ? annotationArea : [
|
|
3833
3860
|
annotationArea
|
|
@@ -3843,7 +3870,7 @@
|
|
|
3843
3870
|
right: 'insideRight'
|
|
3844
3871
|
};
|
|
3845
3872
|
const markArea = annotationAreaList.flatMap((annotationArea)=>{
|
|
3846
|
-
const { selector: selectorPoint, text = '', textPosition = 'top', textColor = '#ffffff', textFontSize = 12, textFontWeight = 400, textAlign = 'center', textBaseline = 'top', textBackgroundVisible = true, textBackgroundColor = '#191d24', textBackgroundBorderColor = '#191d24', textBackgroundBorderWidth = 1, textBackgroundBorderRadius = 4, textBackgroundPadding = 4, areaColor = '#888888', areaColorOpacity = 0.15, areaBorderColor = '#888888', areaBorderRadius = 4, areaBorderWidth = 1, outerPadding = 4 } = annotationArea;
|
|
3873
|
+
const { selector: selectorPoint, text = '', textPosition = 'top', textColor = theme?.textColor ?? '#ffffff', textFontSize = theme?.textFontSize ?? 12, textFontWeight = theme?.textFontWeight ?? 400, textAlign = 'center', textBaseline = 'top', textBackgroundVisible = theme?.textBackgroundVisible ?? true, textBackgroundColor = theme?.textBackgroundColor ?? '#191d24', textBackgroundBorderColor = theme?.textBackgroundBorderColor ?? '#191d24', textBackgroundBorderWidth = theme?.textBackgroundBorderWidth ?? 1, textBackgroundBorderRadius = theme?.textBackgroundBorderRadius ?? 4, textBackgroundPadding = theme?.textBackgroundPadding ?? 4, areaColor = theme?.areaColor ?? '#888888', areaColorOpacity = theme?.areaColorOpacity ?? 0.15, areaBorderColor = theme?.areaBorderColor ?? '#888888', areaBorderRadius = theme?.areaBorderRadius ?? 4, areaBorderWidth = theme?.areaBorderWidth ?? 1, areaLineDash = theme?.areaLineDash, outerPadding = theme?.outerPadding ?? 4 } = annotationArea;
|
|
3847
3874
|
const dataset = advancedVSeed.dataset.flat();
|
|
3848
3875
|
const selectedData = selectorPoint ? dataset.filter((datum)=>selector_selector(datum, selectorPoint)) : [];
|
|
3849
3876
|
const labelPosition = positionMap[textPosition || 'top'];
|
|
@@ -3913,7 +3940,7 @@
|
|
|
3913
3940
|
visible: true,
|
|
3914
3941
|
text: text,
|
|
3915
3942
|
style: {
|
|
3916
|
-
dy: isBottom ? 2 * -(textFontSize || 12) :
|
|
3943
|
+
dy: isBottom ? 2 * -(textFontSize || 12) : 0,
|
|
3917
3944
|
textAlign: textAlign,
|
|
3918
3945
|
textBaseline: textBaseline,
|
|
3919
3946
|
fill: textColor,
|
|
@@ -3926,11 +3953,12 @@
|
|
|
3926
3953
|
visible: textBackgroundVisible,
|
|
3927
3954
|
padding: textBackgroundPadding,
|
|
3928
3955
|
style: {
|
|
3929
|
-
dy: isBottom ? 2 * -(textFontSize || 12) :
|
|
3956
|
+
dy: isBottom ? 2 * -(textFontSize || 12) : 0,
|
|
3930
3957
|
cornerRadius: textBackgroundBorderRadius ?? 4,
|
|
3931
3958
|
fill: textBackgroundColor,
|
|
3932
3959
|
stroke: textBackgroundBorderColor,
|
|
3933
|
-
lineWidth: textBackgroundBorderWidth
|
|
3960
|
+
lineWidth: textBackgroundBorderWidth,
|
|
3961
|
+
fillOpacity: 1
|
|
3934
3962
|
}
|
|
3935
3963
|
}
|
|
3936
3964
|
},
|
|
@@ -3941,7 +3969,8 @@
|
|
|
3941
3969
|
fillOpacity: areaColorOpacity,
|
|
3942
3970
|
stroke: areaBorderColor,
|
|
3943
3971
|
lineWidth: areaBorderWidth,
|
|
3944
|
-
cornerRadius: areaBorderRadius
|
|
3972
|
+
cornerRadius: areaBorderRadius,
|
|
3973
|
+
lineDash: areaLineDash
|
|
3945
3974
|
}
|
|
3946
3975
|
}
|
|
3947
3976
|
};
|
|
@@ -4783,9 +4812,10 @@
|
|
|
4783
4812
|
};
|
|
4784
4813
|
};
|
|
4785
4814
|
const annotationAreaBand = (spec, context)=>{
|
|
4786
|
-
const { advancedVSeed } = context;
|
|
4787
|
-
const { annotation } = advancedVSeed;
|
|
4815
|
+
const { advancedVSeed, vseed } = context;
|
|
4816
|
+
const { annotation, config } = advancedVSeed;
|
|
4788
4817
|
if (!annotation || !annotation.annotationArea) return spec;
|
|
4818
|
+
const theme = config?.[vseed.chartType]?.annotation?.annotationArea;
|
|
4789
4819
|
const { annotationArea } = annotation;
|
|
4790
4820
|
const annotationAreaList = Array.isArray(annotationArea) ? annotationArea : [
|
|
4791
4821
|
annotationArea
|
|
@@ -4800,9 +4830,17 @@
|
|
|
4800
4830
|
left: 'insideLeft',
|
|
4801
4831
|
right: 'insideRight'
|
|
4802
4832
|
};
|
|
4833
|
+
const defaultOptions = isBarLikeChart(advancedVSeed) ? {
|
|
4834
|
+
textPosition: 'right',
|
|
4835
|
+
textAlign: 'right'
|
|
4836
|
+
} : {
|
|
4837
|
+
textPosition: 'top',
|
|
4838
|
+
textAlign: 'center'
|
|
4839
|
+
};
|
|
4803
4840
|
const markArea = annotationAreaList.flatMap((annotationArea)=>{
|
|
4804
|
-
const { selector: selectorPoint, text = '',
|
|
4805
|
-
const
|
|
4841
|
+
const { selector: selectorPoint, text = '', textColor = theme?.textColor ?? '#ffffff', textFontSize = theme?.textFontSize ?? 12, textFontWeight = theme?.textFontWeight ?? 400, textAlign = defaultOptions.textAlign, textBaseline = 'middle', textBackgroundVisible = theme?.textBackgroundVisible ?? true, textBackgroundColor = theme?.textBackgroundColor ?? '#191d24', textBackgroundBorderColor = theme?.textBackgroundBorderColor ?? '#191d24', textBackgroundBorderWidth = theme?.textBackgroundBorderWidth ?? 1, textBackgroundBorderRadius = theme?.textBackgroundBorderRadius ?? 4, textBackgroundPadding = theme?.textBackgroundPadding ?? 4, areaColor = theme?.areaColor ?? '#888888', areaColorOpacity = theme?.areaColorOpacity ?? 0.15, areaBorderColor = theme?.areaBorderColor ?? '#888888', areaBorderRadius = theme?.areaBorderRadius ?? 4, areaBorderWidth = theme?.areaBorderWidth ?? 1, areaLineDash = theme?.areaLineDash, outerPadding = theme?.outerPadding ?? 4 } = annotationArea;
|
|
4842
|
+
const textPosition = annotationArea.textPosition ?? defaultOptions.textPosition;
|
|
4843
|
+
const dy = textPosition.includes('bottom') ? -1 * textFontSize : 0;
|
|
4806
4844
|
const dataset = advancedVSeed.dataset.flat();
|
|
4807
4845
|
const selectedData = selectorPoint ? dataset.filter((datum)=>selector_selector(datum, selectorPoint)) : [];
|
|
4808
4846
|
return {
|
|
@@ -4879,7 +4917,7 @@
|
|
|
4879
4917
|
return [];
|
|
4880
4918
|
},
|
|
4881
4919
|
label: {
|
|
4882
|
-
position: positionMap[textPosition
|
|
4920
|
+
position: positionMap[textPosition],
|
|
4883
4921
|
visible: true,
|
|
4884
4922
|
text: text,
|
|
4885
4923
|
style: {
|
|
@@ -4900,7 +4938,8 @@
|
|
|
4900
4938
|
cornerRadius: textBackgroundBorderRadius ?? 4,
|
|
4901
4939
|
fill: textBackgroundColor,
|
|
4902
4940
|
stroke: textBackgroundBorderColor,
|
|
4903
|
-
lineWidth: textBackgroundBorderWidth
|
|
4941
|
+
lineWidth: textBackgroundBorderWidth,
|
|
4942
|
+
fillOpacity: 1
|
|
4904
4943
|
}
|
|
4905
4944
|
}
|
|
4906
4945
|
},
|
|
@@ -4911,7 +4950,8 @@
|
|
|
4911
4950
|
fillOpacity: areaColorOpacity,
|
|
4912
4951
|
stroke: areaBorderColor,
|
|
4913
4952
|
lineWidth: areaBorderWidth,
|
|
4914
|
-
cornerRadius: areaBorderRadius
|
|
4953
|
+
cornerRadius: areaBorderRadius,
|
|
4954
|
+
lineDash: areaLineDash
|
|
4915
4955
|
}
|
|
4916
4956
|
}
|
|
4917
4957
|
};
|
|
@@ -5459,7 +5499,8 @@
|
|
|
5459
5499
|
visible: grid?.visible,
|
|
5460
5500
|
style: {
|
|
5461
5501
|
lineWidth: grid?.gridWidth,
|
|
5462
|
-
stroke: grid?.gridColor
|
|
5502
|
+
stroke: grid?.gridColor,
|
|
5503
|
+
lineDash: grid?.gridLineDash
|
|
5463
5504
|
}
|
|
5464
5505
|
},
|
|
5465
5506
|
domainLine: {
|
|
@@ -5539,7 +5580,8 @@
|
|
|
5539
5580
|
visible: grid?.visible,
|
|
5540
5581
|
style: {
|
|
5541
5582
|
lineWidth: grid?.gridWidth,
|
|
5542
|
-
stroke: grid?.gridColor
|
|
5583
|
+
stroke: grid?.gridColor,
|
|
5584
|
+
lineDash: grid?.gridLineDash
|
|
5543
5585
|
}
|
|
5544
5586
|
},
|
|
5545
5587
|
domainLine: {
|
|
@@ -6662,7 +6704,7 @@
|
|
|
6662
6704
|
lineWidth: 1,
|
|
6663
6705
|
opacity: 1,
|
|
6664
6706
|
stroke: lineColor,
|
|
6665
|
-
lineDash: [
|
|
6707
|
+
lineDash: config.lineDash ?? [
|
|
6666
6708
|
4,
|
|
6667
6709
|
2
|
|
6668
6710
|
]
|
|
@@ -7513,7 +7555,8 @@
|
|
|
7513
7555
|
visible: grid?.visible,
|
|
7514
7556
|
style: {
|
|
7515
7557
|
lineWidth: grid?.gridWidth,
|
|
7516
|
-
stroke: grid?.gridColor
|
|
7558
|
+
stroke: grid?.gridColor,
|
|
7559
|
+
lineDash: grid?.gridLineDash
|
|
7517
7560
|
}
|
|
7518
7561
|
},
|
|
7519
7562
|
domainLine: {
|
|
@@ -7605,7 +7648,8 @@
|
|
|
7605
7648
|
visible: onlySecondary ? true : grid?.visible,
|
|
7606
7649
|
style: {
|
|
7607
7650
|
lineWidth: grid?.gridWidth,
|
|
7608
|
-
stroke: grid?.gridColor
|
|
7651
|
+
stroke: grid?.gridColor,
|
|
7652
|
+
lineDash: grid?.gridLineDash
|
|
7609
7653
|
}
|
|
7610
7654
|
},
|
|
7611
7655
|
domainLine: {
|
|
@@ -7874,29 +7918,27 @@
|
|
|
7874
7918
|
return result;
|
|
7875
7919
|
};
|
|
7876
7920
|
const pieStyle = (spec, context)=>{
|
|
7877
|
-
const { advancedVSeed } = context;
|
|
7921
|
+
const { advancedVSeed, vseed } = context;
|
|
7922
|
+
const { chartType } = vseed;
|
|
7878
7923
|
const { dataset } = advancedVSeed;
|
|
7879
7924
|
const showStroke = dataset.length <= 30;
|
|
7925
|
+
const config = advancedVSeed.config?.[chartType];
|
|
7880
7926
|
const result = {
|
|
7881
7927
|
...spec,
|
|
7882
|
-
pie: {
|
|
7883
|
-
style: {}
|
|
7884
|
-
}
|
|
7885
|
-
};
|
|
7886
|
-
return {
|
|
7887
|
-
...result,
|
|
7888
7928
|
pie: {
|
|
7889
7929
|
style: {
|
|
7890
|
-
stroke: '#ffffff',
|
|
7930
|
+
stroke: config?.backgroundColor ?? '#ffffff',
|
|
7891
7931
|
lineWidth: showStroke ? 1 : 0
|
|
7892
|
-
},
|
|
7893
|
-
state: {
|
|
7894
|
-
hover: {
|
|
7895
|
-
outerRadius: 1.1 * result.outerRadius
|
|
7896
|
-
}
|
|
7897
7932
|
}
|
|
7898
7933
|
}
|
|
7899
7934
|
};
|
|
7935
|
+
if (spec.outerRadius) result.pie.state = {
|
|
7936
|
+
hover: {
|
|
7937
|
+
outerRadius: 1.1 * spec.outerRadius
|
|
7938
|
+
}
|
|
7939
|
+
};
|
|
7940
|
+
if (config?.cornerRadius) result.pie.style.cornerRadius = config.cornerRadius;
|
|
7941
|
+
return result;
|
|
7900
7942
|
};
|
|
7901
7943
|
const labelPie = (spec, context)=>{
|
|
7902
7944
|
const result = {
|
|
@@ -9122,9 +9164,9 @@
|
|
|
9122
9164
|
const getDarkCrosshairLine = ()=>({
|
|
9123
9165
|
visible: true,
|
|
9124
9166
|
labelVisible: true,
|
|
9125
|
-
labelColor: '#
|
|
9126
|
-
labelBackgroundColor: '#
|
|
9127
|
-
lineColor: '#
|
|
9167
|
+
labelColor: '#ffffff',
|
|
9168
|
+
labelBackgroundColor: '#404349',
|
|
9169
|
+
lineColor: '#55595F'
|
|
9128
9170
|
});
|
|
9129
9171
|
const getDarkCrosshairRect = ()=>({
|
|
9130
9172
|
visible: true,
|
|
@@ -9137,8 +9179,8 @@
|
|
|
9137
9179
|
visible: true,
|
|
9138
9180
|
labelVisible: true,
|
|
9139
9181
|
labelColor: '#ffffff',
|
|
9140
|
-
labelBackgroundColor: '#
|
|
9141
|
-
lineColor: '#
|
|
9182
|
+
labelBackgroundColor: '#21252C',
|
|
9183
|
+
lineColor: '#21252C'
|
|
9142
9184
|
});
|
|
9143
9185
|
const getLightCrosshairRect = ()=>({
|
|
9144
9186
|
visible: true,
|
|
@@ -9270,7 +9312,11 @@
|
|
|
9270
9312
|
grid: {
|
|
9271
9313
|
visible: true,
|
|
9272
9314
|
gridColor: '#36415926',
|
|
9273
|
-
gridWidth: 0.5
|
|
9315
|
+
gridWidth: 0.5,
|
|
9316
|
+
gridLineDash: [
|
|
9317
|
+
4,
|
|
9318
|
+
2
|
|
9319
|
+
]
|
|
9274
9320
|
},
|
|
9275
9321
|
tick: {
|
|
9276
9322
|
visible: false,
|
|
@@ -9312,7 +9358,11 @@
|
|
|
9312
9358
|
grid: {
|
|
9313
9359
|
visible: false,
|
|
9314
9360
|
gridColor: '#36415926',
|
|
9315
|
-
gridWidth: 0.5
|
|
9361
|
+
gridWidth: 0.5,
|
|
9362
|
+
gridLineDash: [
|
|
9363
|
+
4,
|
|
9364
|
+
2
|
|
9365
|
+
]
|
|
9316
9366
|
},
|
|
9317
9367
|
tick: {
|
|
9318
9368
|
visible: false,
|
|
@@ -9345,8 +9395,12 @@
|
|
|
9345
9395
|
},
|
|
9346
9396
|
grid: {
|
|
9347
9397
|
visible: true,
|
|
9348
|
-
gridColor: '#
|
|
9349
|
-
gridWidth: 0.5
|
|
9398
|
+
gridColor: '#303339',
|
|
9399
|
+
gridWidth: 0.5,
|
|
9400
|
+
gridLineDash: [
|
|
9401
|
+
4,
|
|
9402
|
+
2
|
|
9403
|
+
]
|
|
9350
9404
|
},
|
|
9351
9405
|
tick: {
|
|
9352
9406
|
visible: false,
|
|
@@ -9387,8 +9441,12 @@
|
|
|
9387
9441
|
},
|
|
9388
9442
|
grid: {
|
|
9389
9443
|
visible: false,
|
|
9390
|
-
gridColor: '#
|
|
9391
|
-
gridWidth: 0.5
|
|
9444
|
+
gridColor: '#303339',
|
|
9445
|
+
gridWidth: 0.5,
|
|
9446
|
+
gridLineDash: [
|
|
9447
|
+
4,
|
|
9448
|
+
2
|
|
9449
|
+
]
|
|
9392
9450
|
},
|
|
9393
9451
|
tick: {
|
|
9394
9452
|
visible: false,
|
|
@@ -9402,6 +9460,116 @@
|
|
|
9402
9460
|
lineWidth: 1
|
|
9403
9461
|
}
|
|
9404
9462
|
});
|
|
9463
|
+
const getLightAnnotationPoint = ()=>({
|
|
9464
|
+
textColor: '#ffffff',
|
|
9465
|
+
textBackgroundVisible: true,
|
|
9466
|
+
textBackgroundColor: '#364159',
|
|
9467
|
+
textBackgroundBorderColor: '#3641594d',
|
|
9468
|
+
textFontSize: 12,
|
|
9469
|
+
textFontWeight: 400,
|
|
9470
|
+
textBackgroundBorderRadius: 4,
|
|
9471
|
+
textBackgroundBorderWidth: 1,
|
|
9472
|
+
textBackgroundPadding: 2
|
|
9473
|
+
});
|
|
9474
|
+
const getLightAnnotationHorizontalLine = ()=>({
|
|
9475
|
+
lineColor: '#BCC1CB',
|
|
9476
|
+
lineWidth: 1,
|
|
9477
|
+
lineStyle: 'solid',
|
|
9478
|
+
lineVisible: true,
|
|
9479
|
+
textColor: '#ffffff',
|
|
9480
|
+
textFontSize: 12,
|
|
9481
|
+
textFontWeight: 400,
|
|
9482
|
+
startSymbolVisible: true,
|
|
9483
|
+
endSymbolVisible: false,
|
|
9484
|
+
textBackgroundVisible: true,
|
|
9485
|
+
textBackgroundColor: '#BCC1CB',
|
|
9486
|
+
textBackgroundBorderColor: '#BCC1CB',
|
|
9487
|
+
textBackgroundBorderWidth: 1,
|
|
9488
|
+
textBackgroundBorderRadius: 0,
|
|
9489
|
+
textBackgroundPadding: 2
|
|
9490
|
+
});
|
|
9491
|
+
const getLightAnnotationVerticalLine = ()=>getLightAnnotationHorizontalLine();
|
|
9492
|
+
const getLightAnnotationArea = ()=>({
|
|
9493
|
+
textColor: '#ffffff',
|
|
9494
|
+
textFontSize: 12,
|
|
9495
|
+
textFontWeight: 400,
|
|
9496
|
+
textBackgroundVisible: true,
|
|
9497
|
+
textBackgroundColor: '#BCC1CB',
|
|
9498
|
+
textBackgroundBorderColor: '#BCC1CB',
|
|
9499
|
+
textBackgroundBorderWidth: 1,
|
|
9500
|
+
textBackgroundBorderRadius: 0,
|
|
9501
|
+
textBackgroundPadding: 4,
|
|
9502
|
+
areaColor: '#BCC1CB',
|
|
9503
|
+
areaColorOpacity: 0.12,
|
|
9504
|
+
areaBorderColor: '#BCC1CB',
|
|
9505
|
+
areaBorderWidth: 0,
|
|
9506
|
+
areaBorderRadius: 0,
|
|
9507
|
+
areaLineDash: [
|
|
9508
|
+
2,
|
|
9509
|
+
2
|
|
9510
|
+
],
|
|
9511
|
+
outerPadding: 4
|
|
9512
|
+
});
|
|
9513
|
+
const getLightAnnotation = ()=>({
|
|
9514
|
+
annotationPoint: getLightAnnotationPoint(),
|
|
9515
|
+
annotationHorizontalLine: getLightAnnotationHorizontalLine(),
|
|
9516
|
+
annotationVerticalLine: getLightAnnotationVerticalLine(),
|
|
9517
|
+
annotationArea: getLightAnnotationArea()
|
|
9518
|
+
});
|
|
9519
|
+
const getDarkAnnotationPoint = ()=>({
|
|
9520
|
+
textColor: '#4B4F54',
|
|
9521
|
+
textBackgroundVisible: true,
|
|
9522
|
+
textBackgroundColor: '#ffffff',
|
|
9523
|
+
textBackgroundBorderColor: '#ffffff',
|
|
9524
|
+
textFontSize: 12,
|
|
9525
|
+
textFontWeight: 400,
|
|
9526
|
+
textBackgroundBorderRadius: 4,
|
|
9527
|
+
textBackgroundBorderWidth: 1,
|
|
9528
|
+
textBackgroundPadding: 2
|
|
9529
|
+
});
|
|
9530
|
+
const getDarkAnnotationHorizontalLine = ()=>({
|
|
9531
|
+
lineColor: '#55595F',
|
|
9532
|
+
lineWidth: 1,
|
|
9533
|
+
lineStyle: 'solid',
|
|
9534
|
+
lineVisible: true,
|
|
9535
|
+
textFontSize: 12,
|
|
9536
|
+
textFontWeight: 400,
|
|
9537
|
+
textBackgroundVisible: true,
|
|
9538
|
+
textColor: '#E2E3E6',
|
|
9539
|
+
textBackgroundColor: '#55595F',
|
|
9540
|
+
textBackgroundBorderColor: '#55595F',
|
|
9541
|
+
textBackgroundBorderWidth: 1,
|
|
9542
|
+
textBackgroundBorderRadius: 0,
|
|
9543
|
+
textBackgroundPadding: 2
|
|
9544
|
+
});
|
|
9545
|
+
const getDarkAnnotationVerticalLine = ()=>getDarkAnnotationHorizontalLine();
|
|
9546
|
+
const getDarkAnnotationArea = ()=>({
|
|
9547
|
+
textColor: '#E2E3E6',
|
|
9548
|
+
textFontSize: 12,
|
|
9549
|
+
textFontWeight: 400,
|
|
9550
|
+
textBackgroundVisible: true,
|
|
9551
|
+
textBackgroundColor: '#55595F',
|
|
9552
|
+
textBackgroundBorderColor: '#55595F',
|
|
9553
|
+
textBackgroundBorderWidth: 1,
|
|
9554
|
+
textBackgroundBorderRadius: 0,
|
|
9555
|
+
textBackgroundPadding: 4,
|
|
9556
|
+
areaColor: '#E2E3E6',
|
|
9557
|
+
areaColorOpacity: 0.15,
|
|
9558
|
+
areaBorderColor: '#E2E3E6',
|
|
9559
|
+
areaBorderWidth: 0,
|
|
9560
|
+
areaBorderRadius: 0,
|
|
9561
|
+
areaLineDash: [
|
|
9562
|
+
2,
|
|
9563
|
+
2
|
|
9564
|
+
],
|
|
9565
|
+
outerPadding: 4
|
|
9566
|
+
});
|
|
9567
|
+
const getDarkAnnotation = ()=>({
|
|
9568
|
+
annotationPoint: getDarkAnnotationPoint(),
|
|
9569
|
+
annotationHorizontalLine: getDarkAnnotationHorizontalLine(),
|
|
9570
|
+
annotationVerticalLine: getDarkAnnotationVerticalLine(),
|
|
9571
|
+
annotationArea: getDarkAnnotationArea()
|
|
9572
|
+
});
|
|
9405
9573
|
const lightTheme = ()=>{
|
|
9406
9574
|
const linearAxis = getLightLinearAxis();
|
|
9407
9575
|
const bandAxis = getLightBandAxis();
|
|
@@ -9437,7 +9605,8 @@
|
|
|
9437
9605
|
xAxis: bandAxis,
|
|
9438
9606
|
yAxis: linearAxis,
|
|
9439
9607
|
crosshairLine,
|
|
9440
|
-
pivotGrid: getLightPivotChartGridConfig()
|
|
9608
|
+
pivotGrid: getLightPivotChartGridConfig(),
|
|
9609
|
+
annotation: getLightAnnotation()
|
|
9441
9610
|
},
|
|
9442
9611
|
column: {
|
|
9443
9612
|
...baseConfig,
|
|
@@ -9450,7 +9619,8 @@
|
|
|
9450
9619
|
0,
|
|
9451
9620
|
0
|
|
9452
9621
|
],
|
|
9453
|
-
pivotGrid: getLightPivotChartGridConfig()
|
|
9622
|
+
pivotGrid: getLightPivotChartGridConfig(),
|
|
9623
|
+
annotation: getLightAnnotation()
|
|
9454
9624
|
},
|
|
9455
9625
|
columnParallel: {
|
|
9456
9626
|
...baseConfig,
|
|
@@ -9463,7 +9633,8 @@
|
|
|
9463
9633
|
0,
|
|
9464
9634
|
0
|
|
9465
9635
|
],
|
|
9466
|
-
pivotGrid: getLightPivotChartGridConfig()
|
|
9636
|
+
pivotGrid: getLightPivotChartGridConfig(),
|
|
9637
|
+
annotation: getLightAnnotation()
|
|
9467
9638
|
},
|
|
9468
9639
|
columnPercent: {
|
|
9469
9640
|
...baseConfig,
|
|
@@ -9478,7 +9649,8 @@
|
|
|
9478
9649
|
0,
|
|
9479
9650
|
0
|
|
9480
9651
|
],
|
|
9481
|
-
pivotGrid: getLightPivotChartGridConfig()
|
|
9652
|
+
pivotGrid: getLightPivotChartGridConfig(),
|
|
9653
|
+
annotation: getLightAnnotation()
|
|
9482
9654
|
},
|
|
9483
9655
|
bar: {
|
|
9484
9656
|
...baseConfig,
|
|
@@ -9491,7 +9663,8 @@
|
|
|
9491
9663
|
4,
|
|
9492
9664
|
0
|
|
9493
9665
|
],
|
|
9494
|
-
pivotGrid: getLightPivotChartGridConfig()
|
|
9666
|
+
pivotGrid: getLightPivotChartGridConfig(),
|
|
9667
|
+
annotation: getLightAnnotation()
|
|
9495
9668
|
},
|
|
9496
9669
|
barParallel: {
|
|
9497
9670
|
...baseConfig,
|
|
@@ -9504,7 +9677,8 @@
|
|
|
9504
9677
|
4,
|
|
9505
9678
|
0
|
|
9506
9679
|
],
|
|
9507
|
-
pivotGrid: getLightPivotChartGridConfig()
|
|
9680
|
+
pivotGrid: getLightPivotChartGridConfig(),
|
|
9681
|
+
annotation: getLightAnnotation()
|
|
9508
9682
|
},
|
|
9509
9683
|
barPercent: {
|
|
9510
9684
|
...baseConfig,
|
|
@@ -9519,14 +9693,16 @@
|
|
|
9519
9693
|
4,
|
|
9520
9694
|
0
|
|
9521
9695
|
],
|
|
9522
|
-
pivotGrid: getLightPivotChartGridConfig()
|
|
9696
|
+
pivotGrid: getLightPivotChartGridConfig(),
|
|
9697
|
+
annotation: getLightAnnotation()
|
|
9523
9698
|
},
|
|
9524
9699
|
area: {
|
|
9525
9700
|
...baseConfig,
|
|
9526
9701
|
xAxis: bandAxis,
|
|
9527
9702
|
yAxis: linearAxis,
|
|
9528
9703
|
crosshairLine,
|
|
9529
|
-
pivotGrid: getLightPivotChartGridConfig()
|
|
9704
|
+
pivotGrid: getLightPivotChartGridConfig(),
|
|
9705
|
+
annotation: getLightAnnotation()
|
|
9530
9706
|
},
|
|
9531
9707
|
areaPercent: {
|
|
9532
9708
|
...baseConfig,
|
|
@@ -9535,7 +9711,8 @@
|
|
|
9535
9711
|
...linearAxis
|
|
9536
9712
|
},
|
|
9537
9713
|
crosshairLine,
|
|
9538
|
-
pivotGrid: getLightPivotChartGridConfig()
|
|
9714
|
+
pivotGrid: getLightPivotChartGridConfig(),
|
|
9715
|
+
annotation: getLightAnnotation()
|
|
9539
9716
|
},
|
|
9540
9717
|
scatter: {
|
|
9541
9718
|
...baseConfig,
|
|
@@ -9563,7 +9740,8 @@
|
|
|
9563
9740
|
showValue: false,
|
|
9564
9741
|
showValuePercent: false
|
|
9565
9742
|
},
|
|
9566
|
-
pivotGrid: getLightPivotChartGridConfig()
|
|
9743
|
+
pivotGrid: getLightPivotChartGridConfig(),
|
|
9744
|
+
annotation: getLightAnnotation()
|
|
9567
9745
|
},
|
|
9568
9746
|
dualAxis: {
|
|
9569
9747
|
...baseConfig,
|
|
@@ -9580,7 +9758,8 @@
|
|
|
9580
9758
|
secondary: 'line'
|
|
9581
9759
|
},
|
|
9582
9760
|
crosshairRect,
|
|
9583
|
-
pivotGrid: getLightPivotChartGridConfig()
|
|
9761
|
+
pivotGrid: getLightPivotChartGridConfig(),
|
|
9762
|
+
annotation: getLightAnnotation()
|
|
9584
9763
|
},
|
|
9585
9764
|
pie: {
|
|
9586
9765
|
...baseConfig,
|
|
@@ -9674,7 +9853,8 @@
|
|
|
9674
9853
|
xAxis: bandAxis,
|
|
9675
9854
|
yAxis: linearAxis,
|
|
9676
9855
|
crosshairLine: crosshairLine,
|
|
9677
|
-
pivotGrid: getDarkPivotChartGridConfig()
|
|
9856
|
+
pivotGrid: getDarkPivotChartGridConfig(),
|
|
9857
|
+
annotation: getDarkAnnotation()
|
|
9678
9858
|
},
|
|
9679
9859
|
column: {
|
|
9680
9860
|
...baseConfig,
|
|
@@ -9687,7 +9867,8 @@
|
|
|
9687
9867
|
0,
|
|
9688
9868
|
0
|
|
9689
9869
|
],
|
|
9690
|
-
pivotGrid: getDarkPivotChartGridConfig()
|
|
9870
|
+
pivotGrid: getDarkPivotChartGridConfig(),
|
|
9871
|
+
annotation: getDarkAnnotation()
|
|
9691
9872
|
},
|
|
9692
9873
|
columnParallel: {
|
|
9693
9874
|
...baseConfig,
|
|
@@ -9700,7 +9881,8 @@
|
|
|
9700
9881
|
0,
|
|
9701
9882
|
0
|
|
9702
9883
|
],
|
|
9703
|
-
pivotGrid: getDarkPivotChartGridConfig()
|
|
9884
|
+
pivotGrid: getDarkPivotChartGridConfig(),
|
|
9885
|
+
annotation: getDarkAnnotation()
|
|
9704
9886
|
},
|
|
9705
9887
|
columnPercent: {
|
|
9706
9888
|
...baseConfig,
|
|
@@ -9713,7 +9895,8 @@
|
|
|
9713
9895
|
0,
|
|
9714
9896
|
0
|
|
9715
9897
|
],
|
|
9716
|
-
pivotGrid: getDarkPivotChartGridConfig()
|
|
9898
|
+
pivotGrid: getDarkPivotChartGridConfig(),
|
|
9899
|
+
annotation: getDarkAnnotation()
|
|
9717
9900
|
},
|
|
9718
9901
|
bar: {
|
|
9719
9902
|
...baseConfig,
|
|
@@ -9726,7 +9909,8 @@
|
|
|
9726
9909
|
4,
|
|
9727
9910
|
0
|
|
9728
9911
|
],
|
|
9729
|
-
pivotGrid: getDarkPivotChartGridConfig()
|
|
9912
|
+
pivotGrid: getDarkPivotChartGridConfig(),
|
|
9913
|
+
annotation: getDarkAnnotation()
|
|
9730
9914
|
},
|
|
9731
9915
|
barParallel: {
|
|
9732
9916
|
...baseConfig,
|
|
@@ -9739,7 +9923,8 @@
|
|
|
9739
9923
|
4,
|
|
9740
9924
|
0
|
|
9741
9925
|
],
|
|
9742
|
-
pivotGrid: getDarkPivotChartGridConfig()
|
|
9926
|
+
pivotGrid: getDarkPivotChartGridConfig(),
|
|
9927
|
+
annotation: getDarkAnnotation()
|
|
9743
9928
|
},
|
|
9744
9929
|
barPercent: {
|
|
9745
9930
|
...baseConfig,
|
|
@@ -9752,21 +9937,24 @@
|
|
|
9752
9937
|
4,
|
|
9753
9938
|
0
|
|
9754
9939
|
],
|
|
9755
|
-
pivotGrid: getDarkPivotChartGridConfig()
|
|
9940
|
+
pivotGrid: getDarkPivotChartGridConfig(),
|
|
9941
|
+
annotation: getDarkAnnotation()
|
|
9756
9942
|
},
|
|
9757
9943
|
area: {
|
|
9758
9944
|
...baseConfig,
|
|
9759
9945
|
xAxis: bandAxis,
|
|
9760
9946
|
yAxis: linearAxis,
|
|
9761
9947
|
crosshairLine: crosshairLine,
|
|
9762
|
-
pivotGrid: getDarkPivotChartGridConfig()
|
|
9948
|
+
pivotGrid: getDarkPivotChartGridConfig(),
|
|
9949
|
+
annotation: getDarkAnnotation()
|
|
9763
9950
|
},
|
|
9764
9951
|
areaPercent: {
|
|
9765
9952
|
...baseConfig,
|
|
9766
9953
|
xAxis: bandAxis,
|
|
9767
9954
|
yAxis: linearAxis,
|
|
9768
9955
|
crosshairLine: crosshairLine,
|
|
9769
|
-
pivotGrid: getDarkPivotChartGridConfig()
|
|
9956
|
+
pivotGrid: getDarkPivotChartGridConfig(),
|
|
9957
|
+
annotation: getDarkAnnotation()
|
|
9770
9958
|
},
|
|
9771
9959
|
scatter: {
|
|
9772
9960
|
...baseConfig,
|
|
@@ -9794,7 +9982,8 @@
|
|
|
9794
9982
|
showValue: false,
|
|
9795
9983
|
showValuePercent: false
|
|
9796
9984
|
},
|
|
9797
|
-
pivotGrid: getDarkPivotChartGridConfig()
|
|
9985
|
+
pivotGrid: getDarkPivotChartGridConfig(),
|
|
9986
|
+
annotation: getDarkAnnotation()
|
|
9798
9987
|
},
|
|
9799
9988
|
dualAxis: {
|
|
9800
9989
|
...baseConfig,
|
|
@@ -9811,7 +10000,8 @@
|
|
|
9811
10000
|
secondary: 'line'
|
|
9812
10001
|
},
|
|
9813
10002
|
crosshairRect,
|
|
9814
|
-
pivotGrid: getDarkPivotChartGridConfig()
|
|
10003
|
+
pivotGrid: getDarkPivotChartGridConfig(),
|
|
10004
|
+
annotation: getDarkAnnotation()
|
|
9815
10005
|
},
|
|
9816
10006
|
pie: {
|
|
9817
10007
|
...baseConfig,
|
|
@@ -13494,7 +13684,8 @@
|
|
|
13494
13684
|
grid: schemas_object({
|
|
13495
13685
|
visible: schemas_boolean().default(false).nullish(),
|
|
13496
13686
|
gridColor: schemas_string().default('rgba(54, 65, 89, 0.15)').nullish(),
|
|
13497
|
-
gridWidth: schemas_number().default(0.5).nullish()
|
|
13687
|
+
gridWidth: schemas_number().default(0.5).nullish(),
|
|
13688
|
+
gridLineDash: schemas_array(schemas_number()).nullish()
|
|
13498
13689
|
}).nullish()
|
|
13499
13690
|
});
|
|
13500
13691
|
const zYBandAxis = zXBandAxis;
|
|
@@ -13536,7 +13727,8 @@
|
|
|
13536
13727
|
grid: schemas_object({
|
|
13537
13728
|
visible: schemas_boolean().default(false).nullish(),
|
|
13538
13729
|
gridColor: schemas_string().default('rgba(54, 65, 89, 0.15)').nullish(),
|
|
13539
|
-
gridWidth: schemas_number().default(0.5).nullish()
|
|
13730
|
+
gridWidth: schemas_number().default(0.5).nullish(),
|
|
13731
|
+
gridLineDash: schemas_array(schemas_number()).nullish()
|
|
13540
13732
|
}).nullish()
|
|
13541
13733
|
});
|
|
13542
13734
|
const zYLinearAxis = zXLinearAxis;
|
|
@@ -13545,7 +13737,8 @@
|
|
|
13545
13737
|
lineColor: schemas_string().nullish(),
|
|
13546
13738
|
labelColor: schemas_string().nullish(),
|
|
13547
13739
|
labelVisible: schemas_boolean().nullish(),
|
|
13548
|
-
labelBackgroundColor: schemas_string().nullish()
|
|
13740
|
+
labelBackgroundColor: schemas_string().nullish(),
|
|
13741
|
+
lineDash: schemas_array(schemas_number()).nullish()
|
|
13549
13742
|
});
|
|
13550
13743
|
const zCrosshairRect = schemas_object({
|
|
13551
13744
|
visible: schemas_boolean().nullish(),
|
|
@@ -13674,6 +13867,233 @@
|
|
|
13674
13867
|
const zTooltip = schemas_object({
|
|
13675
13868
|
enable: schemas_boolean().default(true).nullish()
|
|
13676
13869
|
});
|
|
13870
|
+
const zSelector = union([
|
|
13871
|
+
schemas_string(),
|
|
13872
|
+
schemas_number(),
|
|
13873
|
+
schemas_object({
|
|
13874
|
+
field: schemas_string(),
|
|
13875
|
+
operator: schemas_enum([
|
|
13876
|
+
'=',
|
|
13877
|
+
'==',
|
|
13878
|
+
'!=',
|
|
13879
|
+
'>',
|
|
13880
|
+
'<',
|
|
13881
|
+
'>=',
|
|
13882
|
+
'<=',
|
|
13883
|
+
'between'
|
|
13884
|
+
]).nullish(),
|
|
13885
|
+
op: schemas_enum([
|
|
13886
|
+
'=',
|
|
13887
|
+
'==',
|
|
13888
|
+
'!=',
|
|
13889
|
+
'>',
|
|
13890
|
+
'<',
|
|
13891
|
+
'>=',
|
|
13892
|
+
'<=',
|
|
13893
|
+
'between'
|
|
13894
|
+
]).nullish(),
|
|
13895
|
+
value: union([
|
|
13896
|
+
schemas_string(),
|
|
13897
|
+
schemas_number(),
|
|
13898
|
+
schemas_array(union([
|
|
13899
|
+
schemas_string(),
|
|
13900
|
+
schemas_number()
|
|
13901
|
+
]))
|
|
13902
|
+
])
|
|
13903
|
+
}),
|
|
13904
|
+
schemas_object({
|
|
13905
|
+
field: schemas_string(),
|
|
13906
|
+
operator: schemas_enum([
|
|
13907
|
+
'in',
|
|
13908
|
+
'not in'
|
|
13909
|
+
]).nullish(),
|
|
13910
|
+
op: schemas_enum([
|
|
13911
|
+
'in',
|
|
13912
|
+
'not in'
|
|
13913
|
+
]).nullish(),
|
|
13914
|
+
value: union([
|
|
13915
|
+
schemas_string(),
|
|
13916
|
+
schemas_number(),
|
|
13917
|
+
schemas_array(union([
|
|
13918
|
+
schemas_string(),
|
|
13919
|
+
schemas_number()
|
|
13920
|
+
]))
|
|
13921
|
+
])
|
|
13922
|
+
})
|
|
13923
|
+
]);
|
|
13924
|
+
const zSelectors = schemas_array(zSelector);
|
|
13925
|
+
const zAnnotationPoint = schemas_object({
|
|
13926
|
+
selector: union([
|
|
13927
|
+
zSelector,
|
|
13928
|
+
zSelectors
|
|
13929
|
+
]).nullish(),
|
|
13930
|
+
text: schemas_string().or(schemas_array(schemas_string())).nullish(),
|
|
13931
|
+
textColor: schemas_string().default('#ffffff').nullish(),
|
|
13932
|
+
textFontSize: schemas_number().default(12).nullish(),
|
|
13933
|
+
textFontWeight: schemas_number().default(400).nullish(),
|
|
13934
|
+
textAlign: schemas_enum([
|
|
13935
|
+
'left',
|
|
13936
|
+
'right',
|
|
13937
|
+
'center'
|
|
13938
|
+
]).default('center').nullish(),
|
|
13939
|
+
textBaseline: schemas_enum([
|
|
13940
|
+
'top',
|
|
13941
|
+
'middle',
|
|
13942
|
+
'bottom'
|
|
13943
|
+
]).default('middle').nullish(),
|
|
13944
|
+
textBackgroundVisible: schemas_boolean().default(true).nullish(),
|
|
13945
|
+
textBackgroundColor: schemas_string().default('#212121').nullish(),
|
|
13946
|
+
textBackgroundBorderColor: schemas_string().nullish(),
|
|
13947
|
+
textBackgroundBorderWidth: schemas_number().default(1).nullish(),
|
|
13948
|
+
textBackgroundBorderRadius: schemas_number().default(4).nullish(),
|
|
13949
|
+
textBackgroundPadding: schemas_number().nullish(),
|
|
13950
|
+
offsetY: schemas_number().default(0).nullish(),
|
|
13951
|
+
offsetX: schemas_number().default(0).nullish()
|
|
13952
|
+
});
|
|
13953
|
+
const zAnnotationHorizontalLine = schemas_object({
|
|
13954
|
+
selector: union([
|
|
13955
|
+
zSelector,
|
|
13956
|
+
zSelectors
|
|
13957
|
+
]).nullish(),
|
|
13958
|
+
yValue: union([
|
|
13959
|
+
schemas_number(),
|
|
13960
|
+
schemas_string(),
|
|
13961
|
+
schemas_array(union([
|
|
13962
|
+
schemas_number(),
|
|
13963
|
+
schemas_string()
|
|
13964
|
+
]))
|
|
13965
|
+
]).nullish(),
|
|
13966
|
+
text: schemas_string().or(schemas_array(schemas_string())).nullish(),
|
|
13967
|
+
textPosition: schemas_enum([
|
|
13968
|
+
'outsideStart',
|
|
13969
|
+
'outsideEnd',
|
|
13970
|
+
'outsideMiddle',
|
|
13971
|
+
'insideStart',
|
|
13972
|
+
'insideMiddle',
|
|
13973
|
+
'insideEnd'
|
|
13974
|
+
]).default('insideEnd').nullish(),
|
|
13975
|
+
textColor: schemas_string().default('#ffffff').nullish(),
|
|
13976
|
+
textFontSize: schemas_number().default(12).nullish(),
|
|
13977
|
+
textFontWeight: schemas_number().default(400).nullish(),
|
|
13978
|
+
textAlign: schemas_enum([
|
|
13979
|
+
'left',
|
|
13980
|
+
'right',
|
|
13981
|
+
'center'
|
|
13982
|
+
]).default('right').nullish(),
|
|
13983
|
+
textBaseline: schemas_enum([
|
|
13984
|
+
'top',
|
|
13985
|
+
'middle',
|
|
13986
|
+
'bottom'
|
|
13987
|
+
]).default('top').nullish(),
|
|
13988
|
+
lineVisible: schemas_boolean().default(true).nullish(),
|
|
13989
|
+
lineColor: schemas_string().default('#212121').nullish(),
|
|
13990
|
+
lineWidth: schemas_number().default(1).nullish(),
|
|
13991
|
+
lineStyle: union([
|
|
13992
|
+
literal('solid'),
|
|
13993
|
+
literal('dashed'),
|
|
13994
|
+
literal('dotted')
|
|
13995
|
+
]).default('dashed').nullish(),
|
|
13996
|
+
textBackgroundVisible: schemas_boolean().default(true).nullish(),
|
|
13997
|
+
textBackgroundColor: schemas_string().default('#212121').nullish(),
|
|
13998
|
+
textBackgroundBorderColor: schemas_string().default('#212121').nullish(),
|
|
13999
|
+
textBackgroundBorderRadius: schemas_number().default(4).nullish(),
|
|
14000
|
+
textBackgroundBorderWidth: schemas_number().default(1).nullish(),
|
|
14001
|
+
textBackgroundPadding: schemas_number().default(2).nullish()
|
|
14002
|
+
});
|
|
14003
|
+
const zAnnotationArea = schemas_object({
|
|
14004
|
+
selector: union([
|
|
14005
|
+
zSelector,
|
|
14006
|
+
zSelectors
|
|
14007
|
+
]).nullish(),
|
|
14008
|
+
textPosition: schemas_enum([
|
|
14009
|
+
'top',
|
|
14010
|
+
'topRight',
|
|
14011
|
+
'topLeft',
|
|
14012
|
+
'bottom',
|
|
14013
|
+
'bottomLeft',
|
|
14014
|
+
'bottomRight',
|
|
14015
|
+
'left',
|
|
14016
|
+
'right'
|
|
14017
|
+
]).default('top').nullish(),
|
|
14018
|
+
text: schemas_string().or(schemas_array(schemas_string())).nullish(),
|
|
14019
|
+
textColor: schemas_string().default('#ffffff').nullish(),
|
|
14020
|
+
textFontSize: schemas_number().default(12).nullish(),
|
|
14021
|
+
textFontWeight: schemas_number().default(400).nullish(),
|
|
14022
|
+
textAlign: schemas_enum([
|
|
14023
|
+
'left',
|
|
14024
|
+
'right',
|
|
14025
|
+
'center'
|
|
14026
|
+
]).default('center').nullish(),
|
|
14027
|
+
textBaseline: schemas_enum([
|
|
14028
|
+
'top',
|
|
14029
|
+
'middle',
|
|
14030
|
+
'bottom'
|
|
14031
|
+
]).default('top').nullish(),
|
|
14032
|
+
textBackgroundVisible: schemas_boolean().default(true).nullish(),
|
|
14033
|
+
textBackgroundColor: schemas_string().default('#191d24').nullish(),
|
|
14034
|
+
textBackgroundBorderColor: schemas_string().default('#191d24').nullish(),
|
|
14035
|
+
textBackgroundBorderWidth: schemas_number().default(1).nullish(),
|
|
14036
|
+
textBackgroundBorderRadius: schemas_number().default(4).nullish(),
|
|
14037
|
+
textBackgroundPadding: schemas_number().default(4).nullish(),
|
|
14038
|
+
areaColor: schemas_string().default('#888888').nullish(),
|
|
14039
|
+
areaColorOpacity: schemas_number().default(0.15).nullish(),
|
|
14040
|
+
areaBorderColor: schemas_string().default('#888888').nullish(),
|
|
14041
|
+
areaBorderWidth: schemas_number().default(1).nullish(),
|
|
14042
|
+
areaBorderRadius: schemas_number().default(4).nullish(),
|
|
14043
|
+
areaLineDash: schemas_array(schemas_number()).nullish(),
|
|
14044
|
+
outerPadding: schemas_number().default(4).nullish()
|
|
14045
|
+
});
|
|
14046
|
+
const zAnnotationPointConfig = zAnnotationPoint.omit({
|
|
14047
|
+
selector: true,
|
|
14048
|
+
text: true
|
|
14049
|
+
}).partial();
|
|
14050
|
+
const zAnnotationHorizontalLineConfig = zAnnotationHorizontalLine.pick({
|
|
14051
|
+
lineColor: true,
|
|
14052
|
+
lineWidth: true,
|
|
14053
|
+
lineVisible: true,
|
|
14054
|
+
lineStyle: true,
|
|
14055
|
+
textBackgroundVisible: true,
|
|
14056
|
+
textColor: true,
|
|
14057
|
+
textFontSize: true,
|
|
14058
|
+
textFontWeight: true,
|
|
14059
|
+
textBackgroundColor: true,
|
|
14060
|
+
textBackgroundBorderColor: true,
|
|
14061
|
+
textBackgroundBorderWidth: true,
|
|
14062
|
+
textBackgroundBorderRadius: true,
|
|
14063
|
+
textBackgroundPadding: true
|
|
14064
|
+
}).extend({
|
|
14065
|
+
endSymbolVisible: schemas_boolean().nullish(),
|
|
14066
|
+
endSymbolType: schemas_string().nullish(),
|
|
14067
|
+
endSymbolSize: schemas_number().nullish(),
|
|
14068
|
+
startSymbolVisible: schemas_boolean().nullish(),
|
|
14069
|
+
startSymbolType: schemas_string().nullish(),
|
|
14070
|
+
startSymbolSize: schemas_number().nullish()
|
|
14071
|
+
}).partial();
|
|
14072
|
+
const zAnnotationVerticalLineConfig = zAnnotationHorizontalLineConfig.clone();
|
|
14073
|
+
const zAnnotationAreaConfig = zAnnotationArea.pick({
|
|
14074
|
+
textColor: true,
|
|
14075
|
+
textFontSize: true,
|
|
14076
|
+
textFontWeight: true,
|
|
14077
|
+
textBackgroundVisible: true,
|
|
14078
|
+
textBackgroundColor: true,
|
|
14079
|
+
textBackgroundBorderColor: true,
|
|
14080
|
+
textBackgroundBorderWidth: true,
|
|
14081
|
+
textBackgroundBorderRadius: true,
|
|
14082
|
+
textBackgroundPadding: true,
|
|
14083
|
+
areaColor: true,
|
|
14084
|
+
areaColorOpacity: true,
|
|
14085
|
+
areaBorderColor: true,
|
|
14086
|
+
areaBorderWidth: true,
|
|
14087
|
+
areaBorderRadius: true,
|
|
14088
|
+
areaLineDash: true,
|
|
14089
|
+
outerPadding: true
|
|
14090
|
+
}).partial();
|
|
14091
|
+
const zAnnotaionConfig = schemas_object({
|
|
14092
|
+
annotationPoint: zAnnotationPointConfig.nullish(),
|
|
14093
|
+
annotationHorizontalLine: zAnnotationHorizontalLineConfig.nullish(),
|
|
14094
|
+
annotationVerticalLine: zAnnotationVerticalLineConfig.nullish(),
|
|
14095
|
+
annotationArea: zAnnotationAreaConfig.nullish()
|
|
14096
|
+
});
|
|
13677
14097
|
const zTableConfig = schemas_object({
|
|
13678
14098
|
backgroundColor: zBackgroundColor.nullish(),
|
|
13679
14099
|
borderColor: schemas_string().nullish(),
|
|
@@ -13708,7 +14128,8 @@
|
|
|
13708
14128
|
xAxis: zXBandAxis.nullish(),
|
|
13709
14129
|
yAxis: zYLinearAxis.nullish(),
|
|
13710
14130
|
crosshairLine: zCrosshairLine.nullish(),
|
|
13711
|
-
pivotGrid: zPivotChartGridConfig.nullish()
|
|
14131
|
+
pivotGrid: zPivotChartGridConfig.nullish(),
|
|
14132
|
+
annotation: zAnnotaionConfig.nullish()
|
|
13712
14133
|
});
|
|
13713
14134
|
const zColumnConfig = schemas_object({
|
|
13714
14135
|
backgroundColor: zBackgroundColor.nullish(),
|
|
@@ -13720,7 +14141,8 @@
|
|
|
13720
14141
|
yAxis: zYLinearAxis.nullish(),
|
|
13721
14142
|
crosshairRect: zCrosshairRect.nullish(),
|
|
13722
14143
|
stackCornerRadius: zStackCornerRadius.nullish(),
|
|
13723
|
-
pivotGrid: zPivotChartGridConfig.nullish()
|
|
14144
|
+
pivotGrid: zPivotChartGridConfig.nullish(),
|
|
14145
|
+
annotation: zAnnotaionConfig.nullish()
|
|
13724
14146
|
});
|
|
13725
14147
|
const zColumnParallelConfig = zColumnConfig;
|
|
13726
14148
|
const zColumnPercentConfig = zColumnConfig;
|
|
@@ -13734,7 +14156,8 @@
|
|
|
13734
14156
|
yAxis: zYBandAxis.nullish(),
|
|
13735
14157
|
crosshairRect: zCrosshairRect.nullish(),
|
|
13736
14158
|
stackCornerRadius: zStackCornerRadius.nullish(),
|
|
13737
|
-
pivotGrid: zPivotChartGridConfig.nullish()
|
|
14159
|
+
pivotGrid: zPivotChartGridConfig.nullish(),
|
|
14160
|
+
annotation: zAnnotaionConfig.nullish()
|
|
13738
14161
|
});
|
|
13739
14162
|
const zBarParallelConfig = zBarConfig;
|
|
13740
14163
|
const zBarPercentConfig = zBarConfig;
|
|
@@ -13747,7 +14170,8 @@
|
|
|
13747
14170
|
xAxis: zXBandAxis.nullish(),
|
|
13748
14171
|
yAxis: zYLinearAxis.nullish(),
|
|
13749
14172
|
crosshairLine: zCrosshairLine.nullish(),
|
|
13750
|
-
pivotGrid: zPivotChartGridConfig.nullish()
|
|
14173
|
+
pivotGrid: zPivotChartGridConfig.nullish(),
|
|
14174
|
+
annotation: zAnnotaionConfig.nullish()
|
|
13751
14175
|
});
|
|
13752
14176
|
const zAreaPercentConfig = zAreaConfig;
|
|
13753
14177
|
const zDualAxisConfig = schemas_object({
|
|
@@ -13762,7 +14186,8 @@
|
|
|
13762
14186
|
secondaryYAxis: schemas_array(zYLinearAxis).or(zYLinearAxis).nullish(),
|
|
13763
14187
|
xAxis: zXBandAxis.nullish(),
|
|
13764
14188
|
crosshairRect: zCrosshairRect.nullish(),
|
|
13765
|
-
pivotGrid: zPivotChartGridConfig.nullish()
|
|
14189
|
+
pivotGrid: zPivotChartGridConfig.nullish(),
|
|
14190
|
+
annotation: zAnnotaionConfig.nullish()
|
|
13766
14191
|
});
|
|
13767
14192
|
const zScatterConfig = schemas_object({
|
|
13768
14193
|
backgroundColor: zBackgroundColor.nullish(),
|
|
@@ -13775,7 +14200,8 @@
|
|
|
13775
14200
|
crosshairLine: zCrosshairLine.nullish(),
|
|
13776
14201
|
size: schemas_number().or(schemas_array(schemas_number())).nullish(),
|
|
13777
14202
|
sizeRange: schemas_number().or(schemas_array(schemas_number())).nullish(),
|
|
13778
|
-
pivotGrid: zPivotChartGridConfig.nullish()
|
|
14203
|
+
pivotGrid: zPivotChartGridConfig.nullish(),
|
|
14204
|
+
annotation: zAnnotaionConfig.nullish()
|
|
13779
14205
|
});
|
|
13780
14206
|
const zRoseConfig = schemas_object({
|
|
13781
14207
|
backgroundColor: zBackgroundColor.nullish(),
|
|
@@ -13792,7 +14218,8 @@
|
|
|
13792
14218
|
color: zColor.nullish(),
|
|
13793
14219
|
tooltip: zTooltip.nullish(),
|
|
13794
14220
|
legend: zLegend.nullish(),
|
|
13795
|
-
pivotGrid: zPivotChartGridConfig.nullish()
|
|
14221
|
+
pivotGrid: zPivotChartGridConfig.nullish(),
|
|
14222
|
+
cornerRadius: schemas_number().nullish()
|
|
13796
14223
|
});
|
|
13797
14224
|
const zDonutConfig = zPieConfig;
|
|
13798
14225
|
const zRadarConfig = zPieConfig;
|
|
@@ -13825,61 +14252,6 @@
|
|
|
13825
14252
|
});
|
|
13826
14253
|
const zCustomTheme = record(schemas_string(), zCustomThemeConfig).nullish();
|
|
13827
14254
|
const zTheme = schemas_string();
|
|
13828
|
-
const zSelector = union([
|
|
13829
|
-
schemas_string(),
|
|
13830
|
-
schemas_number(),
|
|
13831
|
-
schemas_object({
|
|
13832
|
-
field: schemas_string(),
|
|
13833
|
-
operator: schemas_enum([
|
|
13834
|
-
'=',
|
|
13835
|
-
'==',
|
|
13836
|
-
'!=',
|
|
13837
|
-
'>',
|
|
13838
|
-
'<',
|
|
13839
|
-
'>=',
|
|
13840
|
-
'<=',
|
|
13841
|
-
'between'
|
|
13842
|
-
]).nullish(),
|
|
13843
|
-
op: schemas_enum([
|
|
13844
|
-
'=',
|
|
13845
|
-
'==',
|
|
13846
|
-
'!=',
|
|
13847
|
-
'>',
|
|
13848
|
-
'<',
|
|
13849
|
-
'>=',
|
|
13850
|
-
'<=',
|
|
13851
|
-
'between'
|
|
13852
|
-
]).nullish(),
|
|
13853
|
-
value: union([
|
|
13854
|
-
schemas_string(),
|
|
13855
|
-
schemas_number(),
|
|
13856
|
-
schemas_array(union([
|
|
13857
|
-
schemas_string(),
|
|
13858
|
-
schemas_number()
|
|
13859
|
-
]))
|
|
13860
|
-
])
|
|
13861
|
-
}),
|
|
13862
|
-
schemas_object({
|
|
13863
|
-
field: schemas_string(),
|
|
13864
|
-
operator: schemas_enum([
|
|
13865
|
-
'in',
|
|
13866
|
-
'not in'
|
|
13867
|
-
]).nullish(),
|
|
13868
|
-
op: schemas_enum([
|
|
13869
|
-
'in',
|
|
13870
|
-
'not in'
|
|
13871
|
-
]).nullish(),
|
|
13872
|
-
value: union([
|
|
13873
|
-
schemas_string(),
|
|
13874
|
-
schemas_number(),
|
|
13875
|
-
schemas_array(union([
|
|
13876
|
-
schemas_string(),
|
|
13877
|
-
schemas_number()
|
|
13878
|
-
]))
|
|
13879
|
-
])
|
|
13880
|
-
})
|
|
13881
|
-
]);
|
|
13882
|
-
const zSelectors = schemas_array(zSelector);
|
|
13883
14255
|
const zBarStyle = schemas_object({
|
|
13884
14256
|
selector: union([
|
|
13885
14257
|
zSelector,
|
|
@@ -13952,34 +14324,6 @@
|
|
|
13952
14324
|
lineStyle: zLineStyle.or(schemas_array(zLineStyle)).nullish(),
|
|
13953
14325
|
areaStyle: zAreaStyle.or(schemas_array(zAreaStyle)).nullish()
|
|
13954
14326
|
});
|
|
13955
|
-
const zAnnotationPoint = schemas_object({
|
|
13956
|
-
selector: union([
|
|
13957
|
-
zSelector,
|
|
13958
|
-
zSelectors
|
|
13959
|
-
]).nullish(),
|
|
13960
|
-
text: schemas_string().or(schemas_array(schemas_string())).nullish(),
|
|
13961
|
-
textColor: schemas_string().default('#ffffff').nullish(),
|
|
13962
|
-
textFontSize: schemas_number().default(12).nullish(),
|
|
13963
|
-
textFontWeight: schemas_number().default(400).nullish(),
|
|
13964
|
-
textAlign: schemas_enum([
|
|
13965
|
-
'left',
|
|
13966
|
-
'right',
|
|
13967
|
-
'center'
|
|
13968
|
-
]).default('center').nullish(),
|
|
13969
|
-
textBaseline: schemas_enum([
|
|
13970
|
-
'top',
|
|
13971
|
-
'middle',
|
|
13972
|
-
'bottom'
|
|
13973
|
-
]).default('middle').nullish(),
|
|
13974
|
-
textBackgroundVisible: schemas_boolean().default(true).nullish(),
|
|
13975
|
-
textBackgroundColor: schemas_string().default('#212121').nullish(),
|
|
13976
|
-
textBackgroundBorderColor: schemas_string().nullish(),
|
|
13977
|
-
textBackgroundBorderWidth: schemas_number().default(1).nullish(),
|
|
13978
|
-
textBackgroundBorderRadius: schemas_number().default(4).nullish(),
|
|
13979
|
-
textBackgroundPadding: schemas_number().nullish(),
|
|
13980
|
-
offsetY: schemas_number().default(0).nullish(),
|
|
13981
|
-
offsetX: schemas_number().default(0).nullish()
|
|
13982
|
-
});
|
|
13983
14327
|
const zAnnotationVerticalLine = schemas_object({
|
|
13984
14328
|
selector: union([
|
|
13985
14329
|
zSelector,
|
|
@@ -14030,98 +14374,6 @@
|
|
|
14030
14374
|
literal('dotted')
|
|
14031
14375
|
]).default('dashed').nullish()
|
|
14032
14376
|
});
|
|
14033
|
-
const zAnnotationHorizontalLine = schemas_object({
|
|
14034
|
-
selector: union([
|
|
14035
|
-
zSelector,
|
|
14036
|
-
zSelectors
|
|
14037
|
-
]).nullish(),
|
|
14038
|
-
yValue: union([
|
|
14039
|
-
schemas_number(),
|
|
14040
|
-
schemas_string(),
|
|
14041
|
-
schemas_array(union([
|
|
14042
|
-
schemas_number(),
|
|
14043
|
-
schemas_string()
|
|
14044
|
-
]))
|
|
14045
|
-
]).nullish(),
|
|
14046
|
-
text: schemas_string().or(schemas_array(schemas_string())).nullish(),
|
|
14047
|
-
textPosition: schemas_enum([
|
|
14048
|
-
'outsideStart',
|
|
14049
|
-
'outsideEnd',
|
|
14050
|
-
'outsideMiddle',
|
|
14051
|
-
'insideStart',
|
|
14052
|
-
'insideMiddle',
|
|
14053
|
-
'insideEnd'
|
|
14054
|
-
]).default('insideEnd').nullish(),
|
|
14055
|
-
textColor: schemas_string().default('#ffffff').nullish(),
|
|
14056
|
-
textFontSize: schemas_number().default(12).nullish(),
|
|
14057
|
-
textFontWeight: schemas_number().default(400).nullish(),
|
|
14058
|
-
textAlign: schemas_enum([
|
|
14059
|
-
'left',
|
|
14060
|
-
'right',
|
|
14061
|
-
'center'
|
|
14062
|
-
]).default('right').nullish(),
|
|
14063
|
-
textBaseline: schemas_enum([
|
|
14064
|
-
'top',
|
|
14065
|
-
'middle',
|
|
14066
|
-
'bottom'
|
|
14067
|
-
]).default('top').nullish(),
|
|
14068
|
-
lineVisible: schemas_boolean().default(true).nullish(),
|
|
14069
|
-
lineColor: schemas_string().default('#212121').nullish(),
|
|
14070
|
-
lineWidth: schemas_number().default(1).nullish(),
|
|
14071
|
-
lineStyle: union([
|
|
14072
|
-
literal('solid'),
|
|
14073
|
-
literal('dashed'),
|
|
14074
|
-
literal('dotted')
|
|
14075
|
-
]).default('dashed').nullish(),
|
|
14076
|
-
textBackgroundVisible: schemas_boolean().default(true).nullish(),
|
|
14077
|
-
textBackgroundColor: schemas_string().default('#212121').nullish(),
|
|
14078
|
-
textBackgroundBorderColor: schemas_string().default('#212121').nullish(),
|
|
14079
|
-
textBackgroundBorderRadius: schemas_number().default(4).nullish(),
|
|
14080
|
-
textBackgroundBorderWidth: schemas_number().default(1).nullish(),
|
|
14081
|
-
textBackgroundPadding: schemas_number().default(2).nullish()
|
|
14082
|
-
});
|
|
14083
|
-
const zAnnotationArea = schemas_object({
|
|
14084
|
-
selector: union([
|
|
14085
|
-
zSelector,
|
|
14086
|
-
zSelectors
|
|
14087
|
-
]).nullish(),
|
|
14088
|
-
textPosition: schemas_enum([
|
|
14089
|
-
'top',
|
|
14090
|
-
'topRight',
|
|
14091
|
-
'topLeft',
|
|
14092
|
-
'bottom',
|
|
14093
|
-
'bottomLeft',
|
|
14094
|
-
'bottomRight',
|
|
14095
|
-
'left',
|
|
14096
|
-
'right'
|
|
14097
|
-
]).default('top').nullish(),
|
|
14098
|
-
text: schemas_string().or(schemas_array(schemas_string())).nullish(),
|
|
14099
|
-
textColor: schemas_string().default('#ffffff').nullish(),
|
|
14100
|
-
textFontSize: schemas_number().default(12).nullish(),
|
|
14101
|
-
textFontWeight: schemas_number().default(400).nullish(),
|
|
14102
|
-
textAlign: schemas_enum([
|
|
14103
|
-
'left',
|
|
14104
|
-
'right',
|
|
14105
|
-
'center'
|
|
14106
|
-
]).default('center').nullish(),
|
|
14107
|
-
textBaseline: schemas_enum([
|
|
14108
|
-
'top',
|
|
14109
|
-
'middle',
|
|
14110
|
-
'bottom'
|
|
14111
|
-
]).default('top').nullish(),
|
|
14112
|
-
textBackgroundVisible: schemas_boolean().default(true).nullish(),
|
|
14113
|
-
textBackgroundColor: schemas_string().default('#191d24').nullish(),
|
|
14114
|
-
textBackgroundBorderColor: schemas_string().default('#191d24').nullish(),
|
|
14115
|
-
textBackgroundBorderWidth: schemas_number().default(1).nullish(),
|
|
14116
|
-
textBackgroundBorderRadius: schemas_number().default(4).nullish(),
|
|
14117
|
-
textBackgroundPadding: schemas_number().default(4).nullish(),
|
|
14118
|
-
areaColor: schemas_string().default('#888888').nullish(),
|
|
14119
|
-
areaColorOpacity: schemas_number().default(0.15).nullish(),
|
|
14120
|
-
areaBorderColor: schemas_string().default('#888888').nullish(),
|
|
14121
|
-
areaBorderWidth: schemas_number().default(1).nullish(),
|
|
14122
|
-
areaBorderRadius: schemas_number().default(4).nullish(),
|
|
14123
|
-
outerPadding: schemas_number().default(4).nullish()
|
|
14124
|
-
});
|
|
14125
14377
|
const zAnnotation = schemas_object({
|
|
14126
14378
|
annotationPoint: zAnnotationPoint.or(schemas_array(zAnnotationPoint)).nullish(),
|
|
14127
14379
|
annotationVerticalLine: zAnnotationVerticalLine.or(schemas_array(zAnnotationVerticalLine)).nullish(),
|