microsoft / fluentui-system-icons

Fluent System Icons are a collection of familiar, friendly and modern icons from Microsoft.
https://aka.ms/fluentui-system-icons
MIT License
5.93k stars 517 forks source link

Feature: Support auto-mirroring React icons #553

Open behowell opened 1 year ago

behowell commented 1 year ago

Feature request: https://github.com/microsoft/fluentui/issues/25624

### Tasks
- [ ] Add support for applying mirroring styles (`transform: 'scaleX(-1)'`) when generating the React icon
- [ ] Fill out the list of icons that should flip: [rtl.txt](https://github.com/microsoft/fluentui-system-icons/blob/main/importer/rtl.txt) (might need to create a new list -- check how this one is currently used)
- [ ] (Maybe) Add a prop to control the flipping behavior (opt-out of auto-flipping)
- [ ] Add support for conditionally rendering a different SVG based on RTL (e.g. `BookQuestionMark24Regular` => `BookQuestionMarkRtl24Regular`)
- [ ] (Maybe) Export a function to create icons that swap SVGs based on RTL (similar to `bundleIcon`)