svelecte
svelecte copied to clipboard
Refactor css to allow to pass inline CSS variables
Hi is it still expected to use `global` for basic styling? Passing a CSS variable to the component (`<Svelecte --sv-min-height="35px" />`) does not work since it is wrapped in extra markup . It also get overriden for any element that isn't the root `.svelecte-control` since the CSS variables are reapplied for each sub-element, example with
<style>
:global(.svelecte-control) {
--sv-min-height: 32px ;
}
</style>
CSS variable is applied for top-level element:
But default comes back for any nested element:
Originally posted by @gterras in https://github.com/mskocik/svelecte/issues/98#issuecomment-1326331763