cjens19 opened a new issue, #21205:
URL: https://github.com/apache/echarts/issues/21205

   ### Version
   
   6.0.0
   
   ### Link to Minimal Reproduction
   
   https://codesandbox.io/p/devbox/yr3gf4
   
   ### Steps to Reproduce
   
   1. Create the chart using ngx-echarts directive
   ```
   <div
     echarts
     [options]="chartOption"
     (chartInit)="onChartInit($event)"
     class="demo-chart"
     style="height: 400px"
   ></div>
   ```
   2. Hook into the dataZoom event handler and attempt to parse the batch items 
as their type
   ```
       this.chart.on('dataZoom', (params: unknown) => {
         const dataZoomParams = params as DataZoomEventParams;
   
         const payloadItems: DataZoomPayloadBatchItem[] = dataZoomParams.batch;
   ```
   3. Notice the import error for 
   `import { DataZoomPayloadBatchItem } from 
'echarts/types/src/component/dataZoom/helper';`
   
   ### Current Behavior
   
   The app fails to build because of the missing/failed import. 
   
   ### Expected Behavior
   
   The echarts library correctly exports its types so Angular 20 can consume 
them. If types have been removed or moved, then correct the breaking-changes 
documentation so consumers can be aware of changes they need to make.
   
   ### Environment
   
   ```markdown
   - OS: Windows 11
   - Browser: Chrome
   - Framework: Angular 20, Echarts 6.0.0, typescript 5.8.3
   ```
   
   ### Any additional comments?
   
   This code works for Angular 19 and before. There are also several other 
types now broken after trying to upgrade to Angular 20:
   ```
   import { CommonAxisPointerOption } from 'echarts/types/src/util/types';
   import { DataZoomOption } from 
'echarts/types/src/component/dataZoom/DataZoomModel';
   import { MarkArea2DDataItemOption } from 
'echarts/types/src/component/marker/MarkAreaModel';
   import { MarkLine1DDataItemOption } from 
'echarts/types/src/component/marker/MarkLineModel';
   import { MarkPointDataItemOption } from 
'echarts/types/src/component/marker/MarkPointModel';
   import { OptionDataValue } from 'echarts/types/src/util/types';
   import { ScatterDataItemOption } from 
'echarts/types/src/chart/scatter/ScatterSeries';
   import { TopLevelFormatterParams } from 
'echarts/types/src/component/tooltip/TooltipModel';
   ```
   
   Some of those are able to be fixed by adjusting the import path, but many 
seem to be not available anymore. If that's the case, can we get some 
breaking-changes documentation and perhaps type alternatives that are exported 
correctly?
   
   Another example: DataZoomOption, when the import is changed to 
'echarts/types/dist/shared', I get this error: 
   `TS2459: Module "echarts/types/dist/shared" declares DataZoomOption locally, 
but it is not exported`


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to