@fluentui/react-charting 5.23.21 → 5.23.23

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 (41) hide show
  1. package/CHANGELOG.json +49 -1
  2. package/CHANGELOG.md +23 -2
  3. package/dist/react-charting.d.ts +40 -5
  4. package/dist/react-charting.js +1 -1
  5. package/dist/react-charting.min.js +1 -1
  6. package/etc/react-charting.api.md +2 -0
  7. package/lib/components/DeclarativeChart/DeclarativeChart.d.ts +1 -0
  8. package/lib/components/DeclarativeChart/DeclarativeChart.js +16 -10
  9. package/lib/components/DeclarativeChart/DeclarativeChart.js.map +1 -1
  10. package/lib/components/DeclarativeChart/PlotlySchemaAdapter.d.ts +9 -9
  11. package/lib/components/DeclarativeChart/PlotlySchemaAdapter.js +24 -21
  12. package/lib/components/DeclarativeChart/PlotlySchemaAdapter.js.map +1 -1
  13. package/lib/components/Legends/Legends.base.d.ts +14 -8
  14. package/lib/components/Legends/Legends.base.js +53 -34
  15. package/lib/components/Legends/Legends.base.js.map +1 -1
  16. package/lib/components/Legends/Legends.types.d.ts +40 -5
  17. package/lib/components/Legends/Legends.types.js.map +1 -1
  18. package/lib-amd/components/DeclarativeChart/DeclarativeChart.d.ts +1 -0
  19. package/lib-amd/components/DeclarativeChart/DeclarativeChart.js +18 -12
  20. package/lib-amd/components/DeclarativeChart/DeclarativeChart.js.map +1 -1
  21. package/lib-amd/components/DeclarativeChart/PlotlySchemaAdapter.d.ts +9 -9
  22. package/lib-amd/components/DeclarativeChart/PlotlySchemaAdapter.js +24 -21
  23. package/lib-amd/components/DeclarativeChart/PlotlySchemaAdapter.js.map +1 -1
  24. package/lib-amd/components/Legends/Legends.base.d.ts +14 -8
  25. package/lib-amd/components/Legends/Legends.base.js +53 -34
  26. package/lib-amd/components/Legends/Legends.base.js.map +1 -1
  27. package/lib-amd/components/Legends/Legends.types.d.ts +40 -5
  28. package/lib-amd/components/Legends/Legends.types.js.map +1 -1
  29. package/lib-commonjs/components/DeclarativeChart/DeclarativeChart.d.ts +1 -0
  30. package/lib-commonjs/components/DeclarativeChart/DeclarativeChart.js +18 -11
  31. package/lib-commonjs/components/DeclarativeChart/DeclarativeChart.js.map +1 -1
  32. package/lib-commonjs/components/DeclarativeChart/PlotlySchemaAdapter.d.ts +9 -9
  33. package/lib-commonjs/components/DeclarativeChart/PlotlySchemaAdapter.js +24 -21
  34. package/lib-commonjs/components/DeclarativeChart/PlotlySchemaAdapter.js.map +1 -1
  35. package/lib-commonjs/components/Legends/Legends.base.d.ts +14 -8
  36. package/lib-commonjs/components/Legends/Legends.base.js +53 -34
  37. package/lib-commonjs/components/Legends/Legends.base.js.map +1 -1
  38. package/lib-commonjs/components/Legends/Legends.types.d.ts +40 -5
  39. package/lib-commonjs/components/Legends/Legends.types.js.map +1 -1
  40. package/package.json +3 -3
  41. package/src/components/Legends/Legends.types.ts +42 -5
@@ -226,18 +226,55 @@ export interface ILegendsProps {
226
226
  onChange?: (selectedLegends: string[], event: React.MouseEvent<HTMLButtonElement>, currentLegend?: ILegend) => void;
227
227
 
228
228
  /**
229
- * Keys (title) that will be initially used to set selected items.
230
- * This prop is used for multiSelect scenarios.
231
- * In other cases, defaultSelectedLegend should be used.
229
+ * Keys (title) that will be initially used to set selected items. This prop is used for multi-select scenarios when
230
+ * canSelectMultipleLegends is true; for single-select, use defaultSelectedLegend.
231
+ *
232
+ * Updating this prop does not change the selection after the component has been initialized. For controlled
233
+ * selections, use selectedLegends instead.
234
+ *
235
+ * @see selectedLegends for setting the selected legends in controlled mode.
236
+ * @see defaultSelectedLegend for setting the initially selected legend when canSelectMultipleLegends is false.
232
237
  */
233
238
  defaultSelectedLegends?: string[];
234
239
 
235
240
  /**
236
- * Key that will be initially used to set selected item.
237
- * This prop is used for singleSelect scenarios.
241
+ * Key that will be initially used to set selected item. This prop is used for single-select scenarios when
242
+ * canSelectMultipleLegends is false or unspecified; for multi-select, use defaultSelectedLegends.
243
+ *
244
+ * Updating this prop does not change the selection after the component has been initialized. For controlled
245
+ * selections, use selectedLegend instead.
246
+ *
247
+ * @see selectedLegend for setting the selected legend in controlled mode.
248
+ * @see defaultSelectedLegends for setting the initially selected legends when canSelectMultipleLegends is true.
238
249
  */
239
250
  defaultSelectedLegend?: string;
240
251
 
252
+ /**
253
+ * Keys (title) that will be used to set selected items in multi-select scenarios when canSelectMultipleLegends is
254
+ * true. For single-select, use selectedLegend.
255
+ *
256
+ * When this prop is provided, the component is controlled and does not automatically update the selection based on
257
+ * user interactions; the parent component must update the value passed to this property by handling the onChange
258
+ * event.
259
+ *
260
+ * @see defaultSelectedLegends for setting the initially-selected legends in uncontrolled mode.
261
+ * @see selectedLegends for setting the selected legends when `canSelectMultipleLegends` is `true`.
262
+ */
263
+ selectedLegends?: string[];
264
+
265
+ /**
266
+ * Key (title) that will be used to set the selected item in single-select scenarios when canSelectMultipleLegends is
267
+ * false or unspecified. For multi-select, use selectedLegends.
268
+ *
269
+ * When this prop is provided, the component is controlled and does not automatically update the selection based on
270
+ * user interactions; the parent component must update the value passed to this property by handling the onChange
271
+ * event.
272
+ *
273
+ * @see defaultSelectedLegend for setting the initially-selected legend in uncontrolled mode.
274
+ * @see selectedLegend for setting the selected legend when `canSelectMultipleLegends` is `false`.
275
+ */
276
+ selectedLegend?: string;
277
+
241
278
  /**
242
279
  * The shape for the legend.
243
280
  */