@univerjs-pro/engine-chart 1.0.0-alpha.3 → 1.0.0-alpha.4

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 (107) hide show
  1. package/lib/cjs/facade.js +1 -0
  2. package/lib/cjs/index.js +1 -1
  3. package/lib/es/facade.js +1 -0
  4. package/lib/es/index.js +1 -1
  5. package/lib/facade.js +1 -0
  6. package/lib/index.js +1 -1
  7. package/lib/types/chart-builder/chart-builder-adapter.d.ts +13 -0
  8. package/lib/types/chart-builder/chart-builder.d.ts +35 -0
  9. package/lib/types/chart-builder/chart-description.d.ts +3 -0
  10. package/lib/types/chart-builder/chart-types.d.ts +459 -0
  11. package/lib/types/chart-builder/configuration/aggregation.d.ts +7 -0
  12. package/lib/types/chart-builder/configuration/appearance.d.ts +8 -0
  13. package/lib/types/chart-builder/configuration/area.d.ts +3 -0
  14. package/lib/types/chart-builder/configuration/axes.d.ts +26 -0
  15. package/lib/types/chart-builder/configuration/axis-pointer.d.ts +9 -0
  16. package/lib/types/chart-builder/configuration/bar.d.ts +3 -0
  17. package/lib/types/chart-builder/configuration/cartesian-series.d.ts +25 -0
  18. package/lib/types/chart-builder/configuration/chart-config-operation.d.ts +40 -0
  19. package/lib/types/chart-builder/configuration/combination.d.ts +10 -0
  20. package/lib/types/chart-builder/configuration/funnel.d.ts +4 -0
  21. package/lib/types/chart-builder/configuration/heatmap.d.ts +9 -0
  22. package/lib/types/chart-builder/configuration/index.d.ts +29 -0
  23. package/lib/types/chart-builder/configuration/invalid-value.d.ts +3 -0
  24. package/lib/types/chart-builder/configuration/legend.d.ts +3 -0
  25. package/lib/types/chart-builder/configuration/line.d.ts +3 -0
  26. package/lib/types/chart-builder/configuration/mapping.d.ts +4 -0
  27. package/lib/types/chart-builder/configuration/mark-lines.d.ts +3 -0
  28. package/lib/types/chart-builder/configuration/palette.d.ts +4 -0
  29. package/lib/types/chart-builder/configuration/pareto.d.ts +7 -0
  30. package/lib/types/chart-builder/configuration/pie.d.ts +23 -0
  31. package/lib/types/chart-builder/configuration/point-mapping.d.ts +5 -0
  32. package/lib/types/chart-builder/configuration/radar.d.ts +5 -0
  33. package/lib/types/chart-builder/configuration/relation.d.ts +14 -0
  34. package/lib/types/chart-builder/configuration/subtitle.d.ts +3 -0
  35. package/lib/types/chart-builder/configuration/theme.d.ts +4 -0
  36. package/lib/types/chart-builder/configuration/title.d.ts +3 -0
  37. package/lib/types/chart-builder/configuration/trendline.d.ts +12 -0
  38. package/lib/types/chart-builder/configuration/waterfall.d.ts +12 -0
  39. package/lib/types/chart-builder/configuration/word-cloud.d.ts +7 -0
  40. package/lib/types/chart-builder/conversion/chart-config-converter.d.ts +24 -0
  41. package/lib/types/chart-builder/conversion/chart-model-fields.d.ts +115 -0
  42. package/lib/types/chart-builder/conversion/chart-type-converter.d.ts +6 -0
  43. package/lib/types/chart-builder/conversion/describe-chart-model.d.ts +11 -0
  44. package/lib/types/chart-builder/conversion/resolve-chart-model-data.d.ts +5 -0
  45. package/lib/types/chart-builder/detached-chart-builder-adapter.d.ts +19 -0
  46. package/lib/types/chart-builder/index.d.ts +12 -0
  47. package/lib/types/chart-builder/internal/deep-freeze.d.ts +1 -0
  48. package/lib/types/chart-builder/internal/host-builder-runtime.d.ts +5 -0
  49. package/lib/types/chart-builder/internal/merge-description.d.ts +2 -0
  50. package/lib/types/enum.d.ts +28 -0
  51. package/lib/types/facade/builders/f-area-chart-builder.d.ts +33 -0
  52. package/lib/types/facade/builders/f-bubble-chart-builder.d.ts +33 -0
  53. package/lib/types/facade/builders/f-combination-chart-builder.d.ts +66 -0
  54. package/lib/types/facade/builders/f-funnel-chart-builder.d.ts +61 -0
  55. package/lib/types/facade/builders/f-heatmap-chart-builder.d.ts +124 -0
  56. package/lib/types/facade/builders/f-line-chart-builder.d.ts +36 -0
  57. package/lib/types/facade/builders/f-pareto-chart-builder.d.ts +112 -0
  58. package/lib/types/facade/builders/f-pie-chart-builder.d.ts +324 -0
  59. package/lib/types/facade/builders/f-radar-chart-builder.d.ts +62 -0
  60. package/lib/types/facade/builders/f-relation-chart-builder.d.ts +184 -0
  61. package/lib/types/facade/builders/f-scatter-chart-builder.d.ts +33 -0
  62. package/lib/types/facade/builders/f-waterfall-chart-builder.d.ts +226 -0
  63. package/lib/types/facade/builders/f-word-cloud-chart-builder.d.ts +91 -0
  64. package/lib/types/facade/builders/index.d.ts +13 -0
  65. package/lib/types/facade/chart-builder-registry.d.ts +8 -0
  66. package/lib/types/facade/chart-builder-type-map.d.ts +30 -0
  67. package/lib/types/facade/chart-host-builder-types.d.ts +21 -0
  68. package/lib/types/facade/f-axis-chart-builder.d.ts +245 -0
  69. package/lib/types/facade/f-cartesian-chart-builder.d.ts +146 -0
  70. package/lib/types/facade/f-chart-base.d.ts +82 -0
  71. package/lib/types/facade/f-chart-builder-base.d.ts +331 -0
  72. package/lib/types/facade/f-charts-base.d.ts +74 -0
  73. package/lib/types/facade/f-enum.d.ts +75 -0
  74. package/lib/types/facade/index.d.ts +16 -0
  75. package/lib/types/facade/internal/chart-builder-facade-context.d.ts +12 -0
  76. package/lib/types/facade/internal/constants.d.ts +2 -0
  77. package/lib/types/facade/internal/host-builder-composer.d.ts +16 -0
  78. package/lib/types/facade/register-builders.d.ts +1 -0
  79. package/lib/types/index.d.ts +10 -54
  80. package/lib/types/models/chart-host-style.d.ts +6 -1
  81. package/lib/types/models/chart-model.d.ts +141 -18
  82. package/lib/types/models/chart-resource-serializer.d.ts +10 -0
  83. package/lib/types/models/chart-semantic-axes.d.ts +4 -0
  84. package/lib/types/models/constants/default-chart-style.d.ts +21 -1
  85. package/lib/types/models/mode-converter/converters/waterfall-layout.d.ts +34 -0
  86. package/lib/types/models/mode-converter/render-spec-operators/mark-line.operator.d.ts +3 -0
  87. package/lib/types/models/mode-converter/render-spec-operators/tools.d.ts +2 -3
  88. package/lib/types/source/chart-data-item.d.ts +3 -0
  89. package/lib/types/types.d.ts +61 -2
  90. package/lib/types/util.d.ts +1 -3
  91. package/lib/types/utils/compact.d.ts +4 -0
  92. package/lib/umd/facade.js +1 -0
  93. package/lib/umd/index.js +1 -1
  94. package/package.json +14 -4
  95. package/lib/types/chart-model-api/chart-model-api.d.ts +0 -2
  96. package/lib/types/chart-model-api/chart-type-manifest.d.ts +0 -128
  97. package/lib/types/chart-model-api/chart-type-registry.d.ts +0 -56
  98. package/lib/types/chart-model-api/chart-type.d.ts +0 -7
  99. package/lib/types/chart-model-api/constants.d.ts +0 -99
  100. package/lib/types/chart-model-api/describe.d.ts +0 -3
  101. package/lib/types/chart-model-api/index.d.ts +0 -8
  102. package/lib/types/chart-model-api/patch-builder.d.ts +0 -9
  103. package/lib/types/chart-model-api/series-selector.d.ts +0 -3
  104. package/lib/types/chart-model-api/types.d.ts +0 -452
  105. package/lib/types/chart-model-api/utils.d.ts +0 -10
  106. package/lib/types/chart-model-api/validate.d.ts +0 -5
  107. package/lib/types/f-base-chart.d.ts +0 -25
@@ -0,0 +1,331 @@
1
+ import type { ChartAggregationTarget, ChartAppearanceTarget, ChartBuilder, ChartDescription, ChartLegendSpec, ChartPendingConfig, ChartSubtitleSpec, ChartTitleSpec, IChartAggregationSpec, IChartAppearanceSpec, InvalidValueType } from '@univerjs-pro/engine-chart';
2
+ import type { IChartBuilderTypeMap } from './chart-builder-type-map';
3
+ import { FChartBase } from './f-chart-base';
4
+ export declare class FChartBuilderBase<TBuilder extends ChartBuilder = ChartBuilder, TDescription extends ChartDescription = ChartDescription> extends FChartBase<TDescription, TBuilder> {
5
+ protected _record(patch: ChartPendingConfig): this;
6
+ /**
7
+ * Sets the title configuration and returns this builder for chaining.
8
+ *
9
+ * This method executes synchronously.
10
+ *
11
+ * @param value The semantic value to record.
12
+ * @returns This builder for chaining.
13
+ * @example
14
+ * ```ts
15
+ * const worksheet = univerAPI.getActiveWorkbook().getActiveSheet();
16
+ * const builder = worksheet.charts.create();
17
+ * builder.setTitle({ text: 'Quarterly sales' });
18
+ * ```
19
+ */
20
+ setTitle(value: ChartTitleSpec): this;
21
+ /**
22
+ * Clears the title configuration and returns this builder for chaining.
23
+ *
24
+ * This method executes synchronously.
25
+ *
26
+ * @returns This builder for chaining.
27
+ * @example
28
+ * ```ts
29
+ * const worksheet = univerAPI.getActiveWorkbook().getActiveSheet();
30
+ * const builder = worksheet.charts.create();
31
+ * builder.clearTitle();
32
+ * ```
33
+ */
34
+ clearTitle(): this;
35
+ /**
36
+ * Sets the subtitle configuration and returns this builder for chaining.
37
+ *
38
+ * This method executes synchronously.
39
+ *
40
+ * @param value The semantic value to record.
41
+ * @returns This builder for chaining.
42
+ * @example
43
+ * ```ts
44
+ * const worksheet = univerAPI.getActiveWorkbook().getActiveSheet();
45
+ * const builder = worksheet.charts.create();
46
+ * builder.setSubtitle({ text: 'FY 2026' });
47
+ * ```
48
+ */
49
+ setSubtitle(value: ChartSubtitleSpec): this;
50
+ /**
51
+ * Clears the subtitle configuration and returns this builder for chaining.
52
+ *
53
+ * This method executes synchronously.
54
+ *
55
+ * @returns This builder for chaining.
56
+ * @example
57
+ * ```ts
58
+ * const worksheet = univerAPI.getActiveWorkbook().getActiveSheet();
59
+ * const builder = worksheet.charts.create();
60
+ * builder.clearSubtitle();
61
+ * ```
62
+ */
63
+ clearSubtitle(): this;
64
+ /**
65
+ * Sets the legend configuration and returns this builder for chaining.
66
+ *
67
+ * This method executes synchronously.
68
+ *
69
+ * @param value The semantic value to record.
70
+ * @returns This builder for chaining.
71
+ * @example
72
+ * ```ts
73
+ * const worksheet = univerAPI.getActiveWorkbook().getActiveSheet();
74
+ * const builder = worksheet.charts.create();
75
+ * builder.setLegend(true);
76
+ * ```
77
+ */
78
+ setLegend(value: ChartLegendSpec): this;
79
+ /**
80
+ * Clears the legend configuration and returns this builder for chaining.
81
+ *
82
+ * This method executes synchronously.
83
+ *
84
+ * @returns This builder for chaining.
85
+ * @example
86
+ * ```ts
87
+ * const worksheet = univerAPI.getActiveWorkbook().getActiveSheet();
88
+ * const builder = worksheet.charts.create();
89
+ * builder.clearLegend();
90
+ * ```
91
+ */
92
+ clearLegend(): this;
93
+ /**
94
+ * Sets the theme configuration and returns this builder for chaining.
95
+ *
96
+ * A non-empty chart palette takes precedence over the theme's series colors. This method does
97
+ * not clear that palette; call `clearPalette()` explicitly to use the selected theme colors.
98
+ *
99
+ * This method executes synchronously.
100
+ *
101
+ * @param name The stable registered name.
102
+ * @returns This builder for chaining.
103
+ * @example
104
+ * ```ts
105
+ * const fWorkbook = univerAPI.getActiveWorkbook();
106
+ * const fWorksheet = fWorkbook.getSheetByName('Sheet1');
107
+ * if (!fWorksheet) return;
108
+ * const builder = fWorksheet.charts.create();
109
+ * builder.setTheme('brand');
110
+ * ```
111
+ */
112
+ setTheme(name: string): this;
113
+ /**
114
+ * Clears the theme configuration and returns this builder for chaining.
115
+ *
116
+ * This method executes synchronously.
117
+ *
118
+ * @returns This builder for chaining.
119
+ * @example
120
+ * ```ts
121
+ * const fWorkbook = univerAPI.getActiveWorkbook();
122
+ * const fWorksheet = fWorkbook.getSheetByName('Sheet1');
123
+ * if (!fWorksheet) return;
124
+ * const builder = fWorksheet.charts.create();
125
+ * builder.clearTheme();
126
+ * ```
127
+ */
128
+ clearTheme(): this;
129
+ /**
130
+ * Sets absolute series palette colors and returns this builder for chaining.
131
+ *
132
+ * The values are copied, persisted with the chart, and used unchanged in light and dark mode.
133
+ * A non-empty palette takes precedence over the selected theme's series colors without clearing
134
+ * the selected theme. Call `clearPalette()` to return series-color control to the theme.
135
+ * An empty array has the same effect as `clearPalette()`.
136
+ *
137
+ * @param colors Ordered CSS colors that override the selected theme's series colors.
138
+ * @returns This builder for chaining.
139
+ * @example
140
+ * ```ts
141
+ * const fWorkbook = univerAPI.getActiveWorkbook();
142
+ * const fWorksheet = fWorkbook.getSheetByName('Sheet1');
143
+ * if (!fWorksheet) return;
144
+ * const builder = fWorksheet.charts.create();
145
+ * builder.setPalette(['#1677ff', '#52c41a']);
146
+ * ```
147
+ */
148
+ setPalette(colors: readonly string[]): this;
149
+ /**
150
+ * Clears the chart-owned palette and returns to the selected theme colors.
151
+ *
152
+ * @returns This builder for chaining.
153
+ * @example
154
+ * ```ts
155
+ * const fWorkbook = univerAPI.getActiveWorkbook();
156
+ * const fWorksheet = fWorkbook.getSheetByName('Sheet1');
157
+ * if (!fWorksheet) return;
158
+ * const builder = fWorksheet.charts.list()[0];
159
+ * builder.clearPalette().commit();
160
+ * ```
161
+ */
162
+ clearPalette(): this;
163
+ /**
164
+ * Sets the appearance configuration and returns this builder for chaining.
165
+ *
166
+ * Supported by Sheet, Document, Slide, and Board chart builders. An explicit
167
+ * `'transparent'` background remains transparent, and border width `0` hides
168
+ * the persisted host border without removing selection or transformer chrome.
169
+ *
170
+ * This method executes synchronously.
171
+ *
172
+ * @param value The semantic value to record.
173
+ * @returns This builder for chaining.
174
+ * @example
175
+ * ```ts
176
+ * builder.setAppearance({
177
+ * background: { color: 'transparent' },
178
+ * border: { width: 0 },
179
+ * });
180
+ * ```
181
+ */
182
+ setAppearance(value: IChartAppearanceSpec): this;
183
+ /**
184
+ * Clears the appearance configuration and returns this builder for chaining.
185
+ *
186
+ * This method executes synchronously.
187
+ *
188
+ * @param target The configuration field to clear or reset.
189
+ * @returns This builder for chaining.
190
+ * @example
191
+ * ```ts
192
+ * const worksheet = univerAPI.getActiveWorkbook().getActiveSheet();
193
+ * const builder = worksheet.charts.create();
194
+ * builder.clearAppearance(univerAPI.Enum.ChartAppearanceTarget.Background);
195
+ * ```
196
+ */
197
+ clearAppearance(target?: ChartAppearanceTarget): this;
198
+ /**
199
+ * Sets the invalid value strategy configuration and returns this builder for chaining.
200
+ *
201
+ * This method executes synchronously.
202
+ *
203
+ * @param value The semantic value to record.
204
+ * @returns This builder for chaining.
205
+ * @example
206
+ * ```ts
207
+ * const worksheet = univerAPI.getActiveWorkbook().getActiveSheet();
208
+ * const builder = worksheet.charts.create();
209
+ * builder.setInvalidValueStrategy(univerAPI.Enum.InvalidValueType.Break);
210
+ * ```
211
+ */
212
+ setInvalidValueStrategy(value: InvalidValueType): this;
213
+ /**
214
+ * Restores the invalid value strategy to `Break` and returns this builder for chaining.
215
+ *
216
+ * This method executes synchronously.
217
+ *
218
+ * @returns This builder for chaining.
219
+ * @example
220
+ * ```ts
221
+ * const worksheet = univerAPI.getActiveWorkbook().getActiveSheet();
222
+ * const builder = worksheet.charts.create();
223
+ * builder.resetInvalidValueStrategy();
224
+ * ```
225
+ */
226
+ resetInvalidValueStrategy(): this;
227
+ /**
228
+ * Sets the category field configuration and returns this builder for chaining.
229
+ *
230
+ * This method executes synchronously.
231
+ *
232
+ * @param index The zero-based field or series index.
233
+ * @returns This builder for chaining.
234
+ * @example
235
+ * ```ts
236
+ * const worksheet = univerAPI.getActiveWorkbook().getActiveSheet();
237
+ * const builder = worksheet.charts.create();
238
+ * builder.setCategoryField(0);
239
+ * ```
240
+ */
241
+ setCategoryField(index: number): this;
242
+ /**
243
+ * Clears the category field configuration and returns this builder for chaining.
244
+ *
245
+ * This method executes synchronously.
246
+ *
247
+ * @returns This builder for chaining.
248
+ * @example
249
+ * ```ts
250
+ * const worksheet = univerAPI.getActiveWorkbook().getActiveSheet();
251
+ * const builder = worksheet.charts.create();
252
+ * builder.clearCategoryField();
253
+ * ```
254
+ */
255
+ clearCategoryField(): this;
256
+ /**
257
+ * Sets the value fields configuration and returns this builder for chaining.
258
+ *
259
+ * This method executes synchronously.
260
+ *
261
+ * @param indexes The zero-based field indexes.
262
+ * @returns This builder for chaining.
263
+ * @example
264
+ * ```ts
265
+ * const worksheet = univerAPI.getActiveWorkbook().getActiveSheet();
266
+ * const builder = worksheet.charts.create();
267
+ * builder.setValueFields([1, 2]);
268
+ * ```
269
+ */
270
+ setValueFields(indexes: readonly number[]): this;
271
+ /**
272
+ * Clears the value fields configuration and returns this builder for chaining.
273
+ *
274
+ * This method executes synchronously.
275
+ *
276
+ * @returns This builder for chaining.
277
+ * @example
278
+ * ```ts
279
+ * const worksheet = univerAPI.getActiveWorkbook().getActiveSheet();
280
+ * const builder = worksheet.charts.create();
281
+ * builder.clearValueFields();
282
+ * ```
283
+ */
284
+ clearValueFields(): this;
285
+ /**
286
+ * Sets the aggregation configuration and returns this builder for chaining.
287
+ *
288
+ * This method executes synchronously.
289
+ *
290
+ * @param value The semantic value to record.
291
+ * @returns This builder for chaining.
292
+ * @example
293
+ * ```ts
294
+ * const worksheet = univerAPI.getActiveWorkbook().getActiveSheet();
295
+ * const builder = worksheet.charts.create();
296
+ * builder.setAggregation({ aggregate: true, topN: 10 });
297
+ * ```
298
+ */
299
+ setAggregation(value: IChartAggregationSpec): this;
300
+ /**
301
+ * Clears the aggregation configuration and returns this builder for chaining.
302
+ *
303
+ * This method executes synchronously.
304
+ *
305
+ * @param target The configuration field to clear or reset.
306
+ * @returns This builder for chaining.
307
+ * @example
308
+ * ```ts
309
+ * const worksheet = univerAPI.getActiveWorkbook().getActiveSheet();
310
+ * const builder = worksheet.charts.create();
311
+ * builder.clearAggregation(univerAPI.Enum.ChartAggregationTarget.TopN);
312
+ * ```
313
+ */
314
+ clearAggregation(target?: ChartAggregationTarget): this;
315
+ /**
316
+ * Sets the chart type and returns a builder specialized for that type.
317
+ *
318
+ * This method executes synchronously.
319
+ *
320
+ * @param type The canonical chart type.
321
+ * @returns A new specialized builder that shares this builder's pending configuration.
322
+ * @example
323
+ * ```ts
324
+ * const worksheet = univerAPI.getActiveWorkbook().getActiveSheet();
325
+ * const builder = worksheet.charts.create();
326
+ * const column = builder.setType(univerAPI.Enum.ChartTypeString.Column);
327
+ * ```
328
+ */
329
+ setType<T extends keyof IChartBuilderTypeMap>(type: T): IChartBuilderTypeMap[T];
330
+ protected _setType(type: keyof IChartBuilderTypeMap): void;
331
+ }
@@ -0,0 +1,74 @@
1
+ import type { IEchartTheme } from '@univerjs-pro/engine-chart';
2
+ export interface IChartBuilderHandle {
3
+ getId(): string;
4
+ }
5
+ export interface IChartBuilderHostTypes {
6
+ Initial: IChartBuilderHandle;
7
+ Any: IChartBuilderHandle;
8
+ }
9
+ export declare abstract class FChartsBase<TTypes extends IChartBuilderHostTypes> {
10
+ /**
11
+ * Creates a detached chart builder.
12
+ * @returns A detached builder that does not mutate the host until inserted.
13
+ * @example
14
+ * ```ts
15
+ * const charts = univerAPI.getActiveWorkbook().getActiveSheet().charts;
16
+ * const chart = charts.create();
17
+ * ```
18
+ */
19
+ abstract create(): TTypes['Initial'];
20
+ /**
21
+ * Inserts a detached chart builder into the current host.
22
+ * @param builder The detached builder returned by this collection.
23
+ * @returns The inserted builder, preserving its concrete chart and host APIs.
24
+ * @example
25
+ * ```ts
26
+ * const charts = univerAPI.getActiveWorkbook().getActiveSheet().charts;
27
+ * const chart = charts.create().setSource('A1:B6');
28
+ * await charts.insert(chart);
29
+ * ```
30
+ */
31
+ abstract insert<T extends TTypes['Any']>(builder: T): Promise<T>;
32
+ /**
33
+ * Returns a chart builder by chart ID.
34
+ * @param chartId The host-owned chart ID.
35
+ * @returns The chart builder, or `null` when the ID is not in this host.
36
+ * @example
37
+ * ```ts
38
+ * const chart = univerAPI.getActiveWorkbook().getActiveSheet().charts.get('chart-1');
39
+ * ```
40
+ */
41
+ abstract get(chartId: string): TTypes['Any'] | null;
42
+ /**
43
+ * Returns all chart builders in the current host.
44
+ * @returns The chart builders currently owned by this host.
45
+ * @example
46
+ * ```ts
47
+ * const charts = univerAPI.getActiveWorkbook().getActiveSheet().charts.list();
48
+ * ```
49
+ */
50
+ abstract list(): TTypes['Any'][];
51
+ /**
52
+ * Removes a chart by builder or chart ID.
53
+ * @param builderOrId A chart builder from this host or its chart ID.
54
+ * @returns Whether the host command removed the chart.
55
+ * @example
56
+ * ```ts
57
+ * const charts = univerAPI.getActiveWorkbook().getActiveSheet().charts;
58
+ * await charts.remove('chart-1');
59
+ * ```
60
+ */
61
+ abstract remove(builderOrId: TTypes['Any'] | string): Promise<boolean>;
62
+ /**
63
+ * Registers a chart theme in the shared Univer runtime registry.
64
+ * @param name The stable theme name used by `setTheme`.
65
+ * @param theme The ECharts theme definition.
66
+ * @example
67
+ * ```ts
68
+ * univerAPI.getActiveWorkbook().getActiveSheet().charts.registerTheme('brand', {
69
+ * color: ['#274060', '#1b998b'],
70
+ * });
71
+ * ```
72
+ */
73
+ abstract registerTheme(name: string, theme: IEchartTheme): void;
74
+ }
@@ -0,0 +1,75 @@
1
+ import { AreaLineStyle, ChartAggregationTarget, ChartAllSeriesStyleTarget, ChartAppearanceTarget, ChartAxisDimension, ChartAxisName, ChartAxisPointerTarget, ChartAxisTarget, ChartAxisTickPosition, ChartMarkLineLabelPosition, ChartSemanticAxis, ChartSeriesAxis, ChartSeriesClearTarget, ChartSeriesTypeString, ChartTrendlineType, ChartTypeString, ChartVisualMapType, ChartWaterfallPointRole, ChartWaterfallStyleTarget, ChartWordCloudShapeSource, InvalidValueType, LabelAlignEnum, LegendPositionEnum, LinePointShape, PieLabelPosition, RadarShape, RelationChartLayoutEnum, SelectModeEnum, SeriesLabelPosition, TitlePositionEnum, WaterfallStackTypeEnum, WordCloudShapeEnum } from '@univerjs-pro/engine-chart';
2
+ import { FEnum } from '@univerjs/core/facade';
3
+ /** @ignore */
4
+ export interface IFChartEnumMixin {
5
+ ChartAggregationTarget: typeof ChartAggregationTarget;
6
+ ChartAxisDimension: typeof ChartAxisDimension;
7
+ ChartTrendlineType: typeof ChartTrendlineType;
8
+ ChartAppearanceTarget: typeof ChartAppearanceTarget;
9
+ ChartAxisName: typeof ChartAxisName;
10
+ ChartAxisPointerTarget: typeof ChartAxisPointerTarget;
11
+ ChartAxisTarget: typeof ChartAxisTarget;
12
+ ChartAxisTickPosition: typeof ChartAxisTickPosition;
13
+ ChartMarkLineLabelPosition: typeof ChartMarkLineLabelPosition;
14
+ ChartSemanticAxis: typeof ChartSemanticAxis;
15
+ ChartSeriesAxis: typeof ChartSeriesAxis;
16
+ ChartSeriesClearTarget: typeof ChartSeriesClearTarget;
17
+ ChartAllSeriesStyleTarget: typeof ChartAllSeriesStyleTarget;
18
+ ChartSeriesTypeString: typeof ChartSeriesTypeString;
19
+ ChartTypeString: typeof ChartTypeString;
20
+ ChartVisualMapType: typeof ChartVisualMapType;
21
+ ChartWaterfallStyleTarget: typeof ChartWaterfallStyleTarget;
22
+ ChartWaterfallPointRole: typeof ChartWaterfallPointRole;
23
+ ChartWordCloudShapeSource: typeof ChartWordCloudShapeSource;
24
+ AreaLineStyle: typeof AreaLineStyle;
25
+ InvalidValueType: typeof InvalidValueType;
26
+ LabelAlignEnum: typeof LabelAlignEnum;
27
+ LegendPositionEnum: typeof LegendPositionEnum;
28
+ LinePointShape: typeof LinePointShape;
29
+ PieLabelPosition: typeof PieLabelPosition;
30
+ RadarShape: typeof RadarShape;
31
+ RelationChartLayoutEnum: typeof RelationChartLayoutEnum;
32
+ SelectModeEnum: typeof SelectModeEnum;
33
+ SeriesLabelPosition: typeof SeriesLabelPosition;
34
+ TitlePositionEnum: typeof TitlePositionEnum;
35
+ WaterfallStackTypeEnum: typeof WaterfallStackTypeEnum;
36
+ WordCloudShapeEnum: typeof WordCloudShapeEnum;
37
+ }
38
+ export declare class FChartEnumMixin extends FEnum implements IFChartEnumMixin {
39
+ get ChartAggregationTarget(): typeof ChartAggregationTarget;
40
+ get ChartAxisDimension(): typeof ChartAxisDimension;
41
+ get ChartTrendlineType(): typeof ChartTrendlineType;
42
+ get ChartAppearanceTarget(): typeof ChartAppearanceTarget;
43
+ get ChartAxisName(): typeof ChartAxisName;
44
+ get ChartAxisPointerTarget(): typeof ChartAxisPointerTarget;
45
+ get ChartAxisTarget(): typeof ChartAxisTarget;
46
+ get ChartAxisTickPosition(): typeof ChartAxisTickPosition;
47
+ get ChartMarkLineLabelPosition(): typeof ChartMarkLineLabelPosition;
48
+ get ChartSemanticAxis(): typeof ChartSemanticAxis;
49
+ get ChartSeriesAxis(): typeof ChartSeriesAxis;
50
+ get ChartSeriesClearTarget(): typeof ChartSeriesClearTarget;
51
+ get ChartAllSeriesStyleTarget(): typeof ChartAllSeriesStyleTarget;
52
+ get ChartSeriesTypeString(): typeof ChartSeriesTypeString;
53
+ get ChartTypeString(): typeof ChartTypeString;
54
+ get ChartVisualMapType(): typeof ChartVisualMapType;
55
+ get ChartWaterfallStyleTarget(): typeof ChartWaterfallStyleTarget;
56
+ get ChartWaterfallPointRole(): typeof ChartWaterfallPointRole;
57
+ get ChartWordCloudShapeSource(): typeof ChartWordCloudShapeSource;
58
+ get AreaLineStyle(): typeof AreaLineStyle;
59
+ get InvalidValueType(): typeof InvalidValueType;
60
+ get LabelAlignEnum(): typeof LabelAlignEnum;
61
+ get LegendPositionEnum(): typeof LegendPositionEnum;
62
+ get LinePointShape(): typeof LinePointShape;
63
+ get PieLabelPosition(): typeof PieLabelPosition;
64
+ get RadarShape(): typeof RadarShape;
65
+ get RelationChartLayoutEnum(): typeof RelationChartLayoutEnum;
66
+ get SelectModeEnum(): typeof SelectModeEnum;
67
+ get SeriesLabelPosition(): typeof SeriesLabelPosition;
68
+ get TitlePositionEnum(): typeof TitlePositionEnum;
69
+ get WaterfallStackTypeEnum(): typeof WaterfallStackTypeEnum;
70
+ get WordCloudShapeEnum(): typeof WordCloudShapeEnum;
71
+ }
72
+ declare module '@univerjs/core/facade' {
73
+ interface FEnum extends IFChartEnumMixin {
74
+ }
75
+ }
@@ -0,0 +1,16 @@
1
+ import './register-builders';
2
+ import './f-enum';
3
+ export * from './builders';
4
+ export { getChartBuilderConstructor } from './chart-builder-registry';
5
+ export type { IChartBuilderTypeMap } from './chart-builder-type-map';
6
+ export type { HostAnyChartBuilder, HostChartBuilderOf, HostComposedChartBuilder, IHostChartBuilderTypes } from './chart-host-builder-types';
7
+ export { FAxisChartBuilder } from './f-axis-chart-builder';
8
+ export { FCartesianChartBuilder } from './f-cartesian-chart-builder';
9
+ export { FChartBase } from './f-chart-base';
10
+ export { FChartBuilderBase } from './f-chart-builder-base';
11
+ export { FChartsBase } from './f-charts-base';
12
+ export type { IChartBuilderHostTypes } from './f-charts-base';
13
+ export { getChartBuilderPendingConfig } from './internal/chart-builder-facade-context';
14
+ export { CHART_FACADE_RANDOM_ID_LENGTH } from './internal/constants';
15
+ export { HostBuilderComposer } from './internal/host-builder-composer';
16
+ export type { EngineChartBuilderConstructor } from './internal/host-builder-composer';
@@ -0,0 +1,12 @@
1
+ import type { ChartBuilder } from '@univerjs-pro/engine-chart';
2
+ export type ChartFacadeBuilderConstructor<TFacade = unknown> = new (context: IChartBuilderFacadeContext) => TFacade;
3
+ /** Facade-owned wrapping context for one shared chart builder instance. */
4
+ export interface IChartBuilderFacadeContext<TBuilder extends ChartBuilder = ChartBuilder> {
5
+ readonly builder: TBuilder;
6
+ wrap<TFacade>(Constructor: ChartFacadeBuilderConstructor<TFacade>): TFacade;
7
+ }
8
+ export declare const ChartBuilderFacadeContextAccess: unique symbol;
9
+ export interface IChartBuilderFacadeContextAccess {
10
+ readonly [ChartBuilderFacadeContextAccess]: IChartBuilderFacadeContext;
11
+ }
12
+ export declare function wrapChartBuilder<TFacade>(builder: ChartBuilder, Constructor: ChartFacadeBuilderConstructor<TFacade>): TFacade;
@@ -0,0 +1,2 @@
1
+ /** Length used for facade-generated chart, data-source, and host element IDs. */
2
+ export declare const CHART_FACADE_RANDOM_ID_LENGTH = 6;
@@ -0,0 +1,16 @@
1
+ import type { ChartBuilder } from '@univerjs-pro/engine-chart';
2
+ import type { HostComposedChartBuilder } from '../chart-host-builder-types';
3
+ import type { FChartBuilderBase } from '../f-chart-builder-base';
4
+ import type { IChartBuilderFacadeContext } from './chart-builder-facade-context';
5
+ export type EngineChartBuilderConstructor<TBuilder extends FChartBuilderBase = FChartBuilderBase> = new (context: IChartBuilderFacadeContext) => TBuilder;
6
+ export declare class HostBuilderComposer<THostMethods extends object> {
7
+ private readonly _compose;
8
+ private readonly _cache;
9
+ constructor(_compose: (Constructor: EngineChartBuilderConstructor) => EngineChartBuilderConstructor<FChartBuilderBase & THostMethods>);
10
+ compose<TBuilder extends FChartBuilderBase>(Constructor: EngineChartBuilderConstructor<TBuilder>): EngineChartBuilderConstructor<TBuilder & THostMethods>;
11
+ /**
12
+ * Creates a host-composed builder whose Facade context preserves host methods
13
+ * when `setType()` selects another concrete builder class.
14
+ */
15
+ create<TBuilder extends FChartBuilderBase>(builder: ChartBuilder, Constructor: EngineChartBuilderConstructor<TBuilder>): HostComposedChartBuilder<TBuilder, THostMethods>;
16
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -1,58 +1,12 @@
1
- export { chartModelApi } from './chart-model-api/chart-model-api';
2
- export { buildDonutStyle } from './chart-model-api/chart-type';
3
- export { chartTypeBitsToName } from './chart-model-api/chart-type';
4
- export { chartTypeNameToBits } from './chart-model-api/chart-type';
5
- export { UNSUPPORTED_CHART_TYPE_NAME } from './chart-model-api/chart-type-registry';
6
- export { CHART_MODEL_API_CAPABILITIES_VERSION } from './chart-model-api/constants';
7
- export { CHART_MODEL_DEFAULT_DONUT_HOLE } from './chart-model-api/constants';
8
- export { CHART_MODEL_PATCH_SEMANTICS } from './chart-model-api/constants';
9
- export { CHART_MODEL_UNSUPPORTED_TYPE_SUGGESTION } from './chart-model-api/constants';
10
- export { ChartModelChangedGroup } from './chart-model-api/constants';
11
- export { ChartModelDiagnosticCode } from './chart-model-api/constants';
12
- export { ChartModelPatchGroup } from './chart-model-api/constants';
13
- export { ChartModelPatchSemantic } from './chart-model-api/constants';
14
- export { buildChartModelConfigPatch, buildCreateChartModelConfigPatch } from './chart-model-api/patch-builder';
15
- export type { ChartAdvancedStylePatch } from './chart-model-api/types';
16
- export type { ChartAggregationSpec } from './chart-model-api/types';
17
- export type { ChartAppearanceSpec } from './chart-model-api/types';
18
- export type { ChartAxesSpec } from './chart-model-api/types';
19
- export type { ChartAxisSpec } from './chart-model-api/types';
20
- export type { ChartKnownTypeName } from './chart-model-api/types';
21
- export type { ChartLegendSpec } from './chart-model-api/types';
22
- export type { ChartMappingSpec } from './chart-model-api/types';
23
- export type { ChartModelApi } from './chart-model-api/types';
24
- export type { ChartModelCapabilities } from './chart-model-api/types';
25
- export type { ChartModelConfigPatch } from './chart-model-api/types';
26
- export type { ChartModelCreateSpec } from './chart-model-api/types';
27
- export type { ChartModelDescription } from './chart-model-api/types';
28
- export type { ChartModelDiagnostic } from './chart-model-api/types';
29
- export type { ChartModelInstanceCapabilities } from './chart-model-api/types';
30
- export type { ChartModelPatch } from './chart-model-api/types';
31
- export type { ChartModelPatchSemantics } from './chart-model-api/types';
32
- export type { ChartModelUpdateResult } from './chart-model-api/types';
33
- export type { ChartParetoSpec } from './chart-model-api/types';
34
- export type { ChartPieSpec } from './chart-model-api/types';
35
- export type { ChartRadarSpec } from './chart-model-api/types';
36
- export type { ChartSeriesDescription } from './chart-model-api/types';
37
- export type { ChartSeriesPatch } from './chart-model-api/types';
38
- export type { ChartSeriesSelector } from './chart-model-api/types';
39
- export type { ChartTitleSpec } from './chart-model-api/types';
40
- export type { ChartTypeName } from './chart-model-api/types';
41
- export type { ChartValidationResult } from './chart-model-api/types';
42
- export type { ChartWordCloudDescription } from './chart-model-api/types';
43
- export type { ChartWordCloudSpec } from './chart-model-api/types';
44
- export type { DeepReadonly } from './chart-model-api/types';
45
- export { createChartModelDiagnostic } from './chart-model-api/utils';
46
- export { hasChartModelDiagnosticError } from './chart-model-api/utils';
47
- export { validateChartModelCreateSpec } from './chart-model-api/validate';
48
- export { validateChartModelPatch } from './chart-model-api/validate';
49
- export { AreaLineStyle, AxisAlignEnum, AxisValueType, CategoryType, ChartAttributeBits, ChartBorderDashType, ChartSourceDataTypeEnum, ChartTrendlineType, ChartTypeBits, DataOrientation, InvalidValueType, IRuntimeAxisPosition, IRuntimeAxisPriority, LabelAlignEnum, LabelContentType, LegendPositionEnum, LinePointShape, ParetoSeriesIndex, ParetoSeriesPart, PieLabelPosition, RadarShape, RelationChartLayoutEnum, SelectModeEnum, SeriesLabelPosition, StackType, TextAlign, TextVerticalAlign, TitlePositionEnum, WaterfallSeriesTypeEnum, WaterfallStackTypeEnum, WordCloudShapeEnum, } from './enum';
50
- export type { FAnyChartDescription, FChartDescription, FChartUpdateResult, } from './f-base-chart';
51
- export { FBaseChart, FBaseCharts, } from './f-base-chart';
1
+ export type { ChartDescription, ChartLegendSpec, ChartPublicSeriesSelector, ChartSeriesSelector, ChartSeriesTrendlineSelector, ChartSubtitleSpec, ChartTitleSpec, IChartAggregationSpec, IChartAppearanceSpec, IChartAreaSpec, IChartAxesSpec, IChartAxisBindingDescription, IChartAxisLabelSpec, IChartAxisPointerSpec, IChartAxisSpec, IChartBarSpec, IChartBubbleMappingSpec, IChartDescription, IChartFontSpec, IChartFunnelSpec, IChartHeatmapLabelSpec, IChartHeatmapSpec, IChartLegendOptions, IChartMappingSpec, IChartMarkLineLabelSpec, IChartMarkLineSpec, IChartParetoBarLabelStyleSpec, IChartParetoBarStyleSpec, IChartParetoBorderStyleSpec, IChartParetoLineLabelStyleSpec, IChartParetoLineStyleSpec, IChartParetoPointStyleSpec, IChartParetoSpec, IChartPieLabelSpec, IChartPieSpec, IChartRadarSpec, IChartRelationForceSpec, IChartRelationSpec, IChartScatterMappingSpec, IChartSeriesBorderSpec, IChartSeriesDescription, IChartSeriesLabelSpec, IChartSeriesPatch, IChartSeriesPointSpec, IChartSeriesStyleSpec, IChartSubtitleOptions, IChartTitleOptions, IChartTrendlineSpec, IChartWaterfallConnectorStyleSpec, IChartWaterfallPointRoleSpec, IChartWaterfallSpec, IChartWordCloudDescription, IChartWordCloudSpec, IInlineChartBuilderAdapter, IInlineChartHostPatch, IResolvedChartData, } from './chart-builder';
2
+ export { AREA_CHART_TYPES, AXIS_CHART_TYPES, CARTESIAN_CHART_TYPES, ChartAggregationTarget, ChartAllSeriesStyleTarget, ChartAppearanceTarget, ChartAxisName, ChartAxisPointerTarget, ChartAxisTarget, ChartAxisTickPosition, ChartSeriesAxis, ChartSeriesClearTarget, ChartSeriesTypeString, ChartTypeString, ChartVisualMapType, ChartWaterfallStyleTarget, ChartWordCloudShapeSource, DEFAULT_CHART_TYPE, } from './chart-builder';
3
+ export { ChartBuilder, chartTypeToBits, clearAggregation, clearAllSeriesStyle, clearAppearance, clearAreaLineStyle, clearAxisPointer, clearAxisTitle, clearBar, clearBubbleMapping, clearCategoryField, clearCellLabel, clearCumulativeLineStyle, clearDoughnutHole, clearLegend, clearLineStyle, clearMarkLines, clearPalette, clearMaskImage, clearParetoBarStyle, clearPieLabel, clearRelationForce, clearRightYAxis, clearScatterMapping, clearSeries, clearSliceBorderColor, clearSubtitle, clearTheme, clearTitle, clearTrendlines, clearValueFields, clearValueRange, clearValueSuffix, clearValueUnit, clearWaterfallConnector, clearWaterfallStyle, clearXAxis, clearYAxis, describeChartModel, DetachedChartBuilderAdapter, InlineChartBuilder, removeTrendline, resetCircularLabelRotation, resetCombinationSeriesAxis, resetCombinationSeriesType, resetDecimalPlaces, resetEmphasisEnabled, resetExplosion, resetFunnelGap, resetHalfPie, resetIncludeZeroValues, resetInvalidValueStrategy, resetLabelLineVisible, resetPaddingAngleEnabled, resetRadarFill, resetRadarShape, resetRelationLayout, resetRelationNodeShape, resetRosePie, resetUseAbsoluteValue, resetUseDateAxis, resetUseSubtotal, resetUseValueAsSymbolSize, resetValueScale, resetVisualMapType, resetWaterfallStackType, resetWordCloudRepeat, resetWordCloudShape, resolveChartDescriptionMetadata, resolveChartModelData, resolveInlineChartDataSet, setAggregation, setAllSeriesStyle, setAppearance, setAreaLineStyle, setAxisPointer, setAxisTitle, setBar, setBubbleMapping, setCategoryField, setCellLabel, setCircularLabelRotation, setCombinationSeriesAxis, setCombinationSeriesType, setCumulativeLineStyle, setDecimalPlaces, setDoughnutHole, setEmphasisEnabled, setExplosion, setFunnelGap, setHalfPie, setIncludeZeroValues, setInvalidValueStrategy, setLabelLineVisible, setLegend, setLineStyle, setMarkLines, setMaskImage, setPaddingAngleEnabled, setPalette, setParetoBarStyle, setPieLabel, setRadarFill, setRadarShape, setRelationForce, setRelationLayout, setRelationNodeShape, setRightYAxis, setRosePie, setScatterMapping, setSeries, setSliceBorderColor, setSubtitle, setTheme, setTitle, setTrendline, setUseAbsoluteValue, setUseDateAxis, setUseSubtotal, setUseValueAsSymbolSize, setValueFields, setValueRange, setValueScale, setValueSuffix, setValueUnit, setVisualMapType, setWaterfallConnector, setWaterfallPointRoles, setWaterfallStackType, setWaterfallStyle, setWordCloudRepeat, setWordCloudShape, setXAxis, setYAxis, toChartModelConfig, toCompleteChartModelConfig, } from './chart-builder';
4
+ export type { ChartPendingConfig, ChartTrendlineSelector, ChartTrendlineValue, IChartBuilderAdapter, IChartCreateConfig, } from './chart-builder';
5
+ export { AreaLineStyle, BarShape, AxisAlignEnum, AxisValueType, CategoryType, ChartAttributeBits, ChartAxisDimension, ChartBorderDashType, ChartMarkLineLabelPosition, ChartSemanticAxis, ChartSourceDataTypeEnum, ChartTrendlineType, ChartTypeBits, ChartWaterfallPointRole, DataOrientation, InvalidValueType, IRuntimeAxisPosition, IRuntimeAxisPriority, LabelAlignEnum, LabelContentType, LegendPositionEnum, LinePointShape, ParetoSeriesIndex, ParetoSeriesPart, PieLabelPosition, RadarShape, RelationChartLayoutEnum, SelectModeEnum, SeriesLabelPosition, StackType, TextAlign, TextVerticalAlign, TitlePositionEnum, WaterfallSeriesTypeEnum, WaterfallStackTypeEnum, WordCloudShapeEnum, } from './enum';
52
6
  export { buildChartData, RelationColumnIndex } from './models/chart-data-operators/build-chart-data';
53
7
  export { CartesianPointRoleIndex, CartesianPointValueIndex } from './models/chart-data-operators/cartesian-point-data';
54
8
  export { defaultChartContextOperators, findCategoryIndexes, findCategoryOperator, findHeaderOperator, findSeriesOperator, generateChartModelContextByOperators, pieSeriesFilterOperator, } from './models/chart-data-operators/operators';
55
- export { CHART_HOST_DEFAULT_BORDER_COLOR, CHART_HOST_DEFAULT_BORDER_RADIUS, CHART_HOST_DEFAULT_BORDER_WIDTH, composeChartHostFrameImage, getChartHostFrameContentRect, resolveDefaultChartHostFrameStyle, resolveChartHostFrameStyle, shouldComposeChartHostFrame, } from './models/chart-host-style';
9
+ export { CHART_HOST_DEFAULT_BORDER_COLOR, CHART_HOST_DEFAULT_BORDER_RADIUS, CHART_HOST_DEFAULT_BORDER_WIDTH, composeChartHostFrameImage, getChartHostFrameContentRect, resolveChartHostFrameBorder, resolveChartHostFrameStyle, resolveDefaultChartHostFrameStyle, shouldComposeChartHostFrame, } from './models/chart-host-style';
56
10
  export type { IResolveChartHostFrameStyleInput, IResolveDefaultChartHostFrameStyleInput, } from './models/chart-host-style';
57
11
  export type { IChartLocaleTexts } from './models/chart-locale-texts';
58
12
  export { getDefaultChartLocaleTexts, replaceLocaleParams } from './models/chart-locale-texts';
@@ -60,6 +14,7 @@ export { CHART_DEBOUNCE_TIME, ChartModel, } from './models/chart-model';
60
14
  export { resolveChartRenderModelImageExportInput } from './models/chart-render-input-resolver';
61
15
  export type { IChartRenderInputRuntime, IResolveChartRenderModelImageExportInputParams, } from './models/chart-render-input-resolver';
62
16
  export { ChartRenderModelManagerService, IChartRenderModelManagerService, registerChartRenderModelManagerService, } from './models/chart-render-model-manager.service';
17
+ export { serializeChartResource } from './models/chart-resource-serializer';
63
18
  export { resolveChartRuntimeStyle, resolveChartStyleBackgroundColor, } from './models/chart-runtime-style';
64
19
  export { ChartThemeService, registerChartThemeService, } from './models/chart-theme.service';
65
20
  export { getThemeAxesByType } from './models/constants/build-in-theme';
@@ -76,11 +31,12 @@ export type { IChartModelInitParams } from './models/mode-converter/mode-convert
76
31
  export { convertModelFromInitData, convertModelToSpec, } from './models/mode-converter/mode-converter';
77
32
  export { OffscreenChartHost } from './models/offscreen-chart-host';
78
33
  export { registerWordCloudChartMakImageService, WordCloudMuskImageService, } from './models/word-cloud-musk-image.service';
34
+ export { toChartDataItem } from './source/chart-data-item';
79
35
  export { ChartDataSource } from './source/chart-source';
80
36
  export { StaticChartSource } from './source/static-chart-source';
81
37
  export { ChartHostRenderMode, ChartImageSourceType } from './types';
82
- export type { ChartDataSourceValue, ChartDataSourceValues, ChartDirection, ChartElementEventHandler, ChartElementEventType, ChartElementKind, ChartImageSource, ChartStyle, DeepPartial, DimensionDefinitionLoose, IAllSeriesStyle, IAxisOptions, IChartConfig, IChartContext, IChartData, IChartDataAggregation, IChartDataCategory, IChartDataSeries, IChartDataSource, IChartElementBounds, IChartElementEvent, IChartElementHit, IChartElementOverlay, IChartHost, IChartHostBorderStyle, IChartHostLease, IChartHostRect, IChartHostStyle, IChartInstance, IChartRenderAsImageOptions, IChartRenderInput, IChartRenderInstance, IChartRenderInstanceCreateContext, IChartRenderInstanceSpecInput, IChartRenderInstanceStyleInput, IChartRenderModel, IChartRenderModelImageExportInput, IChartRenderModelImageExportOptions, IChartRenderModelImageExportResult, IChartSnapshot, IChartStyle, IDimensionDefinition, IDomChartHost, IGridLineStyle, IImageChartHost, ILabelStyle, ILegendStyle, IPieLabelStyle, IPointStyle, IRelationForceOptions, IRuntimeAxis, ISeriesLabelStyle, ISeriesStyle, ITrendLine, IUniverDataSet, OptionDataValue, RightYAxisOptions, } from './types';
83
- export { chartBitsUtils, chartTypeCanUseTrendLine, } from './util';
38
+ export type { ChartDataSourceValue, ChartDataSourceValues, ChartDirection, ChartElementEventHandler, ChartElementEventType, ChartElementKind, ChartImageSource, ChartStyle, DeepPartial, DimensionDefinitionLoose, IAllSeriesStyle, IAxisOptions, IBarStyle, IChartConfig, IChartContext, IChartData, IChartDataAggregation, IChartDataCategory, IChartDataSeries, IChartDataSource, IChartElementBounds, IChartElementEvent, IChartElementHit, IChartElementOverlay, IChartHost, IChartHostBorderStyle, IChartHostLease, IChartHostRect, IChartHostStyle, IChartInstance, IChartRenderAsImageOptions, IChartRenderInput, IChartRenderInstance, IChartRenderInstanceCreateContext, IChartRenderInstanceSpecInput, IChartRenderInstanceStyleInput, IChartRenderModel, IChartRenderModelImageExportInput, IChartRenderModelImageExportOptions, IChartRenderModelImageExportResult, IChartSnapshot, IChartStyle, IDimensionDefinition, IDomChartHost, IGridLineStyle, IImageChartHost, ILabelStyle, ILegendStyle, IPieLabelStyle, IPointStyle, IRelationForceOptions, IRuntimeAxis, ISeriesLabelStyle, ISeriesStyle, ITrendLine, IUniverDataSet, OptionDataValue, RightYAxisOptions, } from './types';
39
+ export { chartBitsUtils, chartTypeCanUseTrendLine, mergeChartConfig, } from './util';
84
40
  export * from './utils/echarts';
85
41
  export { WordCloudResourceConfig } from './word-cloud-resource/word-cloud-resource-config';
86
42
  export { WORD_CLOUD_DEFAULT_OPTION, WORD_CLOUD_SERIES_TYPE } from './wordcloud-chart/adapters/echarts/echarts-options';
@@ -1,4 +1,4 @@
1
- import type { ChartImageSource, ChartStyle, IChartHostRect, IChartHostStyle } from '../types';
1
+ import type { ChartImageSource, ChartStyle, IChartHostBorderStyle, IChartHostRect, IChartHostStyle } from '../types';
2
2
  export interface IResolveChartHostFrameStyleInput {
3
3
  style?: ChartStyle | null;
4
4
  getRenderColor?: (color: string) => string;
@@ -32,4 +32,9 @@ export declare function resolveDefaultChartHostFrameStyle(input: IResolveDefault
32
32
  export declare function getChartHostFrameContentRect(outer: IChartHostRect, hostStyle: IChartHostStyle): IChartHostContentRect;
33
33
  export declare function shouldComposeChartHostFrame(hostStyle: IChartHostStyle): boolean;
34
34
  export declare function composeChartHostFrameImage(image: ChartImageSource, outer: IChartHostRect, hostStyle: IChartHostStyle): ChartImageSource;
35
+ /**
36
+ * Resolves the canonical border consumed by every chart host frame renderer.
37
+ * Missing or empty colors and non-positive or non-finite widths disable the border.
38
+ */
39
+ export declare function resolveChartHostFrameBorder(hostStyle: IChartHostStyle): Required<IChartHostBorderStyle> | undefined;
35
40
  export {};