I replace the optionComponent prop of Selector with a cleaner renderOption prop. This simplifies a few things, including removing the need for dedicated option components (ScaleOption and ColorMapOption).
I replace the now-removed ColorMapOption, which was exported in the lib to address #1377, with a new component called ColorMapGradient that takes care only of rendering a little gradient preview for a given color map (which should in fact cover more customisation use cases).
NEW FEATURE
I create a component called ComplexVisTypeSelector (in line with ColorMapSelector and ScaleSelector) to reduce duplication, and I export it in the lib;
I move enum ComplexVisType to the shared package and I export it in the lib; I also replace its values and stop relying on them for display purposes (axis label, plot title, selector options), as this seemed very brittle and prevented displaying different labels in different places.
BREAKING
optionComponent
prop ofSelector
with a cleanerrenderOption
prop. This simplifies a few things, including removing the need for dedicated option components (ScaleOption
andColorMapOption
).ColorMapOption
, which was exported in the lib to address #1377, with a new component calledColorMapGradient
that takes care only of rendering a little gradient preview for a given color map (which should in fact cover more customisation use cases).NEW FEATURE
ComplexVisTypeSelector
(in line withColorMapSelector
andScaleSelector
) to reduce duplication, and I export it in the lib;ComplexVisType
to the shared package and I export it in the lib; I also replace its values and stop relying on them for display purposes (axis label, plot title, selector options), as this seemed very brittle and prevented displaying different labels in different places.