Open ClaudiaJ opened 3 weeks ago
that is an interesting use case, and can definitely add nice touches to certain forms. Let me think about it. Adding every field as a property to the form can very quickly bloat it, so it will need to be an optional thing, and will probably not make sense for all the input types.
Is your feature request related to a problem? Please describe.
No problem, just a nice to have.
Describe the solution you'd like
I would like to style the modal form based on selected values.
This could be achieved by setting
data-value
parameter on the inputs corresponding to the selected value, something likeoninput="this.dataset.value=this.value"
[^credit-connexo-so] should make that work easy squeezy.[^credit-connexo-so]: credit: user
connexo
on Stack Overflow from a quick searchy searchAdditional context
Example:
In this form, I would like to apply a color mapping by the
Subjective Unit of Distress
value, ranging from green to blue to red, and prefix the description input with a cute little temperature icons fromFont Awesome
.With the described potential implementation, I could likely achieve what I'm imagining here w/ CSS by matching
[data-value="N"]
(where N is 0-10).Thank you for considering this Feature Request