Too strict approach when hiding host element in Popover component #7979
Labels
question
Further information is requested
vaadin-popover
waiting for author
Further information is requested
Description
In a recent commit to the new Popover component the host element was set to hidden (see #7671), so it will be aligned with other modal-related components hidden host (see #3597).
However, in Popover, you use Lit's
static get styles
function, while in other components, like Dialog, you use a style tag in the template to achieve the same result (see https://github.com/vaadin/web-components/blob/main/packages/dialog/src/vaadin-dialog.js#L99).I was wondering if the latter approach, of using Lit to enforce static CSS, is not too harsh, and if it would be possible to maintain the template style approach instead.
I myself have a use case where I internalize the overlay to be within the shadow DOM (so it won't be affected from other styles in the page) and I need to override the hidden root style. While I was able to achieve this result with Dialog, it seems that in Popover there is no way to do it.
Expected outcome
instead of
Minimal reproducible example
...
Steps to reproduce
...
Environment
Vaadin version(s): 24.5.0
Browsers
No response
The text was updated successfully, but these errors were encountered: