@descope/flow-components 3.26.4 → 3.27.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.
- package/dist/fm/222.js +1 -1
- package/dist/fm/222.js.map +1 -1
- package/dist/fm/734.js +1 -1
- package/dist/fm/734.js.map +1 -1
- package/dist/fm/761.js +1 -1
- package/dist/fm/761.js.map +1 -1
- package/dist/fm/985.js +1 -1
- package/dist/fm/985.js.map +1 -1
- package/dist/fm/__federation_expose_componentClasses.js +1 -1
- package/dist/fm/__federation_expose_componentClasses.js.map +1 -1
- package/dist/fm/__federation_expose_components.js +1 -1
- package/dist/fm/__federation_expose_theme.js +1 -1
- package/dist/fm/__federation_expose_theme.js.map +1 -1
- package/dist/fm/flowComponents.js +1 -1
- package/dist/fm/flowComponents.js.map +1 -1
- package/dist/fm/main.js +1 -1
- package/dist/fm/main.js.map +1 -1
- package/dist/fm/mf-manifest.json +1 -1
- package/dist/fm/mf-stats.json +1 -1
- package/dist/index.cjs.js +47 -0
- package/package.json +2 -2
package/dist/fm/mf-manifest.json
CHANGED
package/dist/fm/mf-stats.json
CHANGED
package/dist/index.cjs.js
CHANGED
|
@@ -98226,6 +98226,20 @@ function requireIndex_cjs () {
|
|
|
98226
98226
|
const unicodePattern =
|
|
98227
98227
|
"^[\\p{L}\\p{M}\\p{N}._%+'\\-]+@(?:[\\p{L}\\p{M}\\p{N}](?:[\\p{L}\\p{M}\\p{N}\\-]*[\\p{L}\\p{M}\\p{N}])?\\.)+[\\p{L}\\p{M}][\\p{L}\\p{M}\\p{N}\\-]+$";
|
|
98228
98228
|
|
|
98229
|
+
// The autocomplete grammar is ordered (section-*, shipping/billing, field name, webauthn) and on/off can't be
|
|
98230
|
+
// combined with a field name, so `email` takes the field name's place, before webauthn
|
|
98231
|
+
const emailVerificationAutocomplete = (autocomplete) => {
|
|
98232
|
+
const tokens = (autocomplete || '')
|
|
98233
|
+
.split(/\s+/)
|
|
98234
|
+
.filter(
|
|
98235
|
+
(token) => token && !['username', 'email', 'on', 'off'].includes(token),
|
|
98236
|
+
);
|
|
98237
|
+
const webauthn = tokens.indexOf('webauthn');
|
|
98238
|
+
tokens.splice(webauthn === -1 ? tokens.length : webauthn, 0, 'email');
|
|
98239
|
+
|
|
98240
|
+
return tokens.join(' ');
|
|
98241
|
+
};
|
|
98242
|
+
|
|
98229
98243
|
const componentName$U = getComponentName('email-field');
|
|
98230
98244
|
|
|
98231
98245
|
const defaultAutocomplete = 'username';
|
|
@@ -98274,6 +98288,38 @@ function requireIndex_cjs () {
|
|
|
98274
98288
|
if (!this.validatesFormat) {
|
|
98275
98289
|
this.disableFormatValidation();
|
|
98276
98290
|
}
|
|
98291
|
+
|
|
98292
|
+
if (this.emailVerification) {
|
|
98293
|
+
this.enableEmailVerification();
|
|
98294
|
+
}
|
|
98295
|
+
}
|
|
98296
|
+
|
|
98297
|
+
// Read once, in `init`: descope-wc renders the screen html once
|
|
98298
|
+
get emailVerification() {
|
|
98299
|
+
return this.getAttribute('email-verification') === 'true';
|
|
98300
|
+
}
|
|
98301
|
+
|
|
98302
|
+
// Browser email verification needs the native input to be an email field (autocomplete `email`).
|
|
98303
|
+
// The host keeps its own autocomplete: descope-wc finds the passkey autofill field by an exact
|
|
98304
|
+
// `[autocomplete="webauthn"]` match on it, so changing the host would break passkeys
|
|
98305
|
+
enableEmailVerification() {
|
|
98306
|
+
const { baseElement } = this;
|
|
98307
|
+
const delegate = baseElement._delegateAttribute.bind(baseElement);
|
|
98308
|
+
// vaadin writes the native autocomplete only through here, so it writes ours
|
|
98309
|
+
baseElement._delegateAttribute = (name, value) =>
|
|
98310
|
+
delegate(
|
|
98311
|
+
name,
|
|
98312
|
+
name === 'autocomplete'
|
|
98313
|
+
? emailVerificationAutocomplete(value)
|
|
98314
|
+
: value,
|
|
98315
|
+
);
|
|
98316
|
+
baseElement._delegateAttribute('autocomplete', baseElement.autocomplete);
|
|
98317
|
+
|
|
98318
|
+
// the external input copies the host autocomplete once, when it is created
|
|
98319
|
+
this.externalInput?.setAttribute(
|
|
98320
|
+
'autocomplete',
|
|
98321
|
+
emailVerificationAutocomplete(this.getAttribute('autocomplete')),
|
|
98322
|
+
);
|
|
98277
98323
|
}
|
|
98278
98324
|
|
|
98279
98325
|
enableUnicode() {
|
|
@@ -100639,6 +100685,7 @@ function requireIndex_cjs () {
|
|
|
100639
100685
|
${useHostExternalPadding(PasswordClass.cssVarList)}
|
|
100640
100686
|
${resetInputCursor('vaadin-password-field')}
|
|
100641
100687
|
${resetInputLabelPosition('vaadin-password-field')}
|
|
100688
|
+
${resetInputAutoFill('vaadin-password-field', PasswordClass.cssVarList)}
|
|
100642
100689
|
|
|
100643
100690
|
vaadin-password-field {
|
|
100644
100691
|
width: 100%;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@descope/flow-components",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.27.0",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "dist/index.cjs.js",
|
|
6
6
|
"module": "dist/index.esm.js",
|
|
@@ -98,7 +98,7 @@
|
|
|
98
98
|
"webpack-subresource-integrity": "5.2.0-rc.1"
|
|
99
99
|
},
|
|
100
100
|
"dependencies": {
|
|
101
|
-
"@descope/web-components-ui": "3.
|
|
101
|
+
"@descope/web-components-ui": "3.27.0"
|
|
102
102
|
},
|
|
103
103
|
"peerDependencies": {
|
|
104
104
|
"react": ">= 18"
|