@univerjs-pro/engine-chart 1.0.0-alpha.7 → 1.0.0-beta.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +16 -3
- package/lib/cjs/facade.js +1 -1
- package/lib/cjs/index.js +1 -1
- package/lib/cjs/locale/ar-SA.js +1 -0
- package/lib/cjs/locale/ca-ES.js +1 -0
- package/lib/cjs/locale/de-DE.js +1 -0
- package/lib/cjs/locale/en-US.js +1 -0
- package/lib/cjs/locale/es-ES.js +1 -0
- package/lib/cjs/locale/fa-IR.js +1 -0
- package/lib/cjs/locale/fr-FR.js +1 -0
- package/lib/cjs/locale/id-ID.js +1 -0
- package/lib/cjs/locale/it-IT.js +1 -0
- package/lib/cjs/locale/ja-JP.js +1 -0
- package/lib/cjs/locale/ko-KR.js +1 -0
- package/lib/cjs/locale/pl-PL.js +1 -0
- package/lib/cjs/locale/pt-BR.js +1 -0
- package/lib/cjs/locale/ru-RU.js +1 -0
- package/lib/cjs/locale/sk-SK.js +1 -0
- package/lib/cjs/locale/vi-VN.js +1 -0
- package/lib/cjs/locale/zh-CN.js +1 -0
- package/lib/cjs/locale/zh-HK.js +1 -0
- package/lib/cjs/locale/zh-TW.js +1 -0
- package/lib/es/facade.js +1 -1
- package/lib/es/index.js +1 -1
- package/lib/es/locale/ar-SA.js +1 -0
- package/lib/es/locale/ca-ES.js +1 -0
- package/lib/es/locale/de-DE.js +1 -0
- package/lib/es/locale/en-US.js +1 -0
- package/lib/es/locale/es-ES.js +1 -0
- package/lib/es/locale/fa-IR.js +1 -0
- package/lib/es/locale/fr-FR.js +1 -0
- package/lib/es/locale/id-ID.js +1 -0
- package/lib/es/locale/it-IT.js +1 -0
- package/lib/es/locale/ja-JP.js +1 -0
- package/lib/es/locale/ko-KR.js +1 -0
- package/lib/es/locale/pl-PL.js +1 -0
- package/lib/es/locale/pt-BR.js +1 -0
- package/lib/es/locale/ru-RU.js +1 -0
- package/lib/es/locale/sk-SK.js +1 -0
- package/lib/es/locale/vi-VN.js +1 -0
- package/lib/es/locale/zh-CN.js +1 -0
- package/lib/es/locale/zh-HK.js +1 -0
- package/lib/es/locale/zh-TW.js +1 -0
- package/lib/facade.js +1 -1
- package/lib/index.js +1 -1
- package/lib/locale/ar-SA.js +1 -0
- package/lib/locale/ca-ES.js +1 -0
- package/lib/locale/de-DE.js +1 -0
- package/lib/locale/en-US.js +1 -0
- package/lib/locale/es-ES.js +1 -0
- package/lib/locale/fa-IR.js +1 -0
- package/lib/locale/fr-FR.js +1 -0
- package/lib/locale/id-ID.js +1 -0
- package/lib/locale/it-IT.js +1 -0
- package/lib/locale/ja-JP.js +1 -0
- package/lib/locale/ko-KR.js +1 -0
- package/lib/locale/pl-PL.js +1 -0
- package/lib/locale/pt-BR.js +1 -0
- package/lib/locale/ru-RU.js +1 -0
- package/lib/locale/sk-SK.js +1 -0
- package/lib/locale/vi-VN.js +1 -0
- package/lib/locale/zh-CN.js +1 -0
- package/lib/locale/zh-HK.js +1 -0
- package/lib/locale/zh-TW.js +1 -0
- package/lib/types/chart-builder/chart-builder-adapter.d.ts +3 -3
- package/lib/types/chart-builder/chart-builder.d.ts +4 -3
- package/lib/types/chart-builder/chart-starter-data.d.ts +4 -0
- package/lib/types/chart-builder/chart-types.d.ts +180 -67
- package/lib/types/chart-builder/configuration/assertions.d.ts +3 -0
- package/lib/types/chart-builder/configuration/candlestick.d.ts +9 -0
- package/lib/types/chart-builder/configuration/cartesian-series.d.ts +2 -1
- package/lib/types/chart-builder/configuration/chart-config-operation.d.ts +9 -1
- package/lib/types/chart-builder/configuration/chord.d.ts +12 -0
- package/lib/types/chart-builder/configuration/gauge.d.ts +31 -0
- package/lib/types/chart-builder/configuration/histogram.d.ts +11 -0
- package/lib/types/chart-builder/configuration/pie.d.ts +5 -6
- package/lib/types/chart-builder/configuration/point-mapping.d.ts +3 -0
- package/lib/types/chart-builder/configuration/sunburst.d.ts +7 -0
- package/lib/types/chart-builder/configuration/treemap.d.ts +8 -0
- package/lib/types/chart-builder/configuration/waterfall.d.ts +3 -1
- package/lib/types/chart-builder/conversion/chart-config-converter.d.ts +9 -3
- package/lib/types/chart-builder/conversion/chart-context-patch.d.ts +5 -0
- package/lib/types/chart-builder/conversion/chart-model-fields.d.ts +13 -6
- package/lib/types/chart-builder/conversion/chart-type-converter.d.ts +3 -1
- package/lib/types/chart-builder/conversion/describe-chart-model.d.ts +1546 -7
- package/lib/types/chart-builder/conversion/resolve-chart-model-data.d.ts +4 -4
- package/lib/types/chart-builder/detached-chart-builder-adapter.d.ts +10 -1
- package/lib/types/chart-builder/internal/chart-patch-replace-policy.d.ts +6 -0
- package/lib/types/chart-builder/internal/host-builder-runtime.d.ts +0 -2
- package/lib/types/chart-data-aggregation.d.ts +10 -0
- package/lib/types/chart-text-measure-canvas.d.ts +6 -0
- package/lib/types/config/config.d.ts +7 -0
- package/lib/types/enum.d.ts +78 -2
- package/lib/types/facade/builders/f-candlestick-chart-builder.d.ts +133 -0
- package/lib/types/facade/builders/f-chord-chart-builder.d.ts +30 -0
- package/lib/types/facade/builders/f-gauge-chart-builder.d.ts +52 -0
- package/lib/types/facade/builders/f-histogram-chart-builder.d.ts +74 -0
- package/lib/types/facade/builders/f-pie-chart-builder.d.ts +4 -61
- package/lib/types/facade/builders/f-sunburst-chart-builder.d.ts +24 -0
- package/lib/types/facade/builders/f-treemap-chart-builder.d.ts +34 -0
- package/lib/types/facade/chart-builder-type-map.d.ts +26 -1
- package/lib/types/facade/f-cartesian-chart-builder.d.ts +3 -3
- package/lib/types/facade/f-chart-base.d.ts +2 -2
- package/lib/types/facade/f-chart-builder-base.d.ts +4 -1
- package/lib/types/facade/f-enum.d.ts +3 -1
- package/lib/types/facade/index.d.ts +20 -1
- package/lib/types/index.d.ts +122 -39
- package/lib/types/locale/ar-SA.d.ts +3 -0
- package/lib/types/locale/ca-ES.d.ts +3 -0
- package/lib/types/locale/de-DE.d.ts +3 -0
- package/lib/types/locale/en-US.d.ts +46 -0
- package/lib/types/locale/es-ES.d.ts +3 -0
- package/lib/types/locale/fa-IR.d.ts +3 -0
- package/lib/types/locale/fr-FR.d.ts +3 -0
- package/lib/types/locale/id-ID.d.ts +3 -0
- package/lib/types/locale/it-IT.d.ts +3 -0
- package/lib/types/locale/ja-JP.d.ts +3 -0
- package/lib/types/locale/ko-KR.d.ts +3 -0
- package/lib/types/locale/pl-PL.d.ts +3 -0
- package/lib/types/locale/pt-BR.d.ts +3 -0
- package/lib/types/locale/ru-RU.d.ts +3 -0
- package/lib/types/locale/sk-SK.d.ts +3 -0
- package/lib/types/locale/types.d.ts +3 -0
- package/lib/types/locale/vi-VN.d.ts +3 -0
- package/lib/types/locale/zh-CN.d.ts +3 -0
- package/lib/types/locale/zh-HK.d.ts +3 -0
- package/lib/types/locale/zh-TW.d.ts +3 -0
- package/lib/types/models/{chart-semantic-axes.d.ts → chart-context/axes/chart-semantic-axes.d.ts} +2 -2
- package/lib/types/models/chart-context/chart-field-selection.d.ts +21 -0
- package/lib/types/models/chart-context/resolve-chart-context.d.ts +2 -0
- package/lib/types/models/chart-data/build-chart-data.d.ts +5 -0
- package/lib/types/models/chart-data/builders/boxplot-chart-data.d.ts +4 -0
- package/lib/types/models/chart-data/builders/candlestick-chart-data.d.ts +4 -0
- package/lib/types/models/chart-data/builders/cartesian-point-chart-data.d.ts +5 -0
- package/lib/types/models/chart-data/builders/category-series-chart-data.d.ts +5 -0
- package/lib/types/models/chart-data/builders/chord-chart-data.d.ts +4 -0
- package/lib/types/models/chart-data/builders/gauge-chart-data.d.ts +4 -0
- package/lib/types/models/chart-data/builders/heatmap-chart-data.d.ts +3 -0
- package/lib/types/models/chart-data/builders/hierarchy-chart-data.d.ts +5 -0
- package/lib/types/models/chart-data/builders/histogram-chart-data.d.ts +4 -0
- package/lib/types/models/chart-data/builders/relation-chart-data.d.ts +3 -0
- package/lib/types/models/chart-data/builders/sankey-chart-data.d.ts +3 -0
- package/lib/types/models/chart-data/chart-field-consumption-validator.d.ts +15 -0
- package/lib/types/models/chart-data/chart-field-consumption.d.ts +4 -0
- package/lib/types/models/chart-data/chart-field-requirements.d.ts +7 -0
- package/lib/types/models/chart-data/get-chart-data-builder.d.ts +7 -0
- package/lib/types/models/chart-data/internal/aggregate-number-format.d.ts +8 -0
- package/lib/types/models/{chart-data-operators → chart-data/internal}/cartesian-point-data.d.ts +3 -8
- package/lib/types/models/chart-data/internal/category-data.d.ts +3 -0
- package/lib/types/models/chart-data/internal/category-series-aggregation.d.ts +10 -0
- package/lib/types/models/chart-data/internal/chart-data-result.d.ts +5 -0
- package/lib/types/models/chart-data/internal/chart-hierarchy-data.d.ts +1 -0
- package/lib/types/models/chart-data/internal/chord-data.d.ts +7 -0
- package/lib/types/models/chart-data/internal/data-set-accessors.d.ts +7 -0
- package/lib/types/models/chart-data/internal/gauge-data.d.ts +5 -0
- package/lib/types/models/chart-data/internal/histogram-bins.d.ts +10 -0
- package/lib/types/models/chart-data/internal/relation-data-shape.d.ts +2 -0
- package/lib/types/models/chart-data/internal/source-cell-label.d.ts +3 -0
- package/lib/types/models/chart-data/internal/sunburst-data.d.ts +4 -0
- package/lib/types/models/chart-data/internal/treemap-data.d.ts +4 -0
- package/lib/types/models/chart-data/pie-composite/pie-composite-projection.d.ts +36 -0
- package/lib/types/models/chart-data/pie-composite/pie-composite-render-metadata.d.ts +15 -0
- package/lib/types/models/chart-data/pie-composite/pie-composite-spec.d.ts +38 -0
- package/lib/types/models/{chart-host-style.d.ts → chart-host/chart-host-style.d.ts} +1 -1
- package/lib/types/models/{image-chart-host.d.ts → chart-host/image-chart-host.d.ts} +14 -2
- package/lib/types/models/{offscreen-chart-host.d.ts → chart-host/offscreen-chart-host.d.ts} +1 -1
- package/lib/types/models/{chart-resource-serializer.d.ts → chart-host/resource/chart-resource-serializer.d.ts} +1 -1
- package/lib/types/models/chart-host/resource/inline-chart-table.d.ts +4 -0
- package/lib/types/models/chart-host/resource/static-chart-resource-repository.d.ts +75 -0
- package/lib/types/models/chart-host/static/static-chart-model-store.d.ts +43 -0
- package/lib/types/models/chart-host/static/static-chart-runtime.d.ts +26 -0
- package/lib/types/models/{chart-model.d.ts → chart-model/chart-model.d.ts} +1660 -625
- package/lib/types/models/{echart-to-chart-model-init.d.ts → chart-model/echart-to-chart-model-init.d.ts} +2 -2
- package/lib/types/models/{data-context-transformers/bar-data-context-transformer.d.ts → chart-model/type-transition/bar-type-transition.d.ts} +1 -1
- package/lib/types/models/{data-context-transformers/line-like-context-transformer.d.ts → chart-model/type-transition/line-like-type-transition.d.ts} +1 -1
- package/lib/types/models/{data-context-transformers/percent-data-context-transformer.d.ts → chart-model/type-transition/percent-type-transition.d.ts} +1 -1
- package/lib/types/models/{chart-element-axis-id.d.ts → chart-render/axes/chart-element-axis-id.d.ts} +1 -1
- package/lib/types/models/{chart-runtime-axes.d.ts → chart-render/axes/chart-runtime-axes.d.ts} +3 -3
- package/lib/types/models/{chart-render-input-resolver.d.ts → chart-render/chart-render-input-resolver.d.ts} +2 -2
- package/lib/types/models/{chart-render-model-manager.service.d.ts → chart-render/chart-render-model-manager.service.d.ts} +2 -3
- package/lib/types/models/{mode-converter → chart-render/converter}/converters/boxplot-chart-converter.d.ts +1 -1
- package/lib/types/models/{mode-converter → chart-render/converter}/converters/bubble-chart-converter.d.ts +1 -1
- package/lib/types/models/chart-render/converter/converters/candlestick-chart-converter.d.ts +4 -0
- package/lib/types/models/chart-render/converter/converters/chord-chart-converter.d.ts +10 -0
- package/lib/types/models/{mode-converter → chart-render/converter}/converters/combination-chart-converter.d.ts +1 -1
- package/lib/types/models/{mode-converter → chart-render/converter}/converters/funnel-chart-converter.d.ts +1 -1
- package/lib/types/models/chart-render/converter/converters/gauge-chart-converter.d.ts +18 -0
- package/lib/types/models/{mode-converter → chart-render/converter}/converters/heatmap-chart-convert.d.ts +1 -1
- package/lib/types/models/chart-render/converter/converters/histogram-chart-converter.d.ts +3 -0
- package/lib/types/models/{mode-converter → chart-render/converter}/converters/pareto-chart-converter.d.ts +1 -1
- package/lib/types/models/{mode-converter → chart-render/converter}/converters/pie-chart-converter.d.ts +1 -1
- package/lib/types/models/{mode-converter → chart-render/converter}/converters/radar-chart-converter.d.ts +1 -1
- package/lib/types/models/{mode-converter → chart-render/converter}/converters/relation-chart-converter.d.ts +1 -1
- package/lib/types/models/{mode-converter → chart-render/converter}/converters/sankey-chart-converter.d.ts +1 -1
- package/lib/types/models/{mode-converter → chart-render/converter}/converters/scatter-chart-converter.d.ts +1 -1
- package/lib/types/models/chart-render/converter/converters/sunburst-chart-converter.d.ts +3 -0
- package/lib/types/models/{mode-converter → chart-render/converter}/converters/tools.d.ts +1 -1
- package/lib/types/models/chart-render/converter/converters/treemap-chart-converter.d.ts +3 -0
- package/lib/types/models/{mode-converter → chart-render/converter}/converters/waterfall-chart-converter.d.ts +1 -1
- package/lib/types/models/{mode-converter → chart-render/converter}/converters/waterfall-layout.d.ts +2 -2
- package/lib/types/models/{mode-converter → chart-render/converter}/converters/word-cloud-converter.d.ts +1 -1
- package/lib/types/models/{mode-converter → chart-render/converter}/mode-converter.d.ts +3 -5
- package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/auto-gradient-presets.d.ts +1 -1
- package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/axis-title.operator.d.ts +1 -1
- package/lib/types/models/chart-render/converter/render-spec-operators/bar-layout.operator.d.ts +3 -0
- package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/bubble-style.operator.d.ts +1 -1
- package/lib/types/models/{mode-converter/render-spec-operators/trend-line/trend-line.operator.d.ts → chart-render/converter/render-spec-operators/chart-axes.operator.d.ts} +1 -1
- package/lib/types/models/{mode-converter/render-spec-operators/relation-chart-operator/relation-chart-operator.d.ts → chart-render/converter/render-spec-operators/chart-box-style.operator.d.ts} +1 -1
- package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/chart-color.d.ts +1 -1
- package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/empty-style-operator.d.ts +1 -1
- package/lib/types/models/chart-render/converter/render-spec-operators/font-size.operator.d.ts +2 -0
- package/lib/types/models/chart-render/converter/render-spec-operators/grid-operator.d.ts +12 -0
- package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/heatmap-chart-operator.d.ts +1 -1
- package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/hover-mark-style.operator.d.ts +1 -1
- package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/implicit-category-axis.operator.d.ts +1 -1
- package/lib/types/models/{mode-converter/render-spec-operators/series-style-operator/pareto-series-style.handler.d.ts → chart-render/converter/render-spec-operators/invalid-value-style.operator.d.ts} +1 -1
- package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/legend-size.d.ts +1 -1
- package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/legend-style.operator.d.ts +1 -1
- package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/line-like-style.operator.d.ts +1 -1
- package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/mark-line.operator.d.ts +1 -1
- package/lib/types/models/chart-render/converter/render-spec-operators/pie-composite-layout.operator.d.ts +2 -0
- package/lib/types/models/chart-render/converter/render-spec-operators/pie-style.operator.d.ts +2 -0
- package/lib/types/models/chart-render/converter/render-spec-operators/plot-area.d.ts +10 -0
- package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/radar-style.operator.d.ts +1 -1
- package/lib/types/models/chart-render/converter/render-spec-operators/relation-chart-operator/relation-chart-operator.d.ts +2 -0
- package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/rich-text-inheritance.operator.d.ts +1 -1
- package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/rtl-render-spec.operator.d.ts +1 -1
- package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/sankey-chart-operator.d.ts +1 -1
- package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/scatter-style.operator.d.ts +1 -1
- package/lib/types/models/chart-render/converter/render-spec-operators/series-style-operator/pareto-series-style.handler.d.ts +2 -0
- package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/series-style-operator/series-style-operator.d.ts +2 -2
- package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/series-style-operator/waterfall-series-style-operator.d.ts +1 -1
- package/lib/types/models/chart-render/converter/render-spec-operators/stack.operator.d.ts +2 -0
- package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/theme.operator.d.ts +1 -1
- package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/title-style.operator.d.ts +1 -1
- package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/tool-tip-operator.d.ts +8 -3
- package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/tool-tip-renderer.d.ts +1 -1
- package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/tools.d.ts +1 -2
- package/lib/types/models/chart-render/converter/render-spec-operators/trend-line/trend-line.operator.d.ts +2 -0
- package/lib/types/models/chart-render/converter/render-spec-operators/visual-map-operator.d.ts +2 -0
- package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/watermark.operator.d.ts +1 -1
- package/lib/types/models/{echart-render-model.d.ts → chart-render/echart-render-model.d.ts} +10 -4
- package/lib/types/models/{chart-element-edit-overlay → chart-render/edit-overlay}/chart-element-edit-overlay.d.ts +2 -2
- package/lib/types/models/{chart-element-edit-overlay → chart-render/edit-overlay}/resolve-chart-element-hit-layout.d.ts +2 -2
- package/lib/types/models/{chart-element-edit-overlay → chart-render/edit-overlay}/types.d.ts +1 -1
- package/lib/types/models/chart-render/format/chart-value-format.d.ts +16 -0
- package/lib/types/models/{chart-runtime-style.d.ts → chart-render/style/chart-runtime-style.d.ts} +3 -2
- package/lib/types/models/common/chart-field-diagnostic.d.ts +14 -0
- package/lib/types/models/common/chart-field-role.d.ts +53 -0
- package/lib/types/models/common/chart-locale-texts.d.ts +44 -0
- package/lib/types/models/common/constants/chord.d.ts +5 -0
- package/lib/types/models/common/constants/default-chart-style.d.ts +920 -0
- package/lib/types/models/{constants → common/constants}/default.d.ts +1 -1
- package/lib/types/models/common/constants/hierarchy.d.ts +5 -0
- package/lib/types/models/common/constants/histogram-defaults.d.ts +8 -0
- package/lib/types/models/common/constants/treemap.d.ts +1 -0
- package/lib/types/models/common/theme/build-in-theme/theme-util.d.ts +4 -0
- package/lib/types/models/{chart-theme.service.d.ts → common/theme/chart-theme.service.d.ts} +1 -3
- package/lib/types/plugin.d.ts +15 -0
- package/lib/types/types.d.ts +426 -31
- package/lib/types/util.d.ts +1 -7
- package/lib/types/utils/echarts.d.ts +0 -1
- package/lib/types/word-cloud-resource/word-cloud-resource-config.d.ts +5 -0
- package/lib/types/wordcloud-chart/adapters/echarts/chart-view.d.ts +0 -2
- package/lib/types/wordcloud-chart/adapters/echarts/echarts-options.d.ts +1 -1
- package/lib/types/wordcloud-chart/adapters/echarts/layout-register.d.ts +0 -2
- package/lib/types/wordcloud-chart/adapters/echarts/series-model.d.ts +0 -2
- package/lib/types/wordcloud-chart/adapters/echarts/text-measurer.d.ts +1 -1
- package/lib/types/wordcloud-chart/canvas.d.ts +3 -3
- package/lib/types/wordcloud-chart/core/collision/box-shape-engine.d.ts +1 -1
- package/lib/types/wordcloud-chart/core/layout/word-shrink.d.ts +5 -8
- package/lib/types/wordcloud-chart/core/text/formatter.d.ts +2 -2
- package/lib/types/wordcloud-chart/core/text/normalize.d.ts +2 -2
- package/lib/types/wordcloud-chart/defaults.d.ts +2 -2
- package/lib/types/wordcloud-chart/types.d.ts +0 -3
- package/lib/types/wordcloud-chart/word-cloud-render-config.d.ts +1 -0
- package/lib/umd/facade.js +1 -1
- package/lib/umd/index.js +1 -1
- package/lib/umd/locale/ar-SA.js +1 -0
- package/lib/umd/locale/ca-ES.js +1 -0
- package/lib/umd/locale/de-DE.js +1 -0
- package/lib/umd/locale/en-US.js +1 -0
- package/lib/umd/locale/es-ES.js +1 -0
- package/lib/umd/locale/fa-IR.js +1 -0
- package/lib/umd/locale/fr-FR.js +1 -0
- package/lib/umd/locale/id-ID.js +1 -0
- package/lib/umd/locale/it-IT.js +1 -0
- package/lib/umd/locale/ja-JP.js +1 -0
- package/lib/umd/locale/ko-KR.js +1 -0
- package/lib/umd/locale/pl-PL.js +1 -0
- package/lib/umd/locale/pt-BR.js +1 -0
- package/lib/umd/locale/ru-RU.js +1 -0
- package/lib/umd/locale/sk-SK.js +1 -0
- package/lib/umd/locale/vi-VN.js +1 -0
- package/lib/umd/locale/zh-CN.js +1 -0
- package/lib/umd/locale/zh-HK.js +1 -0
- package/lib/umd/locale/zh-TW.js +1 -0
- package/package.json +10 -4
- package/lib/types/chart-builder/configuration/index.d.ts +0 -30
- package/lib/types/chart-builder/index.d.ts +0 -14
- package/lib/types/facade/builders/index.d.ts +0 -14
- package/lib/types/models/chart-data-operators/build-chart-data.d.ts +0 -9
- package/lib/types/models/chart-data-operators/index.d.ts +0 -2
- package/lib/types/models/chart-data-operators/operators.d.ts +0 -20
- package/lib/types/models/chart-element-edit-overlay/index.d.ts +0 -4
- package/lib/types/models/chart-locale-texts.d.ts +0 -22
- package/lib/types/models/constants/build-in-theme/index.d.ts +0 -15
- package/lib/types/models/constants/build-in-theme/theme-util.d.ts +0 -5
- package/lib/types/models/constants/default-chart-style.d.ts +0 -138
- package/lib/types/models/data-context-transformers/box-plot-data-context-transformer.d.ts +0 -3
- package/lib/types/models/data-context-transformers/pareto-data-context-transformer.d.ts +0 -3
- package/lib/types/models/data-context-transformers/pie-data-context-transformer.d.ts +0 -3
- package/lib/types/models/data-context-transformers/word-cloud-data-context-transform.d.ts +0 -3
- package/lib/types/models/mode-converter/render-spec-operators/chart-axes.operator.d.ts +0 -2
- package/lib/types/models/mode-converter/render-spec-operators/chart-box-style.operator.d.ts +0 -2
- package/lib/types/models/mode-converter/render-spec-operators/font-size.operator.d.ts +0 -2
- package/lib/types/models/mode-converter/render-spec-operators/grid-operator.d.ts +0 -2
- package/lib/types/models/mode-converter/render-spec-operators/index.d.ts +0 -15
- package/lib/types/models/mode-converter/render-spec-operators/invalid-value-style.operator.d.ts +0 -2
- package/lib/types/models/mode-converter/render-spec-operators/pie-style.operator.d.ts +0 -2
- package/lib/types/models/mode-converter/render-spec-operators/stack.operator.d.ts +0 -2
- package/lib/types/models/mode-converter/render-spec-operators/visual-map-operator.d.ts +0 -2
- package/lib/types/models/spec-converter/spec-converter.d.ts +0 -1
- package/lib/types/models/word-cloud-musk-image.service.d.ts +0 -17
- package/lib/types/wordcloud-chart/index.d.ts +0 -12
- /package/lib/types/models/{mode-converter → chart-render/converter}/converters/constants.d.ts +0 -0
- /package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/operator-types.d.ts +0 -0
- /package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/relation-chart-operator/relation-force-directed-layout.d.ts +0 -0
- /package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/series-style-operator/series-chart-style.handler.d.ts +0 -0
- /package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/series-style-operator/series-data-label.handler.d.ts +0 -0
- /package/lib/types/models/{mode-converter → chart-render/converter}/render-spec-operators/trend-line/trendline-util.d.ts +0 -0
- /package/lib/types/models/{chart-element-edit-overlay → chart-render/edit-overlay}/palette.d.ts +0 -0
- /package/lib/types/models/{series-style → chart-render/style/series-style}/series-style-resolver.d.ts +0 -0
- /package/lib/types/models/{constants → common/theme}/build-in-theme/default.d.ts +0 -0
- /package/lib/types/models/{constants → common/theme}/build-in-theme/types.d.ts +0 -0
- /package/lib/types/models/{constants → common/theme}/build-in-theme/univer-gradient1.d.ts +0 -0
- /package/lib/types/models/{constants → common/theme}/build-in-theme/univer-gradient2.d.ts +0 -0
- /package/lib/types/models/{constants → common/theme}/build-in-theme/univer-gradient3.d.ts +0 -0
- /package/lib/types/models/{constants → common/theme}/build-in-theme/univer-gradient4.d.ts +0 -0
- /package/lib/types/models/{constants → common/theme}/build-in-theme/univer-gradient5.d.ts +0 -0
- /package/lib/types/models/{constants → common/theme}/build-in-theme/univer-gradient6.d.ts +0 -0
- /package/lib/types/models/{constants → common/theme}/build-in-theme/univer1.d.ts +0 -0
- /package/lib/types/models/{constants → common/theme}/build-in-theme/univer2.d.ts +0 -0
- /package/lib/types/models/{constants → common/theme}/build-in-theme/univer3.d.ts +0 -0
- /package/lib/types/models/{constants → common/theme}/build-in-theme/univer4.d.ts +0 -0
- /package/lib/types/models/{constants → common/theme}/build-in-theme/univer5.d.ts +0 -0
- /package/lib/types/models/{constants → common/theme}/build-in-theme/univer6.d.ts +0 -0
package/lib/types/types.d.ts
CHANGED
|
@@ -1,15 +1,21 @@
|
|
|
1
1
|
import type { IDisposable, Nullable } from '@univerjs/core';
|
|
2
|
+
import type { BarSeriesOption, EChartsOption } from 'echarts';
|
|
2
3
|
import type { Observable } from 'rxjs';
|
|
3
4
|
import type { ChartColor, IChartLinearGradient } from './chart-builder/chart-color';
|
|
4
|
-
import type {
|
|
5
|
-
import type {
|
|
6
|
-
import type {
|
|
7
|
-
import type {
|
|
8
|
-
import type {
|
|
5
|
+
import type { IChartPieCompositeSpec, PieCompositeMarkRole, PieCompositePlot } from './chart-builder/chart-types';
|
|
6
|
+
import type { IChartDataAggregation } from './chart-data-aggregation';
|
|
7
|
+
import type { AreaLineStyle, AxisAlignEnum, AxisValueType, BarShape, CategoryType, ChartAxisDimension, ChartBorderDashType, ChartChordFocusMode, ChartChordLabelPosition, ChartChordRibbonColorMode, ChartGaugeMode, ChartGaugePointerShape, ChartHistogramBinKind, ChartMarkLineLabelPosition, ChartSemanticAxis, ChartSourceDataTypeEnum, ChartSunburstLabelPosition, ChartTrendlineType, ChartTypeBits, ChartWaterfallPointRole, DataOrientation, HistogramBinningMode, InvalidValueType, IRuntimeAxisPosition, IRuntimeAxisPriority, LabelAlignEnum, LabelContentType, LegendPositionEnum, LinePointShape, PieLabelPosition, RadarShape, RelationChartLayoutEnum, SelectModeEnum, SeriesLabelPosition, TitlePositionEnum, TreemapParentLabelLayout, WaterfallSeriesTypeEnum, WaterfallStackTypeEnum, WordCloudShapeEnum } from './enum';
|
|
8
|
+
import type { ICartesianPointData } from './models/chart-data/internal/cartesian-point-data';
|
|
9
|
+
import type { IChartLocaleTexts } from './models/common/chart-locale-texts';
|
|
10
|
+
import type { IEchartTheme } from './models/common/theme/build-in-theme/types';
|
|
9
11
|
import type { IWordCloudRenderConfig } from './wordcloud-chart/word-cloud-render-config';
|
|
10
12
|
export type DeepPartial<T> = T extends IChartLinearGradient ? T : T extends Record<string, any> ? T extends any[] ? T : {
|
|
11
13
|
[key in keyof T]+?: DeepPartial<T[key]>;
|
|
12
14
|
} : T;
|
|
15
|
+
/** Recursive patch shape that permits `null` at every field and treats arrays as atomic values. */
|
|
16
|
+
export type DeepNullish<T> = T extends (...args: never[]) => unknown ? T : T extends readonly unknown[] ? T : T extends object ? {
|
|
17
|
+
[K in keyof T]?: DeepNullish<T[K]> | null;
|
|
18
|
+
} : T;
|
|
13
19
|
export type ChartDirection = 'ltr' | 'rtl';
|
|
14
20
|
export interface IChartDataSource {
|
|
15
21
|
data$: Observable<IUniverDataSet>;
|
|
@@ -28,8 +34,7 @@ export interface IDimensionDefinition {
|
|
|
28
34
|
}
|
|
29
35
|
export type DimensionDefinitionLoose = IDimensionDefinition['name'] | IDimensionDefinition;
|
|
30
36
|
export type OptionDataValue = string | number | Date | null | undefined;
|
|
31
|
-
export type
|
|
32
|
-
export type ChartDataSourceValues = ChartDataSourceValue[][];
|
|
37
|
+
export type ChartDataSourceValues = OptionDataValue[][];
|
|
33
38
|
/**
|
|
34
39
|
* Canonical chart dataset used by chart context operators and chart-data builders.
|
|
35
40
|
*
|
|
@@ -47,10 +52,310 @@ export interface IUniverDataSet {
|
|
|
47
52
|
sourceType?: ChartSourceDataTypeEnum[][];
|
|
48
53
|
sourceLabels?: string[][];
|
|
49
54
|
}
|
|
55
|
+
/** Ordered field names that define the persisted Candlestick OHLC mapping contract. */
|
|
56
|
+
export declare const CHART_CANDLESTICK_MAPPING_FIELDS: readonly ["openIndex", "highIndex", "lowIndex", "closeIndex"];
|
|
57
|
+
/** Required semantic OHLC source fields for one Candlestick series. */
|
|
58
|
+
export interface IChartCandlestickMappingSpec {
|
|
59
|
+
openIndex: number;
|
|
60
|
+
highIndex: number;
|
|
61
|
+
lowIndex: number;
|
|
62
|
+
closeIndex: number;
|
|
63
|
+
}
|
|
64
|
+
/** Semantic body and wick appearance for one Candlestick state. */
|
|
65
|
+
export interface IChartCandlestickStateStyleSpec {
|
|
66
|
+
color?: string;
|
|
67
|
+
fillOpacity?: number;
|
|
68
|
+
border?: {
|
|
69
|
+
color?: string;
|
|
70
|
+
width?: number;
|
|
71
|
+
opacity?: number;
|
|
72
|
+
};
|
|
73
|
+
hollow?: boolean;
|
|
74
|
+
}
|
|
75
|
+
/** Semantic Candlestick style overrides persisted by the chart model. */
|
|
76
|
+
export interface IChartCandlestickSpec {
|
|
77
|
+
rising?: IChartCandlestickStateStyleSpec;
|
|
78
|
+
falling?: IChartCandlestickStateStyleSpec;
|
|
79
|
+
doji?: IChartCandlestickStateStyleSpec;
|
|
80
|
+
candleWidth?: number;
|
|
81
|
+
}
|
|
82
|
+
/** Histogram bin sizing configuration persisted by the semantic chart model. */
|
|
83
|
+
export type IChartHistogramBinningSpec = {
|
|
84
|
+
mode: typeof HistogramBinningMode.Count;
|
|
85
|
+
count: number;
|
|
86
|
+
} | {
|
|
87
|
+
mode: typeof HistogramBinningMode.Width;
|
|
88
|
+
width: number;
|
|
89
|
+
};
|
|
90
|
+
/** Persisted Histogram data-processing options. Omission selects Scott Auto binning. */
|
|
91
|
+
export interface IChartHistogramDataSpec {
|
|
92
|
+
binning?: IChartHistogramBinningSpec;
|
|
93
|
+
underflowThreshold?: number;
|
|
94
|
+
overflowThreshold?: number;
|
|
95
|
+
}
|
|
96
|
+
/** Persisted Histogram appearance options. */
|
|
97
|
+
export interface IChartHistogramStyleSpec {
|
|
98
|
+
/** Gap ratio between adjacent bins. Effective values are from 0 through 0.9. */
|
|
99
|
+
binGap?: number;
|
|
100
|
+
}
|
|
101
|
+
/** Public Histogram semantic configuration. */
|
|
102
|
+
export interface IChartHistogramSpec extends IChartHistogramDataSpec, IChartHistogramStyleSpec {
|
|
103
|
+
}
|
|
104
|
+
/** Shared authored number format for chart labels that display a numeric Value fragment. */
|
|
105
|
+
export interface IChartValueLabelSpec {
|
|
106
|
+
format?: string;
|
|
107
|
+
}
|
|
108
|
+
/** Persisted leaf-label style supported by Treemap charts. */
|
|
109
|
+
export interface IChartTreemapLabelSpec extends IChartValueLabelSpec {
|
|
110
|
+
visible?: boolean;
|
|
111
|
+
contentType?: LabelContentType;
|
|
112
|
+
color?: string;
|
|
113
|
+
fontSize?: number;
|
|
114
|
+
bold?: boolean;
|
|
115
|
+
italic?: boolean;
|
|
116
|
+
family?: string;
|
|
117
|
+
}
|
|
118
|
+
/** Public Treemap semantic style configuration. */
|
|
119
|
+
export interface IChartTreemapSpec {
|
|
120
|
+
parentLabelLayout?: TreemapParentLabelLayout;
|
|
121
|
+
label?: IChartTreemapLabelSpec;
|
|
122
|
+
}
|
|
123
|
+
/** Persisted semantic label style supported by Sunburst charts. */
|
|
124
|
+
export interface IChartSunburstLabelSpec extends IChartValueLabelSpec {
|
|
125
|
+
visible?: boolean;
|
|
126
|
+
contentType?: LabelContentType;
|
|
127
|
+
position?: ChartSunburstLabelPosition;
|
|
128
|
+
color?: string;
|
|
129
|
+
fontSize?: number;
|
|
130
|
+
bold?: boolean;
|
|
131
|
+
italic?: boolean;
|
|
132
|
+
family?: string;
|
|
133
|
+
}
|
|
134
|
+
/** Persisted style for the aggregate value rendered in the Sunburst center. */
|
|
135
|
+
export interface IChartSunburstCenterLabelSpec extends IChartValueLabelSpec {
|
|
136
|
+
visible?: boolean;
|
|
137
|
+
color?: string;
|
|
138
|
+
fontSize?: number;
|
|
139
|
+
bold?: boolean;
|
|
140
|
+
italic?: boolean;
|
|
141
|
+
family?: string;
|
|
142
|
+
}
|
|
143
|
+
/** Public Sunburst semantic style configuration. */
|
|
144
|
+
export interface IChartSunburstSpec {
|
|
145
|
+
centerLabel?: IChartSunburstCenterLabelSpec;
|
|
146
|
+
label?: IChartSunburstLabelSpec;
|
|
147
|
+
}
|
|
148
|
+
export interface IChartGaugeFontSpec {
|
|
149
|
+
color?: string;
|
|
150
|
+
fontSize?: number;
|
|
151
|
+
bold?: boolean;
|
|
152
|
+
italic?: boolean;
|
|
153
|
+
family?: string;
|
|
154
|
+
}
|
|
155
|
+
/** Values are semantic degrees; ratios are represented from 0 through 1. */
|
|
156
|
+
export interface IChartGaugeScaleSpec {
|
|
157
|
+
min?: number;
|
|
158
|
+
max?: number;
|
|
159
|
+
splitNumber?: number;
|
|
160
|
+
}
|
|
161
|
+
export interface IChartGaugeAnglesSpec {
|
|
162
|
+
startAngle?: number;
|
|
163
|
+
endAngle?: number;
|
|
164
|
+
}
|
|
165
|
+
export interface IChartGaugeRangeSpec {
|
|
166
|
+
from: number;
|
|
167
|
+
to: number;
|
|
168
|
+
color: string;
|
|
169
|
+
}
|
|
170
|
+
export interface IChartGaugeAxisLineSpec {
|
|
171
|
+
visible?: boolean;
|
|
172
|
+
width?: number;
|
|
173
|
+
color?: string;
|
|
174
|
+
}
|
|
175
|
+
export interface IChartGaugeAxisTickSpec {
|
|
176
|
+
visible?: boolean;
|
|
177
|
+
splitNumber?: number;
|
|
178
|
+
length?: number;
|
|
179
|
+
width?: number;
|
|
180
|
+
color?: string;
|
|
181
|
+
}
|
|
182
|
+
export interface IChartGaugeSplitLineSpec {
|
|
183
|
+
visible?: boolean;
|
|
184
|
+
length?: number;
|
|
185
|
+
width?: number;
|
|
186
|
+
color?: string;
|
|
187
|
+
}
|
|
188
|
+
export interface IChartGaugeAxisLabelSpec extends IChartGaugeFontSpec, IChartValueLabelSpec {
|
|
189
|
+
visible?: boolean;
|
|
190
|
+
distance?: number;
|
|
191
|
+
}
|
|
192
|
+
export interface IChartGaugePointerSpec {
|
|
193
|
+
visible?: boolean;
|
|
194
|
+
length?: number;
|
|
195
|
+
width?: number;
|
|
196
|
+
color?: string;
|
|
197
|
+
shape?: ChartGaugePointerShape;
|
|
198
|
+
}
|
|
199
|
+
export interface IChartGaugeAnchorSpec {
|
|
200
|
+
visible?: boolean;
|
|
201
|
+
size?: number;
|
|
202
|
+
color?: string;
|
|
203
|
+
borderColor?: string;
|
|
204
|
+
borderWidth?: number;
|
|
205
|
+
}
|
|
206
|
+
export interface IChartGaugeProgressSpec {
|
|
207
|
+
visible?: boolean;
|
|
208
|
+
width?: number;
|
|
209
|
+
color?: string;
|
|
210
|
+
rounded?: boolean;
|
|
211
|
+
}
|
|
212
|
+
export interface IChartGaugeTitleSpec extends IChartGaugeFontSpec {
|
|
213
|
+
visible?: boolean;
|
|
214
|
+
offsetY?: number;
|
|
215
|
+
}
|
|
216
|
+
export interface IChartGaugeDetailSpec extends IChartGaugeFontSpec, IChartValueLabelSpec {
|
|
217
|
+
visible?: boolean;
|
|
218
|
+
offsetY?: number;
|
|
219
|
+
}
|
|
220
|
+
/** Persisted renderer-independent Gauge appearance shared by every rendered gauge item. */
|
|
221
|
+
export interface IChartGaugeSpec {
|
|
222
|
+
mode?: ChartGaugeMode;
|
|
223
|
+
scale?: IChartGaugeScaleSpec;
|
|
224
|
+
angles?: IChartGaugeAnglesSpec;
|
|
225
|
+
ranges?: IChartGaugeRangeSpec[];
|
|
226
|
+
axisLine?: IChartGaugeAxisLineSpec;
|
|
227
|
+
axisTick?: IChartGaugeAxisTickSpec;
|
|
228
|
+
splitLine?: IChartGaugeSplitLineSpec;
|
|
229
|
+
axisLabel?: IChartGaugeAxisLabelSpec;
|
|
230
|
+
pointer?: IChartGaugePointerSpec;
|
|
231
|
+
anchor?: IChartGaugeAnchorSpec;
|
|
232
|
+
progress?: IChartGaugeProgressSpec;
|
|
233
|
+
title?: IChartGaugeTitleSpec;
|
|
234
|
+
detail?: IChartGaugeDetailSpec;
|
|
235
|
+
}
|
|
236
|
+
export interface IChartGaugeItem {
|
|
237
|
+
id: string;
|
|
238
|
+
name: string;
|
|
239
|
+
value: number;
|
|
240
|
+
formattedValue: string;
|
|
241
|
+
}
|
|
242
|
+
export interface IChartGaugeData {
|
|
243
|
+
items: IChartGaugeItem[];
|
|
244
|
+
diagnostic?: string;
|
|
245
|
+
}
|
|
246
|
+
/** Persisted Source/Target/optional-Value roles for an undirected Chord edge list. */
|
|
247
|
+
export interface IChartChordMappingSpec {
|
|
248
|
+
sourceIndex: number;
|
|
249
|
+
targetIndex: number;
|
|
250
|
+
valueIndex?: number;
|
|
251
|
+
}
|
|
252
|
+
export interface IChartChordLayoutSpec {
|
|
253
|
+
startAngle?: number;
|
|
254
|
+
clockwise?: boolean;
|
|
255
|
+
padAngle?: number;
|
|
256
|
+
minAngle?: number;
|
|
257
|
+
innerRadiusRatio?: number;
|
|
258
|
+
outerRadiusRatio?: number;
|
|
259
|
+
}
|
|
260
|
+
export interface IChartChordNodeStyleSpec {
|
|
261
|
+
color?: string;
|
|
262
|
+
opacity?: number;
|
|
263
|
+
borderColor?: string;
|
|
264
|
+
borderWidth?: number;
|
|
265
|
+
borderType?: ChartBorderDashType;
|
|
266
|
+
}
|
|
267
|
+
export interface IChartChordLabelSpec {
|
|
268
|
+
visible?: boolean;
|
|
269
|
+
position?: ChartChordLabelPosition;
|
|
270
|
+
rotation?: number;
|
|
271
|
+
distance?: number;
|
|
272
|
+
color?: string;
|
|
273
|
+
fontSize?: number;
|
|
274
|
+
bold?: boolean;
|
|
275
|
+
italic?: boolean;
|
|
276
|
+
family?: string;
|
|
277
|
+
}
|
|
278
|
+
export interface IChartChordRibbonStyleSpec {
|
|
279
|
+
color?: ChartChordRibbonColorMode;
|
|
280
|
+
opacity?: number;
|
|
281
|
+
width?: number;
|
|
282
|
+
type?: ChartBorderDashType;
|
|
283
|
+
}
|
|
284
|
+
export interface IChartChordEmphasisSpec {
|
|
285
|
+
focus?: ChartChordFocusMode;
|
|
286
|
+
}
|
|
287
|
+
export interface IChartChordSpec {
|
|
288
|
+
layout?: IChartChordLayoutSpec;
|
|
289
|
+
node?: IChartChordNodeStyleSpec;
|
|
290
|
+
label?: IChartChordLabelSpec;
|
|
291
|
+
ribbon?: IChartChordRibbonStyleSpec;
|
|
292
|
+
emphasis?: IChartChordEmphasisSpec;
|
|
293
|
+
}
|
|
294
|
+
export interface IChartChordNode {
|
|
295
|
+
id: string;
|
|
296
|
+
name: string;
|
|
297
|
+
value: number;
|
|
298
|
+
formattedValue: string;
|
|
299
|
+
}
|
|
300
|
+
export interface IChartChordLink {
|
|
301
|
+
id: string;
|
|
302
|
+
endpointAId: string;
|
|
303
|
+
endpointBId: string;
|
|
304
|
+
endpointAName: string;
|
|
305
|
+
endpointBName: string;
|
|
306
|
+
value: number;
|
|
307
|
+
formattedValue: string;
|
|
308
|
+
}
|
|
309
|
+
export interface IChartChordData {
|
|
310
|
+
valueFieldName?: string;
|
|
311
|
+
weightMode: 'value' | 'count';
|
|
312
|
+
nodes: IChartChordNode[];
|
|
313
|
+
links: IChartChordLink[];
|
|
314
|
+
diagnostic?: string;
|
|
315
|
+
}
|
|
316
|
+
/** Runtime-only renderer-independent Treemap node. */
|
|
317
|
+
export interface IChartTreemapNode {
|
|
318
|
+
id: string;
|
|
319
|
+
name: string;
|
|
320
|
+
path: string[];
|
|
321
|
+
value: number;
|
|
322
|
+
selfValue: number;
|
|
323
|
+
formattedValue?: string;
|
|
324
|
+
formattedSelfValue?: string;
|
|
325
|
+
children?: IChartTreemapNode[];
|
|
326
|
+
}
|
|
327
|
+
/** Runtime-only Treemap data prepared from the canonical flat mapping. */
|
|
328
|
+
export interface IChartTreemapData {
|
|
329
|
+
valueFieldName: string;
|
|
330
|
+
nodes: IChartTreemapNode[];
|
|
331
|
+
/** Runtime-only top-level first-source order used for stable palette assignment. */
|
|
332
|
+
paletteOrder?: string[];
|
|
333
|
+
diagnostic?: string;
|
|
334
|
+
}
|
|
335
|
+
/** Runtime-only renderer-independent Sunburst node. */
|
|
336
|
+
export interface IChartSunburstNode {
|
|
337
|
+
id: string;
|
|
338
|
+
name: string;
|
|
339
|
+
path: string[];
|
|
340
|
+
value: number;
|
|
341
|
+
selfValue: number;
|
|
342
|
+
formattedValue?: string;
|
|
343
|
+
formattedSelfValue?: string;
|
|
344
|
+
children?: IChartSunburstNode[];
|
|
345
|
+
}
|
|
346
|
+
/** Runtime-only Sunburst data prepared from the canonical flat mapping. */
|
|
347
|
+
export interface IChartSunburstData {
|
|
348
|
+
valueFieldName: string;
|
|
349
|
+
nodes: IChartSunburstNode[];
|
|
350
|
+
/** Runtime-only top-level first-source order used for stable palette assignment. */
|
|
351
|
+
paletteOrder?: string[];
|
|
352
|
+
diagnostic?: string;
|
|
353
|
+
}
|
|
50
354
|
export interface IChartContext {
|
|
51
355
|
headers?: string[];
|
|
52
356
|
categoryType?: CategoryType;
|
|
53
|
-
|
|
357
|
+
/** Ordered selected Label field indexes. */
|
|
358
|
+
categoryIndexes?: number[];
|
|
54
359
|
/**
|
|
55
360
|
* the flag to indicate whether the chart use date axis, only all category data is date type, the chart will use date axis, if there are some string type data, the chart will use category axis even the flag is true.
|
|
56
361
|
*/
|
|
@@ -58,15 +363,7 @@ export interface IChartContext {
|
|
|
58
363
|
categoryResourceIndexes?: number[];
|
|
59
364
|
seriesIndexes?: number[];
|
|
60
365
|
seriesResourceIndexes?: number[];
|
|
61
|
-
|
|
62
|
-
categoryIndex?: number;
|
|
63
|
-
seriesIndexes?: number[];
|
|
64
|
-
};
|
|
65
|
-
scatterXIndex?: number;
|
|
66
|
-
scatterYIndex?: number;
|
|
67
|
-
scatterLabelIndex?: number;
|
|
68
|
-
bubbleSizeIndex?: number;
|
|
69
|
-
bubbleSeriesIndex?: number;
|
|
366
|
+
histogram?: IChartHistogramDataSpec;
|
|
70
367
|
}
|
|
71
368
|
export interface IRelationNodes {
|
|
72
369
|
id: string;
|
|
@@ -94,10 +391,18 @@ export interface IChartData {
|
|
|
94
391
|
*/
|
|
95
392
|
dataset?: IUniverDataSet;
|
|
96
393
|
cartesianPoint?: ICartesianPointData;
|
|
394
|
+
candlestickData?: IChartCandlestickData;
|
|
395
|
+
histogramData?: IChartHistogramData;
|
|
396
|
+
treemapData?: IChartTreemapData;
|
|
397
|
+
sunburstData?: IChartSunburstData;
|
|
398
|
+
gaugeData?: IChartGaugeData;
|
|
399
|
+
chordData?: IChartChordData;
|
|
400
|
+
fieldDiagnostic?: import('./models/common/chart-field-diagnostic').IChartFieldDiagnostic;
|
|
97
401
|
heatmapData?: {
|
|
98
402
|
xData: string[];
|
|
99
403
|
yData: string[];
|
|
100
404
|
values: number[][];
|
|
405
|
+
formattedValues: string[][];
|
|
101
406
|
isValidateHeatmapSource: boolean;
|
|
102
407
|
};
|
|
103
408
|
relationData?: {
|
|
@@ -118,6 +423,38 @@ export interface IChartData {
|
|
|
118
423
|
isCircular: boolean;
|
|
119
424
|
};
|
|
120
425
|
}
|
|
426
|
+
/** One semantic OHLC point. Renderer tuple order is intentionally absent. */
|
|
427
|
+
export interface IChartCandlestickPoint {
|
|
428
|
+
open: number;
|
|
429
|
+
high: number;
|
|
430
|
+
low: number;
|
|
431
|
+
close: number;
|
|
432
|
+
labels: {
|
|
433
|
+
open: string;
|
|
434
|
+
high: string;
|
|
435
|
+
low: string;
|
|
436
|
+
close: string;
|
|
437
|
+
};
|
|
438
|
+
}
|
|
439
|
+
/** One aligned semantic Candlestick series. */
|
|
440
|
+
export interface IChartCandlestickData {
|
|
441
|
+
name: string;
|
|
442
|
+
items: Array<IChartCandlestickPoint | null>;
|
|
443
|
+
}
|
|
444
|
+
/** Numeric semantic Histogram bin. Renderer labels are intentionally absent. */
|
|
445
|
+
export interface IChartHistogramBin {
|
|
446
|
+
kind: ChartHistogramBinKind;
|
|
447
|
+
lowerBound?: number;
|
|
448
|
+
upperBound?: number;
|
|
449
|
+
count: number;
|
|
450
|
+
}
|
|
451
|
+
/** Derived runtime-only Histogram data. */
|
|
452
|
+
export interface IChartHistogramData {
|
|
453
|
+
sourceIndex: number;
|
|
454
|
+
name: string;
|
|
455
|
+
validSampleCount: number;
|
|
456
|
+
bins: IChartHistogramBin[];
|
|
457
|
+
}
|
|
121
458
|
export interface ISankeyNode {
|
|
122
459
|
name: string;
|
|
123
460
|
}
|
|
@@ -153,6 +490,8 @@ export interface IChartRuntimeContext {
|
|
|
153
490
|
axes: IRuntimeAxis[];
|
|
154
491
|
themeInfo: IEchartTheme;
|
|
155
492
|
wordCloudRenderConfig?: IWordCloudRenderConfig;
|
|
493
|
+
/** Runtime-only host policy for rendering a chart watermark. */
|
|
494
|
+
addWatermark?: boolean;
|
|
156
495
|
/** Runtime-only extra inset reserved by host adapters around chart content. */
|
|
157
496
|
layoutInset?: number;
|
|
158
497
|
/**
|
|
@@ -185,6 +524,13 @@ export interface ILabelStyle {
|
|
|
185
524
|
showMinLabel?: boolean;
|
|
186
525
|
rotate?: number;
|
|
187
526
|
}
|
|
527
|
+
export interface IChartTitleStyle extends Omit<ILabelStyle, 'visible'> {
|
|
528
|
+
/** PowerPoint manual title anchor, as chart-relative edge coordinates. */
|
|
529
|
+
manualLayout?: {
|
|
530
|
+
left: number;
|
|
531
|
+
top: number;
|
|
532
|
+
};
|
|
533
|
+
}
|
|
188
534
|
export interface ILegendStyle {
|
|
189
535
|
position?: LegendPositionEnum;
|
|
190
536
|
label?: Omit<ILabelStyle, 'visible' | 'align' | 'content'>;
|
|
@@ -196,6 +542,7 @@ export interface IGridLineStyle {
|
|
|
196
542
|
visible: boolean;
|
|
197
543
|
color: string;
|
|
198
544
|
width: number;
|
|
545
|
+
dashType?: ChartBorderDashType;
|
|
199
546
|
}
|
|
200
547
|
export interface IAxisOptions {
|
|
201
548
|
lineVisible: boolean;
|
|
@@ -217,10 +564,14 @@ export interface IAxisOptions {
|
|
|
217
564
|
export interface ISeriesLabelStyle extends ILabelStyle {
|
|
218
565
|
contentType: number;
|
|
219
566
|
position: SeriesLabelPosition;
|
|
567
|
+
format?: string;
|
|
568
|
+
/** Per-category text imported from OOXML data-label ranges. */
|
|
569
|
+
customValues?: Record<number, string>;
|
|
220
570
|
}
|
|
221
571
|
export interface IPieLabelStyle extends Omit<ILabelStyle, 'align' | 'content'> {
|
|
222
572
|
contentType: number;
|
|
223
573
|
position: PieLabelPosition;
|
|
574
|
+
format?: string;
|
|
224
575
|
}
|
|
225
576
|
export interface IPointStyle {
|
|
226
577
|
shape: LinePointShape;
|
|
@@ -317,6 +668,10 @@ export type IChartMarkLine = {
|
|
|
317
668
|
value: number;
|
|
318
669
|
});
|
|
319
670
|
export interface IBarStyle {
|
|
671
|
+
/** Gap between category clusters, as a percentage of one bar width. */
|
|
672
|
+
gapWidth?: number;
|
|
673
|
+
/** Series overlap from -100 (separated) through 100 (fully overlapped). */
|
|
674
|
+
overlap?: number;
|
|
320
675
|
/** Exchange metadata. Renderers without 3D support may ignore these fields. */
|
|
321
676
|
is3D: boolean;
|
|
322
677
|
shape: BarShape;
|
|
@@ -325,6 +680,19 @@ export interface IBarStyle {
|
|
|
325
680
|
/** OOXML view rotation around the vertical axis, in degrees. */
|
|
326
681
|
rotY: number;
|
|
327
682
|
}
|
|
683
|
+
export interface IChartBubbleStyle {
|
|
684
|
+
/** Maximum bubble size as an OOXML-compatible percentage. */
|
|
685
|
+
scale?: number;
|
|
686
|
+
/** Whether the authored bubble value represents its area or width. */
|
|
687
|
+
sizeRepresents?: 'area' | 'width';
|
|
688
|
+
}
|
|
689
|
+
/** Manual inner plot rectangle, normalized against the whole chart frame. */
|
|
690
|
+
export interface IChartPlotArea {
|
|
691
|
+
left: number;
|
|
692
|
+
top: number;
|
|
693
|
+
width: number;
|
|
694
|
+
height: number;
|
|
695
|
+
}
|
|
328
696
|
export interface IChartStyle {
|
|
329
697
|
runtime: IChartRuntimeContext;
|
|
330
698
|
/** Runtime-only locale direction. It must not be persisted in chart snapshots. */
|
|
@@ -343,9 +711,11 @@ export interface IChartStyle {
|
|
|
343
711
|
fontFamily: string;
|
|
344
712
|
borderColor: Nullable<string>;
|
|
345
713
|
borderWidth: number;
|
|
714
|
+
/** Omission keeps renderer-owned automatic layout. */
|
|
715
|
+
plotArea?: IChartPlotArea;
|
|
346
716
|
titles: {
|
|
347
|
-
title:
|
|
348
|
-
subtitle:
|
|
717
|
+
title: IChartTitleStyle;
|
|
718
|
+
subtitle: IChartTitleStyle;
|
|
349
719
|
xAxisTitle: Omit<ILabelStyle, 'visible'>;
|
|
350
720
|
/** Primary vertical axis title. RTL may render it on the physical right, but it is still persisted here. */
|
|
351
721
|
yAxisTitle: Omit<ILabelStyle, 'visible'>;
|
|
@@ -364,8 +734,12 @@ export interface IChartStyle {
|
|
|
364
734
|
[id: string]: ISeriesStyle;
|
|
365
735
|
};
|
|
366
736
|
bar: IBarStyle;
|
|
737
|
+
bubble: IChartBubbleStyle;
|
|
367
738
|
trendlines: ITrendLine[];
|
|
368
739
|
pie: {
|
|
740
|
+
composite?: IChartPieCompositeSpec;
|
|
741
|
+
/** Clockwise degrees from 12 o'clock, matching the authored chart semantic. */
|
|
742
|
+
startAngle?: number;
|
|
369
743
|
doughnutHole: Nullable<number>;
|
|
370
744
|
/** Slice offset as a ratio of the pie radius. */
|
|
371
745
|
explosion?: number;
|
|
@@ -378,8 +752,6 @@ export interface IChartStyle {
|
|
|
378
752
|
rosePie: boolean;
|
|
379
753
|
showLabelLine: boolean;
|
|
380
754
|
valueScale: number;
|
|
381
|
-
valueSuffix: string;
|
|
382
|
-
digitalFixed: number;
|
|
383
755
|
/** Persisted sparse slice overrides. Slice data remains owned by the chart data source. */
|
|
384
756
|
sliceStyles: {
|
|
385
757
|
[index: number]: {
|
|
@@ -439,6 +811,12 @@ export interface IChartStyle {
|
|
|
439
811
|
unit?: string;
|
|
440
812
|
label?: ISeriesLabelStyle;
|
|
441
813
|
};
|
|
814
|
+
candlestick: IChartCandlestickSpec;
|
|
815
|
+
histogram: IChartHistogramStyleSpec;
|
|
816
|
+
treemap: IChartTreemapSpec;
|
|
817
|
+
sunburst: IChartSunburstSpec;
|
|
818
|
+
gauge: IChartGaugeSpec;
|
|
819
|
+
chord: IChartChordSpec;
|
|
442
820
|
}
|
|
443
821
|
export interface IRelationForceOptions {
|
|
444
822
|
repulsion?: number;
|
|
@@ -446,10 +824,10 @@ export interface IRelationForceOptions {
|
|
|
446
824
|
gravity?: number;
|
|
447
825
|
}
|
|
448
826
|
export type ChartStyle = DeepPartial<IChartStyle>;
|
|
449
|
-
export
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
}
|
|
827
|
+
export type ChartRenderRuntimeContext = Omit<DeepPartial<IChartRuntimeContext>, 'localeTexts'> & Pick<IChartRuntimeContext, 'localeTexts'>;
|
|
828
|
+
export type ChartRuntimeStyle = Omit<ChartStyle, 'runtime'> & {
|
|
829
|
+
runtime: ChartRenderRuntimeContext;
|
|
830
|
+
};
|
|
453
831
|
export interface IChartConfig extends IChartData {
|
|
454
832
|
type: ChartTypeBits;
|
|
455
833
|
}
|
|
@@ -457,20 +835,25 @@ export interface IChartSnapshot {
|
|
|
457
835
|
id: string;
|
|
458
836
|
chartType: ChartTypeBits;
|
|
459
837
|
orient?: DataOrientation;
|
|
460
|
-
context?:
|
|
838
|
+
context?: IChartSnapshotContext;
|
|
461
839
|
style?: ChartStyle;
|
|
462
840
|
dataAggregation?: IChartDataAggregation;
|
|
463
841
|
}
|
|
842
|
+
/** Persisted chart field selection accepted by the snapshot reader. */
|
|
843
|
+
export interface IChartSnapshotContext extends Pick<IChartContext, 'categoryIndexes' | 'seriesIndexes' | 'histogram'> {
|
|
844
|
+
/** Historical snapshot field decoded only when `categoryIndexes` is absent. */
|
|
845
|
+
categoryIndex?: number;
|
|
846
|
+
}
|
|
464
847
|
export interface IWaterfallLegendData {
|
|
465
848
|
name: string;
|
|
466
849
|
color: ChartColor;
|
|
467
850
|
}
|
|
468
851
|
export interface IChartRenderSpecConverter<ChartRenderSpec = Record<string, any>> {
|
|
469
852
|
canConvert: (config: IChartConfig) => boolean;
|
|
470
|
-
convert: (config: IChartConfig, style:
|
|
853
|
+
convert: (config: IChartConfig, style: ChartRuntimeStyle) => ChartRenderSpec;
|
|
471
854
|
}
|
|
472
855
|
export type ChartConfigInterceptor = (config: IChartConfig) => IChartConfig;
|
|
473
|
-
export type RenderSpecOperator<ChartRenderSpec> = (spec: ChartRenderSpec, style:
|
|
856
|
+
export type RenderSpecOperator<ChartRenderSpec> = (spec: ChartRenderSpec, style: ChartRuntimeStyle, config: IChartConfig, instance: IChartInstance) => void;
|
|
474
857
|
export declare enum ChartHostRenderMode {
|
|
475
858
|
Image = "image",
|
|
476
859
|
Dom = "dom"
|
|
@@ -514,7 +897,7 @@ export interface IDomChartHost extends IChartHost {
|
|
|
514
897
|
export interface IChartRenderInput {
|
|
515
898
|
chartId: string;
|
|
516
899
|
config: IChartConfig;
|
|
517
|
-
style:
|
|
900
|
+
style: ChartRuntimeStyle;
|
|
518
901
|
}
|
|
519
902
|
export interface IChartRenderModelImageExportInput extends IChartRenderInput {
|
|
520
903
|
width: number;
|
|
@@ -555,12 +938,12 @@ export interface IChartRenderInstanceCreateContext<Spec = Record<string, any>> {
|
|
|
555
938
|
prepareSpec?: (input: IChartRenderInstanceSpecInput<Spec>) => Spec;
|
|
556
939
|
}
|
|
557
940
|
export interface IChartRenderModelStylizeInit<Spec> {
|
|
558
|
-
chartStyle:
|
|
941
|
+
chartStyle: ChartRuntimeStyle;
|
|
559
942
|
chartConfig: IChartConfig;
|
|
560
943
|
chartInstance?: IChartInstance<Spec>;
|
|
561
944
|
}
|
|
562
945
|
export interface IChartRenderModel<Spec extends Record<string, any> = Record<string, any>> extends IDisposable {
|
|
563
|
-
toSpec(chartConfig: IChartConfig, style:
|
|
946
|
+
toSpec(chartConfig: IChartConfig, style: ChartRuntimeStyle): Spec;
|
|
564
947
|
stylizeSpec(spec: Spec, stylizeInit: IChartRenderModelStylizeInit<Spec>, rect: IChartHostRect): Spec;
|
|
565
948
|
exportImage(input: IChartRenderModelImageExportInput, options?: IChartRenderModelImageExportOptions): Promise<IChartRenderModelImageExportResult>;
|
|
566
949
|
updateWatermark(addWatermark: boolean): void;
|
|
@@ -630,6 +1013,17 @@ export interface IChartElementHit {
|
|
|
630
1013
|
seriesId?: string;
|
|
631
1014
|
seriesName?: string;
|
|
632
1015
|
dataIndex?: number;
|
|
1016
|
+
/** Stable runtime identity for an aggregated semantic mark. Renderer indexes are intentionally omitted. */
|
|
1017
|
+
semanticId?: string;
|
|
1018
|
+
semanticKind?: 'node' | 'link';
|
|
1019
|
+
semanticValue?: number;
|
|
1020
|
+
semanticFormattedValue?: string;
|
|
1021
|
+
semanticEndpointAName?: string;
|
|
1022
|
+
semanticEndpointBName?: string;
|
|
1023
|
+
pieCompositeRole?: PieCompositeMarkRole;
|
|
1024
|
+
pieCompositePlot?: PieCompositePlot;
|
|
1025
|
+
pieSourcePointIndex?: number;
|
|
1026
|
+
pieAggregateMemberSourcePointIndexes?: readonly number[];
|
|
633
1027
|
baseSeriesIndex?: string;
|
|
634
1028
|
waterfallSeriesType?: WaterfallSeriesTypeEnum;
|
|
635
1029
|
}
|
|
@@ -664,6 +1058,7 @@ export type OptionalDataValue = number | string | null | undefined;
|
|
|
664
1058
|
export type ExtractArrayItem<T> = T extends Array<infer U> ? U : never;
|
|
665
1059
|
export type EChartSpec = EChartsOption;
|
|
666
1060
|
export type EChartSeriesItem = ExtractArrayItem<EChartSpec['series']> & {
|
|
1061
|
+
formattedData?: string[];
|
|
667
1062
|
rawData?: number[];
|
|
668
1063
|
seriesId: string;
|
|
669
1064
|
};
|
package/lib/types/util.d.ts
CHANGED
|
@@ -3,7 +3,7 @@ export declare const chartBitsUtils: {
|
|
|
3
3
|
has(bit: number, attribute: number): boolean;
|
|
4
4
|
baseOn(bit: number, base: number): boolean;
|
|
5
5
|
remove(bit: number, attribute: number): number;
|
|
6
|
-
chartBitToString(bit: ChartTypeBits): "" | "line" | "bar" | "
|
|
6
|
+
chartBitToString(bit: ChartTypeBits): "" | "line" | "bar" | "pie" | "radar" | "scatter" | "combination" | "wordCloud" | "funnel" | "sankey" | "heatmap" | "boxplot" | "candlestick" | "treemap" | "sunburst" | "gauge" | "chord" | "graph";
|
|
7
7
|
};
|
|
8
8
|
export declare function mergeChartConfig<T extends object>(current: T | undefined, update: Partial<T>): T;
|
|
9
9
|
export declare const setProperty: (data: Record<string, any>, propertyPath: string, value: any) => void;
|
|
@@ -14,11 +14,6 @@ export declare const getProperty: <T = any>(data: Record<string, any> | undefine
|
|
|
14
14
|
*/
|
|
15
15
|
export declare const setGraphicToSpec: (spec: Record<string, any>, graphicElements: unknown[]) => void;
|
|
16
16
|
export declare const translateAngleToRadian: (angle: number) => number;
|
|
17
|
-
interface ISize {
|
|
18
|
-
width: number;
|
|
19
|
-
height: number;
|
|
20
|
-
}
|
|
21
|
-
export declare const calcPosition: (text: string, font: string) => ISize;
|
|
22
17
|
/**
|
|
23
18
|
* We define the chart type can use trend line. In excel it also can use for combined chart ro bar chart.
|
|
24
19
|
* @param {ChartTypeBits} chartType The test chart type.
|
|
@@ -26,4 +21,3 @@ export declare const calcPosition: (text: string, font: string) => ISize;
|
|
|
26
21
|
*/
|
|
27
22
|
export declare const chartTypeCanUseTrendLine: (chartType: ChartTypeBits) => boolean;
|
|
28
23
|
export declare function isNegativeRedCached(fmt: string): boolean | undefined;
|
|
29
|
-
export {};
|
|
@@ -14,4 +14,3 @@ export declare const echarts: {
|
|
|
14
14
|
registerPreprocessor: typeof registerPreprocessor;
|
|
15
15
|
util: typeof util;
|
|
16
16
|
};
|
|
17
|
-
export type { BarSeriesOption, DatasetComponentOption, ECharts, EChartsInitOpts, EChartsOption, FunnelSeriesOption, LegendComponentOption, LineSeriesOption, PieSeriesOption, XAXisComponentOption, } from 'echarts';
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import type { echarts } from '../../../utils/echarts';
|
|
2
|
-
import { WORD_CLOUD_SERIES_TYPE } from './echarts-options';
|
|
3
2
|
export interface IRegisterWordCloudChartViewContext {
|
|
4
3
|
createTextElement(layout: any, data: any, dataIndex: number, seriesModel: any): unknown;
|
|
5
4
|
}
|
|
6
5
|
export declare function registerWordCloudChartView(echartsInstance: typeof echarts, context: IRegisterWordCloudChartViewContext): void;
|
|
7
|
-
export { WORD_CLOUD_SERIES_TYPE };
|