@descope/web-components-ui 1.0.258 → 1.0.259

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -528,8 +528,7 @@ const globals = {
528
528
  };
529
529
  const vars$x = getThemeVars(globals);
530
530
 
531
- const createCssVarFallback = (first, ...rest) =>
532
- `var(${first}${rest.length ? ` , ${createCssVarFallback(...rest)}` : ''})`;
531
+ const createCssVar = (varName, fallback) => `var(${varName}${fallback ? `, ${fallback}` : ''})`;
533
532
 
534
533
  const createCssSelector = (baseSelector = '', relativeSelectorOrSelectorFn = '') =>
535
534
  isFunction(relativeSelectorOrSelectorFn)
@@ -582,13 +581,15 @@ const createStyle = (componentName, baseSelector, mappings) => {
582
581
 
583
582
  const cssVarName = getCssVarName(componentName, attr);
584
583
 
585
- attrConfig.forEach(({ selector: relativeSelectorOrSelectorFn, property, important }) => {
586
- style.add(
587
- createCssSelector(baseSelector, relativeSelectorOrSelectorFn),
588
- isFunction(property) ? property() : property,
589
- createCssVarFallback(cssVarName) + (important ? '!important' : '')
590
- );
591
- });
584
+ attrConfig.forEach(
585
+ ({ selector: relativeSelectorOrSelectorFn, property, important, fallback }) => {
586
+ style.add(
587
+ createCssSelector(baseSelector, relativeSelectorOrSelectorFn),
588
+ isFunction(property) ? property() : property,
589
+ createCssVar(cssVarName, fallback) + (important ? '!important' : '')
590
+ );
591
+ }
592
+ );
592
593
  });
593
594
 
594
595
  return style.toString();
@@ -2432,7 +2433,6 @@ const resetStyles = `
2432
2433
  box-shadow: none;
2433
2434
  }
2434
2435
  vaadin-button::part(label) {
2435
- justify-content: center;
2436
2436
  padding: 0;
2437
2437
  width: 100%;
2438
2438
  }
@@ -2486,7 +2486,7 @@ const ButtonClass = compose(
2486
2486
  labelTextColor: { property: 'color' },
2487
2487
  labelTextDecoration: { ...label$a, property: 'text-decoration' },
2488
2488
  labelSpacing: { ...label$a, property: 'gap' },
2489
- textAlign: { ...label$a, property: 'justify-content', important: true },
2489
+ textAlign: { ...label$a, property: 'justify-content', fallback: 'center' },
2490
2490
  },
2491
2491
  }),
2492
2492
  clickableMixin,