@visactor/vseed 0.1.26 → 0.1.27

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.
Files changed (100) hide show
  1. package/dist/cjs/index.cjs +1 -1
  2. package/dist/cjs/index.cjs.map +1 -1
  3. package/dist/esm/builder/builder/builder.d.ts +124 -16
  4. package/dist/esm/dataSelector/selector.js +2 -4
  5. package/dist/esm/dataSelector/selector.js.map +1 -1
  6. package/dist/esm/pipeline/spec/chart/pipes/init/barParallel.js +6 -4
  7. package/dist/esm/pipeline/spec/chart/pipes/init/barParallel.js.map +1 -1
  8. package/dist/esm/pipeline/spec/chart/pipes/init/columnParallel.js +6 -4
  9. package/dist/esm/pipeline/spec/chart/pipes/init/columnParallel.js.map +1 -1
  10. package/dist/esm/pipeline/spec/chart/pipes/init/pivot.d.ts +0 -2
  11. package/dist/esm/pipeline/spec/chart/pipes/init/pivot.js +1 -19
  12. package/dist/esm/pipeline/spec/chart/pipes/init/pivot.js.map +1 -1
  13. package/dist/esm/pipeline/spec/chart/pipes/init/roseParallel.js +6 -4
  14. package/dist/esm/pipeline/spec/chart/pipes/init/roseParallel.js.map +1 -1
  15. package/dist/esm/pipeline/spec/chart/pipes/label/label.d.ts +1 -1
  16. package/dist/esm/pipeline/spec/chart/pipes/label/label.js +11 -6
  17. package/dist/esm/pipeline/spec/chart/pipes/label/label.js.map +1 -1
  18. package/dist/esm/pipeline/spec/chart/pipes/label/labelDualAxis.js +2 -2
  19. package/dist/esm/pipeline/spec/chart/pipes/label/labelDualAxis.js.map +1 -1
  20. package/dist/esm/pipeline/spec/chart/pipes/label/labelPie.js +1 -1
  21. package/dist/esm/pipeline/spec/chart/pipes/label/labelPie.js.map +1 -1
  22. package/dist/esm/pipeline/spec/chart/pipes/label/labelScatter.js +1 -1
  23. package/dist/esm/pipeline/spec/chart/pipes/label/labelScatter.js.map +1 -1
  24. package/dist/esm/theme/common/axes.d.ts +5 -0
  25. package/dist/esm/theme/common/axes.js +156 -0
  26. package/dist/esm/theme/common/axes.js.map +1 -0
  27. package/dist/esm/theme/common/color.d.ts +12 -0
  28. package/dist/esm/theme/common/color.js +43 -0
  29. package/dist/esm/theme/common/color.js.map +1 -0
  30. package/dist/esm/theme/common/crosshair.d.ts +28 -0
  31. package/dist/esm/theme/common/crosshair.js +31 -0
  32. package/dist/esm/theme/common/crosshair.js.map +1 -0
  33. package/dist/esm/theme/common/index.d.ts +7 -0
  34. package/dist/esm/theme/common/index.js +7 -0
  35. package/dist/esm/theme/common/label.d.ts +8 -0
  36. package/dist/esm/theme/common/label.js +11 -0
  37. package/dist/esm/theme/common/label.js.map +1 -0
  38. package/dist/esm/theme/common/legend.d.ts +2 -0
  39. package/dist/esm/theme/common/legend.js +13 -0
  40. package/dist/esm/theme/common/legend.js.map +1 -0
  41. package/dist/esm/theme/common/table.d.ts +3 -0
  42. package/dist/esm/theme/common/table.js +34 -0
  43. package/dist/esm/theme/common/table.js.map +1 -0
  44. package/dist/esm/theme/common/tooltip.d.ts +2 -0
  45. package/dist/esm/theme/common/tooltip.js +6 -0
  46. package/dist/esm/theme/common/tooltip.js.map +1 -0
  47. package/dist/esm/theme/{dark.d.ts → dark/dark.d.ts} +1 -1
  48. package/dist/esm/theme/{dark.js → dark/dark.js} +30 -153
  49. package/dist/esm/theme/dark/dark.js.map +1 -0
  50. package/dist/esm/theme/dark/index.d.ts +1 -0
  51. package/dist/esm/theme/dark/index.js +2 -0
  52. package/dist/esm/theme/index.js +2 -2
  53. package/dist/esm/theme/light/index.d.ts +1 -0
  54. package/dist/esm/theme/light/index.js +2 -0
  55. package/dist/esm/theme/{light.d.ts → light/light.d.ts} +1 -1
  56. package/dist/esm/theme/{light.js → light/light.js} +30 -155
  57. package/dist/esm/theme/light/light.js.map +1 -0
  58. package/dist/esm/types/advancedVSeed.d.ts +44 -8
  59. package/dist/esm/types/chartType/area/zArea.d.ts +9 -8
  60. package/dist/esm/types/chartType/areaPercent/zAreaPercent.d.ts +9 -8
  61. package/dist/esm/types/chartType/bar/zBar.d.ts +9 -8
  62. package/dist/esm/types/chartType/barParallel/zBarParallel.d.ts +9 -8
  63. package/dist/esm/types/chartType/barPercent/zBarPercent.d.ts +9 -8
  64. package/dist/esm/types/chartType/column/zColumn.d.ts +9 -8
  65. package/dist/esm/types/chartType/columnParallel/zColumnParallel.d.ts +9 -8
  66. package/dist/esm/types/chartType/columnPercent/zColumnPercent.d.ts +9 -8
  67. package/dist/esm/types/chartType/donut/zDonut.d.ts +1 -0
  68. package/dist/esm/types/chartType/dualAxis/zDualAxis.d.ts +9 -8
  69. package/dist/esm/types/chartType/funnel/zFunnel.d.ts +1 -0
  70. package/dist/esm/types/chartType/heatmap/zHeatmap.d.ts +1 -0
  71. package/dist/esm/types/chartType/line/zLine.d.ts +9 -8
  72. package/dist/esm/types/chartType/pie/zPie.d.ts +1 -0
  73. package/dist/esm/types/chartType/radar/zRadar.d.ts +1 -0
  74. package/dist/esm/types/chartType/rose/zRose.d.ts +1 -0
  75. package/dist/esm/types/chartType/roseParallel/zRoseParallel.d.ts +1 -0
  76. package/dist/esm/types/chartType/scatter/zScatter.d.ts +9 -8
  77. package/dist/esm/types/dataSelector/selector.d.ts +2 -2
  78. package/dist/esm/types/dataSelector/selector.js.map +1 -1
  79. package/dist/esm/types/properties/annotation/annotation.d.ts +8 -8
  80. package/dist/esm/types/properties/annotation/annotationArea.d.ts +1 -1
  81. package/dist/esm/types/properties/annotation/annotationPoint.d.ts +1 -1
  82. package/dist/esm/types/properties/annotation/zAnnotationArea.d.ts +2 -2
  83. package/dist/esm/types/properties/annotation/zAnnotationArea.js +1 -1
  84. package/dist/esm/types/properties/annotation/zAnnotationArea.js.map +1 -1
  85. package/dist/esm/types/properties/annotation/zAnnotationPoint.d.ts +2 -2
  86. package/dist/esm/types/properties/annotation/zAnnotationPoint.js +1 -1
  87. package/dist/esm/types/properties/annotation/zAnnotationPoint.js.map +1 -1
  88. package/dist/esm/types/properties/config/config.d.ts +36 -0
  89. package/dist/esm/types/properties/config/label/label.d.ts +8 -0
  90. package/dist/esm/types/properties/config/label/zLabel.d.ts +1 -0
  91. package/dist/esm/types/properties/config/label/zLabel.js +1 -0
  92. package/dist/esm/types/properties/config/label/zLabel.js.map +1 -1
  93. package/dist/esm/types/properties/config/label/zPieLabel.d.ts +1 -0
  94. package/dist/esm/types/properties/theme/customTheme.d.ts +36 -0
  95. package/dist/esm/types/zVseed.d.ts +106 -88
  96. package/dist/umd/index.js +309 -284
  97. package/dist/umd/index.js.map +1 -1
  98. package/package.json +1 -1
  99. package/dist/esm/theme/dark.js.map +0 -1
  100. package/dist/esm/theme/light.js.map +0 -1
package/dist/umd/index.js CHANGED
@@ -3081,6 +3081,8 @@
3081
3081
  ];
3082
3082
  switch(op){
3083
3083
  case '=':
3084
+ if (String(datum[selector.field]) === String(selectorValueArr[0])) return true;
3085
+ break;
3084
3086
  case '==':
3085
3087
  if (datum[selector.field] === selectorValueArr[0]) return true;
3086
3088
  break;
@@ -3102,8 +3104,6 @@
3102
3104
  case 'between':
3103
3105
  if (Array.isArray(selector.value) && datum[selector.field] >= selectorValueArr[0] && datum[selector.field] <= selectorValueArr[1]) return true;
3104
3106
  break;
3105
- default:
3106
- break;
3107
3107
  }
3108
3108
  } else if (isDimensionSelector(selector)) {
3109
3109
  const op = selector.operator || selector.op;
@@ -3117,8 +3117,6 @@
3117
3117
  case 'not in':
3118
3118
  if (!selectorValueArr.includes(datum[selector.field])) return true;
3119
3119
  break;
3120
- default:
3121
- break;
3122
3120
  }
3123
3121
  } else if (isPartialDatumSelector(selector)) {
3124
3122
  if (Object.keys(selector).every((key)=>datum[key] === selector[key])) return true;
@@ -3354,7 +3352,7 @@
3354
3352
  const baseConfig = advancedVSeed.config[chartType];
3355
3353
  const foldInfo = datasetReshapeInfo[0].foldInfo;
3356
3354
  const { label } = baseConfig;
3357
- result.label = buildLabel(label, vseed.measures, vseed.dimensions, advancedVSeed.measures, encoding, [
3355
+ result.label = buildLabel(label, vseed.measures, vseed.dimensions, advancedVSeed.dimensions, advancedVSeed.measures, encoding, [
3358
3356
  foldInfo
3359
3357
  ]);
3360
3358
  return result;
@@ -3376,10 +3374,11 @@
3376
3374
  const percentValue = num / sum;
3377
3375
  return formatter(percentValue);
3378
3376
  };
3379
- const buildLabel = (label, vseedMeasures = [], vseedDimensions = [], advancedVSeedMeasures, encoding, foldInfoList)=>{
3380
- const { enable, wrap, showValue, showValuePercent, labelOverlap, labelColorSmartInvert, labelColor, labelFontSize, labelFontWeight, labelBackgroundColor, labelPosition, autoFormat, numFormat = {} } = label;
3381
- const labelDims = T((vseedDimensions || []).filter((item)=>encoding.label?.includes(item.id)), (item)=>item.id);
3382
- const labelMeas = T((vseedMeasures || []).filter((item)=>encoding.label?.includes(item.id)), (item)=>item.id);
3377
+ const buildLabel = (label, vseedMeasures = [], vseedDimensions = [], advancedVSeedDimensions, advancedVSeedMeasures, encoding, foldInfoList)=>{
3378
+ const { enable, wrap, showValue, showValuePercent, showDimension, labelOverlap, labelColorSmartInvert, labelColor, labelFontSize, labelFontWeight, labelBackgroundColor, labelPosition, autoFormat, numFormat = {} } = label;
3379
+ const hasDimLabelEncoding = vseedDimensions.some((item)=>encoding.label?.includes(item.id));
3380
+ const labelDims = T(hasDimLabelEncoding ? vseedDimensions.filter((item)=>encoding.label?.includes(item.id)) : showDimension ? advancedVSeedDimensions.filter((d)=>d.id !== MeasureName) : [], (item)=>item.id);
3381
+ const labelMeas = T(vseedMeasures.filter((item)=>encoding.label?.includes(item.id)), (item)=>item.id);
3383
3382
  const percentFormat = chunk_5S4PYKVY_t(numFormat, {
3384
3383
  type: 'percent'
3385
3384
  });
@@ -3388,7 +3387,10 @@
3388
3387
  visible: enable,
3389
3388
  formatMethod: (_, datum)=>{
3390
3389
  const result = [];
3391
- const dimLabels = labelDims.map((item)=>item.alias || item.id);
3390
+ const dimLabels = labelDims.map((item)=>{
3391
+ const id = item.id;
3392
+ return datum[id];
3393
+ });
3392
3394
  const meaLabels = labelMeas.map((item)=>generateMeasureValue(datum[item.id], item, autoFormat, numFormat));
3393
3395
  result.push(...dimLabels);
3394
3396
  foldInfoList.forEach((foldInfo)=>{
@@ -4175,7 +4177,7 @@
4175
4177
  indicators: indicators
4176
4178
  };
4177
4179
  };
4178
- const pivotIndicators_pivotIndicatorsAsRow = (spec)=>{
4180
+ const pivotIndicatorsAsRow = (spec)=>{
4179
4181
  const result = {
4180
4182
  ...spec
4181
4183
  };
@@ -4184,7 +4186,7 @@
4184
4186
  indicatorsAsCol: false
4185
4187
  };
4186
4188
  };
4187
- const pivotIndicators_pivotIndicatorsAsCol = (spec)=>{
4189
+ const pivotIndicatorsAsCol = (spec)=>{
4188
4190
  const result = {
4189
4191
  ...spec
4190
4192
  };
@@ -4466,7 +4468,7 @@
4466
4468
  const pivotLine = [
4467
4469
  initPivot,
4468
4470
  pivotGridStyle,
4469
- pivotIndicators_pivotIndicatorsAsRow,
4471
+ pivotIndicatorsAsRow,
4470
4472
  datasetPivot,
4471
4473
  pivotIndicators_pivotIndicators([
4472
4474
  initLine,
@@ -4920,7 +4922,7 @@
4920
4922
  const pivotColumn = [
4921
4923
  initPivot,
4922
4924
  pivotGridStyle,
4923
- pivotIndicators_pivotIndicatorsAsRow,
4925
+ pivotIndicatorsAsRow,
4924
4926
  datasetPivot,
4925
4927
  pivotIndicators_pivotIndicators([
4926
4928
  initColumn,
@@ -5032,12 +5034,13 @@
5032
5034
  const sameDimensionsMode = chunk_HGKLN5KY_k(encoding.x, encoding.color);
5033
5035
  result.type = 'bar';
5034
5036
  result.direction = 'vertical';
5035
- result.xField = sameDimensionsMode ? [
5037
+ result.xField = [
5036
5038
  unfoldInfo.encodingX
5037
- ] : [
5038
- unfoldInfo.encodingX,
5039
- unfoldInfo.encodingDetail
5040
5039
  ];
5040
+ if (!sameDimensionsMode) {
5041
+ result.xField.push(unfoldInfo.encodingDetail);
5042
+ if (encoding.detail?.[0] === MeasureName && encoding.y?.length === 1) result.xField.pop();
5043
+ }
5041
5044
  result.yField = foldInfo.measureValue;
5042
5045
  result.seriesField = unfoldInfo.encodingColorId;
5043
5046
  result.padding = 0;
@@ -5071,7 +5074,7 @@
5071
5074
  const pivotColumnParallel = [
5072
5075
  initPivot,
5073
5076
  pivotGridStyle,
5074
- pivotIndicators_pivotIndicatorsAsRow,
5077
+ pivotIndicatorsAsRow,
5075
5078
  datasetPivot,
5076
5079
  pivotIndicators_pivotIndicators([
5077
5080
  initColumnParallel,
@@ -5163,7 +5166,7 @@
5163
5166
  const pivotColumnPercent = [
5164
5167
  initPivot,
5165
5168
  pivotGridStyle,
5166
- pivotIndicators_pivotIndicatorsAsRow,
5169
+ pivotIndicatorsAsRow,
5167
5170
  datasetPivot,
5168
5171
  pivotIndicators_pivotIndicators([
5169
5172
  initColumn,
@@ -5601,7 +5604,7 @@
5601
5604
  const pivotBar = [
5602
5605
  initPivot,
5603
5606
  pivotGridStyle,
5604
- pivotIndicators_pivotIndicatorsAsCol,
5607
+ pivotIndicatorsAsCol,
5605
5608
  datasetPivot,
5606
5609
  pivotIndicators_pivotIndicators([
5607
5610
  initBar,
@@ -5673,12 +5676,13 @@
5673
5676
  const sameDimensionsMode = chunk_HGKLN5KY_k(encoding.y, encoding.color);
5674
5677
  result.type = 'bar';
5675
5678
  result.direction = 'horizontal';
5676
- result.yField = sameDimensionsMode ? [
5679
+ result.yField = [
5677
5680
  unfoldInfo.encodingY
5678
- ] : [
5679
- unfoldInfo.encodingY,
5680
- unfoldInfo.encodingDetail
5681
5681
  ];
5682
+ if (!sameDimensionsMode) {
5683
+ result.yField.push(unfoldInfo.encodingDetail);
5684
+ if (encoding.detail?.[0] === MeasureName && encoding.x?.length === 1) result.yField.pop();
5685
+ }
5682
5686
  result.xField = foldInfo.measureValue;
5683
5687
  result.seriesField = unfoldInfo.encodingColorId;
5684
5688
  result.padding = 0;
@@ -5712,7 +5716,7 @@
5712
5716
  const pivotBarParallel = [
5713
5717
  initPivot,
5714
5718
  pivotGridStyle,
5715
- pivotIndicators_pivotIndicatorsAsCol,
5719
+ pivotIndicatorsAsCol,
5716
5720
  datasetPivot,
5717
5721
  pivotIndicators_pivotIndicators([
5718
5722
  initBarParallel,
@@ -5795,7 +5799,7 @@
5795
5799
  const pivotBarPercent = [
5796
5800
  initPivot,
5797
5801
  pivotGridStyle,
5798
- pivotIndicators_pivotIndicatorsAsCol,
5802
+ pivotIndicatorsAsCol,
5799
5803
  datasetPivot,
5800
5804
  pivotIndicators_pivotIndicators([
5801
5805
  initBar,
@@ -5986,7 +5990,7 @@
5986
5990
  const pivotArea = [
5987
5991
  initPivot,
5988
5992
  pivotGridStyle,
5989
- pivotIndicators_pivotIndicatorsAsRow,
5993
+ pivotIndicatorsAsRow,
5990
5994
  datasetPivot,
5991
5995
  pivotIndicators_pivotIndicators([
5992
5996
  initArea,
@@ -6076,7 +6080,7 @@
6076
6080
  const pivotAreaPercent = [
6077
6081
  initPivot,
6078
6082
  pivotGridStyle,
6079
- pivotIndicators_pivotIndicatorsAsRow,
6083
+ pivotIndicatorsAsRow,
6080
6084
  datasetPivot,
6081
6085
  pivotIndicators_pivotIndicators([
6082
6086
  initArea,
@@ -6523,7 +6527,7 @@
6523
6527
  const baseConfig = advancedVSeed.config[chartType];
6524
6528
  const foldInfoList = datasetReshapeInfo[0].foldInfoList;
6525
6529
  const { label } = baseConfig;
6526
- result.label = buildLabel(label, vseed.measures, vseed.dimensions, advancedVSeed.measures, encoding, foldInfoList);
6530
+ result.label = buildLabel(label, vseed.measures, vseed.dimensions, advancedVSeed.dimensions, advancedVSeed.measures, encoding, foldInfoList);
6527
6531
  return result;
6528
6532
  };
6529
6533
  const tooltipScatter = (spec, context)=>{
@@ -6681,7 +6685,7 @@
6681
6685
  const pivotScatter = [
6682
6686
  initPivot,
6683
6687
  pivotGridStyle,
6684
- pivotIndicators_pivotIndicatorsAsRow,
6688
+ pivotIndicatorsAsRow,
6685
6689
  datasetPivot,
6686
6690
  pivotIndicators_pivotIndicators([
6687
6691
  initScatter,
@@ -7339,7 +7343,7 @@
7339
7343
  const { chartType } = advancedVSeed;
7340
7344
  const baseConfig = advancedVSeed.config[chartType];
7341
7345
  const foldInfoList = datasetReshapeInfo[0].foldInfoList;
7342
- result.label = buildLabel(baseConfig.label, vseed.measures, vseed.dimensions, advancedVSeed.measures, encoding, [
7346
+ result.label = buildLabel(baseConfig.label, vseed.measures, vseed.dimensions, advancedVSeed.dimensions, advancedVSeed.measures, encoding, [
7343
7347
  foldInfoList[0]
7344
7348
  ]);
7345
7349
  result.label.zIndex = 1002;
@@ -7354,7 +7358,7 @@
7354
7358
  const { chartType } = advancedVSeed;
7355
7359
  const baseConfig = advancedVSeed.config[chartType];
7356
7360
  const foldInfoList = datasetReshapeInfo[0].foldInfoList;
7357
- result.label = buildLabel(baseConfig.label, vseed.measures, vseed.dimensions, advancedVSeed.measures, encoding, [
7361
+ result.label = buildLabel(baseConfig.label, vseed.measures, vseed.dimensions, advancedVSeed.dimensions, advancedVSeed.measures, encoding, [
7358
7362
  foldInfoList[1]
7359
7363
  ]);
7360
7364
  result.label.zIndex = 1002;
@@ -7671,7 +7675,7 @@
7671
7675
  const pivotDualAxis = [
7672
7676
  initPivot,
7673
7677
  pivotGridStyle,
7674
- pivotIndicators_pivotIndicatorsAsRow,
7678
+ pivotIndicatorsAsRow,
7675
7679
  datasetPivot,
7676
7680
  pivotIndicators_pivotIndicators([
7677
7681
  series([
@@ -7882,7 +7886,7 @@
7882
7886
  const baseConfig = advancedVSeed.config[chartType];
7883
7887
  const foldInfo = datasetReshapeInfo[0].foldInfo;
7884
7888
  const { label } = baseConfig;
7885
- result.label = buildLabel(label, vseed.measures, vseed.dimensions, advancedVSeed.measures, encoding, [
7889
+ result.label = buildLabel(label, vseed.measures, vseed.dimensions, advancedVSeed.dimensions, advancedVSeed.measures, encoding, [
7886
7890
  foldInfo
7887
7891
  ]);
7888
7892
  if (label.labelLayout) result.label.layout = {
@@ -7912,7 +7916,7 @@
7912
7916
  const pivotPie = [
7913
7917
  initPivot,
7914
7918
  pivotGridStyle,
7915
- pivotIndicators_pivotIndicatorsAsRow,
7919
+ pivotIndicatorsAsRow,
7916
7920
  pivotHideIndicatorName,
7917
7921
  datasetPivot,
7918
7922
  pivotIndicators_pivotIndicators([
@@ -8006,7 +8010,7 @@
8006
8010
  const pivotDonut = [
8007
8011
  initPivot,
8008
8012
  pivotGridStyle,
8009
- pivotIndicators_pivotIndicatorsAsRow,
8013
+ pivotIndicatorsAsRow,
8010
8014
  pivotHideIndicatorName,
8011
8015
  datasetPivot,
8012
8016
  pivotIndicators_pivotIndicators([
@@ -8226,7 +8230,7 @@
8226
8230
  const pivotRose = [
8227
8231
  initPivot,
8228
8232
  pivotGridStyle,
8229
- pivotIndicators_pivotIndicatorsAsRow,
8233
+ pivotIndicatorsAsRow,
8230
8234
  pivotHideIndicatorName,
8231
8235
  datasetPivot,
8232
8236
  pivotIndicators_pivotIndicators([
@@ -8291,12 +8295,13 @@
8291
8295
  const { unfoldInfo, foldInfo } = datasetReshapeInfo[0];
8292
8296
  const sameDimensionsMode = chunk_HGKLN5KY_k(encoding.angle, encoding.color);
8293
8297
  result.type = 'rose';
8294
- result.angleField = sameDimensionsMode ? [
8298
+ result.angleField = [
8295
8299
  unfoldInfo.encodingAngle
8296
- ] : [
8297
- unfoldInfo.encodingAngle,
8298
- unfoldInfo.encodingDetail
8299
8300
  ];
8301
+ if (!sameDimensionsMode) {
8302
+ result.angleField.push(unfoldInfo.encodingDetail);
8303
+ if (encoding.detail?.[0] === MeasureName && encoding.radius?.length === 1) result.angleField.pop();
8304
+ }
8300
8305
  result.valueField = foldInfo.measureValue;
8301
8306
  result.seriesField = unfoldInfo.encodingColorId;
8302
8307
  result.padding = 0;
@@ -8345,7 +8350,7 @@
8345
8350
  const pivotRoseParallel = [
8346
8351
  initPivot,
8347
8352
  pivotGridStyle,
8348
- pivotIndicators_pivotIndicatorsAsRow,
8353
+ pivotIndicatorsAsRow,
8349
8354
  pivotHideIndicatorName,
8350
8355
  datasetPivot,
8351
8356
  pivotIndicators_pivotIndicators([
@@ -8562,7 +8567,7 @@
8562
8567
  const pivotRadar = [
8563
8568
  initPivot,
8564
8569
  pivotGridStyle,
8565
- pivotIndicators_pivotIndicatorsAsRow,
8570
+ pivotIndicatorsAsRow,
8566
8571
  pivotHideIndicatorName,
8567
8572
  datasetPivot,
8568
8573
  pivotIndicators_pivotIndicators([
@@ -8763,7 +8768,7 @@
8763
8768
  const pivotFunnel = [
8764
8769
  initPivot,
8765
8770
  pivotGridStyle,
8766
- pivotIndicators_pivotIndicatorsAsRow,
8771
+ pivotIndicatorsAsRow,
8767
8772
  pivotHideIndicatorName,
8768
8773
  datasetPivot,
8769
8774
  pivotIndicators_pivotIndicators([
@@ -9066,7 +9071,7 @@
9066
9071
  const pivotHeatmap = [
9067
9072
  initPivot,
9068
9073
  pivotGridStyle,
9069
- pivotIndicators_pivotIndicatorsAsRow,
9074
+ pivotIndicatorsAsRow,
9070
9075
  datasetPivot,
9071
9076
  pivotIndicators_pivotIndicators([
9072
9077
  initHeatmap,
@@ -9092,8 +9097,127 @@
9092
9097
  Builder._advancedPipelineMap.heatmap = heatmapAdvancedPipeline;
9093
9098
  Builder._specPipelineMap.heatmap = heatmapSpecPipeline;
9094
9099
  };
9095
- const lightTheme = ()=>{
9096
- const linearAxis = {
9100
+ const getDarkCrosshairLine = ()=>({
9101
+ visible: true,
9102
+ labelVisible: true,
9103
+ labelColor: '#4B4F54',
9104
+ labelBackgroundColor: '#ffffff',
9105
+ lineColor: '#E2E3E6'
9106
+ });
9107
+ const getDarkCrosshairRect = ()=>({
9108
+ visible: true,
9109
+ labelVisible: true,
9110
+ labelColor: '#4B4F54',
9111
+ labelBackgroundColor: '#ffffff',
9112
+ rectColor: '#E2E3E6'
9113
+ });
9114
+ const getLightCrosshairLine = ()=>({
9115
+ visible: true,
9116
+ labelVisible: true,
9117
+ labelColor: '#ffffff',
9118
+ labelBackgroundColor: '#364159',
9119
+ lineColor: '#3641594d'
9120
+ });
9121
+ const getLightCrosshairRect = ()=>({
9122
+ visible: true,
9123
+ labelVisible: true,
9124
+ labelColor: '#ffffff',
9125
+ labelBackgroundColor: '#364159',
9126
+ rectColor: '#3641594d'
9127
+ });
9128
+ const getLightColorScheme = ()=>[
9129
+ '#8D72F6',
9130
+ '#5766EC',
9131
+ '#66A3FE',
9132
+ '#51D5E6',
9133
+ '#4EC0B3',
9134
+ '#F9DF90',
9135
+ '#F9AD71',
9136
+ '#ED8888',
9137
+ '#E9A0C3',
9138
+ '#D77DD3'
9139
+ ];
9140
+ const getDarkColorScheme = ()=>[
9141
+ '#2E62F1',
9142
+ '#4DC36A',
9143
+ '#FF8406',
9144
+ '#FFCC00',
9145
+ '#4F44CF',
9146
+ '#5AC8FA',
9147
+ '#003A8C',
9148
+ '#B08AE2',
9149
+ '#FF6341',
9150
+ '#98DD62'
9151
+ ];
9152
+ const getLightLinearColorScheme = ()=>[
9153
+ '#C2CEFF',
9154
+ '#5766EC'
9155
+ ];
9156
+ const getDarkLinearColorScheme = ()=>[
9157
+ '#A0CEFF',
9158
+ '#2E62F1'
9159
+ ];
9160
+ const getLightColor = ()=>({
9161
+ linearColorScheme: getLightLinearColorScheme(),
9162
+ colorScheme: getLightColorScheme()
9163
+ });
9164
+ const getDarkColor = ()=>({
9165
+ linearColorScheme: getDarkLinearColorScheme(),
9166
+ colorScheme: getDarkColorScheme()
9167
+ });
9168
+ const getDefaultLabel = ()=>({
9169
+ enable: true,
9170
+ wrap: true,
9171
+ showValue: true,
9172
+ showValuePercent: false,
9173
+ labelColorSmartInvert: false,
9174
+ labelOverlap: true
9175
+ });
9176
+ const getDefaultLegend = ()=>({
9177
+ enable: true,
9178
+ border: true,
9179
+ maxSize: 1,
9180
+ shapeType: 'rectRound',
9181
+ position: 'rt',
9182
+ labelColor: '#646A73',
9183
+ labelFontSize: 12,
9184
+ labelFontWeight: 400
9185
+ });
9186
+ const getLightTableConfig = ()=>({
9187
+ borderColor: '#e3e5eb',
9188
+ bodyFontSize: 12,
9189
+ bodyFontColor: '#141414',
9190
+ bodyBackgroundColor: 'transparent',
9191
+ headerFontSize: 12,
9192
+ headerFontColor: '#21252c',
9193
+ headerBackgroundColor: '#f6f7f9',
9194
+ hoverBodyBackgroundColor: '#bedaff',
9195
+ hoverBodyInlineBackgroundColor: '#bedaff33',
9196
+ hoverHeaderBackgroundColor: '#D9DDE4',
9197
+ hoverHeaderInlineBackgroundColor: '#D9DDE455',
9198
+ selectedBorderColor: '#4080ff',
9199
+ selectedBackgroundColor: '#bedaff33',
9200
+ backgroundColor: 'transparent'
9201
+ });
9202
+ const getDarkTableConfig = ()=>({
9203
+ borderColor: '#4b4e53',
9204
+ bodyFontSize: 12,
9205
+ bodyFontColor: '#fdfdfd',
9206
+ bodyBackgroundColor: 'transparent',
9207
+ headerFontSize: 12,
9208
+ headerFontColor: '#fdfdfd',
9209
+ headerBackgroundColor: '#36393e',
9210
+ hoverBodyBackgroundColor: '#4284ff66',
9211
+ hoverBodyInlineBackgroundColor: '#4284ff10',
9212
+ hoverHeaderBackgroundColor: '#6f7984cc',
9213
+ hoverHeaderInlineBackgroundColor: '#4b4f54',
9214
+ selectedBorderColor: '#3073f2',
9215
+ selectedBackgroundColor: '#4284ff33'
9216
+ });
9217
+ const getDefaultTooltip = ()=>({
9218
+ enable: true
9219
+ });
9220
+ const getLightLinearAxis = ()=>({
9097
9221
  nice: true,
9098
9222
  zero: true,
9099
9223
  inverse: false,
@@ -9127,8 +9251,8 @@
9127
9251
  lineColor: '#3641594d',
9128
9252
  lineWidth: 1
9129
9253
  }
9130
- };
9131
- const bandAxis = {
9254
+ });
9255
+ const getLightBandAxis = ()=>({
9132
9256
  labelAutoHide: true,
9133
9257
  labelAutoHideGap: 4,
9134
9258
  labelAutoLimit: true,
@@ -9169,7 +9293,86 @@
9169
9293
  lineColor: '#3641594d',
9170
9294
  lineWidth: 1
9171
9295
  }
9172
- };
9296
+ });
9297
+ const getDarkLinearAxis = ()=>({
9298
+ nice: true,
9299
+ zero: true,
9300
+ label: {
9301
+ visible: true,
9302
+ labelAngle: 0,
9303
+ labelColor: '#E2E3E6',
9304
+ labelFontSize: 12,
9305
+ labelFontWeight: 400
9306
+ },
9307
+ title: {
9308
+ visible: false,
9309
+ titleText: '',
9310
+ titleColor: '#FDFDFD',
9311
+ titleFontSize: 12,
9312
+ titleFontWeight: 400
9313
+ },
9314
+ grid: {
9315
+ visible: true,
9316
+ gridColor: '#404349',
9317
+ gridWidth: 0.5
9318
+ },
9319
+ tick: {
9320
+ visible: false,
9321
+ tickInside: false,
9322
+ tickSize: 4,
9323
+ tickColor: '#4B4F54'
9324
+ },
9325
+ line: {
9326
+ visible: false,
9327
+ lineColor: '#4B4F54',
9328
+ lineWidth: 1
9329
+ }
9330
+ });
9331
+ const getDarkBandAxis = ()=>({
9332
+ labelAutoHide: true,
9333
+ labelAutoHideGap: 4,
9334
+ labelAutoLimit: true,
9335
+ labelAutoLimitLength: 80,
9336
+ labelAutoRotate: false,
9337
+ labelAutoRotateAngleRange: [
9338
+ 0,
9339
+ -45,
9340
+ -90
9341
+ ],
9342
+ label: {
9343
+ visible: true,
9344
+ labelAngle: 0,
9345
+ labelColor: '#E2E3E6',
9346
+ labelFontSize: 12,
9347
+ labelFontWeight: 400
9348
+ },
9349
+ title: {
9350
+ visible: false,
9351
+ titleText: '',
9352
+ titleColor: '#FDFDFD',
9353
+ titleFontSize: 12,
9354
+ titleFontWeight: 400
9355
+ },
9356
+ grid: {
9357
+ visible: false,
9358
+ gridColor: '#404349',
9359
+ gridWidth: 0.5
9360
+ },
9361
+ tick: {
9362
+ visible: false,
9363
+ tickInside: false,
9364
+ tickSize: 4,
9365
+ tickColor: '#4B4F54'
9366
+ },
9367
+ line: {
9368
+ visible: true,
9369
+ lineColor: '#4B4F54',
9370
+ lineWidth: 1
9371
+ }
9372
+ });
9373
+ const lightTheme = ()=>{
9374
+ const linearAxis = getLightLinearAxis();
9375
+ const bandAxis = getLightBandAxis();
9173
9376
  const barBandAxis = {
9174
9377
  ...bandAxis,
9175
9378
  labelAutoHide: false,
@@ -9183,78 +9386,16 @@
9183
9386
  -90
9184
9387
  ]
9185
9388
  };
9186
- const crosshairLine = {
9187
- visible: true,
9188
- labelVisible: true,
9189
- lineColor: '#3641594d',
9190
- labelColor: '#ffffff',
9191
- labelBackgroundColor: '#364159'
9192
- };
9193
- const crosshairRect = {
9194
- visible: true,
9195
- labelVisible: true,
9196
- rectColor: '#3641594d',
9197
- labelColor: '#ffffff',
9198
- labelBackgroundColor: '#364159'
9199
- };
9389
+ const crosshairLine = getLightCrosshairLine();
9390
+ const crosshairRect = getLightCrosshairRect();
9200
9391
  const baseConfig = {
9201
9392
  backgroundColor: 'transparent',
9202
- color: {
9203
- linearColorScheme: [
9204
- '#C2CEFF',
9205
- '#5766EC'
9206
- ],
9207
- colorScheme: [
9208
- '#8D72F6',
9209
- '#5766EC',
9210
- '#66A3FE',
9211
- '#51D5E6',
9212
- '#4EC0B3',
9213
- '#F9DF90',
9214
- '#F9AD71',
9215
- '#ED8888',
9216
- '#E9A0C3',
9217
- '#D77DD3'
9218
- ]
9219
- },
9220
- label: {
9221
- enable: true,
9222
- wrap: true,
9223
- showValue: true,
9224
- showValuePercent: false,
9225
- labelColorSmartInvert: false,
9226
- labelOverlap: true
9227
- },
9228
- tooltip: {
9229
- enable: true
9230
- },
9231
- legend: {
9232
- enable: true,
9233
- border: true,
9234
- maxSize: 1,
9235
- shapeType: 'rectRound',
9236
- position: 'rt',
9237
- labelColor: '#646A73',
9238
- labelFontSize: 12,
9239
- labelFontWeight: 400
9240
- }
9241
- };
9242
- const tableConfig = {
9243
- borderColor: '#e3e5eb',
9244
- bodyFontSize: 12,
9245
- bodyFontColor: '#141414',
9246
- bodyBackgroundColor: 'transparent',
9247
- headerFontSize: 12,
9248
- headerFontColor: '#21252c',
9249
- headerBackgroundColor: '#f6f7f9',
9250
- hoverBodyBackgroundColor: '#bedaff',
9251
- hoverBodyInlineBackgroundColor: '#bedaff33',
9252
- hoverHeaderBackgroundColor: '#D9DDE4',
9253
- hoverHeaderInlineBackgroundColor: '#D9DDE455',
9254
- selectedBorderColor: '#4080ff',
9255
- selectedBackgroundColor: '#bedaff33',
9256
- backgroundColor: 'transparent'
9393
+ color: getLightColor(),
9394
+ label: getDefaultLabel(),
9395
+ legend: getDefaultLegend(),
9396
+ tooltip: getDefaultTooltip()
9257
9397
  };
9398
+ const tableConfig = getLightTableConfig();
9258
9399
  return {
9259
9400
  config: {
9260
9401
  table: tableConfig,
@@ -9357,6 +9498,11 @@
9357
9498
  },
9358
9499
  scatter: {
9359
9500
  ...baseConfig,
9501
+ crosshairLine,
9502
+ sizeRange: [
9503
+ 8,
9504
+ 24
9505
+ ],
9360
9506
  xAxis: {
9361
9507
  ...linearAxis,
9362
9508
  line: {
@@ -9371,11 +9517,11 @@
9371
9517
  visible: true
9372
9518
  }
9373
9519
  },
9374
- crosshairLine,
9375
- sizeRange: [
9376
- 8,
9377
- 24
9378
- ]
9520
+ label: {
9521
+ ...baseConfig.label,
9522
+ showValue: false,
9523
+ showValuePercent: false
9524
+ }
9379
9525
  },
9380
9526
  dualAxis: {
9381
9527
  ...baseConfig,
@@ -9398,7 +9544,8 @@
9398
9544
  label: {
9399
9545
  ...baseConfig.label,
9400
9546
  showValuePercent: true,
9401
- labelLayout: 'labelLine'
9547
+ labelLayout: 'labelLine',
9548
+ showDimension: true
9402
9549
  }
9403
9550
  },
9404
9551
  donut: {
@@ -9406,7 +9553,8 @@
9406
9553
  label: {
9407
9554
  ...baseConfig.label,
9408
9555
  showValuePercent: true,
9409
- labelLayout: 'labelLine'
9556
+ labelLayout: 'labelLine',
9557
+ showDimension: true
9410
9558
  }
9411
9559
  },
9412
9560
  radar: {
@@ -9416,14 +9564,16 @@
9416
9564
  ...baseConfig,
9417
9565
  label: {
9418
9566
  ...baseConfig.label,
9419
- showValuePercent: true
9567
+ showValuePercent: true,
9568
+ showDimension: true
9420
9569
  }
9421
9570
  },
9422
9571
  roseParallel: {
9423
9572
  ...baseConfig,
9424
9573
  label: {
9425
9574
  ...baseConfig.label,
9426
- showValuePercent: true
9575
+ showValuePercent: true,
9576
+ showDimension: true
9427
9577
  }
9428
9578
  },
9429
9579
  funnel: {
@@ -9440,82 +9590,8 @@
9440
9590
  };
9441
9591
  };
9442
9592
  const darkTheme = ()=>{
9443
- const linearAxis = {
9444
- nice: true,
9445
- zero: true,
9446
- label: {
9447
- visible: true,
9448
- labelAngle: 0,
9449
- labelColor: '#E2E3E6',
9450
- labelFontSize: 12,
9451
- labelFontWeight: 400
9452
- },
9453
- title: {
9454
- visible: false,
9455
- titleText: '',
9456
- titleColor: '#FDFDFD',
9457
- titleFontSize: 12,
9458
- titleFontWeight: 400
9459
- },
9460
- grid: {
9461
- visible: true,
9462
- gridColor: '#404349',
9463
- gridWidth: 0.5
9464
- },
9465
- tick: {
9466
- visible: false,
9467
- tickInside: false,
9468
- tickSize: 4,
9469
- tickColor: '#4B4F54'
9470
- },
9471
- line: {
9472
- visible: false,
9473
- lineColor: '#4B4F54',
9474
- lineWidth: 1
9475
- }
9476
- };
9477
- const bandAxis = {
9478
- labelAutoHide: true,
9479
- labelAutoHideGap: 4,
9480
- labelAutoLimit: true,
9481
- labelAutoLimitLength: 80,
9482
- labelAutoRotate: false,
9483
- labelAutoRotateAngleRange: [
9484
- 0,
9485
- -45,
9486
- -90
9487
- ],
9488
- label: {
9489
- visible: true,
9490
- labelAngle: 0,
9491
- labelColor: '#E2E3E6',
9492
- labelFontSize: 12,
9493
- labelFontWeight: 400
9494
- },
9495
- title: {
9496
- visible: false,
9497
- titleText: '',
9498
- titleColor: '#FDFDFD',
9499
- titleFontSize: 12,
9500
- titleFontWeight: 400
9501
- },
9502
- grid: {
9503
- visible: false,
9504
- gridColor: '#404349',
9505
- gridWidth: 0.5
9506
- },
9507
- tick: {
9508
- visible: false,
9509
- tickInside: false,
9510
- tickSize: 4,
9511
- tickColor: '#4B4F54'
9512
- },
9513
- line: {
9514
- visible: true,
9515
- lineColor: '#4B4F54',
9516
- lineWidth: 1
9517
- }
9518
- };
9593
+ const linearAxis = getDarkLinearAxis();
9594
+ const bandAxis = getDarkBandAxis();
9519
9595
  const barBandAxis = {
9520
9596
  ...bandAxis,
9521
9597
  labelAutoHide: false,
@@ -9529,77 +9605,16 @@
9529
9605
  -90
9530
9606
  ]
9531
9607
  };
9532
- const crosshairLine = {
9533
- visible: true,
9534
- labelVisible: true,
9535
- lineColor: '#E2E3E6',
9536
- labelColor: '#4B4F54',
9537
- labelBackgroundColor: '#ffffff'
9538
- };
9539
- const crosshairRect = {
9540
- visible: true,
9541
- labelVisible: true,
9542
- lineColor: '#E2E3E6',
9543
- labelColor: '#4B4F54',
9544
- labelBackgroundColor: '#ffffff'
9545
- };
9608
+ const crosshairLine = getDarkCrosshairLine();
9609
+ const crosshairRect = getDarkCrosshairRect();
9546
9610
  const baseConfig = {
9547
9611
  backgroundColor: 'transparent',
9548
- color: {
9549
- linearColorScheme: [
9550
- '#A0CEFF',
9551
- '#2E62F1'
9552
- ],
9553
- colorScheme: [
9554
- '#2E62F1',
9555
- '#4DC36A',
9556
- '#FF8406',
9557
- '#FFCC00',
9558
- '#4F44CF',
9559
- '#5AC8FA',
9560
- '#003A8C',
9561
- '#B08AE2',
9562
- '#FF6341',
9563
- '#98DD62'
9564
- ]
9565
- },
9566
- label: {
9567
- enable: true,
9568
- wrap: true,
9569
- showValue: true,
9570
- showValuePercent: false,
9571
- labelColorSmartInvert: false,
9572
- labelOverlap: true
9573
- },
9574
- tooltip: {
9575
- enable: true
9576
- },
9577
- legend: {
9578
- enable: true,
9579
- border: true,
9580
- maxSize: 1,
9581
- position: 'rt',
9582
- shapeType: 'rectRound',
9583
- labelColor: '#FDFDFD',
9584
- labelFontSize: 12,
9585
- labelFontWeight: 400
9586
- }
9587
- };
9588
- const tableConfig = {
9589
- borderColor: '#4b4e53',
9590
- bodyFontSize: 12,
9591
- bodyFontColor: '#fdfdfd',
9592
- bodyBackgroundColor: 'transparent',
9593
- headerFontSize: 12,
9594
- headerFontColor: '#fdfdfd',
9595
- headerBackgroundColor: '#36393e',
9596
- hoverBodyBackgroundColor: '#4284ff66',
9597
- hoverBodyInlineBackgroundColor: '#4284ff10',
9598
- hoverHeaderBackgroundColor: '#6f7984cc',
9599
- hoverHeaderInlineBackgroundColor: '#4b4f54',
9600
- selectedBorderColor: '#3073f2',
9601
- selectedBackgroundColor: '#4284ff33'
9612
+ color: getDarkColor(),
9613
+ label: getDefaultLabel(),
9614
+ legend: getDefaultLegend(),
9615
+ tooltip: getDefaultTooltip()
9602
9616
  };
9617
+ const tableConfig = getDarkTableConfig();
9603
9618
  return {
9604
9619
  config: {
9605
9620
  table: tableConfig,
@@ -9696,6 +9711,11 @@
9696
9711
  },
9697
9712
  scatter: {
9698
9713
  ...baseConfig,
9714
+ crosshairLine,
9715
+ sizeRange: [
9716
+ 8,
9717
+ 24
9718
+ ],
9699
9719
  xAxis: {
9700
9720
  ...linearAxis,
9701
9721
  line: {
@@ -9710,11 +9730,11 @@
9710
9730
  visible: true
9711
9731
  }
9712
9732
  },
9713
- crosshairLine,
9714
- sizeRange: [
9715
- 8,
9716
- 24
9717
- ]
9733
+ label: {
9734
+ ...baseConfig.label,
9735
+ showValue: false,
9736
+ showValuePercent: false
9737
+ }
9718
9738
  },
9719
9739
  dualAxis: {
9720
9740
  ...baseConfig,
@@ -9737,7 +9757,8 @@
9737
9757
  label: {
9738
9758
  ...baseConfig.label,
9739
9759
  showValuePercent: true,
9740
- labelLayout: 'labelLine'
9760
+ labelLayout: 'labelLine',
9761
+ showDimension: true
9741
9762
  }
9742
9763
  },
9743
9764
  donut: {
@@ -9745,7 +9766,8 @@
9745
9766
  label: {
9746
9767
  ...baseConfig.label,
9747
9768
  showValuePercent: true,
9748
- labelLayout: 'labelLine'
9769
+ labelLayout: 'labelLine',
9770
+ showDimension: true
9749
9771
  }
9750
9772
  },
9751
9773
  radar: {
@@ -9755,14 +9777,16 @@
9755
9777
  ...baseConfig,
9756
9778
  label: {
9757
9779
  ...baseConfig.label,
9758
- showValuePercent: true
9780
+ showValuePercent: true,
9781
+ showDimension: true
9759
9782
  }
9760
9783
  },
9761
9784
  roseParallel: {
9762
9785
  ...baseConfig,
9763
9786
  label: {
9764
9787
  ...baseConfig.label,
9765
- showValuePercent: true
9788
+ showValuePercent: true,
9789
+ showDimension: true
9766
9790
  }
9767
9791
  },
9768
9792
  funnel: {
@@ -13482,6 +13506,7 @@
13482
13506
  wrap: schemas_boolean().nullish(),
13483
13507
  showValue: schemas_boolean().nullish(),
13484
13508
  showValuePercent: schemas_boolean().nullish(),
13509
+ showDimension: schemas_boolean().nullish(),
13485
13510
  autoFormat: schemas_boolean().nullish(),
13486
13511
  numFormat: zNumFormat.nullish(),
13487
13512
  labelFontSize: schemas_number().nullish(),
@@ -13847,7 +13872,7 @@
13847
13872
  selector: union([
13848
13873
  zSelector,
13849
13874
  zSelectors
13850
- ]),
13875
+ ]).nullish(),
13851
13876
  text: schemas_string().or(schemas_array(schemas_string())).nullish(),
13852
13877
  textColor: schemas_string().default('#ffffff').nullish(),
13853
13878
  textFontSize: schemas_number().default(12).nullish(),
@@ -13975,7 +14000,7 @@
13975
14000
  selector: union([
13976
14001
  zSelector,
13977
14002
  zSelectors
13978
- ]),
14003
+ ]).nullish(),
13979
14004
  textPosition: schemas_enum([
13980
14005
  'top',
13981
14006
  'topRight',