Closed etc-tiago closed 4 years ago
@kripod If you find this feature interesting, I can do the implementation and create a pull request
Thank you for this submission! I left my review at #30, suggesting to join the ongoing discussion at #3, so that we can think about this deeper before experimenting with implementations. I'm closing this issue for now to focus the discourse to a single place.
Motivation
My web application has some buttons and inputs with the same styles, but with peculiarities that make them the same. And instead of writing the css in each element and when it is necessary to change something having to practically redo the whole process in each button, we could store the value of these repetitive styles in a variable of the type
ScopedCSSRules
and join in the functioncss
Basic example
Allow:
and
This example is extremely basic, but represents an override of styles that are considered a good feature.
Steps to implementation
[ ] Update OtionInstance interface
[ ] Update css function
I am using this code separately from otion, and in my opinion it would be a very desired feature since there are several codes that are repeated in the css style and in some cases it would be very nice to be able to overwrite some styles before generating the class.
I tried to create a pull request, but I still haven't been able to normalize the typing then getting the error: