@orbcharts/plugins-basic 3.0.0-alpha.39 → 3.0.0-alpha.40

Sign up to get free protection for your applications and to get access to all the features.
Files changed (116) hide show
  1. package/dist/{src → orbcharts-plugins-basic/src}/base/BaseBarStack.d.ts +1 -1
  2. package/dist/{src → orbcharts-plugins-basic/src}/base/BaseBars.d.ts +1 -1
  3. package/dist/{src → orbcharts-plugins-basic/src}/base/BaseBarsTriangle.d.ts +1 -1
  4. package/dist/{src → orbcharts-plugins-basic/src}/base/BaseDots.d.ts +1 -1
  5. package/dist/{src → orbcharts-plugins-basic/src}/base/BaseLegend.d.ts +1 -0
  6. package/dist/orbcharts-plugins-basic/src/base/BaseLineAreas.d.ts +30 -0
  7. package/dist/{src → orbcharts-plugins-basic/src}/base/BaseLines.d.ts +1 -1
  8. package/dist/{src → orbcharts-plugins-basic/src}/grid/defaults.d.ts +2 -1
  9. package/dist/{src → orbcharts-plugins-basic/src}/grid/gridObservables.d.ts +2 -2
  10. package/dist/{src → orbcharts-plugins-basic/src}/grid/index.d.ts +1 -0
  11. package/dist/orbcharts-plugins-basic/src/grid/plugins/LineAreas.d.ts +1 -0
  12. package/dist/{src → orbcharts-plugins-basic/src}/grid/types.d.ts +5 -0
  13. package/dist/orbcharts-plugins-basic/src/index.d.ts +5 -0
  14. package/dist/{src → orbcharts-plugins-basic/src}/multiGrid/types.d.ts +1 -0
  15. package/dist/{src → orbcharts-plugins-basic/src}/series/types.d.ts +1 -0
  16. package/dist/{src → orbcharts-plugins-basic/src}/tree/types.d.ts +1 -0
  17. package/dist/{src → orbcharts-plugins-basic/src}/utils/orbchartsUtils.d.ts +7 -2
  18. package/dist/orbcharts-plugins-basic.es.js +7449 -7078
  19. package/dist/orbcharts-plugins-basic.umd.js +12 -9
  20. package/dist/src/index.d.ts +1 -5
  21. package/package.json +2 -2
  22. package/src/base/BaseBarStack.ts +7 -3
  23. package/src/base/BaseBars.ts +7 -3
  24. package/src/base/BaseBarsTriangle.ts +52 -135
  25. package/src/base/BaseDots.ts +7 -3
  26. package/src/base/BaseLegend.ts +16 -1
  27. package/src/base/BaseLineAreas.ts +625 -0
  28. package/src/base/BaseLines.ts +12 -12
  29. package/src/base/BaseValueAxis.ts +0 -1
  30. package/src/grid/defaults.ts +7 -0
  31. package/src/grid/gridObservables.ts +5 -5
  32. package/src/grid/index.ts +1 -0
  33. package/src/grid/plugins/BarStack.ts +1 -1
  34. package/src/grid/plugins/Bars.ts +1 -1
  35. package/src/grid/plugins/BarsDiverging.ts +1 -1
  36. package/src/grid/plugins/BarsTriangle.ts +1 -1
  37. package/src/grid/plugins/Dots.ts +1 -1
  38. package/src/grid/plugins/GroupAux.ts +8 -0
  39. package/src/grid/plugins/LineAreas.ts +37 -0
  40. package/src/grid/plugins/Lines.ts +1 -1
  41. package/src/grid/plugins/ScalingArea.ts +11 -7
  42. package/src/grid/types.ts +6 -1
  43. package/src/multiGrid/defaults.ts +2 -1
  44. package/src/multiGrid/multiGridObservables.ts +6 -6
  45. package/src/multiGrid/plugins/MultiBarStack.ts +1 -1
  46. package/src/multiGrid/plugins/MultiBars.ts +1 -1
  47. package/src/multiGrid/plugins/MultiBarsTriangle.ts +1 -1
  48. package/src/multiGrid/plugins/MultiDots.ts +1 -1
  49. package/src/multiGrid/plugins/MultiLines.ts +1 -1
  50. package/src/multiGrid/types.ts +1 -0
  51. package/src/noneData/defaults.ts +21 -7
  52. package/src/series/defaults.ts +1 -0
  53. package/src/series/types.ts +1 -0
  54. package/src/tree/defaults.ts +1 -0
  55. package/src/tree/plugins/TreeMap.ts +6 -4
  56. package/src/tree/types.ts +1 -0
  57. package/src/utils/orbchartsUtils.ts +22 -8
  58. package/tsconfig.json +4 -1
  59. /package/dist/{src → orbcharts-plugins-basic/src}/base/BaseGroupArea.d.ts +0 -0
  60. /package/dist/{src → orbcharts-plugins-basic/src}/base/BaseGroupAxis.d.ts +0 -0
  61. /package/dist/{src → orbcharts-plugins-basic/src}/base/BaseValueAxis.d.ts +0 -0
  62. /package/dist/{src → orbcharts-plugins-basic/src}/base/types.d.ts +0 -0
  63. /package/dist/{src → orbcharts-plugins-basic/src}/grid/plugins/BarStack.d.ts +0 -0
  64. /package/dist/{src → orbcharts-plugins-basic/src}/grid/plugins/Bars.d.ts +0 -0
  65. /package/dist/{src → orbcharts-plugins-basic/src}/grid/plugins/BarsDiverging.d.ts +0 -0
  66. /package/dist/{src → orbcharts-plugins-basic/src}/grid/plugins/BarsTriangle.d.ts +0 -0
  67. /package/dist/{src → orbcharts-plugins-basic/src}/grid/plugins/Dots.d.ts +0 -0
  68. /package/dist/{src → orbcharts-plugins-basic/src}/grid/plugins/GridLegend.d.ts +0 -0
  69. /package/dist/{src → orbcharts-plugins-basic/src}/grid/plugins/GroupAux.d.ts +0 -0
  70. /package/dist/{src → orbcharts-plugins-basic/src}/grid/plugins/GroupAxis.d.ts +0 -0
  71. /package/dist/{src → orbcharts-plugins-basic/src}/grid/plugins/Lines.d.ts +0 -0
  72. /package/dist/{src → orbcharts-plugins-basic/src}/grid/plugins/Ranking.d.ts +0 -0
  73. /package/dist/{src → orbcharts-plugins-basic/src}/grid/plugins/RankingAxis.d.ts +0 -0
  74. /package/dist/{src → orbcharts-plugins-basic/src}/grid/plugins/ScalingArea.d.ts +0 -0
  75. /package/dist/{src → orbcharts-plugins-basic/src}/grid/plugins/ValueAxis.d.ts +0 -0
  76. /package/dist/{src → orbcharts-plugins-basic/src}/grid/plugins/ValueStackAxis.d.ts +0 -0
  77. /package/dist/{src → orbcharts-plugins-basic/src}/multiGrid/defaults.d.ts +0 -0
  78. /package/dist/{src → orbcharts-plugins-basic/src}/multiGrid/index.d.ts +0 -0
  79. /package/dist/{src → orbcharts-plugins-basic/src}/multiGrid/multiGridObservables.d.ts +0 -0
  80. /package/dist/{src → orbcharts-plugins-basic/src}/multiGrid/plugins/MultiBarStack.d.ts +0 -0
  81. /package/dist/{src → orbcharts-plugins-basic/src}/multiGrid/plugins/MultiBars.d.ts +0 -0
  82. /package/dist/{src → orbcharts-plugins-basic/src}/multiGrid/plugins/MultiBarsTriangle.d.ts +0 -0
  83. /package/dist/{src → orbcharts-plugins-basic/src}/multiGrid/plugins/MultiDots.d.ts +0 -0
  84. /package/dist/{src → orbcharts-plugins-basic/src}/multiGrid/plugins/MultiGridLegend.d.ts +0 -0
  85. /package/dist/{src → orbcharts-plugins-basic/src}/multiGrid/plugins/MultiGroupAxis.d.ts +0 -0
  86. /package/dist/{src → orbcharts-plugins-basic/src}/multiGrid/plugins/MultiLines.d.ts +0 -0
  87. /package/dist/{src → orbcharts-plugins-basic/src}/multiGrid/plugins/MultiValueAxis.d.ts +0 -0
  88. /package/dist/{src → orbcharts-plugins-basic/src}/multiGrid/plugins/OverlappingValueAxes.d.ts +0 -0
  89. /package/dist/{src → orbcharts-plugins-basic/src}/multiValue/index.d.ts +0 -0
  90. /package/dist/{src → orbcharts-plugins-basic/src}/multiValue/plugins/Scatter.d.ts +0 -0
  91. /package/dist/{src → orbcharts-plugins-basic/src}/multiValue/plugins/ScatterAxes.d.ts +0 -0
  92. /package/dist/{src → orbcharts-plugins-basic/src}/noneData/defaults.d.ts +0 -0
  93. /package/dist/{src → orbcharts-plugins-basic/src}/noneData/index.d.ts +0 -0
  94. /package/dist/{src → orbcharts-plugins-basic/src}/noneData/plugins/Container.d.ts +0 -0
  95. /package/dist/{src → orbcharts-plugins-basic/src}/noneData/plugins/Tooltip.d.ts +0 -0
  96. /package/dist/{src → orbcharts-plugins-basic/src}/noneData/types.d.ts +0 -0
  97. /package/dist/{src → orbcharts-plugins-basic/src}/relationship/index.d.ts +0 -0
  98. /package/dist/{src → orbcharts-plugins-basic/src}/relationship/plugins/Relationship.d.ts +0 -0
  99. /package/dist/{src → orbcharts-plugins-basic/src}/series/defaults.d.ts +0 -0
  100. /package/dist/{src → orbcharts-plugins-basic/src}/series/index.d.ts +0 -0
  101. /package/dist/{src → orbcharts-plugins-basic/src}/series/plugins/Bubbles.d.ts +0 -0
  102. /package/dist/{src → orbcharts-plugins-basic/src}/series/plugins/Pie.d.ts +0 -0
  103. /package/dist/{src → orbcharts-plugins-basic/src}/series/plugins/PieEventTexts.d.ts +0 -0
  104. /package/dist/{src → orbcharts-plugins-basic/src}/series/plugins/PieLabels.d.ts +0 -0
  105. /package/dist/{src → orbcharts-plugins-basic/src}/series/plugins/SeriesLegend.d.ts +0 -0
  106. /package/dist/{src → orbcharts-plugins-basic/src}/series/plugins/Waffle.d.ts +0 -0
  107. /package/dist/{src → orbcharts-plugins-basic/src}/series/seriesUtils.d.ts +0 -0
  108. /package/dist/{src → orbcharts-plugins-basic/src}/tree/defaults.d.ts +0 -0
  109. /package/dist/{src → orbcharts-plugins-basic/src}/tree/index.d.ts +0 -0
  110. /package/dist/{src → orbcharts-plugins-basic/src}/tree/plugins/TreeLegend.d.ts +0 -0
  111. /package/dist/{src → orbcharts-plugins-basic/src}/tree/plugins/TreeMap.d.ts +0 -0
  112. /package/dist/{src → orbcharts-plugins-basic/src}/utils/commonUtils.d.ts +0 -0
  113. /package/dist/{src → orbcharts-plugins-basic/src}/utils/d3Graphics.d.ts +0 -0
  114. /package/dist/{src → orbcharts-plugins-basic/src}/utils/d3Utils.d.ts +0 -0
  115. /package/dist/{src → orbcharts-plugins-basic/src}/utils/observables.d.ts +0 -0
  116. /package/dist/{vite.config.d.ts → orbcharts-plugins-basic/vite.config.d.ts} +0 -0
@@ -11,7 +11,7 @@ interface BaseBarStackContext {
11
11
  selection: d3.Selection<any, unknown, any, unknown>;
12
12
  computedData$: Observable<ComputedDataGrid>;
13
13
  visibleComputedData$: Observable<ComputedDatumGrid[][]>;
14
- existedSeriesLabels$: Observable<string[]>;
14
+ existSeriesLabels$: Observable<string[]>;
15
15
  SeriesDataMap$: Observable<Map<string, ComputedDatumGrid[]>>;
16
16
  GroupDataMap$: Observable<Map<string, ComputedDatumGrid[]>>;
17
17
  fullParams$: Observable<BaseBarStackParams>;
@@ -12,7 +12,7 @@ interface BaseBarsContext {
12
12
  selection: d3.Selection<any, unknown, any, unknown>;
13
13
  computedData$: Observable<ComputedDataGrid>;
14
14
  visibleComputedData$: Observable<ComputedDatumGrid[][]>;
15
- existedSeriesLabels$: Observable<string[]>;
15
+ existSeriesLabels$: Observable<string[]>;
16
16
  SeriesDataMap$: Observable<Map<string, ComputedDatumGrid[]>>;
17
17
  GroupDataMap$: Observable<Map<string, ComputedDatumGrid[]>>;
18
18
  fullParams$: Observable<BaseBarsParams>;
@@ -12,7 +12,7 @@ interface BaseBarsContext {
12
12
  selection: d3.Selection<any, unknown, any, unknown>;
13
13
  computedData$: Observable<ComputedDataGrid>;
14
14
  visibleComputedData$: Observable<ComputedDatumGrid[][]>;
15
- existedSeriesLabels$: Observable<string[]>;
15
+ existSeriesLabels$: Observable<string[]>;
16
16
  SeriesDataMap$: Observable<Map<string, ComputedDatumGrid[]>>;
17
17
  GroupDataMap$: Observable<Map<string, ComputedDatumGrid[]>>;
18
18
  fullParams$: Observable<BaseBarsTriangleParams>;
@@ -13,7 +13,7 @@ interface BaseDotsContext {
13
13
  selection: d3.Selection<any, unknown, any, unknown>;
14
14
  computedData$: Observable<ComputedDataGrid>;
15
15
  visibleComputedData$: Observable<ComputedDatumGrid[][]>;
16
- existedSeriesLabels$: Observable<string[]>;
16
+ existSeriesLabels$: Observable<string[]>;
17
17
  SeriesDataMap$: Observable<Map<string, ComputedDatumGrid[]>>;
18
18
  GroupDataMap$: Observable<Map<string, ComputedDatumGrid[]>>;
19
19
  fullParams$: Observable<BaseDotsParams>;
@@ -8,6 +8,7 @@ export interface BaseLegendParams {
8
8
  padding: number;
9
9
  backgroundFill: ColorType;
10
10
  backgroundStroke: ColorType;
11
+ textColorType: ColorType;
11
12
  gap: number;
12
13
  seriesList: Array<{
13
14
  listRectWidth: number;
@@ -0,0 +1,30 @@
1
+ import { Observable, Subject } from 'rxjs';
2
+ import { BasePluginFn } from './types';
3
+ import { ComputedDatumGrid, ComputedDataGrid, DataFormatterGrid, EventGrid, ContainerPosition, ChartParams, Layout, TransformData } from '@orbcharts/core';
4
+ import * as d3 from 'd3';
5
+ export interface BaseLineAreasParams {
6
+ lineCurve: string;
7
+ linearGradientOpacity: [number, number];
8
+ }
9
+ interface BaseLineAreasContext {
10
+ selection: d3.Selection<any, unknown, any, unknown>;
11
+ computedData$: Observable<ComputedDataGrid>;
12
+ existSeriesLabels$: Observable<string[]>;
13
+ SeriesDataMap$: Observable<Map<string, ComputedDatumGrid[]>>;
14
+ GroupDataMap$: Observable<Map<string, ComputedDatumGrid[]>>;
15
+ fullDataFormatter$: Observable<DataFormatterGrid>;
16
+ fullParams$: Observable<BaseLineAreasParams>;
17
+ fullChartParams$: Observable<ChartParams>;
18
+ gridAxesTransform$: Observable<TransformData>;
19
+ gridGraphicTransform$: Observable<TransformData>;
20
+ gridAxesSize$: Observable<{
21
+ width: number;
22
+ height: number;
23
+ }>;
24
+ gridHighlight$: Observable<string[]>;
25
+ gridContainer$: Observable<ContainerPosition[]>;
26
+ layout$: Observable<Layout>;
27
+ event$: Subject<EventGrid>;
28
+ }
29
+ export declare const createBaseLineAreas: BasePluginFn<BaseLineAreasContext>;
30
+ export {};
@@ -9,7 +9,7 @@ export interface BaseLinesParams {
9
9
  interface BaseLinesContext {
10
10
  selection: d3.Selection<any, unknown, any, unknown>;
11
11
  computedData$: Observable<ComputedDataGrid>;
12
- existedSeriesLabels$: Observable<string[]>;
12
+ existSeriesLabels$: Observable<string[]>;
13
13
  SeriesDataMap$: Observable<Map<string, ComputedDatumGrid[]>>;
14
14
  GroupDataMap$: Observable<Map<string, ComputedDatumGrid[]>>;
15
15
  fullDataFormatter$: Observable<DataFormatterGrid>;
@@ -1,6 +1,7 @@
1
- import { LinesParams, GroupAuxParams, DotsParams, BarsParams, BarStackParams, BarsTriangleParams, GroupAxisParams, ValueAxisParams, ValueStackAxisParams, ScalingAreaParams, GridLegendParams } from './types';
1
+ import { LinesParams, LineAreasParams, GroupAuxParams, DotsParams, BarsParams, BarStackParams, BarsTriangleParams, GroupAxisParams, ValueAxisParams, ValueStackAxisParams, ScalingAreaParams, GridLegendParams } from './types';
2
2
 
3
3
  export declare const DEFAULT_LINES_PARAMS: LinesParams;
4
+ export declare const DEFAULT_LINE_AREAS_PARAMS: LineAreasParams;
4
5
  export declare const DEFAULT_DOTS_PARAMS: DotsParams;
5
6
  export declare const DEFAULT_GROUP_AREA_PARAMS: GroupAuxParams;
6
7
  export declare const DEFAULT_BARS_PARAMS: BarsParams;
@@ -1,11 +1,11 @@
1
1
  import { Observable } from 'rxjs';
2
2
  import { ChartParams, DataFormatterGrid, ComputedDataGrid, TransformData, ContainerPosition } from '@orbcharts/core';
3
3
  import * as d3 from 'd3';
4
- export declare const gridSelectionsObservable: ({ selection, pluginName, clipPathID, existedSeriesLabels$, gridContainer$, gridAxesTransform$, gridGraphicTransform$ }: {
4
+ export declare const gridSelectionsObservable: ({ selection, pluginName, clipPathID, existSeriesLabels$, gridContainer$, gridAxesTransform$, gridGraphicTransform$ }: {
5
5
  selection: d3.Selection<any, unknown, any, unknown>;
6
6
  pluginName: string;
7
7
  clipPathID: string;
8
- existedSeriesLabels$: Observable<string[]>;
8
+ existSeriesLabels$: Observable<string[]>;
9
9
  gridContainer$: Observable<ContainerPosition[]>;
10
10
  gridAxesTransform$: Observable<TransformData>;
11
11
  gridGraphicTransform$: Observable<TransformData>;
@@ -1,6 +1,7 @@
1
1
  export * from './defaults';
2
2
  export * from './types';
3
3
  export { Lines } from './plugins/Lines';
4
+ export { LineAreas } from './plugins/LineAreas';
4
5
  export { Bars } from './plugins/Bars';
5
6
  export { BarsDiverging } from './plugins/BarsDiverging';
6
7
  export { BarStack } from './plugins/BarStack';
@@ -0,0 +1 @@
1
+ export declare const LineAreas: import('@orbcharts/core').PluginConstructor<"grid", string, import('..').LineAreasParams>;
@@ -4,6 +4,10 @@ export interface LinesParams {
4
4
  lineCurve: string;
5
5
  lineWidth: number;
6
6
  }
7
+ export interface LineAreasParams {
8
+ lineCurve: string;
9
+ linearGradientOpacity: [number, number];
10
+ }
7
11
  export interface DotsParams {
8
12
  radius: number;
9
13
  fillColorType: ColorType;
@@ -83,4 +87,5 @@ export interface GridLegendParams {
83
87
  listRectWidth: number;
84
88
  listRectHeight: number;
85
89
  listRectRadius: number;
90
+ textColorType: ColorType;
86
91
  }
@@ -0,0 +1,5 @@
1
+ export * from './grid';
2
+ export * from './multiGrid';
3
+ export * from './noneData';
4
+ export * from './series';
5
+ export * from './tree';
@@ -26,6 +26,7 @@ export interface MultiGridLegendParams {
26
26
  listRectHeight: number;
27
27
  listRectRadius: number;
28
28
  }>;
29
+ textColorType: ColorType;
29
30
  }
30
31
  export interface MultiGroupAxisParams extends BaseGroupAxisParams {
31
32
  gridIndexes: number[];
@@ -53,4 +53,5 @@ export interface SeriesLegendParams {
53
53
  listRectWidth: number;
54
54
  listRectHeight: number;
55
55
  listRectRadius: number;
56
+ textColorType: ColorType;
56
57
  }
@@ -17,4 +17,5 @@ export interface TreeLegendParams {
17
17
  listRectWidth: number;
18
18
  listRectHeight: number;
19
19
  listRectRadius: number;
20
+ textColorType: ColorType;
20
21
  }
@@ -1,8 +1,13 @@
1
- import { AxisPosition, ColorType, ChartParams, ComputedDatumBase } from '@orbcharts/core';
1
+ import { AxisPosition, ColorType, ChartParams, ComputedDatumBase, ComputedDatumCategoryValue } from '@orbcharts/core';
2
2
 
3
3
  export declare function getMinAndMaxValue(data: ComputedDatumBase[]): [number, number];
4
4
  export declare function getColor(colorType: ColorType, fullChartParams: ChartParams): string;
5
- export declare function getSeriesColor(seriesIndex: number, fullChartParams: ChartParams): string;
5
+ export declare function getSeriesValueColor(): void;
6
+ export declare function getCategoryValueColor({ datum, colorType, fullChartParams }: {
7
+ datum: ComputedDatumCategoryValue;
8
+ colorType: ColorType;
9
+ fullChartParams: ChartParams;
10
+ }): void;
6
11
  export declare function getDatumColor({ datum, colorType, fullChartParams }: {
7
12
  datum: ComputedDatumBase;
8
13
  colorType: ColorType;