victory
victory copied to clipboard
Fix label spacing and text size approximation to support non-latin characters and RTL
This is an issue to overhaul how label size is determined. Right now, label size is approximated using the size of specific characters in specific fonts, but this does not adapt to custom fonts, non-Latin character sets, and RTL text.
This solution might require some discussion - right now the only proposed fix for this would be to pre-render the text with a CSS rule like visibility: hidden
, measure the text, and re-render the text with the correct spacing. Are there other solutions to this problem?
Note for contributors: This issue is most likely a medium time commitment (1 week or more), but doesn't touch as much of the complex Victory internals.
Most of this work is currently being done in textsize.js.
@becca-bailey did you added feature to support charts for RTL?
@becca-bailey @boygirl Is RTL supported on victory-native charts now?