@descope/web-components-ui 1.53.0 → 1.55.0

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.
@@ -10587,7 +10587,7 @@ class RawPolicyValidation extends createBaseClass({ componentName: componentName
10587
10587
 
10588
10588
  if (attrName === 'data-password-policy-value-passwordstrength') {
10589
10589
  const passwordStrength = parseInt(newValue);
10590
- if (!Number.isNaN(passwordStrength) && passwordStrength > 0) {
10590
+ if (!Number.isNaN(passwordStrength) && passwordStrength >= 0) {
10591
10591
  this.#overrides = {
10592
10592
  ...this.#overrides,
10593
10593
  passwordstrength: {
@@ -10600,7 +10600,7 @@ class RawPolicyValidation extends createBaseClass({ componentName: componentName
10600
10600
 
10601
10601
  if (attrName === 'data-password-policy-actual-passwordstrength') {
10602
10602
  const ln = Number(newValue);
10603
- if (!Number.isNaN(ln) && ln > 0) {
10603
+ if (!Number.isNaN(ln) && ln >= 0) {
10604
10604
  this.#overrides = {
10605
10605
  ...this.#overrides,
10606
10606
  passwordstrength: { ...this.#overrides?.passwordstrength, actual: ln },
@@ -10685,7 +10685,11 @@ class RawPolicyValidation extends createBaseClass({ componentName: componentName
10685
10685
  const exp = new RegExp(interpolateString(pattern, data));
10686
10686
  validationResult.valid = exp.test(this.value);
10687
10687
  } else if (compare) {
10688
- validationResult.valid = this.compareValues(compare, data.expected, data.actual);
10688
+ validationResult.valid = this.compareValues(
10689
+ compare,
10690
+ data?.expected ?? -1,
10691
+ data?.actual ?? -1
10692
+ );
10689
10693
  }
10690
10694
 
10691
10695
  results.push(validationResult);
@@ -12866,7 +12870,12 @@ const multiSelectComboBoxMixin = (superclass) =>
12866
12870
 
12867
12871
  // eslint-disable-next-line class-methods-use-this
12868
12872
  #renderItem = ({ displayName, value, label }) => {
12869
- return `<span data-name="${label}" data-id="${value}">${displayName || label}</span>`;
12873
+ const ele = document.createElement('span');
12874
+ ele.setAttribute('data-name', label);
12875
+ ele.setAttribute('data-id', value);
12876
+ ele.textContent = displayName || label;
12877
+
12878
+ return ele.outerHTML;
12870
12879
  };
12871
12880
 
12872
12881
  #data;