@visactor/vseed 0.0.17 → 0.0.19
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/builder/builder/build.d.ts +0 -1
- package/dist/builder/builder/buildAdvanced.d.ts +0 -1
- package/dist/builder/builder/buildSpec.d.ts +0 -1
- package/dist/builder/builder/builder.d.ts +5973 -6047
- package/dist/builder/builder/index.d.ts +0 -1
- package/dist/builder/index.d.ts +0 -1
- package/dist/builder/register/all.d.ts +0 -1
- package/dist/builder/register/chartType.d.ts +0 -1
- package/dist/builder/register/index.d.ts +0 -1
- package/dist/builder/register/theme.d.ts +0 -1
- package/dist/dataReshape/constant.d.ts +0 -1
- package/dist/dataReshape/dataReshapeFor1D1M.d.ts +0 -1
- package/dist/dataReshape/dataReshapeFor1D2M.d.ts +0 -1
- package/dist/dataReshape/dataReshapeFor2D1M.d.ts +0 -1
- package/dist/dataReshape/foldMeasures.d.ts +0 -1
- package/dist/dataReshape/index.d.ts +0 -1
- package/dist/dataReshape/unfoldDimensions.d.ts +0 -1
- package/dist/dataSelector/index.d.ts +0 -1
- package/dist/dataSelector/selector.d.ts +0 -1
- package/dist/i18n/i18n.d.ts +0 -1
- package/dist/i18n/index.d.ts +0 -1
- package/dist/index.cjs +872 -725
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +0 -1
- package/dist/index.js +706 -655
- package/dist/index.js.map +1 -1
- package/dist/pipeline/advanced/index.d.ts +0 -1
- package/dist/pipeline/advanced/pipeline/area.d.ts +0 -1
- package/dist/pipeline/advanced/pipeline/areaPercent.d.ts +0 -1
- package/dist/pipeline/advanced/pipeline/bar.d.ts +0 -1
- package/dist/pipeline/advanced/pipeline/barParallel.d.ts +0 -1
- package/dist/pipeline/advanced/pipeline/barPercent.d.ts +0 -1
- package/dist/pipeline/advanced/pipeline/column.d.ts +0 -1
- package/dist/pipeline/advanced/pipeline/columnParallel.d.ts +0 -1
- package/dist/pipeline/advanced/pipeline/columnPercent.d.ts +0 -1
- package/dist/pipeline/advanced/pipeline/donut.d.ts +0 -1
- package/dist/pipeline/advanced/pipeline/funnel.d.ts +0 -1
- package/dist/pipeline/advanced/pipeline/index.d.ts +0 -1
- package/dist/pipeline/advanced/pipeline/line.d.ts +0 -1
- package/dist/pipeline/advanced/pipeline/pie.d.ts +0 -1
- package/dist/pipeline/advanced/pipeline/rose.d.ts +0 -1
- package/dist/pipeline/advanced/pipeline/roseParallel.d.ts +0 -1
- package/dist/pipeline/advanced/pipeline/scatter.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/annotation/annotation.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/annotation/index.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/config/config.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/config/index.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/encoding/encodingFunnel.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/encoding/encodingPie.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/encoding/encodingRose.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/encoding/encodingXY.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/encoding/encodingYX.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/encoding/encodingYY.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/encoding/index.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/i18n/index.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/i18n/locale.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/index.d.ts +0 -2
- package/dist/pipeline/advanced/pipes/init/autoDimensions.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/init/autoMeasures.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/init/index.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/init/initAdvancedVSeed.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/init/utils.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/markStyle/index.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/markStyle/markStyle.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/pivot/index.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/pivot/pivotAdapter.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/reshape/index.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/reshape/pivotReshapeTo1D1M.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/reshape/pivotReshapeTo1D2M.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/reshape/pivotReshapeTo2D1M.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/reshape/reshapeTo1D1M.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/reshape/reshapeTo1D2M.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/reshape/reshapeTo2D1M.d.ts +0 -1
- package/dist/pipeline/advanced/pipes/theme/index.d.ts +1 -2
- package/dist/pipeline/advanced/pipes/theme/theme.d.ts +1 -3
- package/dist/pipeline/constant.d.ts +0 -1
- package/dist/pipeline/index.d.ts +0 -1
- package/dist/pipeline/spec/index.d.ts +0 -1
- package/dist/pipeline/spec/pipeline/area.d.ts +0 -1
- package/dist/pipeline/spec/pipeline/areaPercent.d.ts +0 -1
- package/dist/pipeline/spec/pipeline/bar.d.ts +0 -1
- package/dist/pipeline/spec/pipeline/barParallel.d.ts +0 -1
- package/dist/pipeline/spec/pipeline/barPercent.d.ts +0 -1
- package/dist/pipeline/spec/pipeline/column.d.ts +0 -1
- package/dist/pipeline/spec/pipeline/columnParallel.d.ts +0 -1
- package/dist/pipeline/spec/pipeline/columnPercent.d.ts +0 -1
- package/dist/pipeline/spec/pipeline/donut.d.ts +0 -1
- package/dist/pipeline/spec/pipeline/funnel.d.ts +0 -1
- package/dist/pipeline/spec/pipeline/index.d.ts +0 -1
- package/dist/pipeline/spec/pipeline/line.d.ts +0 -1
- package/dist/pipeline/spec/pipeline/pie.d.ts +0 -1
- package/dist/pipeline/spec/pipeline/rose.d.ts +0 -1
- package/dist/pipeline/spec/pipeline/roseParallel.d.ts +0 -1
- package/dist/pipeline/spec/pipeline/scatter.d.ts +0 -1
- package/dist/pipeline/spec/pipes/index.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/annotation/annotationArea.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/annotation/annotationAreaBand.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/annotation/annotationHorizontalLine.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/annotation/annotationPoint.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/annotation/annotationVerticalLine.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/annotation/index.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/annotation/utils.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/axes/a.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/axes/angle.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/axes/index.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/axes/radius.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/axes/xBand.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/axes/xLinear.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/axes/yBand.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/axes/yLinear.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/backgroundColor/background.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/backgroundColor/index.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/color/color.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/color/index.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/crosshair/horizontalCrosshairLine.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/crosshair/horizontalCrosshairRect.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/crosshair/index.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/crosshair/verticalCrosshairLine.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/crosshair/verticalCrosshairRect.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/dataset/dataset.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/dataset/datasetPivot.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/dataset/index.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/area.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/bar.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/barParallel.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/column.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/columnParallel.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/donut.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/funnel.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/index.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/line.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/pie.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/pivot.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/rose.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/roseParallel.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/scatter.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/label/index.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/label/label.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/legend/discreteLegend.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/legend/index.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/legend/pivotDiscreteLegend.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/markStyle/areaStyle.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/markStyle/barStyle.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/markStyle/index.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/markStyle/lineStyle.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/markStyle/pointState.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/markStyle/pointStyle.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/percent/index.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/percent/percent.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/pivotChart/index.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/pivotChart/pivotAdapter.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/pivotChart/pivotColumnDimensions.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/pivotChart/pivotGridStyle.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/pivotChart/pivotIndicators.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/pivotChart/pivotRowDimensions.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/stack/index.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/stack/stack.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/stack/stackCornerRadius.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/tooltip/index.d.ts +0 -1
- package/dist/pipeline/spec/pipes/vchart/tooltip/tooltip.d.ts +0 -1
- package/dist/pipeline/utils/chatType.d.ts +4 -40
- package/dist/pipeline/utils/format/createFormatter.d.ts +0 -1
- package/dist/pipeline/utils/format/createNumFormatter.d.ts +1 -2
- package/dist/pipeline/utils/format/index.d.ts +0 -1
- package/dist/pipeline/utils/index.d.ts +0 -1
- package/dist/pipeline/utils/measures/findMeasureById.d.ts +2 -3
- package/dist/pipeline/utils/measures/index.d.ts +0 -1
- package/dist/pipeline/utils/pipeline.d.ts +0 -1
- package/dist/theme/dark.d.ts +0 -1
- package/dist/theme/index.d.ts +0 -1
- package/dist/theme/light.d.ts +0 -1
- package/dist/types/advancedVSeed.d.ts +2503 -1941
- package/dist/types/builder/builder.d.ts +0 -1
- package/dist/types/builder/index.d.ts +0 -1
- package/dist/types/builder/spec.d.ts +0 -1
- package/dist/types/chartType/area/area.d.ts +450 -28
- package/dist/types/chartType/area/index.d.ts +0 -1
- package/dist/types/chartType/areaPercent/areaPercent.d.ts +450 -28
- package/dist/types/chartType/areaPercent/index.d.ts +0 -1
- package/dist/types/chartType/bar/bar.d.ts +450 -28
- package/dist/types/chartType/bar/index.d.ts +0 -1
- package/dist/types/chartType/barParallel/barParallel.d.ts +450 -28
- package/dist/types/chartType/barParallel/index.d.ts +0 -1
- package/dist/types/chartType/barPercent/barPercent.d.ts +450 -28
- package/dist/types/chartType/barPercent/index.d.ts +0 -1
- package/dist/types/chartType/column/column.d.ts +450 -28
- package/dist/types/chartType/column/index.d.ts +0 -1
- package/dist/types/chartType/columnParallel/columnParallel.d.ts +450 -28
- package/dist/types/chartType/columnParallel/index.d.ts +0 -1
- package/dist/types/chartType/columnPercent/columnPercent.d.ts +450 -28
- package/dist/types/chartType/columnPercent/index.d.ts +0 -1
- package/dist/types/chartType/donut/donut.d.ts +36 -16
- package/dist/types/chartType/donut/index.d.ts +0 -1
- package/dist/types/chartType/dualAxis/dualAxis.d.ts +0 -1
- package/dist/types/chartType/dualAxis/index.d.ts +0 -1
- package/dist/types/chartType/funnel/funnel.d.ts +36 -16
- package/dist/types/chartType/funnel/index.d.ts +0 -1
- package/dist/types/chartType/index.d.ts +0 -1
- package/dist/types/chartType/line/index.d.ts +0 -1
- package/dist/types/chartType/line/line.d.ts +450 -28
- package/dist/types/chartType/pie/index.d.ts +0 -1
- package/dist/types/chartType/pie/pie.d.ts +36 -16
- package/dist/types/chartType/pivotTable/index.d.ts +0 -1
- package/dist/types/chartType/pivotTable/pivotTable.d.ts +0 -1
- package/dist/types/chartType/rose/index.d.ts +0 -1
- package/dist/types/chartType/rose/rose.d.ts +36 -16
- package/dist/types/chartType/roseParallel/index.d.ts +0 -1
- package/dist/types/chartType/roseParallel/roseParallel.d.ts +36 -16
- package/dist/types/chartType/scatter/index.d.ts +0 -1
- package/dist/types/chartType/scatter/scatter.d.ts +452 -28
- package/dist/types/chartType/table/index.d.ts +0 -1
- package/dist/types/chartType/table/table.d.ts +0 -1
- package/dist/types/dataSelector/index.d.ts +0 -1
- package/dist/types/dataSelector/selector.d.ts +0 -1
- package/dist/types/i18n/i18n.d.ts +0 -1
- package/dist/types/i18n/index.d.ts +0 -1
- package/dist/types/index.d.ts +3 -4
- package/dist/types/pipeline/advancedVSeed/advancedVSeed.d.ts +0 -1
- package/dist/types/pipeline/advancedVSeed/index.d.ts +0 -1
- package/dist/types/pipeline/index.d.ts +0 -1
- package/dist/types/pipeline/pipeline.d.ts +0 -1
- package/dist/types/pipeline/spec/index.d.ts +0 -1
- package/dist/types/pipeline/spec/spec.d.ts +0 -1
- package/dist/types/properties/annotation/annotation.d.ts +0 -9
- package/dist/types/properties/annotation/annotationArea.d.ts +0 -1
- package/dist/types/properties/annotation/annotationHorizontalLine.d.ts +0 -3
- package/dist/types/properties/annotation/annotationPoint.d.ts +0 -1
- package/dist/types/properties/annotation/annotationVerticalLine.d.ts +0 -3
- package/dist/types/properties/annotation/index.d.ts +0 -1
- package/dist/types/properties/chartType/chartType.d.ts +0 -1
- package/dist/types/properties/chartType/index.d.ts +0 -1
- package/dist/types/properties/config/{axis.d.ts → axes/axis.d.ts} +13 -2
- package/dist/types/properties/config/{bandAxis.d.ts → axes/bandAxis.d.ts} +2 -3
- package/dist/types/properties/config/axes/index.d.ts +3 -0
- package/dist/types/properties/config/{linearAxis.d.ts → axes/linearAxis.d.ts} +4 -1
- package/dist/types/properties/{baseConfig → config/backgroundColor}/backgroundColor.d.ts +0 -1
- package/dist/types/properties/config/backgroundColor/index.d.ts +1 -0
- package/dist/types/properties/{baseConfig → config/color}/color.d.ts +0 -1
- package/dist/types/properties/config/color/index.d.ts +1 -0
- package/dist/types/properties/config/config.d.ts +3029 -7
- package/dist/types/properties/config/{crosshair.d.ts → crosshair/crosshair.d.ts} +0 -1
- package/dist/types/properties/config/crosshair/index.d.ts +1 -0
- package/dist/types/properties/config/index.d.ts +6 -4
- package/dist/types/properties/config/label/index.d.ts +1 -0
- package/dist/types/properties/{baseConfig → config/label}/label.d.ts +0 -1
- package/dist/types/properties/config/legend/index.d.ts +1 -0
- package/dist/types/properties/{baseConfig → config/legend}/legend.d.ts +0 -1
- package/dist/types/properties/config/stackCornerRadius/index.d.ts +1 -0
- package/dist/types/properties/config/{stackCornerRadius.d.ts → stackCornerRadius/stackCornerRadius.d.ts} +0 -1
- package/dist/types/properties/config/tooltip/index.d.ts +1 -0
- package/dist/types/properties/{baseConfig → config/tooltip}/tooltip.d.ts +0 -1
- package/dist/types/properties/dataset/dataset.d.ts +0 -1
- package/dist/types/properties/dataset/index.d.ts +0 -1
- package/dist/types/properties/datasetReshapeInfo/datasetReshapeInfo.d.ts +0 -1
- package/dist/types/properties/datasetReshapeInfo/index.d.ts +0 -1
- package/dist/types/properties/dimensions/dimensions.d.ts +4 -5
- package/dist/types/properties/dimensions/index.d.ts +0 -1
- package/dist/types/properties/encoding/encoding.d.ts +0 -1
- package/dist/types/properties/encoding/index.d.ts +0 -1
- package/dist/types/properties/index.d.ts +0 -2
- package/dist/types/properties/markStyle/areaStyle.d.ts +0 -1
- package/dist/types/properties/markStyle/barStyle.d.ts +0 -1
- package/dist/types/properties/markStyle/index.d.ts +0 -1
- package/dist/types/properties/markStyle/lineStyle.d.ts +0 -1
- package/dist/types/properties/markStyle/markStyle.d.ts +0 -1
- package/dist/types/properties/markStyle/pointStyle.d.ts +0 -1
- package/dist/types/properties/measures/format/formatter.d.ts +0 -1
- package/dist/types/properties/measures/format/index.d.ts +0 -1
- package/dist/types/properties/measures/format/numFormat.d.ts +99 -7
- package/dist/types/properties/measures/index.d.ts +0 -1
- package/dist/types/properties/measures/measures.d.ts +105 -30
- package/dist/types/properties/theme/customTheme.d.ts +2349 -3242
- package/dist/types/properties/theme/index.d.ts +0 -1
- package/dist/types/properties/theme/theme.d.ts +0 -1
- package/dist/types/vseed.d.ts +5541 -1205
- package/dist/umd/index.js +798 -715
- package/dist/umd/index.js.map +1 -1
- package/package.json +3 -1
- package/dist/builder/builder/build.d.ts.map +0 -1
- package/dist/builder/builder/buildAdvanced.d.ts.map +0 -1
- package/dist/builder/builder/buildSpec.d.ts.map +0 -1
- package/dist/builder/builder/builder.d.ts.map +0 -1
- package/dist/builder/builder/index.d.ts.map +0 -1
- package/dist/builder/index.d.ts.map +0 -1
- package/dist/builder/register/all.d.ts.map +0 -1
- package/dist/builder/register/chartType.d.ts.map +0 -1
- package/dist/builder/register/index.d.ts.map +0 -1
- package/dist/builder/register/theme.d.ts.map +0 -1
- package/dist/dataReshape/constant.d.ts.map +0 -1
- package/dist/dataReshape/dataReshapeFor1D1M.d.ts.map +0 -1
- package/dist/dataReshape/dataReshapeFor1D2M.d.ts.map +0 -1
- package/dist/dataReshape/dataReshapeFor2D1M.d.ts.map +0 -1
- package/dist/dataReshape/foldMeasures.d.ts.map +0 -1
- package/dist/dataReshape/index.d.ts.map +0 -1
- package/dist/dataReshape/unfoldDimensions.d.ts.map +0 -1
- package/dist/dataSelector/index.d.ts.map +0 -1
- package/dist/dataSelector/selector.d.ts.map +0 -1
- package/dist/i18n/i18n.d.ts.map +0 -1
- package/dist/i18n/index.d.ts.map +0 -1
- package/dist/index.d.ts.map +0 -1
- package/dist/pipeline/advanced/index.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipeline/area.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipeline/areaPercent.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipeline/bar.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipeline/barParallel.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipeline/barPercent.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipeline/column.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipeline/columnParallel.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipeline/columnPercent.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipeline/donut.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipeline/funnel.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipeline/index.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipeline/line.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipeline/pie.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipeline/rose.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipeline/roseParallel.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipeline/scatter.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/annotation/annotation.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/annotation/index.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/baseConfig/baseConfig.d.ts +0 -4
- package/dist/pipeline/advanced/pipes/baseConfig/baseConfig.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/baseConfig/index.d.ts +0 -2
- package/dist/pipeline/advanced/pipes/baseConfig/index.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/config/config.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/config/index.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/encoding/encodingFunnel.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/encoding/encodingPie.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/encoding/encodingRose.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/encoding/encodingXY.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/encoding/encodingYX.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/encoding/encodingYY.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/encoding/index.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/i18n/index.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/i18n/locale.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/index.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/init/autoDimensions.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/init/autoMeasures.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/init/index.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/init/initAdvancedVSeed.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/init/utils.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/markStyle/index.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/markStyle/markStyle.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/pivot/index.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/pivot/pivotAdapter.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/reshape/index.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/reshape/pivotReshapeTo1D1M.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/reshape/pivotReshapeTo1D2M.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/reshape/pivotReshapeTo2D1M.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/reshape/reshapeTo1D1M.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/reshape/reshapeTo1D2M.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/reshape/reshapeTo2D1M.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/theme/index.d.ts.map +0 -1
- package/dist/pipeline/advanced/pipes/theme/theme.d.ts.map +0 -1
- package/dist/pipeline/constant.d.ts.map +0 -1
- package/dist/pipeline/index.d.ts.map +0 -1
- package/dist/pipeline/spec/index.d.ts.map +0 -1
- package/dist/pipeline/spec/pipeline/area.d.ts.map +0 -1
- package/dist/pipeline/spec/pipeline/areaPercent.d.ts.map +0 -1
- package/dist/pipeline/spec/pipeline/bar.d.ts.map +0 -1
- package/dist/pipeline/spec/pipeline/barParallel.d.ts.map +0 -1
- package/dist/pipeline/spec/pipeline/barPercent.d.ts.map +0 -1
- package/dist/pipeline/spec/pipeline/column.d.ts.map +0 -1
- package/dist/pipeline/spec/pipeline/columnParallel.d.ts.map +0 -1
- package/dist/pipeline/spec/pipeline/columnPercent.d.ts.map +0 -1
- package/dist/pipeline/spec/pipeline/donut.d.ts.map +0 -1
- package/dist/pipeline/spec/pipeline/funnel.d.ts.map +0 -1
- package/dist/pipeline/spec/pipeline/index.d.ts.map +0 -1
- package/dist/pipeline/spec/pipeline/line.d.ts.map +0 -1
- package/dist/pipeline/spec/pipeline/pie.d.ts.map +0 -1
- package/dist/pipeline/spec/pipeline/rose.d.ts.map +0 -1
- package/dist/pipeline/spec/pipeline/roseParallel.d.ts.map +0 -1
- package/dist/pipeline/spec/pipeline/scatter.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/index.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/annotation/annotationArea.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/annotation/annotationAreaBand.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/annotation/annotationHorizontalLine.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/annotation/annotationPoint.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/annotation/annotationVerticalLine.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/annotation/index.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/annotation/utils.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/axes/a.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/axes/angle.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/axes/index.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/axes/radius.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/axes/xBand.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/axes/xLinear.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/axes/yBand.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/axes/yLinear.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/backgroundColor/background.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/backgroundColor/index.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/color/color.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/color/index.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/crosshair/horizontalCrosshairLine.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/crosshair/horizontalCrosshairRect.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/crosshair/index.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/crosshair/verticalCrosshairLine.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/crosshair/verticalCrosshairRect.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/dataset/dataset.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/dataset/datasetPivot.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/dataset/index.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/area.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/bar.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/barParallel.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/column.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/columnParallel.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/donut.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/funnel.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/index.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/line.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/pie.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/pivot.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/rose.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/roseParallel.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/init/scatter.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/label/index.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/label/label.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/legend/discreteLegend.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/legend/index.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/legend/pivotDiscreteLegend.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/markStyle/areaStyle.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/markStyle/barStyle.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/markStyle/index.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/markStyle/lineStyle.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/markStyle/pointState.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/markStyle/pointStyle.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/percent/index.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/percent/percent.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/pivotChart/index.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/pivotChart/pivotAdapter.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/pivotChart/pivotColumnDimensions.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/pivotChart/pivotGridStyle.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/pivotChart/pivotIndicators.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/pivotChart/pivotRowDimensions.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/stack/index.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/stack/stack.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/stack/stackCornerRadius.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/tooltip/index.d.ts.map +0 -1
- package/dist/pipeline/spec/pipes/vchart/tooltip/tooltip.d.ts.map +0 -1
- package/dist/pipeline/utils/chatType.d.ts.map +0 -1
- package/dist/pipeline/utils/format/createFormatter.d.ts.map +0 -1
- package/dist/pipeline/utils/format/createNumFormatter.d.ts.map +0 -1
- package/dist/pipeline/utils/format/index.d.ts.map +0 -1
- package/dist/pipeline/utils/index.d.ts.map +0 -1
- package/dist/pipeline/utils/measures/findMeasureById.d.ts.map +0 -1
- package/dist/pipeline/utils/measures/index.d.ts.map +0 -1
- package/dist/pipeline/utils/pipeline.d.ts.map +0 -1
- package/dist/theme/dark.d.ts.map +0 -1
- package/dist/theme/index.d.ts.map +0 -1
- package/dist/theme/light.d.ts.map +0 -1
- package/dist/types/advancedVSeed.d.ts.map +0 -1
- package/dist/types/builder/builder.d.ts.map +0 -1
- package/dist/types/builder/index.d.ts.map +0 -1
- package/dist/types/builder/spec.d.ts.map +0 -1
- package/dist/types/chartType/area/area.d.ts.map +0 -1
- package/dist/types/chartType/area/index.d.ts.map +0 -1
- package/dist/types/chartType/areaPercent/areaPercent.d.ts.map +0 -1
- package/dist/types/chartType/areaPercent/index.d.ts.map +0 -1
- package/dist/types/chartType/bar/bar.d.ts.map +0 -1
- package/dist/types/chartType/bar/index.d.ts.map +0 -1
- package/dist/types/chartType/barParallel/barParallel.d.ts.map +0 -1
- package/dist/types/chartType/barParallel/index.d.ts.map +0 -1
- package/dist/types/chartType/barPercent/barPercent.d.ts.map +0 -1
- package/dist/types/chartType/barPercent/index.d.ts.map +0 -1
- package/dist/types/chartType/column/column.d.ts.map +0 -1
- package/dist/types/chartType/column/index.d.ts.map +0 -1
- package/dist/types/chartType/columnParallel/columnParallel.d.ts.map +0 -1
- package/dist/types/chartType/columnParallel/index.d.ts.map +0 -1
- package/dist/types/chartType/columnPercent/columnPercent.d.ts.map +0 -1
- package/dist/types/chartType/columnPercent/index.d.ts.map +0 -1
- package/dist/types/chartType/donut/donut.d.ts.map +0 -1
- package/dist/types/chartType/donut/index.d.ts.map +0 -1
- package/dist/types/chartType/dualAxis/dualAxis.d.ts.map +0 -1
- package/dist/types/chartType/dualAxis/index.d.ts.map +0 -1
- package/dist/types/chartType/funnel/funnel.d.ts.map +0 -1
- package/dist/types/chartType/funnel/index.d.ts.map +0 -1
- package/dist/types/chartType/index.d.ts.map +0 -1
- package/dist/types/chartType/line/index.d.ts.map +0 -1
- package/dist/types/chartType/line/line.d.ts.map +0 -1
- package/dist/types/chartType/pie/index.d.ts.map +0 -1
- package/dist/types/chartType/pie/pie.d.ts.map +0 -1
- package/dist/types/chartType/pivotTable/index.d.ts.map +0 -1
- package/dist/types/chartType/pivotTable/pivotTable.d.ts.map +0 -1
- package/dist/types/chartType/rose/index.d.ts.map +0 -1
- package/dist/types/chartType/rose/rose.d.ts.map +0 -1
- package/dist/types/chartType/roseParallel/index.d.ts.map +0 -1
- package/dist/types/chartType/roseParallel/roseParallel.d.ts.map +0 -1
- package/dist/types/chartType/scatter/index.d.ts.map +0 -1
- package/dist/types/chartType/scatter/scatter.d.ts.map +0 -1
- package/dist/types/chartType/table/index.d.ts.map +0 -1
- package/dist/types/chartType/table/table.d.ts.map +0 -1
- package/dist/types/dataSelector/index.d.ts.map +0 -1
- package/dist/types/dataSelector/selector.d.ts.map +0 -1
- package/dist/types/i18n/i18n.d.ts.map +0 -1
- package/dist/types/i18n/index.d.ts.map +0 -1
- package/dist/types/index.d.ts.map +0 -1
- package/dist/types/pipeline/advancedVSeed/advancedVSeed.d.ts.map +0 -1
- package/dist/types/pipeline/advancedVSeed/index.d.ts.map +0 -1
- package/dist/types/pipeline/index.d.ts.map +0 -1
- package/dist/types/pipeline/pipeline.d.ts.map +0 -1
- package/dist/types/pipeline/spec/index.d.ts.map +0 -1
- package/dist/types/pipeline/spec/spec.d.ts.map +0 -1
- package/dist/types/properties/annotation/annotation.d.ts.map +0 -1
- package/dist/types/properties/annotation/annotationArea.d.ts.map +0 -1
- package/dist/types/properties/annotation/annotationHorizontalLine.d.ts.map +0 -1
- package/dist/types/properties/annotation/annotationPoint.d.ts.map +0 -1
- package/dist/types/properties/annotation/annotationVerticalLine.d.ts.map +0 -1
- package/dist/types/properties/annotation/index.d.ts.map +0 -1
- package/dist/types/properties/baseConfig/backgroundColor.d.ts.map +0 -1
- package/dist/types/properties/baseConfig/baseConfig.d.ts +0 -147
- package/dist/types/properties/baseConfig/baseConfig.d.ts.map +0 -1
- package/dist/types/properties/baseConfig/color.d.ts.map +0 -1
- package/dist/types/properties/baseConfig/index.d.ts +0 -13
- package/dist/types/properties/baseConfig/index.d.ts.map +0 -1
- package/dist/types/properties/baseConfig/label.d.ts.map +0 -1
- package/dist/types/properties/baseConfig/legend.d.ts.map +0 -1
- package/dist/types/properties/baseConfig/tooltip.d.ts.map +0 -1
- package/dist/types/properties/chartType/chartType.d.ts.map +0 -1
- package/dist/types/properties/chartType/index.d.ts.map +0 -1
- package/dist/types/properties/config/axis.d.ts.map +0 -1
- package/dist/types/properties/config/bandAxis.d.ts.map +0 -1
- package/dist/types/properties/config/config.d.ts.map +0 -1
- package/dist/types/properties/config/crosshair.d.ts.map +0 -1
- package/dist/types/properties/config/index.d.ts.map +0 -1
- package/dist/types/properties/config/linearAxis.d.ts.map +0 -1
- package/dist/types/properties/config/stackCornerRadius.d.ts.map +0 -1
- package/dist/types/properties/dataset/dataset.d.ts.map +0 -1
- package/dist/types/properties/dataset/index.d.ts.map +0 -1
- package/dist/types/properties/datasetReshapeInfo/datasetReshapeInfo.d.ts.map +0 -1
- package/dist/types/properties/datasetReshapeInfo/index.d.ts.map +0 -1
- package/dist/types/properties/dimensions/dimensions.d.ts.map +0 -1
- package/dist/types/properties/dimensions/index.d.ts.map +0 -1
- package/dist/types/properties/encoding/encoding.d.ts.map +0 -1
- package/dist/types/properties/encoding/index.d.ts.map +0 -1
- package/dist/types/properties/index.d.ts.map +0 -1
- package/dist/types/properties/markStyle/areaStyle.d.ts.map +0 -1
- package/dist/types/properties/markStyle/barStyle.d.ts.map +0 -1
- package/dist/types/properties/markStyle/index.d.ts.map +0 -1
- package/dist/types/properties/markStyle/lineStyle.d.ts.map +0 -1
- package/dist/types/properties/markStyle/markStyle.d.ts.map +0 -1
- package/dist/types/properties/markStyle/pointStyle.d.ts.map +0 -1
- package/dist/types/properties/measures/format/formatter.d.ts.map +0 -1
- package/dist/types/properties/measures/format/index.d.ts.map +0 -1
- package/dist/types/properties/measures/format/numFormat.d.ts.map +0 -1
- package/dist/types/properties/measures/index.d.ts.map +0 -1
- package/dist/types/properties/measures/measures.d.ts.map +0 -1
- package/dist/types/properties/theme/customTheme.d.ts.map +0 -1
- package/dist/types/properties/theme/index.d.ts.map +0 -1
- package/dist/types/properties/theme/theme.d.ts.map +0 -1
- package/dist/types/vseed.d.ts.map +0 -1
package/dist/index.js
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
import { clone
|
1
|
+
import { clone, groupBy, isArray, isEmpty, isNullish, isNumber, isString, mergeDeep, omit, pick, unique } from "remeda";
|
2
2
|
import { z } from "zod";
|
3
3
|
const initAdvancedVSeed = (advancedVSeed, context)=>{
|
4
4
|
const { vseed } = context;
|
@@ -12,11 +12,11 @@ const execPipeline = (pipeline, context, initialValue = {})=>{
|
|
12
12
|
const result = pipeline.reduce((prev, cur)=>cur(prev, context), initialValue);
|
13
13
|
return result;
|
14
14
|
};
|
15
|
-
const isVTable = (
|
15
|
+
const isVTable = (vseed)=>[
|
16
16
|
'table',
|
17
17
|
'pivotTable'
|
18
|
-
].includes(chartType);
|
19
|
-
const isVChart = (
|
18
|
+
].includes(vseed.chartType);
|
19
|
+
const isVChart = (vseed)=>!isVTable(vseed);
|
20
20
|
const isPivotChart = (vseed)=>{
|
21
21
|
const { measures, dimensions } = vseed;
|
22
22
|
const hasRowOrColumnDimension = dimensions && dimensions.some((dimension)=>'rowDimension' === dimension.location || 'columnDimension' === dimension.location);
|
@@ -24,7 +24,7 @@ const isPivotChart = (vseed)=>{
|
|
24
24
|
return hasRowOrColumnDimension || hasMeasureGroup;
|
25
25
|
};
|
26
26
|
var i18n_namespaceObject = JSON.parse('{"指标名称":{"en-US":"MeasureName","zh-CN":"指标名称"},"指标Id":{"en-US":"MeasureId","zh-CN":"指标Id"},"指标值":{"en-US":"MeasureValue","zh-CN":"指标值"}}');
|
27
|
-
class
|
27
|
+
class i18n_Intl {
|
28
28
|
static instance;
|
29
29
|
translateMap = i18n_namespaceObject;
|
30
30
|
locale = 'zh-CN';
|
@@ -43,14 +43,34 @@ class Intl {
|
|
43
43
|
};
|
44
44
|
getLocale = ()=>this.locale;
|
45
45
|
static getInstance() {
|
46
|
-
if (!
|
47
|
-
return
|
46
|
+
if (!i18n_Intl.instance) i18n_Intl.instance = new i18n_Intl();
|
47
|
+
return i18n_Intl.instance;
|
48
48
|
}
|
49
49
|
}
|
50
|
-
const intl =
|
50
|
+
const intl = i18n_Intl.getInstance();
|
51
51
|
const i18n = intl.i18n;
|
52
|
-
const createNumFormatter = (format)=>{
|
53
|
-
const { type = 'number', ratio = 1, symbol = '', thousandSeparator = true,
|
52
|
+
const createNumFormatter = (format, locale = intl.getLocale())=>{
|
53
|
+
const { type = 'number', ratio = 1, symbol = '', thousandSeparator = true, prefix = '', suffix = '', fractionDigits = 2, significantDigits, roundingMode = 'halfExpand', roundingPriority = 'auto' } = format || {};
|
54
|
+
const numFormatterOptions = {
|
55
|
+
style: 'decimal',
|
56
|
+
notation: 'scientific' === type ? 'scientific' : 'standard',
|
57
|
+
roundingMode,
|
58
|
+
roundingPriority
|
59
|
+
};
|
60
|
+
console.log('debug roundingMode', roundingMode);
|
61
|
+
if (isNumber(fractionDigits)) {
|
62
|
+
if (fractionDigits >= 0) {
|
63
|
+
numFormatterOptions.minimumFractionDigits = fractionDigits;
|
64
|
+
numFormatterOptions.maximumFractionDigits = fractionDigits;
|
65
|
+
}
|
66
|
+
}
|
67
|
+
if (isNumber(significantDigits) && significantDigits > 0) {
|
68
|
+
if (significantDigits > 0) {
|
69
|
+
numFormatterOptions.minimumSignificantDigits = significantDigits;
|
70
|
+
numFormatterOptions.maximumSignificantDigits = significantDigits;
|
71
|
+
}
|
72
|
+
}
|
73
|
+
const numFormatter = new Intl.NumberFormat(locale, numFormatterOptions);
|
54
74
|
return (value)=>{
|
55
75
|
let num = Number(value);
|
56
76
|
let typeSymbol = '';
|
@@ -62,9 +82,7 @@ const createNumFormatter = (format)=>{
|
|
62
82
|
num *= 1000;
|
63
83
|
typeSymbol = "\u2030";
|
64
84
|
} else if ('number' === type) num /= ratio || 1;
|
65
|
-
|
66
|
-
num = Math[round](num * multiplier) / multiplier;
|
67
|
-
let numStr = num.toFixed(decimalPlaces);
|
85
|
+
let numStr = numFormatter.format(num);
|
68
86
|
if (thousandSeparator) {
|
69
87
|
const parts = numStr.split('.');
|
70
88
|
parts[0] = parts[0].replace(/\B(?=(\d{3})+(?!\d))/g, ',');
|
@@ -77,80 +95,20 @@ const autoNumFormatter = (value, locale = intl.getLocale())=>{
|
|
77
95
|
if (null == value) return String(value);
|
78
96
|
const num = Number(value);
|
79
97
|
if (Number.isNaN(num)) return String(value);
|
80
|
-
const
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
};
|
89
|
-
|
90
|
-
type: 'number',
|
91
|
-
decimalPlaces: countDecimalPlaces(num),
|
92
|
-
round: 'round',
|
93
|
-
thousandSeparator: true
|
94
|
-
};
|
95
|
-
const rules = NUMBER_FORMAT_RULES[locale] || NUMBER_FORMAT_RULES['default'];
|
96
|
-
for (const rule of rules)if (num >= rule.threshold) {
|
97
|
-
numFormat.ratio = rule.ratio;
|
98
|
-
numFormat.symbol = rule.symbol;
|
99
|
-
break;
|
100
|
-
}
|
101
|
-
return createNumFormatter(numFormat)(value);
|
102
|
-
};
|
103
|
-
const NUMBER_FORMAT_RULES = {
|
104
|
-
'zh-CN': [
|
105
|
-
{
|
106
|
-
threshold: 100000000,
|
107
|
-
ratio: 100000000,
|
108
|
-
symbol: "\u4EBF"
|
109
|
-
},
|
110
|
-
{
|
111
|
-
threshold: 10000,
|
112
|
-
ratio: 10000,
|
113
|
-
symbol: "\u4E07"
|
114
|
-
}
|
115
|
-
],
|
116
|
-
'en-US': [
|
117
|
-
{
|
118
|
-
threshold: 1000000000,
|
119
|
-
ratio: 1000000000,
|
120
|
-
symbol: 'B'
|
121
|
-
},
|
122
|
-
{
|
123
|
-
threshold: 1000000,
|
124
|
-
ratio: 1000000,
|
125
|
-
symbol: 'M'
|
126
|
-
},
|
127
|
-
{
|
128
|
-
threshold: 1000,
|
129
|
-
ratio: 1000,
|
130
|
-
symbol: 'K'
|
131
|
-
}
|
132
|
-
],
|
133
|
-
default: [
|
134
|
-
{
|
135
|
-
threshold: 1000000000,
|
136
|
-
ratio: 1000000000,
|
137
|
-
symbol: 'B'
|
138
|
-
},
|
139
|
-
{
|
140
|
-
threshold: 1000000,
|
141
|
-
ratio: 1000000,
|
142
|
-
symbol: 'M'
|
143
|
-
},
|
144
|
-
{
|
145
|
-
threshold: 1000,
|
146
|
-
ratio: 1000,
|
147
|
-
symbol: 'K'
|
148
|
-
}
|
149
|
-
]
|
98
|
+
const numFormatterOptions = {
|
99
|
+
style: 'decimal',
|
100
|
+
notation: 'compact'
|
101
|
+
};
|
102
|
+
numFormatterOptions.minimumFractionDigits = 0;
|
103
|
+
numFormatterOptions.maximumFractionDigits = 2;
|
104
|
+
const numFormatter = new Intl.NumberFormat(locale, {
|
105
|
+
...numFormatterOptions
|
106
|
+
});
|
107
|
+
return numFormatter.format(Number(value));
|
150
108
|
};
|
151
109
|
const createFormatter = (format)=>createNumFormatter(format);
|
152
110
|
const autoFormatter = (value, locale)=>autoNumFormatter(value, locale);
|
153
|
-
const findMeasureById = (measures, id)=>{
|
111
|
+
const findMeasureById = (measures = [], id)=>{
|
154
112
|
if (!measures) return;
|
155
113
|
const stack = [
|
156
114
|
...measures
|
@@ -162,7 +120,7 @@ const findMeasureById = (measures, id)=>{
|
|
162
120
|
if ('children' in current && current.children) stack.push(...current.children);
|
163
121
|
}
|
164
122
|
};
|
165
|
-
const findFirstMeasure = (measures)=>{
|
123
|
+
const findFirstMeasure = (measures = [])=>{
|
166
124
|
if (!measures) return;
|
167
125
|
const stack = [
|
168
126
|
...measures
|
@@ -394,14 +352,17 @@ const dataReshapeFor2D1M = (dataset, dimensions, measures, options)=>{
|
|
394
352
|
};
|
395
353
|
}
|
396
354
|
{
|
397
|
-
const
|
398
|
-
|
399
|
-
|
400
|
-
|
401
|
-
|
402
|
-
|
403
|
-
|
404
|
-
|
355
|
+
const onlyOneMeasure = 1 === measures.length;
|
356
|
+
const onlyOneDimension = 1 === dimensions.length;
|
357
|
+
const dims = [
|
358
|
+
...dimensions
|
359
|
+
];
|
360
|
+
if (!onlyOneMeasure || onlyOneDimension) dims.push({
|
361
|
+
id: foldMeasureName,
|
362
|
+
alias: i18n`指标名称`,
|
363
|
+
location: 'dimension'
|
364
|
+
});
|
365
|
+
const { dataset: finalDataset, unfoldInfo } = unfoldDimensions(foldedDataset, dims, [
|
405
366
|
{
|
406
367
|
id: foldMeasureValue,
|
407
368
|
alias: i18n`指标值`
|
@@ -453,14 +414,17 @@ const dataReshapeFor1D1M = (dataset, dimensions, measures, options)=>{
|
|
453
414
|
};
|
454
415
|
}
|
455
416
|
{
|
456
|
-
const
|
417
|
+
const dims = 1 === measures.length ? [
|
418
|
+
...dimensions
|
419
|
+
] : [
|
457
420
|
...dimensions,
|
458
421
|
{
|
459
422
|
id: foldMeasureName,
|
460
423
|
alias: i18n`指标名称`,
|
461
424
|
location: 'dimension'
|
462
425
|
}
|
463
|
-
]
|
426
|
+
];
|
427
|
+
const { dataset: finalDataset, unfoldInfo } = unfoldDimensions(foldedDataset, dims, [
|
464
428
|
{
|
465
429
|
id: foldMeasureValue,
|
466
430
|
alias: i18n`指标值`
|
@@ -887,32 +851,18 @@ const encodingFunnel = (advancedVSeed)=>{
|
|
887
851
|
encoding
|
888
852
|
};
|
889
853
|
};
|
890
|
-
const
|
854
|
+
const lineConfig = (advancedVSeed, context)=>{
|
891
855
|
const { vseed } = context;
|
856
|
+
const { chartType } = vseed;
|
892
857
|
const result = {
|
893
858
|
...advancedVSeed
|
894
859
|
};
|
895
|
-
const config =
|
860
|
+
const config = pick(vseed, [
|
896
861
|
'backgroundColor',
|
897
862
|
'color',
|
898
863
|
'label',
|
899
864
|
'legend',
|
900
|
-
'tooltip'
|
901
|
-
]);
|
902
|
-
result.baseConfig = {
|
903
|
-
vchart: {
|
904
|
-
...config
|
905
|
-
}
|
906
|
-
};
|
907
|
-
return result;
|
908
|
-
};
|
909
|
-
const lineConfig = (advancedVSeed, context)=>{
|
910
|
-
const { vseed } = context;
|
911
|
-
const { chartType } = vseed;
|
912
|
-
const result = {
|
913
|
-
...advancedVSeed
|
914
|
-
};
|
915
|
-
const config = external_remeda_pick(vseed, [
|
865
|
+
'tooltip',
|
916
866
|
'xAxis',
|
917
867
|
'yAxis',
|
918
868
|
'crosshairLine'
|
@@ -931,7 +881,12 @@ const columnConfig = (advancedVSeed, context)=>{
|
|
931
881
|
const result = {
|
932
882
|
...advancedVSeed
|
933
883
|
};
|
934
|
-
const config =
|
884
|
+
const config = pick(vseed, [
|
885
|
+
'backgroundColor',
|
886
|
+
'color',
|
887
|
+
'label',
|
888
|
+
'legend',
|
889
|
+
'tooltip',
|
935
890
|
'xAxis',
|
936
891
|
'yAxis',
|
937
892
|
'crosshairRect',
|
@@ -951,7 +906,13 @@ const pieConfig = (advancedVSeed, context)=>{
|
|
951
906
|
const result = {
|
952
907
|
...advancedVSeed
|
953
908
|
};
|
954
|
-
const config =
|
909
|
+
const config = pick(vseed, [
|
910
|
+
'backgroundColor',
|
911
|
+
'color',
|
912
|
+
'label',
|
913
|
+
'legend',
|
914
|
+
'tooltip'
|
915
|
+
]);
|
955
916
|
result.config = {
|
956
917
|
...result.config || {},
|
957
918
|
[chartType]: {
|
@@ -972,29 +933,27 @@ const donutConfig = pieConfig;
|
|
972
933
|
const roseConfig = pieConfig;
|
973
934
|
const roseParallelConfig = pieConfig;
|
974
935
|
const funnelConfig = pieConfig;
|
975
|
-
const
|
936
|
+
const theme_theme = (advancedVSeed, context)=>{
|
976
937
|
const { customTheme, vseed } = context;
|
977
938
|
const { theme = 'light', chartType } = vseed;
|
978
939
|
const result = {
|
979
940
|
...advancedVSeed
|
980
941
|
};
|
981
942
|
if (!customTheme || !customTheme[theme]) return result;
|
982
|
-
const baseConfigVChartTheme = customTheme?.[theme].baseConfig?.vchart;
|
983
|
-
if (baseConfigVChartTheme) {
|
984
|
-
const baseConfigVChart = result.baseConfig?.vchart || {};
|
985
|
-
const mergedConfig = external_remeda_mergeDeep(baseConfigVChartTheme, external_remeda_clone(baseConfigVChart));
|
986
|
-
result.baseConfig = {
|
987
|
-
vchart: mergedConfig
|
988
|
-
};
|
989
|
-
}
|
990
943
|
const chartConfigTheme = customTheme?.[theme].config?.[chartType];
|
991
944
|
if (chartConfigTheme) {
|
992
945
|
const chartConfig = result.config?.[chartType] || {};
|
993
|
-
const mergedConfig =
|
946
|
+
const mergedConfig = mergeDeep(chartConfigTheme, clone(chartConfig));
|
994
947
|
result.config = {
|
995
948
|
[chartType]: mergedConfig
|
996
949
|
};
|
997
950
|
}
|
951
|
+
const chartCustomTheme = customTheme?.[theme]?.config?.[chartType];
|
952
|
+
result.customTheme = {
|
953
|
+
config: {
|
954
|
+
[chartType]: chartCustomTheme
|
955
|
+
}
|
956
|
+
};
|
998
957
|
return result;
|
999
958
|
};
|
1000
959
|
const pivotAdapter = (pipeline, pivotPipeline)=>(advancedVSeed, context)=>{
|
@@ -1005,7 +964,7 @@ const pivotAdapter = (pipeline, pivotPipeline)=>(advancedVSeed, context)=>{
|
|
1005
964
|
};
|
1006
965
|
const markStyle_markStyle = (advancedVSeed, context)=>{
|
1007
966
|
const { vseed } = context;
|
1008
|
-
const markStyle =
|
967
|
+
const markStyle = pick(vseed, [
|
1009
968
|
'barStyle',
|
1010
969
|
'pointStyle',
|
1011
970
|
'lineStyle',
|
@@ -1018,7 +977,7 @@ const markStyle_markStyle = (advancedVSeed, context)=>{
|
|
1018
977
|
};
|
1019
978
|
const annotation_annotation = (advancedVSeed, context)=>{
|
1020
979
|
const { vseed } = context;
|
1021
|
-
const annotation =
|
980
|
+
const annotation = pick(vseed, [
|
1022
981
|
'annotationPoint',
|
1023
982
|
'annotationHorizontalLine',
|
1024
983
|
'annotationVerticalLine',
|
@@ -1048,9 +1007,8 @@ const lineAdvancedPipeline = [
|
|
1048
1007
|
pivotReshapeTo2D1M
|
1049
1008
|
]),
|
1050
1009
|
encodingXY,
|
1051
|
-
vchartBaseConfig,
|
1052
1010
|
lineConfig,
|
1053
|
-
|
1011
|
+
theme_theme,
|
1054
1012
|
markStyle_markStyle,
|
1055
1013
|
annotation_annotation
|
1056
1014
|
];
|
@@ -1066,8 +1024,7 @@ const barAdvancedPipeline = [
|
|
1066
1024
|
]),
|
1067
1025
|
encodingYX,
|
1068
1026
|
barConfig,
|
1069
|
-
|
1070
|
-
vchartTheme,
|
1027
|
+
theme_theme,
|
1071
1028
|
markStyle_markStyle,
|
1072
1029
|
annotation_annotation
|
1073
1030
|
];
|
@@ -1083,8 +1040,7 @@ const barParallelAdvancedPipeline = [
|
|
1083
1040
|
]),
|
1084
1041
|
encodingYX,
|
1085
1042
|
barParallelConfig,
|
1086
|
-
|
1087
|
-
vchartTheme,
|
1043
|
+
theme_theme,
|
1088
1044
|
markStyle_markStyle,
|
1089
1045
|
annotation_annotation
|
1090
1046
|
];
|
@@ -1100,8 +1056,7 @@ const barPercentAdvancedPipeline = [
|
|
1100
1056
|
]),
|
1101
1057
|
encodingYX,
|
1102
1058
|
barPercentConfig,
|
1103
|
-
|
1104
|
-
vchartTheme,
|
1059
|
+
theme_theme,
|
1105
1060
|
markStyle_markStyle,
|
1106
1061
|
annotation_annotation
|
1107
1062
|
];
|
@@ -1117,8 +1072,7 @@ const columnAdvancedPipeline = [
|
|
1117
1072
|
]),
|
1118
1073
|
encodingXY,
|
1119
1074
|
columnConfig,
|
1120
|
-
|
1121
|
-
vchartTheme,
|
1075
|
+
theme_theme,
|
1122
1076
|
markStyle_markStyle,
|
1123
1077
|
annotation_annotation
|
1124
1078
|
];
|
@@ -1134,8 +1088,7 @@ const columnParallelAdvancedPipeline = [
|
|
1134
1088
|
]),
|
1135
1089
|
encodingXY,
|
1136
1090
|
columnParallelConfig,
|
1137
|
-
|
1138
|
-
vchartTheme,
|
1091
|
+
theme_theme,
|
1139
1092
|
markStyle_markStyle,
|
1140
1093
|
annotation_annotation
|
1141
1094
|
];
|
@@ -1151,8 +1104,7 @@ const columnPercentAdvancedPipeline = [
|
|
1151
1104
|
]),
|
1152
1105
|
encodingXY,
|
1153
1106
|
columnPercentConfig,
|
1154
|
-
|
1155
|
-
vchartTheme,
|
1107
|
+
theme_theme,
|
1156
1108
|
markStyle_markStyle,
|
1157
1109
|
annotation_annotation
|
1158
1110
|
];
|
@@ -1168,8 +1120,7 @@ const areaAdvancedPipeline = [
|
|
1168
1120
|
]),
|
1169
1121
|
encodingXY,
|
1170
1122
|
areaConfig,
|
1171
|
-
|
1172
|
-
vchartTheme,
|
1123
|
+
theme_theme,
|
1173
1124
|
markStyle_markStyle,
|
1174
1125
|
annotation_annotation
|
1175
1126
|
];
|
@@ -1185,8 +1136,7 @@ const areaPercentAdvancedPipeline = [
|
|
1185
1136
|
]),
|
1186
1137
|
encodingXY,
|
1187
1138
|
areaPercentConfig,
|
1188
|
-
|
1189
|
-
vchartTheme,
|
1139
|
+
theme_theme,
|
1190
1140
|
markStyle_markStyle,
|
1191
1141
|
annotation_annotation
|
1192
1142
|
];
|
@@ -1202,8 +1152,7 @@ const pieAdvancedPipeline = [
|
|
1202
1152
|
]),
|
1203
1153
|
encodingPie,
|
1204
1154
|
pieConfig,
|
1205
|
-
|
1206
|
-
vchartTheme,
|
1155
|
+
theme_theme,
|
1207
1156
|
annotation_annotation
|
1208
1157
|
];
|
1209
1158
|
const donutAdvancedPipeline = [
|
@@ -1218,8 +1167,7 @@ const donutAdvancedPipeline = [
|
|
1218
1167
|
]),
|
1219
1168
|
encodingPie,
|
1220
1169
|
donutConfig,
|
1221
|
-
|
1222
|
-
vchartTheme,
|
1170
|
+
theme_theme,
|
1223
1171
|
annotation_annotation
|
1224
1172
|
];
|
1225
1173
|
const roseAdvancedPipeline = [
|
@@ -1234,8 +1182,7 @@ const roseAdvancedPipeline = [
|
|
1234
1182
|
]),
|
1235
1183
|
encodingRose,
|
1236
1184
|
roseConfig,
|
1237
|
-
|
1238
|
-
vchartTheme,
|
1185
|
+
theme_theme,
|
1239
1186
|
markStyle_markStyle,
|
1240
1187
|
annotation_annotation
|
1241
1188
|
];
|
@@ -1251,8 +1198,7 @@ const roseParallelAdvancedPipeline = [
|
|
1251
1198
|
]),
|
1252
1199
|
encodingRose,
|
1253
1200
|
roseParallelConfig,
|
1254
|
-
|
1255
|
-
vchartTheme,
|
1201
|
+
theme_theme,
|
1256
1202
|
markStyle_markStyle,
|
1257
1203
|
annotation_annotation
|
1258
1204
|
];
|
@@ -1268,8 +1214,7 @@ const funnelAdvancedPipeline = [
|
|
1268
1214
|
]),
|
1269
1215
|
encodingFunnel,
|
1270
1216
|
funnelConfig,
|
1271
|
-
|
1272
|
-
vchartTheme,
|
1217
|
+
theme_theme,
|
1273
1218
|
annotation_annotation
|
1274
1219
|
];
|
1275
1220
|
const encodingYY = (advancedVSeed)=>{
|
@@ -1319,9 +1264,8 @@ const scatterAdvancedPipeline = [
|
|
1319
1264
|
pivotReshapeTo1D2M
|
1320
1265
|
]),
|
1321
1266
|
encodingYY,
|
1322
|
-
vchartBaseConfig,
|
1323
1267
|
scatterConfig,
|
1324
|
-
|
1268
|
+
theme_theme,
|
1325
1269
|
markStyle_markStyle,
|
1326
1270
|
annotation_annotation
|
1327
1271
|
];
|
@@ -1527,7 +1471,8 @@ const initPie = (spec, context)=>{
|
|
1527
1471
|
result.pie = {
|
1528
1472
|
style: {
|
1529
1473
|
stroke: '#ffffff',
|
1530
|
-
lineWidth: 1
|
1474
|
+
lineWidth: 1,
|
1475
|
+
centerOffset: 0
|
1531
1476
|
},
|
1532
1477
|
state: {
|
1533
1478
|
hover: {
|
@@ -1817,13 +1762,14 @@ const xLinear = (spec, context)=>{
|
|
1817
1762
|
];
|
1818
1763
|
return result;
|
1819
1764
|
}
|
1820
|
-
const { visible = true, label, tick, title, grid, line, zero, nice, inverse, max, min } = config;
|
1765
|
+
const { visible = true, label, tick, title, grid, line, zero, nice, inverse, max, min, log, logBase = 10 } = config;
|
1821
1766
|
const linearAxis = {
|
1822
1767
|
visible,
|
1823
|
-
type: 'linear',
|
1768
|
+
type: log ? 'log' : 'linear',
|
1769
|
+
base: logBase,
|
1824
1770
|
orient: 'bottom',
|
1825
1771
|
nice,
|
1826
|
-
zero,
|
1772
|
+
zero: log ? false : zero,
|
1827
1773
|
inverse,
|
1828
1774
|
max,
|
1829
1775
|
min,
|
@@ -1993,13 +1939,14 @@ const yLinear = (spec, context)=>{
|
|
1993
1939
|
];
|
1994
1940
|
return result;
|
1995
1941
|
}
|
1996
|
-
const { visible = true, label, tick, title, grid, line, zero, nice, inverse, max, min } = config;
|
1942
|
+
const { visible = true, label, tick, title, grid, line, zero, nice, inverse, max, min, log, logBase = 10 } = config;
|
1997
1943
|
const linearAxis = {
|
1998
1944
|
visible,
|
1999
|
-
type: 'linear',
|
1945
|
+
type: log ? 'log' : 'linear',
|
1946
|
+
base: logBase,
|
2000
1947
|
orient: 'left',
|
2001
1948
|
nice,
|
2002
|
-
zero,
|
1949
|
+
zero: log ? false : zero,
|
2003
1950
|
inverse,
|
2004
1951
|
max,
|
2005
1952
|
min,
|
@@ -2155,25 +2102,22 @@ const background_backgroundColor = (spec, context)=>{
|
|
2155
2102
|
...spec
|
2156
2103
|
};
|
2157
2104
|
const { advancedVSeed } = context;
|
2158
|
-
const {
|
2159
|
-
|
2160
|
-
const { backgroundColor } = baseConfig
|
2105
|
+
const { chartType } = advancedVSeed;
|
2106
|
+
const baseConfig = advancedVSeed.config[chartType];
|
2107
|
+
const { backgroundColor } = baseConfig;
|
2161
2108
|
return {
|
2162
2109
|
...result,
|
2163
2110
|
background: backgroundColor
|
2164
2111
|
};
|
2165
2112
|
};
|
2166
|
-
const defaultTooltip = {
|
2167
|
-
enable: true
|
2168
|
-
};
|
2169
2113
|
const tooltip_tooltip = (spec, context)=>{
|
2170
2114
|
const result = {
|
2171
2115
|
...spec
|
2172
2116
|
};
|
2173
2117
|
const { advancedVSeed } = context;
|
2174
|
-
const { measures, datasetReshapeInfo } = advancedVSeed;
|
2175
|
-
const baseConfig = advancedVSeed.
|
2176
|
-
const { tooltip
|
2118
|
+
const { measures, datasetReshapeInfo, chartType } = advancedVSeed;
|
2119
|
+
const baseConfig = advancedVSeed.config[chartType];
|
2120
|
+
const { tooltip } = baseConfig;
|
2177
2121
|
const { enable } = tooltip;
|
2178
2122
|
const { measureId, measureValue } = datasetReshapeInfo[0].foldInfo;
|
2179
2123
|
const { groupName } = datasetReshapeInfo[0].unfoldInfo;
|
@@ -2235,7 +2179,8 @@ const label_label = (spec, context)=>{
|
|
2235
2179
|
};
|
2236
2180
|
const { advancedVSeed } = context;
|
2237
2181
|
const { measures, datasetReshapeInfo, locale } = advancedVSeed;
|
2238
|
-
const
|
2182
|
+
const { chartType } = advancedVSeed;
|
2183
|
+
const baseConfig = advancedVSeed.config[chartType];
|
2239
2184
|
if (!baseConfig || !baseConfig.label) return result;
|
2240
2185
|
const { measureId, measureValue } = datasetReshapeInfo[0].foldInfo;
|
2241
2186
|
const { label } = baseConfig;
|
@@ -2267,9 +2212,9 @@ const discreteLegend = (spec, context)=>{
|
|
2267
2212
|
...spec
|
2268
2213
|
};
|
2269
2214
|
const { advancedVSeed } = context;
|
2270
|
-
const { datasetReshapeInfo } = advancedVSeed;
|
2215
|
+
const { datasetReshapeInfo, chartType } = advancedVSeed;
|
2271
2216
|
const { unfoldInfo } = datasetReshapeInfo[0];
|
2272
|
-
const baseConfig = advancedVSeed.
|
2217
|
+
const baseConfig = advancedVSeed.config[chartType];
|
2273
2218
|
if (!baseConfig || !baseConfig.legend) return result;
|
2274
2219
|
const { legend } = baseConfig;
|
2275
2220
|
const { enable, position = 'bottom', labelFontColor, labelFontSize = 12, labelFontWeight, maxSize, border, shapeType = 'rectRound' } = legend || {};
|
@@ -2366,7 +2311,8 @@ const pivotDiscreteLegend = (spec, context)=>{
|
|
2366
2311
|
...spec
|
2367
2312
|
};
|
2368
2313
|
const { advancedVSeed } = context;
|
2369
|
-
const
|
2314
|
+
const { chartType } = advancedVSeed;
|
2315
|
+
const baseConfig = advancedVSeed.config[chartType];
|
2370
2316
|
if (!baseConfig || !baseConfig.legend) return result;
|
2371
2317
|
const { datasetReshapeInfo } = advancedVSeed;
|
2372
2318
|
const colorItems = unique(datasetReshapeInfo.flatMap((d)=>d.unfoldInfo.colorItems));
|
@@ -2475,9 +2421,9 @@ const color_color = (spec, context)=>{
|
|
2475
2421
|
...spec
|
2476
2422
|
};
|
2477
2423
|
const { advancedVSeed } = context;
|
2478
|
-
const { datasetReshapeInfo } = advancedVSeed;
|
2424
|
+
const { datasetReshapeInfo, chartType } = advancedVSeed;
|
2479
2425
|
const { unfoldInfo } = datasetReshapeInfo[0];
|
2480
|
-
const baseConfig = advancedVSeed.
|
2426
|
+
const baseConfig = advancedVSeed.config[chartType];
|
2481
2427
|
if (!baseConfig || !baseConfig.color) return result;
|
2482
2428
|
const { color } = baseConfig;
|
2483
2429
|
const { colorScheme, colorMapping } = color;
|
@@ -2879,8 +2825,7 @@ const pointStyle_pointStyle = (spec, context)=>{
|
|
2879
2825
|
const { markStyle } = advancedVSeed;
|
2880
2826
|
const { pointStyle } = markStyle;
|
2881
2827
|
const result = {
|
2882
|
-
...spec
|
2883
|
-
point: {}
|
2828
|
+
...spec
|
2884
2829
|
};
|
2885
2830
|
if (!pointStyle) return result;
|
2886
2831
|
const pointStyles = Array.isArray(pointStyle) ? pointStyle : [
|
@@ -2933,6 +2878,7 @@ const pointStateDimensionHover = (spec)=>{
|
|
2933
2878
|
point: {
|
2934
2879
|
...point,
|
2935
2880
|
state: {
|
2881
|
+
...point.state || {},
|
2936
2882
|
dimension_hover: {
|
2937
2883
|
scaleX: 1.4,
|
2938
2884
|
scaleY: 1.4
|
@@ -2951,6 +2897,7 @@ const pointStateHover = (spec, context)=>{
|
|
2951
2897
|
point: {
|
2952
2898
|
...point,
|
2953
2899
|
state: {
|
2900
|
+
...point.state || {},
|
2954
2901
|
hover: {
|
2955
2902
|
scaleX: 1.4,
|
2956
2903
|
scaleY: 1.4,
|
@@ -3145,7 +3092,7 @@ const annotationVerticalLine_annotationVerticalLine = (spec, context)=>{
|
|
3145
3092
|
insideEnd: 'insideEndTop'
|
3146
3093
|
};
|
3147
3094
|
const markLine = annotationVerticalLineList.flatMap((annotationVerticalLine)=>{
|
3148
|
-
const { selector: selectorPoint, xValue, text = '', textPosition = 'insideEnd', textColor = '#ffffff', textFontSize = 12, textFontWeight = 400, textAlign = 'right', textBaseline = 'top', backgroundBorderColor, backgroundBorderRadius = 4, backgroundBorderWidth = 1, backgroundColor = '#212121', backgroundPadding = 2, backgroundVisible = true,
|
3095
|
+
const { selector: selectorPoint, xValue, text = '', textPosition = 'insideEnd', textColor = '#ffffff', textFontSize = 12, textFontWeight = 400, textAlign = 'right', textBaseline = 'top', backgroundBorderColor, backgroundBorderRadius = 4, backgroundBorderWidth = 1, backgroundColor = '#212121', backgroundPadding = 2, backgroundVisible = true, lineColor = '#212121', lineStyle = 'dashed', lineVisible = true, lineWidth = 1 } = annotationVerticalLine;
|
3149
3096
|
const dataset = advancedVSeed.dataset.flat();
|
3150
3097
|
const generateOneMarkLine = (x)=>({
|
3151
3098
|
x: x,
|
@@ -3153,8 +3100,6 @@ const annotationVerticalLine_annotationVerticalLine = (spec, context)=>{
|
|
3153
3100
|
line: {
|
3154
3101
|
visible: lineVisible,
|
3155
3102
|
style: {
|
3156
|
-
offsetX,
|
3157
|
-
offsetY,
|
3158
3103
|
stroke: lineColor,
|
3159
3104
|
lineStyle: lineStyle,
|
3160
3105
|
lineWidth: lineWidth,
|
@@ -3173,8 +3118,6 @@ const annotationVerticalLine_annotationVerticalLine = (spec, context)=>{
|
|
3173
3118
|
text: text,
|
3174
3119
|
position: positionMap[textPosition],
|
3175
3120
|
style: {
|
3176
|
-
offsetX,
|
3177
|
-
offsetY,
|
3178
3121
|
visible: true,
|
3179
3122
|
textAlign: textAlign,
|
3180
3123
|
textBaseline: textBaseline,
|
@@ -3186,8 +3129,6 @@ const annotationVerticalLine_annotationVerticalLine = (spec, context)=>{
|
|
3186
3129
|
visible: backgroundVisible,
|
3187
3130
|
padding: backgroundPadding,
|
3188
3131
|
style: {
|
3189
|
-
offsetX,
|
3190
|
-
offsetY,
|
3191
3132
|
cornerRadius: backgroundBorderRadius ?? 4,
|
3192
3133
|
fill: backgroundColor,
|
3193
3134
|
stroke: backgroundBorderColor,
|
@@ -3242,7 +3183,7 @@ const annotationHorizontalLine_annotationHorizontalLine = (spec, context)=>{
|
|
3242
3183
|
insideEnd: 'insideEndTop'
|
3243
3184
|
};
|
3244
3185
|
const markLine = annotationVerticalLineList.flatMap((annotationVerticalLine)=>{
|
3245
|
-
const { selector: selectorPoint, yValue, text = '', textPosition = 'insideEnd', textColor = '#ffffff', textFontSize = 12, textFontWeight = 400, textAlign = 'center', textBaseline = 'bottom', backgroundBorderColor, backgroundBorderRadius = 4, backgroundBorderWidth = 1, backgroundColor = '#212121', backgroundPadding = 2, backgroundVisible = true,
|
3186
|
+
const { selector: selectorPoint, yValue, text = '', textPosition = 'insideEnd', textColor = '#ffffff', textFontSize = 12, textFontWeight = 400, textAlign = 'center', textBaseline = 'bottom', backgroundBorderColor, backgroundBorderRadius = 4, backgroundBorderWidth = 1, backgroundColor = '#212121', backgroundPadding = 2, backgroundVisible = true, lineColor = '#212121', lineStyle = 'dashed', lineVisible = true, lineWidth = 1 } = annotationVerticalLine;
|
3246
3187
|
const dataset = advancedVSeed.dataset.flat();
|
3247
3188
|
const generateOneMarkLine = (y)=>({
|
3248
3189
|
y,
|
@@ -3250,8 +3191,6 @@ const annotationHorizontalLine_annotationHorizontalLine = (spec, context)=>{
|
|
3250
3191
|
line: {
|
3251
3192
|
visible: lineVisible,
|
3252
3193
|
style: {
|
3253
|
-
offsetX,
|
3254
|
-
offsetY,
|
3255
3194
|
stroke: lineColor,
|
3256
3195
|
lineStyle: lineStyle,
|
3257
3196
|
lineWidth: lineWidth,
|
@@ -3270,8 +3209,6 @@ const annotationHorizontalLine_annotationHorizontalLine = (spec, context)=>{
|
|
3270
3209
|
text: text,
|
3271
3210
|
position: positionMap[textPosition],
|
3272
3211
|
style: {
|
3273
|
-
offsetX,
|
3274
|
-
offsetY,
|
3275
3212
|
visible: true,
|
3276
3213
|
textAlign: textAlign,
|
3277
3214
|
textBaseline: textBaseline,
|
@@ -3283,8 +3220,6 @@ const annotationHorizontalLine_annotationHorizontalLine = (spec, context)=>{
|
|
3283
3220
|
visible: backgroundVisible,
|
3284
3221
|
padding: backgroundPadding,
|
3285
3222
|
style: {
|
3286
|
-
offsetX,
|
3287
|
-
offsetY,
|
3288
3223
|
cornerRadius: backgroundBorderRadius ?? 4,
|
3289
3224
|
fill: backgroundColor,
|
3290
3225
|
stroke: backgroundBorderColor,
|
@@ -4672,52 +4607,49 @@ const darkTheme = ()=>{
|
|
4672
4607
|
labelColor: '#4B4F54',
|
4673
4608
|
labelBackgroundColor: '#ffffff'
|
4674
4609
|
};
|
4675
|
-
|
4676
|
-
|
4677
|
-
|
4678
|
-
|
4679
|
-
|
4680
|
-
|
4681
|
-
|
4682
|
-
|
4683
|
-
|
4684
|
-
|
4685
|
-
|
4686
|
-
|
4687
|
-
|
4688
|
-
|
4689
|
-
|
4690
|
-
|
4691
|
-
|
4692
|
-
|
4693
|
-
|
4694
|
-
|
4695
|
-
|
4696
|
-
label: {
|
4697
|
-
enable: true
|
4698
|
-
},
|
4699
|
-
tooltip: {
|
4700
|
-
enable: true
|
4701
|
-
},
|
4702
|
-
legend: {
|
4703
|
-
enable: true,
|
4704
|
-
border: true,
|
4705
|
-
maxSize: 1,
|
4706
|
-
position: 'rt',
|
4707
|
-
shapeType: 'rectRound',
|
4708
|
-
labelFontColor: '#FDFDFD',
|
4709
|
-
labelFontSize: 12,
|
4710
|
-
labelFontWeight: 400
|
4711
|
-
}
|
4712
|
-
}
|
4610
|
+
const baseConfig = {
|
4611
|
+
backgroundColor: 'transparent',
|
4612
|
+
color: {
|
4613
|
+
colorScheme: [
|
4614
|
+
'#2E62F1',
|
4615
|
+
'#4DC36A',
|
4616
|
+
'#FF8406',
|
4617
|
+
'#FFCC00',
|
4618
|
+
'#4F44CF',
|
4619
|
+
'#5AC8FA',
|
4620
|
+
'#003A8C',
|
4621
|
+
'#B08AE2',
|
4622
|
+
'#FF6341',
|
4623
|
+
'#98DD62'
|
4624
|
+
]
|
4625
|
+
},
|
4626
|
+
label: {
|
4627
|
+
enable: true
|
4628
|
+
},
|
4629
|
+
tooltip: {
|
4630
|
+
enable: true
|
4713
4631
|
},
|
4632
|
+
legend: {
|
4633
|
+
enable: true,
|
4634
|
+
border: true,
|
4635
|
+
maxSize: 1,
|
4636
|
+
position: 'rt',
|
4637
|
+
shapeType: 'rectRound',
|
4638
|
+
labelFontColor: '#FDFDFD',
|
4639
|
+
labelFontSize: 12,
|
4640
|
+
labelFontWeight: 400
|
4641
|
+
}
|
4642
|
+
};
|
4643
|
+
return {
|
4714
4644
|
config: {
|
4715
4645
|
line: {
|
4646
|
+
...baseConfig,
|
4716
4647
|
xAxis: bandAxis,
|
4717
4648
|
yAxis: linearAxis,
|
4718
4649
|
crosshairLine: crosshairLine
|
4719
4650
|
},
|
4720
4651
|
column: {
|
4652
|
+
...baseConfig,
|
4721
4653
|
xAxis: bandAxis,
|
4722
4654
|
yAxis: linearAxis,
|
4723
4655
|
crosshairRect: crosshairRect,
|
@@ -4729,6 +4661,7 @@ const darkTheme = ()=>{
|
|
4729
4661
|
]
|
4730
4662
|
},
|
4731
4663
|
columnParallel: {
|
4664
|
+
...baseConfig,
|
4732
4665
|
xAxis: bandAxis,
|
4733
4666
|
yAxis: linearAxis,
|
4734
4667
|
crosshairRect: crosshairRect,
|
@@ -4740,6 +4673,7 @@ const darkTheme = ()=>{
|
|
4740
4673
|
]
|
4741
4674
|
},
|
4742
4675
|
columnPercent: {
|
4676
|
+
...baseConfig,
|
4743
4677
|
xAxis: bandAxis,
|
4744
4678
|
yAxis: linearAxis,
|
4745
4679
|
crosshairRect: crosshairRect,
|
@@ -4751,6 +4685,7 @@ const darkTheme = ()=>{
|
|
4751
4685
|
]
|
4752
4686
|
},
|
4753
4687
|
bar: {
|
4688
|
+
...baseConfig,
|
4754
4689
|
xAxis: linearAxis,
|
4755
4690
|
yAxis: barBandAxis,
|
4756
4691
|
crosshairRect: crosshairRect,
|
@@ -4762,6 +4697,7 @@ const darkTheme = ()=>{
|
|
4762
4697
|
]
|
4763
4698
|
},
|
4764
4699
|
barParallel: {
|
4700
|
+
...baseConfig,
|
4765
4701
|
xAxis: linearAxis,
|
4766
4702
|
yAxis: barBandAxis,
|
4767
4703
|
crosshairRect: crosshairRect,
|
@@ -4773,6 +4709,7 @@ const darkTheme = ()=>{
|
|
4773
4709
|
]
|
4774
4710
|
},
|
4775
4711
|
barPercent: {
|
4712
|
+
...baseConfig,
|
4776
4713
|
xAxis: linearAxis,
|
4777
4714
|
yAxis: barBandAxis,
|
4778
4715
|
crosshairRect: crosshairRect,
|
@@ -4784,16 +4721,19 @@ const darkTheme = ()=>{
|
|
4784
4721
|
]
|
4785
4722
|
},
|
4786
4723
|
area: {
|
4724
|
+
...baseConfig,
|
4787
4725
|
xAxis: bandAxis,
|
4788
4726
|
yAxis: linearAxis,
|
4789
4727
|
crosshairLine: crosshairLine
|
4790
4728
|
},
|
4791
4729
|
areaPercent: {
|
4730
|
+
...baseConfig,
|
4792
4731
|
xAxis: bandAxis,
|
4793
4732
|
yAxis: linearAxis,
|
4794
4733
|
crosshairLine: crosshairLine
|
4795
4734
|
},
|
4796
4735
|
scatter: {
|
4736
|
+
...baseConfig,
|
4797
4737
|
xAxis: {
|
4798
4738
|
...linearAxis,
|
4799
4739
|
line: {
|
@@ -4809,6 +4749,35 @@ const darkTheme = ()=>{
|
|
4809
4749
|
}
|
4810
4750
|
},
|
4811
4751
|
crosshairLine
|
4752
|
+
},
|
4753
|
+
pie: {
|
4754
|
+
...baseConfig
|
4755
|
+
},
|
4756
|
+
donut: {
|
4757
|
+
...baseConfig
|
4758
|
+
},
|
4759
|
+
rose: {
|
4760
|
+
...baseConfig
|
4761
|
+
},
|
4762
|
+
roseParallel: {
|
4763
|
+
...baseConfig
|
4764
|
+
},
|
4765
|
+
funnel: {
|
4766
|
+
...baseConfig,
|
4767
|
+
color: {
|
4768
|
+
colorScheme: [
|
4769
|
+
'#2E62F1',
|
4770
|
+
'#3A6EF6',
|
4771
|
+
'#4780FA',
|
4772
|
+
'#548CFE',
|
4773
|
+
'#6198FF',
|
4774
|
+
'#6FA3FF',
|
4775
|
+
'#7CACFF',
|
4776
|
+
'#88B7FF',
|
4777
|
+
'#94C2FF',
|
4778
|
+
'#A0CEFF'
|
4779
|
+
]
|
4780
|
+
}
|
4812
4781
|
}
|
4813
4782
|
}
|
4814
4783
|
};
|
@@ -4918,52 +4887,49 @@ const lightTheme = ()=>{
|
|
4918
4887
|
labelColor: '#ffffff',
|
4919
4888
|
labelBackgroundColor: '#364159'
|
4920
4889
|
};
|
4921
|
-
|
4922
|
-
|
4923
|
-
|
4924
|
-
|
4925
|
-
|
4926
|
-
|
4927
|
-
|
4928
|
-
|
4929
|
-
|
4930
|
-
|
4931
|
-
|
4932
|
-
|
4933
|
-
|
4934
|
-
|
4935
|
-
|
4936
|
-
'#F9AD71',
|
4937
|
-
'#ED8888',
|
4938
|
-
'#E9A0C3',
|
4939
|
-
'#D77DD3'
|
4940
|
-
]
|
4941
|
-
},
|
4942
|
-
label: {
|
4943
|
-
enable: true
|
4944
|
-
},
|
4945
|
-
tooltip: {
|
4946
|
-
enable: true
|
4947
|
-
},
|
4948
|
-
legend: {
|
4949
|
-
enable: true,
|
4950
|
-
border: true,
|
4951
|
-
maxSize: 1,
|
4952
|
-
shapeType: 'rectRound',
|
4953
|
-
position: 'rt',
|
4954
|
-
labelFontColor: '#646A73',
|
4955
|
-
labelFontSize: 12,
|
4956
|
-
labelFontWeight: 400
|
4957
|
-
}
|
4958
|
-
}
|
4890
|
+
const baseConfig = {
|
4891
|
+
backgroundColor: 'transparent',
|
4892
|
+
color: {
|
4893
|
+
colorScheme: [
|
4894
|
+
'#8D72F6',
|
4895
|
+
'#5766EC',
|
4896
|
+
'#66A3FE',
|
4897
|
+
'#51D5E6',
|
4898
|
+
'#4EC0B3',
|
4899
|
+
'#F9DF90',
|
4900
|
+
'#F9AD71',
|
4901
|
+
'#ED8888',
|
4902
|
+
'#E9A0C3',
|
4903
|
+
'#D77DD3'
|
4904
|
+
]
|
4959
4905
|
},
|
4906
|
+
label: {
|
4907
|
+
enable: true
|
4908
|
+
},
|
4909
|
+
tooltip: {
|
4910
|
+
enable: true
|
4911
|
+
},
|
4912
|
+
legend: {
|
4913
|
+
enable: true,
|
4914
|
+
border: true,
|
4915
|
+
maxSize: 1,
|
4916
|
+
shapeType: 'rectRound',
|
4917
|
+
position: 'rt',
|
4918
|
+
labelFontColor: '#646A73',
|
4919
|
+
labelFontSize: 12,
|
4920
|
+
labelFontWeight: 400
|
4921
|
+
}
|
4922
|
+
};
|
4923
|
+
return {
|
4960
4924
|
config: {
|
4961
4925
|
line: {
|
4926
|
+
...baseConfig,
|
4962
4927
|
xAxis: bandAxis,
|
4963
4928
|
yAxis: linearAxis,
|
4964
4929
|
crosshairLine
|
4965
4930
|
},
|
4966
4931
|
column: {
|
4932
|
+
...baseConfig,
|
4967
4933
|
xAxis: bandAxis,
|
4968
4934
|
yAxis: linearAxis,
|
4969
4935
|
crosshairRect,
|
@@ -4975,6 +4941,7 @@ const lightTheme = ()=>{
|
|
4975
4941
|
]
|
4976
4942
|
},
|
4977
4943
|
columnParallel: {
|
4944
|
+
...baseConfig,
|
4978
4945
|
xAxis: bandAxis,
|
4979
4946
|
yAxis: linearAxis,
|
4980
4947
|
crosshairRect,
|
@@ -4986,6 +4953,7 @@ const lightTheme = ()=>{
|
|
4986
4953
|
]
|
4987
4954
|
},
|
4988
4955
|
columnPercent: {
|
4956
|
+
...baseConfig,
|
4989
4957
|
xAxis: bandAxis,
|
4990
4958
|
yAxis: linearAxis,
|
4991
4959
|
crosshairRect,
|
@@ -4997,6 +4965,7 @@ const lightTheme = ()=>{
|
|
4997
4965
|
]
|
4998
4966
|
},
|
4999
4967
|
bar: {
|
4968
|
+
...baseConfig,
|
5000
4969
|
xAxis: linearAxis,
|
5001
4970
|
yAxis: barBandAxis,
|
5002
4971
|
crosshairRect,
|
@@ -5008,6 +4977,7 @@ const lightTheme = ()=>{
|
|
5008
4977
|
]
|
5009
4978
|
},
|
5010
4979
|
barParallel: {
|
4980
|
+
...baseConfig,
|
5011
4981
|
xAxis: linearAxis,
|
5012
4982
|
yAxis: barBandAxis,
|
5013
4983
|
crosshairRect,
|
@@ -5019,6 +4989,7 @@ const lightTheme = ()=>{
|
|
5019
4989
|
]
|
5020
4990
|
},
|
5021
4991
|
barPercent: {
|
4992
|
+
...baseConfig,
|
5022
4993
|
xAxis: linearAxis,
|
5023
4994
|
yAxis: barBandAxis,
|
5024
4995
|
crosshairRect,
|
@@ -5030,16 +5001,19 @@ const lightTheme = ()=>{
|
|
5030
5001
|
]
|
5031
5002
|
},
|
5032
5003
|
area: {
|
5004
|
+
...baseConfig,
|
5033
5005
|
xAxis: bandAxis,
|
5034
5006
|
yAxis: linearAxis,
|
5035
5007
|
crosshairLine
|
5036
5008
|
},
|
5037
5009
|
areaPercent: {
|
5010
|
+
...baseConfig,
|
5038
5011
|
xAxis: bandAxis,
|
5039
5012
|
yAxis: linearAxis,
|
5040
5013
|
crosshairLine
|
5041
5014
|
},
|
5042
5015
|
scatter: {
|
5016
|
+
...baseConfig,
|
5043
5017
|
xAxis: {
|
5044
5018
|
...linearAxis,
|
5045
5019
|
line: {
|
@@ -5055,6 +5029,35 @@ const lightTheme = ()=>{
|
|
5055
5029
|
}
|
5056
5030
|
},
|
5057
5031
|
crosshairLine
|
5032
|
+
},
|
5033
|
+
pie: {
|
5034
|
+
...baseConfig
|
5035
|
+
},
|
5036
|
+
donut: {
|
5037
|
+
...baseConfig
|
5038
|
+
},
|
5039
|
+
rose: {
|
5040
|
+
...baseConfig
|
5041
|
+
},
|
5042
|
+
roseParallel: {
|
5043
|
+
...baseConfig
|
5044
|
+
},
|
5045
|
+
funnel: {
|
5046
|
+
...baseConfig,
|
5047
|
+
color: {
|
5048
|
+
colorScheme: [
|
5049
|
+
'#5766EC',
|
5050
|
+
'#6372F0',
|
5051
|
+
'#7080F4',
|
5052
|
+
'#7C8CFA',
|
5053
|
+
'#8998FF',
|
5054
|
+
'#95A3FF',
|
5055
|
+
'#A0AEFF',
|
5056
|
+
'#ACB9FF',
|
5057
|
+
'#B7C4FF',
|
5058
|
+
'#C2CEFF'
|
5059
|
+
]
|
5060
|
+
}
|
5058
5061
|
}
|
5059
5062
|
}
|
5060
5063
|
};
|
@@ -5121,38 +5124,48 @@ const zDimension = z.object({
|
|
5121
5124
|
'dimension',
|
5122
5125
|
'rowDimension',
|
5123
5126
|
'columnDimension'
|
5124
|
-
])
|
5127
|
+
]).default('dimension').optional()
|
5125
5128
|
});
|
5126
5129
|
const zDimensions = z.array(zDimension).optional();
|
5127
5130
|
const zNumFormat = z.object({
|
5128
5131
|
type: z["enum"]([
|
5129
5132
|
'number',
|
5130
5133
|
'percent',
|
5131
|
-
'permille'
|
5134
|
+
'permille',
|
5135
|
+
'scientific'
|
5132
5136
|
]).default('number').optional(),
|
5133
5137
|
ratio: z.number().default(1).optional(),
|
5134
5138
|
symbol: z.string().default('').optional(),
|
5135
5139
|
thousandSeparator: z.boolean().default(false).optional(),
|
5136
|
-
decimalPlaces: z.number().default(2).optional(),
|
5137
|
-
round: z["enum"]([
|
5138
|
-
'round',
|
5139
|
-
'floor',
|
5140
|
-
'ceil'
|
5141
|
-
]).default('round').optional(),
|
5142
5140
|
prefix: z.string().default('').optional(),
|
5143
|
-
suffix: z.string().default('').optional()
|
5141
|
+
suffix: z.string().default('').optional(),
|
5142
|
+
fractionDigits: z.number().default(2).optional(),
|
5143
|
+
significantDigits: z.number().default(0).optional(),
|
5144
|
+
roundingPriority: z["enum"]([
|
5145
|
+
'morePrecision',
|
5146
|
+
'lessPrecision'
|
5147
|
+
]).default('morePrecision').optional(),
|
5148
|
+
roundingMode: z["enum"]([
|
5149
|
+
'floor',
|
5150
|
+
'ceil',
|
5151
|
+
'halfEven',
|
5152
|
+
'expand',
|
5153
|
+
'trunc',
|
5154
|
+
'halfFloor',
|
5155
|
+
'halfCeil',
|
5156
|
+
'halfExpand',
|
5157
|
+
'halfTrunc'
|
5158
|
+
]).default('halfCeil').optional()
|
5144
5159
|
}).optional();
|
5145
5160
|
const zMeasure = z.object({
|
5146
5161
|
id: z.string(),
|
5147
5162
|
alias: z.string().optional(),
|
5148
|
-
visible: z.boolean().default(true).optional(),
|
5149
5163
|
autoFormat: z.boolean().default(true).optional(),
|
5150
5164
|
format: zNumFormat["default"]({}).optional()
|
5151
5165
|
});
|
5152
5166
|
const zMeasureGroup = z.object({
|
5153
5167
|
id: z.string(),
|
5154
5168
|
alias: z.string().optional(),
|
5155
|
-
visible: z.boolean().default(true).optional(),
|
5156
5169
|
get children () {
|
5157
5170
|
return z.array(zMeasureGroup.or(zMeasure)).optional();
|
5158
5171
|
}
|
@@ -5185,94 +5198,10 @@ const zEncoding = z.array(z.object({
|
|
5185
5198
|
tooltip: z.array(z.string()).optional(),
|
5186
5199
|
size: z.array(z.string()).optional()
|
5187
5200
|
}));
|
5188
|
-
const
|
5189
|
-
const zLabel = z.object({
|
5190
|
-
enable: z.boolean().default(true).optional()
|
5191
|
-
});
|
5192
|
-
const zColor = z.object({
|
5193
|
-
colorScheme: z.array(z.string()).optional(),
|
5194
|
-
colorMapping: z.record(z.string(), z.string()).optional()
|
5195
|
-
});
|
5196
|
-
const zTooltip = z.object({
|
5197
|
-
enable: z.boolean().default(true).optional()
|
5198
|
-
});
|
5199
|
-
const zLegend = z.object({
|
5200
|
-
enable: z.boolean().default(true).optional(),
|
5201
|
-
border: z.boolean().default(true).optional(),
|
5202
|
-
maxSize: z.number().default(1).optional(),
|
5203
|
-
shapeType: z["enum"]([
|
5204
|
-
'circle',
|
5205
|
-
'cross',
|
5206
|
-
'diamond',
|
5207
|
-
'square',
|
5208
|
-
'arrow',
|
5209
|
-
'arrow2Left',
|
5210
|
-
'arrow2Right',
|
5211
|
-
'wedge',
|
5212
|
-
'thinTriangle',
|
5213
|
-
'triangle',
|
5214
|
-
'triangleUp',
|
5215
|
-
'triangleDown',
|
5216
|
-
'triangleRight',
|
5217
|
-
'triangleLeft',
|
5218
|
-
'stroke',
|
5219
|
-
'star',
|
5220
|
-
'wye',
|
5221
|
-
'rect',
|
5222
|
-
'arrowLeft',
|
5223
|
-
'arrowRight',
|
5224
|
-
'rectRound',
|
5225
|
-
'roundLine'
|
5226
|
-
]).default('rectRound').optional(),
|
5227
|
-
position: z["enum"]([
|
5228
|
-
'left',
|
5229
|
-
'leftTop',
|
5230
|
-
'leftBottom',
|
5231
|
-
'lt',
|
5232
|
-
'lb',
|
5233
|
-
'top',
|
5234
|
-
'topLeft',
|
5235
|
-
'topRight',
|
5236
|
-
'tl',
|
5237
|
-
'tr',
|
5238
|
-
'right',
|
5239
|
-
'rightTop',
|
5240
|
-
'rightBottom',
|
5241
|
-
'rt',
|
5242
|
-
'rb',
|
5243
|
-
'bottom',
|
5244
|
-
'bottomLeft',
|
5245
|
-
'bottomRight',
|
5246
|
-
'bl',
|
5247
|
-
'br'
|
5248
|
-
]).default('bottom').optional(),
|
5249
|
-
labelFontSize: z.number().default(12).optional(),
|
5250
|
-
labelFontColor: z.string().default('#fff').optional(),
|
5251
|
-
labelFontWeight: z.number().or(z.string()).default(400).optional()
|
5252
|
-
});
|
5253
|
-
const zVChartBaseConfig = z.object({
|
5254
|
-
backgroundColor: zBackgroundColor,
|
5255
|
-
label: zLabel.optional(),
|
5256
|
-
color: zColor.optional(),
|
5257
|
-
tooltip: zTooltip.optional(),
|
5258
|
-
legend: zLegend.optional()
|
5259
|
-
});
|
5260
|
-
const zVTableBaseConfig = z.object({
|
5261
|
-
backgroundColor: zBackgroundColor
|
5262
|
-
});
|
5263
|
-
const zBaseConfig = z.object({
|
5264
|
-
vchart: zVChartBaseConfig.optional(),
|
5265
|
-
vtable: zVTableBaseConfig.optional()
|
5266
|
-
});
|
5267
|
-
const zAxis = z.object({
|
5201
|
+
const zXBandAxis = z.object({
|
5268
5202
|
visible: z.boolean().default(true).optional(),
|
5269
|
-
min: z.number().optional(),
|
5270
|
-
max: z.number().optional(),
|
5271
|
-
nice: z.boolean().default(true).optional(),
|
5272
|
-
zero: z.boolean().default(true).optional(),
|
5273
|
-
inverse: z.boolean().default(false).optional(),
|
5274
5203
|
labelAutoHide: z.boolean().default(true).optional(),
|
5275
|
-
labelAutoHideGap: z.number().default(
|
5204
|
+
labelAutoHideGap: z.number().default(0).optional(),
|
5276
5205
|
labelAutoRotate: z.boolean().default(true).optional(),
|
5277
5206
|
labelAutoRotateAngleRange: z.array(z.number()).default([
|
5278
5207
|
0,
|
@@ -5312,57 +5241,16 @@ const zAxis = z.object({
|
|
5312
5241
|
gridWidth: z.number().default(0.5).optional()
|
5313
5242
|
}).optional()
|
5314
5243
|
});
|
5315
|
-
const
|
5244
|
+
const zYBandAxis = zXBandAxis;
|
5245
|
+
const zXLinearAxis = z.object({
|
5316
5246
|
visible: z.boolean().default(true).optional(),
|
5317
|
-
|
5318
|
-
|
5319
|
-
|
5320
|
-
|
5321
|
-
|
5322
|
-
|
5323
|
-
|
5324
|
-
]).optional(),
|
5325
|
-
labelAutoLimit: z.boolean().default(true).optional(),
|
5326
|
-
labelAutoLimitLength: z.number().default(100).optional(),
|
5327
|
-
label: z.object({
|
5328
|
-
visible: z.boolean().default(true).optional(),
|
5329
|
-
labelColor: z.string().default('#797B85').optional(),
|
5330
|
-
labelFontSize: z.number().default(12).optional(),
|
5331
|
-
labelFontWeight: z.number().default(400).optional(),
|
5332
|
-
labelAngle: z.number().default(0).optional()
|
5333
|
-
}).optional(),
|
5334
|
-
line: z.object({
|
5335
|
-
visible: z.boolean().default(true).optional(),
|
5336
|
-
lineColor: z.string().default('rgba(54, 65, 89, 0.30)').optional(),
|
5337
|
-
lineWidth: z.number().default(1).optional()
|
5338
|
-
}).optional(),
|
5339
|
-
tick: z.object({
|
5340
|
-
visible: z.boolean().default(true).optional(),
|
5341
|
-
tickInside: z.boolean().default(false).optional(),
|
5342
|
-
tickColor: z.string().default('rgba(54, 65, 89, 0.30)').optional(),
|
5343
|
-
tickSize: z.number().default(4).optional()
|
5344
|
-
}).optional(),
|
5345
|
-
title: z.object({
|
5346
|
-
visible: z.boolean().default(false).optional(),
|
5347
|
-
titleText: z.string().default('').optional(),
|
5348
|
-
titleColor: z.string().default('#646A73').optional(),
|
5349
|
-
titleFontSize: z.number().default(12).optional(),
|
5350
|
-
titleFontWeight: z.number().default(400).optional()
|
5351
|
-
}).optional(),
|
5352
|
-
grid: z.object({
|
5353
|
-
visible: z.boolean().default(false).optional(),
|
5354
|
-
gridColor: z.string().default('rgba(54, 65, 89, 0.15)').optional(),
|
5355
|
-
gridWidth: z.number().default(0.5).optional()
|
5356
|
-
}).optional()
|
5357
|
-
});
|
5358
|
-
const zYBandAxis = zXBandAxis;
|
5359
|
-
const zXLinearAxis = z.object({
|
5360
|
-
visible: z.boolean().default(true).optional(),
|
5361
|
-
min: z.number().optional(),
|
5362
|
-
max: z.number().optional(),
|
5363
|
-
nice: z.boolean().default(true).optional(),
|
5364
|
-
zero: z.boolean().default(true).optional(),
|
5365
|
-
inverse: z.boolean().default(false).optional(),
|
5247
|
+
min: z.number().optional(),
|
5248
|
+
max: z.number().optional(),
|
5249
|
+
nice: z.boolean().default(true).optional(),
|
5250
|
+
zero: z.boolean().default(true).optional(),
|
5251
|
+
log: z.boolean().default(false).optional(),
|
5252
|
+
logBase: z.number().default(10).optional(),
|
5253
|
+
inverse: z.boolean().default(false).optional(),
|
5366
5254
|
label: z.object({
|
5367
5255
|
visible: z.boolean().default(true).optional(),
|
5368
5256
|
labelColor: z.string().default('#797B85').optional(),
|
@@ -5415,72 +5303,233 @@ const zStackCornerRadius = z.number().or(z.array(z.number())).default([
|
|
5415
5303
|
0,
|
5416
5304
|
0
|
5417
5305
|
]);
|
5306
|
+
const zBackgroundColor = z.string().default('transparent').optional();
|
5307
|
+
const zColor = z.object({
|
5308
|
+
colorScheme: z.array(z.string()).optional(),
|
5309
|
+
colorMapping: z.record(z.string(), z.string()).optional()
|
5310
|
+
});
|
5311
|
+
const zLabel = z.object({
|
5312
|
+
enable: z.boolean().default(true).optional()
|
5313
|
+
});
|
5314
|
+
const zLegend = z.object({
|
5315
|
+
enable: z.boolean().default(true).optional(),
|
5316
|
+
border: z.boolean().default(true).optional(),
|
5317
|
+
maxSize: z.number().default(1).optional(),
|
5318
|
+
shapeType: z["enum"]([
|
5319
|
+
'circle',
|
5320
|
+
'cross',
|
5321
|
+
'diamond',
|
5322
|
+
'square',
|
5323
|
+
'arrow',
|
5324
|
+
'arrow2Left',
|
5325
|
+
'arrow2Right',
|
5326
|
+
'wedge',
|
5327
|
+
'thinTriangle',
|
5328
|
+
'triangle',
|
5329
|
+
'triangleUp',
|
5330
|
+
'triangleDown',
|
5331
|
+
'triangleRight',
|
5332
|
+
'triangleLeft',
|
5333
|
+
'stroke',
|
5334
|
+
'star',
|
5335
|
+
'wye',
|
5336
|
+
'rect',
|
5337
|
+
'arrowLeft',
|
5338
|
+
'arrowRight',
|
5339
|
+
'rectRound',
|
5340
|
+
'roundLine'
|
5341
|
+
]).default('rectRound').optional(),
|
5342
|
+
position: z["enum"]([
|
5343
|
+
'left',
|
5344
|
+
'leftTop',
|
5345
|
+
'leftBottom',
|
5346
|
+
'lt',
|
5347
|
+
'lb',
|
5348
|
+
'top',
|
5349
|
+
'topLeft',
|
5350
|
+
'topRight',
|
5351
|
+
'tl',
|
5352
|
+
'tr',
|
5353
|
+
'right',
|
5354
|
+
'rightTop',
|
5355
|
+
'rightBottom',
|
5356
|
+
'rt',
|
5357
|
+
'rb',
|
5358
|
+
'bottom',
|
5359
|
+
'bottomLeft',
|
5360
|
+
'bottomRight',
|
5361
|
+
'bl',
|
5362
|
+
'br'
|
5363
|
+
]).default('bottom').optional(),
|
5364
|
+
labelFontSize: z.number().default(12).optional(),
|
5365
|
+
labelFontColor: z.string().default('#fff').optional(),
|
5366
|
+
labelFontWeight: z.number().or(z.string()).default(400).optional()
|
5367
|
+
});
|
5368
|
+
const zTooltip = z.object({
|
5369
|
+
enable: z.boolean().default(true).optional()
|
5370
|
+
});
|
5371
|
+
const zLineConfig = z.object({
|
5372
|
+
backgroundColor: zBackgroundColor.optional(),
|
5373
|
+
label: zLabel.optional(),
|
5374
|
+
color: zColor.optional(),
|
5375
|
+
tooltip: zTooltip.optional(),
|
5376
|
+
legend: zLegend.optional(),
|
5377
|
+
xAxis: zXBandAxis.optional(),
|
5378
|
+
yAxis: zYLinearAxis.optional(),
|
5379
|
+
crosshairLine: zCrosshairLine.optional()
|
5380
|
+
});
|
5381
|
+
const zColumnConfig = z.object({
|
5382
|
+
backgroundColor: zBackgroundColor.optional(),
|
5383
|
+
label: zLabel.optional(),
|
5384
|
+
color: zColor.optional(),
|
5385
|
+
tooltip: zTooltip.optional(),
|
5386
|
+
legend: zLegend.optional(),
|
5387
|
+
xAxis: zXBandAxis.optional(),
|
5388
|
+
yAxis: zYLinearAxis.optional(),
|
5389
|
+
crosshairRect: zCrosshairRect.optional(),
|
5390
|
+
stackCornerRadius: zStackCornerRadius.optional()
|
5391
|
+
});
|
5392
|
+
const zColumnParallelConfig = zColumnConfig;
|
5393
|
+
const zColumnPercentConfig = zColumnConfig;
|
5394
|
+
const zBarConfig = z.object({
|
5395
|
+
backgroundColor: zBackgroundColor.optional(),
|
5396
|
+
label: zLabel.optional(),
|
5397
|
+
color: zColor.optional(),
|
5398
|
+
tooltip: zTooltip.optional(),
|
5399
|
+
legend: zLegend.optional(),
|
5400
|
+
xAxis: zXLinearAxis.optional(),
|
5401
|
+
yAxis: zYBandAxis.optional(),
|
5402
|
+
crosshairRect: zCrosshairRect.optional(),
|
5403
|
+
stackCornerRadius: zStackCornerRadius.optional()
|
5404
|
+
});
|
5405
|
+
const zBarParallelConfig = zBarConfig;
|
5406
|
+
const zBarPercentConfig = zBarConfig;
|
5407
|
+
const zAreaConfig = z.object({
|
5408
|
+
backgroundColor: zBackgroundColor.optional(),
|
5409
|
+
label: zLabel.optional(),
|
5410
|
+
color: zColor.optional(),
|
5411
|
+
tooltip: zTooltip.optional(),
|
5412
|
+
legend: zLegend.optional(),
|
5413
|
+
xAxis: zXBandAxis.optional(),
|
5414
|
+
yAxis: zYLinearAxis.optional(),
|
5415
|
+
crosshairLine: zCrosshairLine.optional()
|
5416
|
+
});
|
5417
|
+
const zAreaPercentConfig = zAreaConfig;
|
5418
|
+
const zRoseConfig = z.object({
|
5419
|
+
backgroundColor: zBackgroundColor.optional(),
|
5420
|
+
label: zLabel.optional(),
|
5421
|
+
color: zColor.optional(),
|
5422
|
+
tooltip: zTooltip.optional(),
|
5423
|
+
legend: zLegend.optional()
|
5424
|
+
});
|
5425
|
+
const zRoseParallelConfig = zRoseConfig;
|
5426
|
+
const zPieConfig = z.object({
|
5427
|
+
backgroundColor: zBackgroundColor.optional(),
|
5428
|
+
label: zLabel.optional(),
|
5429
|
+
color: zColor.optional(),
|
5430
|
+
tooltip: zTooltip.optional(),
|
5431
|
+
legend: zLegend.optional()
|
5432
|
+
});
|
5433
|
+
const zDonutConfig = zPieConfig;
|
5434
|
+
const zDualAxisConfig = z.object({
|
5435
|
+
backgroundColor: zBackgroundColor.optional(),
|
5436
|
+
label: zLabel.optional(),
|
5437
|
+
color: zColor.optional(),
|
5438
|
+
tooltip: zTooltip.optional(),
|
5439
|
+
legend: zLegend.optional()
|
5440
|
+
});
|
5441
|
+
const zScatterConfig = z.object({
|
5442
|
+
backgroundColor: zBackgroundColor.optional(),
|
5443
|
+
label: zLabel.optional(),
|
5444
|
+
color: zColor.optional(),
|
5445
|
+
tooltip: zTooltip.optional(),
|
5446
|
+
legend: zLegend.optional(),
|
5447
|
+
xAxis: zXLinearAxis.optional(),
|
5448
|
+
yAxis: zYLinearAxis.optional(),
|
5449
|
+
crosshairLine: zCrosshairLine.optional()
|
5450
|
+
});
|
5451
|
+
const zFunnelConfig = z.object({
|
5452
|
+
backgroundColor: zBackgroundColor.optional(),
|
5453
|
+
color: zColor.optional(),
|
5454
|
+
tooltip: zTooltip.optional(),
|
5455
|
+
label: zLabel.optional(),
|
5456
|
+
legend: zLegend.optional()
|
5457
|
+
});
|
5418
5458
|
const zConfig = z.object({
|
5419
5459
|
table: z.object({}).optional(),
|
5420
5460
|
pivotTable: z.object({}).optional(),
|
5421
|
-
line:
|
5422
|
-
|
5423
|
-
|
5424
|
-
|
5425
|
-
|
5426
|
-
|
5427
|
-
|
5428
|
-
|
5429
|
-
|
5430
|
-
|
5431
|
-
|
5432
|
-
|
5433
|
-
|
5434
|
-
|
5435
|
-
|
5436
|
-
|
5437
|
-
|
5438
|
-
|
5439
|
-
|
5440
|
-
|
5441
|
-
|
5442
|
-
|
5443
|
-
|
5444
|
-
|
5445
|
-
|
5446
|
-
|
5447
|
-
|
5448
|
-
|
5449
|
-
|
5450
|
-
|
5451
|
-
|
5452
|
-
|
5453
|
-
|
5454
|
-
|
5455
|
-
|
5456
|
-
|
5457
|
-
|
5458
|
-
|
5459
|
-
|
5460
|
-
|
5461
|
+
line: zLineConfig.optional(),
|
5462
|
+
column: zColumnConfig.optional(),
|
5463
|
+
columnParallel: zColumnParallelConfig.optional(),
|
5464
|
+
columnPercent: zColumnPercentConfig.optional(),
|
5465
|
+
bar: zBarConfig.optional(),
|
5466
|
+
barParallel: zBarParallelConfig.optional(),
|
5467
|
+
barPercent: zBarPercentConfig.optional(),
|
5468
|
+
area: zAreaConfig.optional(),
|
5469
|
+
areaPercent: zAreaPercentConfig.optional(),
|
5470
|
+
rose: zRoseConfig.optional(),
|
5471
|
+
roseParallel: zRoseParallelConfig.optional(),
|
5472
|
+
pie: zPieConfig.optional(),
|
5473
|
+
donut: zDonutConfig.optional(),
|
5474
|
+
dualAxis: zDualAxisConfig.optional(),
|
5475
|
+
scatter: zScatterConfig.optional(),
|
5476
|
+
funnel: zFunnelConfig.optional()
|
5477
|
+
});
|
5478
|
+
const zAxis = z.object({
|
5479
|
+
visible: z.boolean().default(true).optional(),
|
5480
|
+
min: z.number().optional(),
|
5481
|
+
max: z.number().optional(),
|
5482
|
+
nice: z.boolean().default(true).optional(),
|
5483
|
+
zero: z.boolean().default(true).optional(),
|
5484
|
+
inverse: z.boolean().default(false).optional(),
|
5485
|
+
log: z.boolean().default(false).optional(),
|
5486
|
+
logBase: z.number().default(10).optional(),
|
5487
|
+
labelAutoHide: z.boolean().default(true).optional(),
|
5488
|
+
labelAutoHideGap: z.number().default(4).optional(),
|
5489
|
+
labelAutoRotate: z.boolean().default(true).optional(),
|
5490
|
+
labelAutoRotateAngleRange: z.array(z.number()).default([
|
5491
|
+
0,
|
5492
|
+
-45,
|
5493
|
+
-90
|
5494
|
+
]).optional(),
|
5495
|
+
labelAutoLimit: z.boolean().default(true).optional(),
|
5496
|
+
labelAutoLimitLength: z.number().default(100).optional(),
|
5497
|
+
label: z.object({
|
5498
|
+
visible: z.boolean().default(true).optional(),
|
5499
|
+
labelColor: z.string().default('#797B85').optional(),
|
5500
|
+
labelFontSize: z.number().default(12).optional(),
|
5501
|
+
labelFontWeight: z.number().default(400).optional(),
|
5502
|
+
labelAngle: z.number().default(0).optional()
|
5461
5503
|
}).optional(),
|
5462
|
-
|
5463
|
-
|
5464
|
-
|
5465
|
-
|
5504
|
+
line: z.object({
|
5505
|
+
visible: z.boolean().default(true).optional(),
|
5506
|
+
lineColor: z.string().default('rgba(54, 65, 89, 0.30)').optional(),
|
5507
|
+
lineWidth: z.number().default(1).optional()
|
5466
5508
|
}).optional(),
|
5467
|
-
|
5468
|
-
|
5469
|
-
|
5470
|
-
|
5509
|
+
tick: z.object({
|
5510
|
+
visible: z.boolean().default(true).optional(),
|
5511
|
+
tickInside: z.boolean().default(false).optional(),
|
5512
|
+
tickColor: z.string().default('rgba(54, 65, 89, 0.30)').optional(),
|
5513
|
+
tickSize: z.number().default(4).optional()
|
5471
5514
|
}).optional(),
|
5472
|
-
|
5473
|
-
|
5474
|
-
|
5475
|
-
|
5476
|
-
|
5477
|
-
|
5478
|
-
xAxis: zXLinearAxis.optional(),
|
5479
|
-
yAxis: zYLinearAxis.optional(),
|
5480
|
-
crosshairLine: zCrosshairLine.optional()
|
5515
|
+
title: z.object({
|
5516
|
+
visible: z.boolean().default(false).optional(),
|
5517
|
+
titleText: z.string().default('').optional(),
|
5518
|
+
titleColor: z.string().default('#646A73').optional(),
|
5519
|
+
titleFontSize: z.number().default(12).optional(),
|
5520
|
+
titleFontWeight: z.number().default(400).optional()
|
5481
5521
|
}).optional(),
|
5482
|
-
|
5522
|
+
grid: z.object({
|
5523
|
+
visible: z.boolean().default(false).optional(),
|
5524
|
+
gridColor: z.string().default('rgba(54, 65, 89, 0.15)').optional(),
|
5525
|
+
gridWidth: z.number().default(0.5).optional()
|
5526
|
+
}).optional()
|
5483
5527
|
});
|
5528
|
+
const zCustomThemeConfig = z.object({
|
5529
|
+
config: zConfig.optional()
|
5530
|
+
});
|
5531
|
+
const zCustomTheme = z.record(z.string(), zCustomThemeConfig).optional();
|
5532
|
+
const zTheme = z.string();
|
5484
5533
|
const zSelector = z.union([
|
5485
5534
|
z.string(),
|
5486
5535
|
z.number(),
|
@@ -5536,6 +5585,74 @@ const zSelector = z.union([
|
|
5536
5585
|
})
|
5537
5586
|
]);
|
5538
5587
|
const zSelectors = z.array(zSelector);
|
5588
|
+
const zBarStyle = z.object({
|
5589
|
+
selector: z.union([
|
5590
|
+
zSelector,
|
5591
|
+
zSelectors
|
5592
|
+
]).optional(),
|
5593
|
+
barColor: z.string().optional(),
|
5594
|
+
barColorOpacity: z.number().optional(),
|
5595
|
+
barBorderColor: z.string().optional(),
|
5596
|
+
barBorderWidth: z.number().optional(),
|
5597
|
+
barBorderStyle: z.union([
|
5598
|
+
z.literal('solid'),
|
5599
|
+
z.literal('dashed'),
|
5600
|
+
z.literal('dotted')
|
5601
|
+
]).optional(),
|
5602
|
+
barRadius: z.union([
|
5603
|
+
z.number(),
|
5604
|
+
z.array(z.number())
|
5605
|
+
]).optional()
|
5606
|
+
});
|
5607
|
+
const zPointStyle = z.object({
|
5608
|
+
selector: z.union([
|
5609
|
+
zSelector,
|
5610
|
+
zSelectors
|
5611
|
+
]).optional(),
|
5612
|
+
pointSize: z.number().optional(),
|
5613
|
+
pointColor: z.string().optional(),
|
5614
|
+
pointColorOpacity: z.number().optional(),
|
5615
|
+
pointBorderColor: z.string().optional(),
|
5616
|
+
pointBorderWidth: z.number().optional(),
|
5617
|
+
pointBorderStyle: z.union([
|
5618
|
+
z["enum"]([
|
5619
|
+
'solid',
|
5620
|
+
'dashed',
|
5621
|
+
'dotted'
|
5622
|
+
])
|
5623
|
+
]).optional()
|
5624
|
+
});
|
5625
|
+
const zLineStyle = z.object({
|
5626
|
+
selector: z.union([
|
5627
|
+
zSelector,
|
5628
|
+
zSelectors
|
5629
|
+
]).optional(),
|
5630
|
+
lineSmooth: z.boolean().default(true).optional(),
|
5631
|
+
lineColor: z.string().optional(),
|
5632
|
+
lineColorOpacity: z.number().optional(),
|
5633
|
+
lineWidth: z.number().optional(),
|
5634
|
+
lineStyle: z.union([
|
5635
|
+
z["enum"]([
|
5636
|
+
'solid',
|
5637
|
+
'dashed',
|
5638
|
+
'dotted'
|
5639
|
+
])
|
5640
|
+
]).optional()
|
5641
|
+
});
|
5642
|
+
const zAreaStyle = z.object({
|
5643
|
+
selector: z.union([
|
5644
|
+
zSelector,
|
5645
|
+
zSelectors
|
5646
|
+
]).optional(),
|
5647
|
+
areaColor: z.string().optional(),
|
5648
|
+
areaColorOpacity: z.number().optional()
|
5649
|
+
});
|
5650
|
+
const zMarkStyle = z.object({
|
5651
|
+
barStyle: zBarStyle.or(z.array(zBarStyle)).optional(),
|
5652
|
+
pointStyle: zPointStyle.or(z.array(zPointStyle)).optional(),
|
5653
|
+
lineStyle: zLineStyle.or(z.array(zLineStyle)).optional(),
|
5654
|
+
areaStyle: zAreaStyle.or(z.array(zAreaStyle)).optional()
|
5655
|
+
});
|
5539
5656
|
const zAnnotationPoint = z.object({
|
5540
5657
|
selector: z.union([
|
5541
5658
|
zSelector,
|
@@ -5612,9 +5729,7 @@ const zAnnotationVerticalLine = z.object({
|
|
5612
5729
|
backgroundBorderColor: z.string().optional(),
|
5613
5730
|
backgroundBorderWidth: z.number().default(1).optional(),
|
5614
5731
|
backgroundBorderRadius: z.number().default(4).optional(),
|
5615
|
-
backgroundPadding: z.number().optional()
|
5616
|
-
offsetY: z.number().default(0).optional(),
|
5617
|
-
offsetX: z.number().default(0).optional()
|
5732
|
+
backgroundPadding: z.number().optional()
|
5618
5733
|
});
|
5619
5734
|
const zAnnotationHorizontalLine = z.object({
|
5620
5735
|
selector: z.union([
|
@@ -5664,9 +5779,7 @@ const zAnnotationHorizontalLine = z.object({
|
|
5664
5779
|
backgroundBorderColor: z.string().optional(),
|
5665
5780
|
backgroundBorderWidth: z.number().default(1).optional(),
|
5666
5781
|
backgroundBorderRadius: z.number().default(4).optional(),
|
5667
|
-
backgroundPadding: z.number().optional()
|
5668
|
-
offsetY: z.number().default(0).optional(),
|
5669
|
-
offsetX: z.number().default(0).optional()
|
5782
|
+
backgroundPadding: z.number().optional()
|
5670
5783
|
});
|
5671
5784
|
const zAnnotationArea = z.object({
|
5672
5785
|
selector: z.union([
|
@@ -5716,110 +5829,12 @@ const zAnnotation = z.object({
|
|
5716
5829
|
annotationHorizontalLine: zAnnotationHorizontalLine.or(z.array(zAnnotationHorizontalLine)).optional(),
|
5717
5830
|
annotationArea: zAnnotationArea.or(z.array(zAnnotationArea)).optional()
|
5718
5831
|
});
|
5719
|
-
const zBarStyle = z.object({
|
5720
|
-
selector: z.union([
|
5721
|
-
zSelector,
|
5722
|
-
zSelectors
|
5723
|
-
]).optional(),
|
5724
|
-
barColor: z.string().optional(),
|
5725
|
-
barColorOpacity: z.number().optional(),
|
5726
|
-
barBorderColor: z.string().optional(),
|
5727
|
-
barBorderWidth: z.number().optional(),
|
5728
|
-
barBorderStyle: z.union([
|
5729
|
-
z.literal('solid'),
|
5730
|
-
z.literal('dashed'),
|
5731
|
-
z.literal('dotted')
|
5732
|
-
]).optional(),
|
5733
|
-
barRadius: z.union([
|
5734
|
-
z.number(),
|
5735
|
-
z.array(z.number())
|
5736
|
-
]).optional()
|
5737
|
-
});
|
5738
|
-
const zPointStyle = z.object({
|
5739
|
-
selector: z.union([
|
5740
|
-
zSelector,
|
5741
|
-
zSelectors
|
5742
|
-
]).optional(),
|
5743
|
-
pointSize: z.number().optional(),
|
5744
|
-
pointColor: z.string().optional(),
|
5745
|
-
pointColorOpacity: z.number().optional(),
|
5746
|
-
pointBorderColor: z.string().optional(),
|
5747
|
-
pointBorderWidth: z.number().optional(),
|
5748
|
-
pointBorderStyle: z.union([
|
5749
|
-
z["enum"]([
|
5750
|
-
'solid',
|
5751
|
-
'dashed',
|
5752
|
-
'dotted'
|
5753
|
-
])
|
5754
|
-
]).optional()
|
5755
|
-
});
|
5756
|
-
const zLineStyle = z.object({
|
5757
|
-
selector: z.union([
|
5758
|
-
zSelector,
|
5759
|
-
zSelectors
|
5760
|
-
]).optional(),
|
5761
|
-
lineSmooth: z.boolean().default(true).optional(),
|
5762
|
-
lineColor: z.string().optional(),
|
5763
|
-
lineColorOpacity: z.number().optional(),
|
5764
|
-
lineWidth: z.number().optional(),
|
5765
|
-
lineStyle: z.union([
|
5766
|
-
z["enum"]([
|
5767
|
-
'solid',
|
5768
|
-
'dashed',
|
5769
|
-
'dotted'
|
5770
|
-
])
|
5771
|
-
]).optional()
|
5772
|
-
});
|
5773
|
-
const zAreaStyle = z.object({
|
5774
|
-
selector: z.union([
|
5775
|
-
zSelector,
|
5776
|
-
zSelectors
|
5777
|
-
]).optional(),
|
5778
|
-
areaColor: z.string().optional(),
|
5779
|
-
areaColorOpacity: z.number().optional()
|
5780
|
-
});
|
5781
|
-
const zMarkStyle = z.object({
|
5782
|
-
barStyle: zBarStyle.or(z.array(zBarStyle)).optional(),
|
5783
|
-
pointStyle: zPointStyle.or(z.array(zPointStyle)).optional(),
|
5784
|
-
lineStyle: zLineStyle.or(z.array(zLineStyle)).optional(),
|
5785
|
-
areaStyle: zAreaStyle.or(z.array(zAreaStyle)).optional()
|
5786
|
-
});
|
5787
|
-
const zCustomThemeConfig = z.object({
|
5788
|
-
baseConfig: zBaseConfig.optional(),
|
5789
|
-
config: zConfig.optional(),
|
5790
|
-
annotation: zAnnotation.optional(),
|
5791
|
-
markStyle: zMarkStyle.optional()
|
5792
|
-
});
|
5793
|
-
const zCustomTheme = z.record(z.string(), zCustomThemeConfig).optional();
|
5794
|
-
const zTheme = z.string();
|
5795
5832
|
const zLocale = z["enum"]([
|
5796
5833
|
'zh-CN',
|
5797
5834
|
'en-US'
|
5798
5835
|
]).default('zh-CN');
|
5799
|
-
const
|
5800
|
-
chartType: z.literal('
|
5801
|
-
dataset: zDataset.optional(),
|
5802
|
-
dimensions: zDimensions.optional(),
|
5803
|
-
measures: zMeasures.optional(),
|
5804
|
-
backgroundColor: zBackgroundColor.optional(),
|
5805
|
-
color: zColor.optional(),
|
5806
|
-
label: zLabel.optional(),
|
5807
|
-
legend: zLegend.optional(),
|
5808
|
-
tooltip: zTooltip.optional(),
|
5809
|
-
xAxis: zXLinearAxis.optional(),
|
5810
|
-
yAxis: zYBandAxis.optional(),
|
5811
|
-
crosshairRect: zCrosshairRect.optional(),
|
5812
|
-
stackCornerRadius: zStackCornerRadius.optional(),
|
5813
|
-
theme: zTheme.optional(),
|
5814
|
-
barStyle: zBarStyle.optional(),
|
5815
|
-
annotationPoint: zAnnotationPoint.optional(),
|
5816
|
-
annotationVerticalLine: zAnnotationVerticalLine.optional(),
|
5817
|
-
annotationHorizontalLine: zAnnotationHorizontalLine.optional(),
|
5818
|
-
annotationArea: zAnnotationArea.optional(),
|
5819
|
-
locale: zLocale.optional()
|
5820
|
-
});
|
5821
|
-
const zBarParallel = z.object({
|
5822
|
-
chartType: z.literal('barParallel'),
|
5836
|
+
const zLine = z.object({
|
5837
|
+
chartType: z.literal('line'),
|
5823
5838
|
dataset: zDataset.optional(),
|
5824
5839
|
dimensions: zDimensions.optional(),
|
5825
5840
|
measures: zMeasures.optional(),
|
@@ -5828,16 +5843,16 @@ const zBarParallel = z.object({
|
|
5828
5843
|
label: zLabel.optional(),
|
5829
5844
|
legend: zLegend.optional(),
|
5830
5845
|
tooltip: zTooltip.optional(),
|
5831
|
-
xAxis:
|
5832
|
-
yAxis:
|
5833
|
-
|
5834
|
-
stackCornerRadius: zStackCornerRadius.optional(),
|
5846
|
+
xAxis: zXBandAxis.optional(),
|
5847
|
+
yAxis: zYLinearAxis.optional(),
|
5848
|
+
crosshairLine: zCrosshairLine.optional(),
|
5835
5849
|
theme: zTheme.optional(),
|
5836
|
-
|
5837
|
-
|
5838
|
-
|
5839
|
-
|
5840
|
-
|
5850
|
+
pointStyle: zPointStyle.optional(),
|
5851
|
+
lineStyle: zLineStyle.optional(),
|
5852
|
+
annotationPoint: z.array(zAnnotationPoint).or(zAnnotationPoint).optional(),
|
5853
|
+
annotationVerticalLine: z.array(zAnnotationVerticalLine).or(zAnnotationVerticalLine).optional(),
|
5854
|
+
annotationHorizontalLine: z.array(zAnnotationHorizontalLine).or(zAnnotationHorizontalLine).optional(),
|
5855
|
+
annotationArea: z.array(zAnnotationArea).or(zAnnotationArea).optional(),
|
5841
5856
|
locale: zLocale.optional()
|
5842
5857
|
});
|
5843
5858
|
const zColumn = z.object({
|
@@ -5856,10 +5871,10 @@ const zColumn = z.object({
|
|
5856
5871
|
stackCornerRadius: zStackCornerRadius.optional(),
|
5857
5872
|
theme: zTheme.optional(),
|
5858
5873
|
barStyle: zBarStyle.optional(),
|
5859
|
-
annotationPoint: zAnnotationPoint.optional(),
|
5860
|
-
annotationVerticalLine: zAnnotationVerticalLine.optional(),
|
5861
|
-
annotationHorizontalLine: zAnnotationHorizontalLine.optional(),
|
5862
|
-
annotationArea: zAnnotationArea.optional(),
|
5874
|
+
annotationPoint: z.array(zAnnotationPoint).or(zAnnotationPoint).optional(),
|
5875
|
+
annotationVerticalLine: z.array(zAnnotationVerticalLine).or(zAnnotationVerticalLine).optional(),
|
5876
|
+
annotationHorizontalLine: z.array(zAnnotationHorizontalLine).or(zAnnotationHorizontalLine).optional(),
|
5877
|
+
annotationArea: z.array(zAnnotationArea).or(zAnnotationArea).optional(),
|
5863
5878
|
locale: zLocale.optional()
|
5864
5879
|
});
|
5865
5880
|
const zColumnParallel = z.object({
|
@@ -5878,10 +5893,10 @@ const zColumnParallel = z.object({
|
|
5878
5893
|
stackCornerRadius: zStackCornerRadius.optional(),
|
5879
5894
|
theme: zTheme.optional(),
|
5880
5895
|
barStyle: zBarStyle.optional(),
|
5881
|
-
annotationPoint: zAnnotationPoint.optional(),
|
5882
|
-
annotationVerticalLine: zAnnotationVerticalLine.optional(),
|
5883
|
-
annotationHorizontalLine: zAnnotationHorizontalLine.optional(),
|
5884
|
-
annotationArea: zAnnotationArea.optional(),
|
5896
|
+
annotationPoint: z.array(zAnnotationPoint).or(zAnnotationPoint).optional(),
|
5897
|
+
annotationVerticalLine: z.array(zAnnotationVerticalLine).or(zAnnotationVerticalLine).optional(),
|
5898
|
+
annotationHorizontalLine: z.array(zAnnotationHorizontalLine).or(zAnnotationHorizontalLine).optional(),
|
5899
|
+
annotationArea: z.array(zAnnotationArea).or(zAnnotationArea).optional(),
|
5885
5900
|
locale: zLocale.optional()
|
5886
5901
|
});
|
5887
5902
|
const zColumnPercent = z.object({
|
@@ -5900,14 +5915,14 @@ const zColumnPercent = z.object({
|
|
5900
5915
|
stackCornerRadius: zStackCornerRadius.optional(),
|
5901
5916
|
theme: zTheme.optional(),
|
5902
5917
|
barStyle: zBarStyle.optional(),
|
5903
|
-
annotationPoint: zAnnotationPoint.optional(),
|
5904
|
-
annotationVerticalLine: zAnnotationVerticalLine.optional(),
|
5905
|
-
annotationHorizontalLine: zAnnotationHorizontalLine.optional(),
|
5906
|
-
annotationArea: zAnnotationArea.optional(),
|
5918
|
+
annotationPoint: z.array(zAnnotationPoint).or(zAnnotationPoint).optional(),
|
5919
|
+
annotationVerticalLine: z.array(zAnnotationVerticalLine).or(zAnnotationVerticalLine).optional(),
|
5920
|
+
annotationHorizontalLine: z.array(zAnnotationHorizontalLine).or(zAnnotationHorizontalLine).optional(),
|
5921
|
+
annotationArea: z.array(zAnnotationArea).or(zAnnotationArea).optional(),
|
5907
5922
|
locale: zLocale.optional()
|
5908
5923
|
});
|
5909
|
-
const
|
5910
|
-
chartType: z.literal('
|
5924
|
+
const zBar = z.object({
|
5925
|
+
chartType: z.literal('bar'),
|
5911
5926
|
dataset: zDataset.optional(),
|
5912
5927
|
dimensions: zDimensions.optional(),
|
5913
5928
|
measures: zMeasures.optional(),
|
@@ -5916,20 +5931,20 @@ const zLine = z.object({
|
|
5916
5931
|
label: zLabel.optional(),
|
5917
5932
|
legend: zLegend.optional(),
|
5918
5933
|
tooltip: zTooltip.optional(),
|
5919
|
-
xAxis:
|
5920
|
-
yAxis:
|
5921
|
-
|
5934
|
+
xAxis: zXLinearAxis.optional(),
|
5935
|
+
yAxis: zYBandAxis.optional(),
|
5936
|
+
crosshairRect: zCrosshairRect.optional(),
|
5937
|
+
stackCornerRadius: zStackCornerRadius.optional(),
|
5922
5938
|
theme: zTheme.optional(),
|
5923
|
-
|
5924
|
-
|
5925
|
-
|
5926
|
-
|
5927
|
-
|
5928
|
-
annotationArea: zAnnotationArea.optional(),
|
5939
|
+
barStyle: zBarStyle.optional(),
|
5940
|
+
annotationPoint: z.array(zAnnotationPoint).or(zAnnotationPoint).optional(),
|
5941
|
+
annotationVerticalLine: z.array(zAnnotationVerticalLine).or(zAnnotationVerticalLine).optional(),
|
5942
|
+
annotationHorizontalLine: z.array(zAnnotationHorizontalLine).or(zAnnotationHorizontalLine).optional(),
|
5943
|
+
annotationArea: z.array(zAnnotationArea).or(zAnnotationArea).optional(),
|
5929
5944
|
locale: zLocale.optional()
|
5930
5945
|
});
|
5931
|
-
const
|
5932
|
-
chartType: z.literal('
|
5946
|
+
const zBarParallel = z.object({
|
5947
|
+
chartType: z.literal('barParallel'),
|
5933
5948
|
dataset: zDataset.optional(),
|
5934
5949
|
dimensions: zDimensions.optional(),
|
5935
5950
|
measures: zMeasures.optional(),
|
@@ -5938,7 +5953,16 @@ const zRose = z.object({
|
|
5938
5953
|
label: zLabel.optional(),
|
5939
5954
|
legend: zLegend.optional(),
|
5940
5955
|
tooltip: zTooltip.optional(),
|
5956
|
+
xAxis: zXLinearAxis.optional(),
|
5957
|
+
yAxis: zYBandAxis.optional(),
|
5958
|
+
crosshairRect: zCrosshairRect.optional(),
|
5959
|
+
stackCornerRadius: zStackCornerRadius.optional(),
|
5941
5960
|
theme: zTheme.optional(),
|
5961
|
+
barStyle: zBarStyle.optional(),
|
5962
|
+
annotationPoint: z.array(zAnnotationPoint).or(zAnnotationPoint).optional(),
|
5963
|
+
annotationVerticalLine: z.array(zAnnotationVerticalLine).or(zAnnotationVerticalLine).optional(),
|
5964
|
+
annotationHorizontalLine: z.array(zAnnotationHorizontalLine).or(zAnnotationHorizontalLine).optional(),
|
5965
|
+
annotationArea: z.array(zAnnotationArea).or(zAnnotationArea).optional(),
|
5942
5966
|
locale: zLocale.optional()
|
5943
5967
|
});
|
5944
5968
|
const zBarPercent = z.object({
|
@@ -5957,14 +5981,14 @@ const zBarPercent = z.object({
|
|
5957
5981
|
stackCornerRadius: zStackCornerRadius.optional(),
|
5958
5982
|
theme: zTheme.optional(),
|
5959
5983
|
barStyle: zBarStyle.optional(),
|
5960
|
-
annotationPoint: zAnnotationPoint.optional(),
|
5961
|
-
annotationVerticalLine: zAnnotationVerticalLine.optional(),
|
5962
|
-
annotationHorizontalLine: zAnnotationHorizontalLine.optional(),
|
5963
|
-
annotationArea: zAnnotationArea.optional(),
|
5984
|
+
annotationPoint: z.array(zAnnotationPoint).or(zAnnotationPoint).optional(),
|
5985
|
+
annotationVerticalLine: z.array(zAnnotationVerticalLine).or(zAnnotationVerticalLine).optional(),
|
5986
|
+
annotationHorizontalLine: z.array(zAnnotationHorizontalLine).or(zAnnotationHorizontalLine).optional(),
|
5987
|
+
annotationArea: z.array(zAnnotationArea).or(zAnnotationArea).optional(),
|
5964
5988
|
locale: zLocale.optional()
|
5965
5989
|
});
|
5966
|
-
const
|
5967
|
-
chartType: z.literal('
|
5990
|
+
const zArea = z.object({
|
5991
|
+
chartType: z.literal('area'),
|
5968
5992
|
dataset: zDataset.optional(),
|
5969
5993
|
dimensions: zDimensions.optional(),
|
5970
5994
|
measures: zMeasures.optional(),
|
@@ -5973,11 +5997,21 @@ const zPie = z.object({
|
|
5973
5997
|
label: zLabel.optional(),
|
5974
5998
|
legend: zLegend.optional(),
|
5975
5999
|
tooltip: zTooltip.optional(),
|
6000
|
+
xAxis: zXBandAxis.optional(),
|
6001
|
+
yAxis: zYLinearAxis.optional(),
|
6002
|
+
crosshairLine: zCrosshairLine.optional(),
|
5976
6003
|
theme: zTheme.optional(),
|
6004
|
+
pointStyle: zPointStyle.optional(),
|
6005
|
+
lineStyle: zLineStyle.optional(),
|
6006
|
+
areaStyle: zAreaStyle.optional(),
|
6007
|
+
annotationPoint: z.array(zAnnotationPoint).or(zAnnotationPoint).optional(),
|
6008
|
+
annotationVerticalLine: z.array(zAnnotationVerticalLine).or(zAnnotationVerticalLine).optional(),
|
6009
|
+
annotationHorizontalLine: z.array(zAnnotationHorizontalLine).or(zAnnotationHorizontalLine).optional(),
|
6010
|
+
annotationArea: z.array(zAnnotationArea).or(zAnnotationArea).optional(),
|
5977
6011
|
locale: zLocale.optional()
|
5978
6012
|
});
|
5979
|
-
const
|
5980
|
-
chartType: z.literal('
|
6013
|
+
const zAreaPercent = z.object({
|
6014
|
+
chartType: z.literal('areaPercent'),
|
5981
6015
|
dataset: zDataset.optional(),
|
5982
6016
|
dimensions: zDimensions.optional(),
|
5983
6017
|
measures: zMeasures.optional(),
|
@@ -5986,11 +6020,21 @@ const zDonut = z.object({
|
|
5986
6020
|
label: zLabel.optional(),
|
5987
6021
|
legend: zLegend.optional(),
|
5988
6022
|
tooltip: zTooltip.optional(),
|
6023
|
+
xAxis: zXBandAxis.optional(),
|
6024
|
+
yAxis: zYLinearAxis.optional(),
|
6025
|
+
crosshairLine: zCrosshairLine.optional(),
|
5989
6026
|
theme: zTheme.optional(),
|
6027
|
+
pointStyle: zPointStyle.optional(),
|
6028
|
+
lineStyle: zLineStyle.optional(),
|
6029
|
+
areaStyle: zAreaStyle.optional(),
|
6030
|
+
annotationPoint: z.array(zAnnotationPoint).or(zAnnotationPoint).optional(),
|
6031
|
+
annotationVerticalLine: z.array(zAnnotationVerticalLine).or(zAnnotationVerticalLine).optional(),
|
6032
|
+
annotationHorizontalLine: z.array(zAnnotationHorizontalLine).or(zAnnotationHorizontalLine).optional(),
|
6033
|
+
annotationArea: z.array(zAnnotationArea).or(zAnnotationArea).optional(),
|
5990
6034
|
locale: zLocale.optional()
|
5991
6035
|
});
|
5992
|
-
const
|
5993
|
-
chartType: z.literal('
|
6036
|
+
const zRose = z.object({
|
6037
|
+
chartType: z.literal('rose'),
|
5994
6038
|
dataset: zDataset.optional(),
|
5995
6039
|
dimensions: zDimensions.optional(),
|
5996
6040
|
measures: zMeasures.optional(),
|
@@ -5999,21 +6043,11 @@ const zArea = z.object({
|
|
5999
6043
|
label: zLabel.optional(),
|
6000
6044
|
legend: zLegend.optional(),
|
6001
6045
|
tooltip: zTooltip.optional(),
|
6002
|
-
xAxis: zXBandAxis.optional(),
|
6003
|
-
yAxis: zYLinearAxis.optional(),
|
6004
|
-
crosshairLine: zCrosshairLine.optional(),
|
6005
6046
|
theme: zTheme.optional(),
|
6006
|
-
pointStyle: zPointStyle.optional(),
|
6007
|
-
lineStyle: zLineStyle.optional(),
|
6008
|
-
areaStyle: zAreaStyle.optional(),
|
6009
|
-
annotationPoint: zAnnotationPoint.optional(),
|
6010
|
-
annotationVerticalLine: zAnnotationVerticalLine.optional(),
|
6011
|
-
annotationHorizontalLine: zAnnotationHorizontalLine.optional(),
|
6012
|
-
annotationArea: zAnnotationArea.optional(),
|
6013
6047
|
locale: zLocale.optional()
|
6014
6048
|
});
|
6015
|
-
const
|
6016
|
-
chartType: z.literal('
|
6049
|
+
const zRoseParallel = z.object({
|
6050
|
+
chartType: z.literal('roseParallel'),
|
6017
6051
|
dataset: zDataset.optional(),
|
6018
6052
|
dimensions: zDimensions.optional(),
|
6019
6053
|
measures: zMeasures.optional(),
|
@@ -6022,21 +6056,24 @@ const zAreaPercent = z.object({
|
|
6022
6056
|
label: zLabel.optional(),
|
6023
6057
|
legend: zLegend.optional(),
|
6024
6058
|
tooltip: zTooltip.optional(),
|
6025
|
-
xAxis: zXBandAxis.optional(),
|
6026
|
-
yAxis: zYLinearAxis.optional(),
|
6027
|
-
crosshairLine: zCrosshairLine.optional(),
|
6028
6059
|
theme: zTheme.optional(),
|
6029
|
-
pointStyle: zPointStyle.optional(),
|
6030
|
-
lineStyle: zLineStyle.optional(),
|
6031
|
-
areaStyle: zAreaStyle.optional(),
|
6032
|
-
annotationPoint: zAnnotationPoint.optional(),
|
6033
|
-
annotationVerticalLine: zAnnotationVerticalLine.optional(),
|
6034
|
-
annotationHorizontalLine: zAnnotationHorizontalLine.optional(),
|
6035
|
-
annotationArea: zAnnotationArea.optional(),
|
6036
6060
|
locale: zLocale.optional()
|
6037
6061
|
});
|
6038
|
-
const
|
6039
|
-
chartType: z.literal('
|
6062
|
+
const zPie = z.object({
|
6063
|
+
chartType: z.literal('pie'),
|
6064
|
+
dataset: zDataset.optional(),
|
6065
|
+
dimensions: zDimensions.optional(),
|
6066
|
+
measures: zMeasures.optional(),
|
6067
|
+
backgroundColor: zBackgroundColor.optional(),
|
6068
|
+
color: zColor.optional(),
|
6069
|
+
label: zLabel.optional(),
|
6070
|
+
legend: zLegend.optional(),
|
6071
|
+
tooltip: zTooltip.optional(),
|
6072
|
+
theme: zTheme.optional(),
|
6073
|
+
locale: zLocale.optional()
|
6074
|
+
});
|
6075
|
+
const zDonut = z.object({
|
6076
|
+
chartType: z.literal('donut'),
|
6040
6077
|
dataset: zDataset.optional(),
|
6041
6078
|
dimensions: zDimensions.optional(),
|
6042
6079
|
measures: zMeasures.optional(),
|
@@ -6063,10 +6100,10 @@ const zScatter = z.object({
|
|
6063
6100
|
crosshairLine: zCrosshairLine.optional(),
|
6064
6101
|
theme: zTheme.optional(),
|
6065
6102
|
pointStyle: zPointStyle.optional(),
|
6066
|
-
annotationPoint: zAnnotationPoint.optional(),
|
6067
|
-
annotationVerticalLine: zAnnotationVerticalLine.optional(),
|
6068
|
-
annotationHorizontalLine: zAnnotationHorizontalLine.optional(),
|
6069
|
-
annotationArea: zAnnotationArea.optional(),
|
6103
|
+
annotationPoint: z.array(zAnnotationPoint).or(zAnnotationPoint).optional(),
|
6104
|
+
annotationVerticalLine: z.array(zAnnotationVerticalLine).or(zAnnotationVerticalLine).optional(),
|
6105
|
+
annotationHorizontalLine: z.array(zAnnotationHorizontalLine).or(zAnnotationHorizontalLine).optional(),
|
6106
|
+
annotationArea: z.array(zAnnotationArea).or(zAnnotationArea).optional(),
|
6070
6107
|
locale: zLocale.optional()
|
6071
6108
|
});
|
6072
6109
|
const zFunnel = z.object({
|
@@ -6099,6 +6136,20 @@ const zVSeed = z.discriminatedUnion('chartType', [
|
|
6099
6136
|
zDonut,
|
6100
6137
|
zFunnel
|
6101
6138
|
]);
|
6102
|
-
|
6139
|
+
const zAdvancedVSeed = z.object({
|
6140
|
+
chartType: zChartType,
|
6141
|
+
dataset: zDataset,
|
6142
|
+
datasetReshapeInfo: zDatasetReshapeInfo,
|
6143
|
+
dimensions: zDimensions,
|
6144
|
+
measures: zMeasures,
|
6145
|
+
encoding: zEncoding,
|
6146
|
+
config: zConfig,
|
6147
|
+
theme: zTheme,
|
6148
|
+
markStyle: zMarkStyle,
|
6149
|
+
customTheme: zCustomThemeConfig,
|
6150
|
+
annotation: zAnnotation,
|
6151
|
+
locale: zLocale
|
6152
|
+
});
|
6153
|
+
export { Builder, FoldMeasureId, FoldMeasureName, FoldMeasureValue, ORIGINAL_DATA, Separator, UnfoldDimensionGroup, UnfoldDimensionGroupId, areaAdvancedPipeline, areaPercentAdvancedPipeline, areaPercentSpecPipeline, areaSpecPipeline, autoFormatter, autoNumFormatter, barAdvancedPipeline, barParallelAdvancedPipeline, barParallelSpecPipeline, barPercentAdvancedPipeline, barPercentSpecPipeline, barSpecPipeline, columnAdvancedPipeline, columnParallelAdvancedPipeline, columnParallelSpecPipeline, columnPercentAdvancedPipeline, columnPercentSpecPipeline, columnSpecPipeline, createFormatter, createNumFormatter, darkTheme, dataReshapeFor1D1M, dataReshapeFor1D2M, dataReshapeFor2D1M, donutAdvancedPipeline, donutSpecPipeline, execPipeline, findFirstMeasure, findMeasureById, foldMeasures, funnelAdvancedPipeline, funnelSpecPipeline, i18n, intl, isPivotChart, isVChart, isVTable, lightTheme, lineAdvancedPipeline, lineSpecPipeline, pieAdvancedPipeline, pieSpecPipeline, registerAll, registerArea, registerAreaPercent, registerBar, registerBarParallel, registerBarPercent, registerColumn, registerColumnParallel, registerColumnPercent, registerCustomTheme, registerDarkTheme, registerLightTheme, registerLine, roseAdvancedPipeline, roseParallelAdvancedPipeline, roseParallelSpecPipeline, roseSpecPipeline, scatterAdvancedPipeline, scatterSpecPipeline, unfoldDimensions, zAdvancedVSeed, zAnnotation, zAnnotationArea, zAnnotationHorizontalLine, zAnnotationPoint, zAnnotationVerticalLine, zArea, zAreaConfig, zAreaPercent, zAreaPercentConfig, zAreaStyle, zAxis, zBackgroundColor, zBar, zBarConfig, zBarParallel, zBarParallelConfig, zBarPercent, zBarPercentConfig, zBarStyle, zChartType, zColor, zColumn, zColumnConfig, zColumnParallel, zColumnParallelConfig, zColumnPercent, zColumnPercentConfig, zConfig, zCrosshairLine, zCrosshairRect, zCustomTheme, zCustomThemeConfig, zDataset, zDatasetReshapeInfo, zDatum, zDimension, zDimensions, zDonut, zDonutConfig, zDualAxisConfig, zEncoding, zFoldInfo, zFunnel, zFunnelConfig, zLabel, zLegend, zLine, zLineConfig, zLineStyle, zLocale, zMarkStyle, zMeasure, zMeasureGroup, zMeasures, zNumFormat, zPie, zPieConfig, zPointStyle, zRose, zRoseConfig, zRoseParallel, zRoseParallelConfig, zScatter, zScatterConfig, zStackCornerRadius, zTheme, zTooltip, zUnfoldInfo, zVSeed, zXBandAxis, zXLinearAxis, zYBandAxis, zYLinearAxis };
|
6103
6154
|
|
6104
6155
|
//# sourceMappingURL=index.js.map
|