theKashey / react-focus-on

🎯 Solution for WAI ARIA compatible modal dialogs or full-screen tasks, you were looking for
MIT License
336 stars 14 forks source link

Passed className prop to outer div #30

Closed sami616 closed 4 years ago

sami616 commented 4 years ago

Hello i couldn't find a contributing guide but i've made the basic changes to pass the classname prop down to the most outer div in the component for easier styling based on the issue i filed

Fixes #29

theKashey commented 4 years ago

FocusLock will also generate a div, which you will not able to style. It would be not a great solution. However, I reckon nobody target that secondary div with exact CSS rules, and we could remove...

sami616 commented 4 years ago

Would changing the fragment you have wrapping your components to a div and applying a className prop to that work?

theKashey commented 4 years ago

There is no such thing as "work" - there are different use cases, and it would work for one, and not for another. I am already trying to keep only one div, it would be logical to apply className on, but it requires changes to all sub-libraries use by this one.

theKashey commented 4 years ago

Closing in favor of #31