UNPKG

@mui/x-charts

Version:

The community edition of the charts components (MUI X).

16 lines 439 B
var legendGetter = function legendGetter(params) { var seriesOrder = params.seriesOrder, series = params.series; return seriesOrder.flatMap(function (seriesId) { return series[seriesId].data.map(function (item) { return { color: item.color, label: item.label, id: item.id }; }).filter(function (item) { return item.label !== undefined; }); }); }; export default legendGetter;