@descope/web-components-ui 1.0.299 → 1.0.300
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/index.esm.js +9 -5
- package/dist/index.esm.js.map +1 -1
- package/dist/umd/descope-new-password-descope-new-password-internal-index-js.js +1 -1
- package/dist/umd/descope-new-password-index-js.js +1 -1
- package/package.json +1 -1
- package/src/components/descope-new-password/descope-new-password-internal/NewPasswordInternal.js +9 -5
package/dist/index.esm.js
CHANGED
@@ -6452,14 +6452,16 @@ class NewPasswordInternal extends BaseInputClass$4 {
|
|
6452
6452
|
});
|
6453
6453
|
|
6454
6454
|
super.init?.();
|
6455
|
-
this.renderInputs(this.hasConfirm);
|
6455
|
+
this.renderInputs(this.hasConfirm, this.hasValidation);
|
6456
6456
|
}
|
6457
6457
|
|
6458
|
-
renderInputs(shouldRenderConfirm) {
|
6458
|
+
renderInputs(shouldRenderConfirm, shouldRenderValidation) {
|
6459
6459
|
let template = `
|
6460
6460
|
<div>
|
6461
6461
|
<descope-password data-id="password"></descope-password>
|
6462
|
-
<descope-policy-validation
|
6462
|
+
<descope-policy-validation class="${
|
6463
|
+
shouldRenderValidation ? 'hidden' : ''
|
6464
|
+
}"></descope-policy-validation>
|
6463
6465
|
</div>
|
6464
6466
|
`;
|
6465
6467
|
|
@@ -6570,8 +6572,10 @@ class NewPasswordInternal extends BaseInputClass$4 {
|
|
6570
6572
|
super.attributeChangedCallback?.(attrName, oldValue, newValue);
|
6571
6573
|
|
6572
6574
|
if (oldValue !== newValue) {
|
6573
|
-
if (attrName === 'has-
|
6574
|
-
this.renderInputs(
|
6575
|
+
if (attrName === 'has-validation') {
|
6576
|
+
this.renderInputs(this.hasConfirm, newValue === 'true');
|
6577
|
+
} else if (attrName === 'has-confirm') {
|
6578
|
+
this.renderInputs(newValue !== null && newValue !== 'false', this.hasValidation);
|
6575
6579
|
} else if (commonAttrs.includes(attrName)) {
|
6576
6580
|
this.inputs.forEach((input) => this.toggleBooleanAttribute(input, attrName, newValue));
|
6577
6581
|
} else if (passwordInputAttrs.includes(attrName)) {
|