vaadin / web-components

A set of high-quality standards based web components for enterprise web applications. Part of Vaadin 20+
https://vaadin.com/docs/latest/components
473 stars 83 forks source link

Bordered Lumo variants for input fields #5629

Open rolfsmeds opened 1 year ago

rolfsmeds commented 1 year ago

Describe your motivation

It's not uncommon to want to apply borders to certain instances of input fields, even if the application's theme generally uses borderless input fields like the default Lumo styling.

The introduction of optional borders, applied by providing a value to the --vaadin-input-field-border-width property, makes this already possible, but it would be much more convenient – and consistent with other style variants – to have proper theme name variants for the bordered style in Lumo.

Describe the solution you'd like

Lumo theme variants for boredered input fields through the usual theme variant API:

Describe alternatives you've considered

No response

Additional context

No response

jouni commented 1 year ago

Lumo theme variants for boredered input fields through the usual theme variant API

Instead of bloating the built-in stylesheets with more variants, I would rather bundle these as part of the upcoming theme editor. My assumption is that you either want every input field in your app to have borders, or none of them. So you basically want to adjust the default variant, instead of a case-by-case variant.

If I could go back in time, I think I would apply this to some/many of the existing built-in variants as well.