upmostly / modali

A delightful modal dialog component for React, built from the ground up to support React Hooks.
212 stars 23 forks source link

separate display from logic #25

Open wmertens opened 5 years ago

wmertens commented 5 years ago

I like the approach here and I appreciate all the aria things, but I think the current styling approach is a bit heavy-handed.

How about separating the styling into the absolutely necessary for modals, and the optional for making it look nice? Then the necessary bits can be done with inline styles, which work everywhere, and the optional bits can be in a css file that the user has to include themselves.

An additional approach would be to allow passing components that replace the ones with optional styling. That way css-in-js can be used as well.

King-Success commented 4 years ago

I agree with this. It should allow for inline styling!