blob: 5eaeced7cf4a8b84412e64a8eb9657cea1698253 [file] [log] [blame]
(window.webpackJsonp=window.webpackJsonp||[]).push([[16],{317:function(e,n,t){"use strict";t.r(n),n.default="# Apache ECharts 5.6.0 Features\n\n## Define Region Styles in Original GeoJSON Data\n\nECharts maps use GeoJSON format to define data. In theory, following the principle of \"separation of data and style\", GeoJSON should only define data while styles should be defined in ECharts. However, in some cases, styles themselves are a form of data expression (for example: using dashed lines to represent disputed borders - here the \"dashed line\" is a style but actually expresses a data concept, so defining styles in GeoJSON is reasonable).\n\nIn ECharts 5.6.0, we support defining region styles in the original GeoJSON data by specifying `features[].properties.echartsStyle`. This is consistent with the [data](${optionPath}series-map.data) option, which supports configuring `itemStyle`, `label`, `tooltip` etc. Example:\n\n```ts\ngeoJSON.features[0].properties.echartsStyle = {\n itemStyle: {\n areaColor: 'green'\n }\n}\n\ngeoJSON.features[1].properties.echartsStyle = {\n selected: true,\n label: {\n formatter: 'Default Selected:\\n{b}'\n }\n}\n\ngeoJSON.features[2].properties.echartsStyle = {\n itemStyle: {\n borderType: 'dotted',\n borderColor: 'blue'\n }\n}\n\ngeoJSON.features[11].properties.echartsStyle = {\n itemStyle: {\n // This region will be overridden as `cyan` by the data item option\n areaColor: 'black'\n },\n tooltip: {\n formatter: function (params) {\n return 'This is a custom tooltip from GeoJSON: ' + params.name;\n }\n }\n}\n```\n\n## Axis Labels Support Tooltips\n\nIn some cases, axis labels are too long or we want to display more information on axis labels. In ECharts 5.6.0, we support adding tooltips to axis labels. The configuration is consistent with the `tooltip` option, please refer to [axis.tooltip documentation](${optionPath}xAxis.tooltip) for details.\n\n![](images/5-6-0/axis-tooltip.png)\n\n## Sunburst Chart Supports Focusing All Descendants and Ancestors\n\nIn previous versions of sunburst charts, [emphasis.focus](${optionPath}series-sunburst.emphasis.focus) supported the following values:\n\n- `'none'` Do not fade out other data, it's by default.\n- `'self'` Only focus (not fade out) the element of the currently highlighted data.\n- `'series'` Focus on all elements of the series which the currently highlighted data belongs to.\n- `'ancestor'` Focus on all ancestor nodes.\n'descendant' Focus on all descendants nodes.\n\nIn ECharts 5.6.0, we added `'relative'`, which focuses on all descendants and ancestor nodes.\n\n![](images/5-6-0/sunburst-emphasis-relative.png)\n\n## Added Support for Two New Languages\n\nIn this version, support for Swedish and Persian languages has been added. With this, ECharts now supports 22 languages.\n\n## Line Chart Performance Optimization\n\nIn this version, we optimized the rendering performance of line charts, solving the problem of memory growth with time.\n\n## Complete Changelog\n\nView the [changelog](${mainSitePath}changelog.html#v5-6-0)\n\nThe next major version, Apache ECharts 6.0.0, is currently being actively developed and is expected to be released in the first quarter of 2025. Stay tuned for more updates.\n"}}]);