@everymatrix/player-account-controller 1.54.6 → 1.54.8
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/components/{GeneralLogout-Ddt-oH9k.js → GeneralLogout-ChXyfO7j.js} +504 -512
- package/components/GeneralLogout-CoXr5Hra.js +4819 -0
- package/components/GeneralLogout-JiIri-az.cjs +8 -0
- package/components/PlayerAccountBettingHistory-C4SfQEr4.js +333 -0
- package/components/{PlayerAccountBettingHistory-C7xwYi03.js → PlayerAccountBettingHistory-CElNilNd.js} +24 -24
- package/components/PlayerAccountBettingHistory-CSI5k3hd.cjs +1 -0
- package/components/PlayerAccountBiometrics-BS3jkUXn.cjs +1 -0
- package/components/{PlayerAccountBiometrics-D7WS5cnI.js → PlayerAccountBiometrics-D9kYcZXR.js} +26 -26
- package/components/PlayerAccountBiometrics-orQ-qG9h.js +307 -0
- package/components/{PlayerAccountClosure-yRlo8hXR.js → PlayerAccountClosure-CHUq23nB.js} +13 -13
- package/components/PlayerAccountClosure-CWd3utu_.js +347 -0
- package/components/PlayerAccountClosure-DdfqiT7d.cjs +1 -0
- package/components/{PlayerAccountController-BEYNBwE6.js → PlayerAccountController-BclvS237.js} +126 -126
- package/components/PlayerAccountController-DEXL47fX.js +6671 -0
- package/components/PlayerAccountController-DX3vsM6e.cjs +1 -0
- package/components/PlayerAccountGamingLimits-CKnItii4.cjs +1 -0
- package/components/{PlayerAccountGamingLimits-CTBhVGgC.js → PlayerAccountGamingLimits-DXQNmZKD.js} +19 -19
- package/components/PlayerAccountGamingLimits-Db6qUAS-.js +766 -0
- package/components/{PlayerAccountGamingLimitsConfirmationModal-CuQvNzww.js → PlayerAccountGamingLimitsConfirmationModal-i09zMH6w.js} +59 -59
- package/components/PlayerAccountGamingLimitsConfirmationModal-jZS53-sU.cjs +1 -0
- package/components/PlayerAccountGamingLimitsConfirmationModal-l4fu3WOl.js +310 -0
- package/components/{PlayerAccountGamingLimitsGroupEdit-Du2YQlDU.js → PlayerAccountGamingLimitsGroupEdit-BIt0U7Ia.js} +51 -51
- package/components/PlayerAccountGamingLimitsGroupEdit-CsnzS7iF.js +4170 -0
- package/components/PlayerAccountGamingLimitsGroupEdit-DZlV6G_9.cjs +10 -0
- package/components/PlayerAccountGamingLimitsHistory2-CrW3EIzV.cjs +1 -0
- package/components/{PlayerAccountGamingLimitsHistory2-CXKA0L0d.js → PlayerAccountGamingLimitsHistory2-D04L-msb.js} +44 -44
- package/components/PlayerAccountGamingLimitsHistory2-DA5YY1gv.js +767 -0
- package/components/{PlayerAccountGamingLimitsInfoCard-CWTybgoQ.js → PlayerAccountGamingLimitsInfoCard-B2YB4bdP.js} +95 -95
- package/components/PlayerAccountGamingLimitsInfoCard-B4t7J9Ea.js +1513 -0
- package/components/PlayerAccountGamingLimitsInfoCard-CaJYYEdy.cjs +1 -0
- package/components/PlayerAccountGamingLimitsPage2Gm16-B1GlGvDK.cjs +21 -0
- package/components/PlayerAccountGamingLimitsPage2Gm16-CbtwzTC5.js +3283 -0
- package/components/{PlayerAccountGamingLimitsPage2Gm16-CXjNcIFP.js → PlayerAccountGamingLimitsPage2Gm16-D8OKZxQt.js} +90 -90
- package/components/{PlayerAccountGamingLimitsPopup-CJu5RRl6.js → PlayerAccountGamingLimitsPopup-B7ZXSiK5.js} +17 -17
- package/components/PlayerAccountGamingLimitsPopup-C9KoZcRj.cjs +1 -0
- package/components/PlayerAccountGamingLimitsPopup-DxXAP_Yw.js +344 -0
- package/components/{PlayerAccountGamingLimitsWrapper2-BdpxEDlV.js → PlayerAccountGamingLimitsWrapper2-BoFnZpPK.js} +8 -8
- package/components/PlayerAccountGamingLimitsWrapper2-Dll6Amu9.cjs +1 -0
- package/components/PlayerAccountGamingLimitsWrapper2-eSNYZCaw.js +866 -0
- package/components/PlayerAccountGeneralConfirmationModal-B-p3sJZ3.cjs +1 -0
- package/components/{PlayerAccountGeneralConfirmationModal-DG0N686t.js → PlayerAccountGeneralConfirmationModal-DLBQH_sl.js} +66 -66
- package/components/PlayerAccountGeneralConfirmationModal-DhTWcbuE.js +365 -0
- package/components/PlayerAccountMenu-BGRoL3Yz.js +579 -0
- package/components/{PlayerAccountMenu-CZBa8_5G.js → PlayerAccountMenu-BxjdHhZ_.js} +17 -17
- package/components/PlayerAccountMenu-Csb1tUf_.cjs +1 -0
- package/components/{PlayerAccountModal-BmKjtXKT.js → PlayerAccountModal-C4nIa5u0.js} +28 -28
- package/components/PlayerAccountModal-D29fr970.js +213 -0
- package/components/PlayerAccountModal-DabmJiP4.cjs +1 -0
- package/components/{PlayerAccountNotifications-B4Ht-hHj.js → PlayerAccountNotifications-4sGKSJWy.js} +16 -16
- package/components/PlayerAccountNotifications-C3rPIsKp.js +261 -0
- package/components/PlayerAccountNotifications-O92_s-dm.cjs +1 -0
- package/components/PlayerAccountSelfExclusion-BkBWGAy2.cjs +3557 -0
- package/components/PlayerAccountSelfExclusion-CpKuxBrZ.js +16678 -0
- package/components/{PlayerAccountSelfExclusion-DxGHXTb8.js → PlayerAccountSelfExclusion-U9dfheYH.js} +11029 -12570
- package/components/PlayerAccountTimeout-CucYpS_w.cjs +1 -0
- package/components/{PlayerAccountTimeout-DOSjICsY.js → PlayerAccountTimeout-DIRXKowJ.js} +25 -25
- package/components/PlayerAccountTimeout-c2osWNku.js +819 -0
- package/components/{PlayerActiveBonuses-DMAG7NUP.js → PlayerActiveBonuses-B2QAPJxC.js} +49 -49
- package/components/PlayerActiveBonuses-DDcAwy_n.js +1089 -0
- package/components/PlayerActiveBonuses-cecVnp46.cjs +1 -0
- package/components/{PlayerBonusCard-Dss1REmn.js → PlayerBonusCard-BQU7JBPr.js} +50 -50
- package/components/PlayerBonusCard-C9Xdv-lu.cjs +1 -0
- package/components/PlayerBonusCard-TYI-WkBy.js +701 -0
- package/components/{PlayerBonusHistory-bS_5m4-D.js → PlayerBonusHistory-Boz8c3tb.js} +30 -30
- package/components/PlayerBonusHistory-CMPf8GQz.cjs +1 -0
- package/components/PlayerBonusHistory-cNqY_wfD.js +920 -0
- package/components/{PlayerChangePassword-DnCj-wcc.js → PlayerChangePassword-BGxYGFs-.js} +103 -103
- package/components/PlayerChangePassword-Dl3Pgpul.js +1177 -0
- package/components/PlayerChangePassword-X_GfgxAV.cjs +3 -0
- package/components/{PlayerDeposit-CHIQ8EaC.js → PlayerDeposit-BzSW3HMj.js} +25 -25
- package/components/PlayerDeposit-CqpNLpaq.cjs +1 -0
- package/components/PlayerDeposit-kjy658sM.js +395 -0
- package/components/PlayerGamingHistory-B6KJDVn0.cjs +1 -0
- package/components/PlayerGamingHistory-BW5rigFC.js +986 -0
- package/components/{PlayerGamingHistory-ByyLQwtw.js → PlayerGamingHistory-DIgLxCfL.js} +31 -31
- package/components/PlayerPendingWithdrawals--W6Dfn3K.cjs +1 -0
- package/components/{PlayerPendingWithdrawals-BbTa7_8U.js → PlayerPendingWithdrawals-BzOmRYiC.js} +33 -33
- package/components/PlayerPendingWithdrawals-pV1C12y5.js +311 -0
- package/components/PlayerProfileInfo-BTgis7wR.cjs +1 -0
- package/components/{PlayerProfileInfo-CvAqD3Dk.js → PlayerProfileInfo-CTgSfW-l.js} +45 -45
- package/components/PlayerProfileInfo-DkVAYiPX.js +1753 -0
- package/components/PlayerRealityCheck-BcsDhvm0.cjs +1 -0
- package/components/{PlayerRealityCheck-3d-B64ie.js → PlayerRealityCheck-BdZDs3Tl.js} +26 -26
- package/components/PlayerRealityCheck-DT3kOky2.js +598 -0
- package/components/PlayerTransactionHistory-BL92RRLF.cjs +1 -0
- package/components/{PlayerTransactionHistory-BYJNabMB.js → PlayerTransactionHistory-BQIA4QRw.js} +23 -23
- package/components/PlayerTransactionHistory-Yhwt7kUa.js +315 -0
- package/components/{PlayerWithdrawal-DDWroufG.js → PlayerWithdrawal-Cgv9nZE8.js} +20 -20
- package/components/PlayerWithdrawal-KgqM9wo-.cjs +1 -0
- package/components/PlayerWithdrawal-uB46JhmK.js +369 -0
- package/es2015/player-account-controller.cjs +1 -0
- package/es2015/player-account-controller.js +16 -0
- package/esnext/player-account-controller.js +1 -1
- package/package.json +1 -1
- package/stencil/app-globals-0f993ce5-8artnnwr.cjs +1 -0
- package/stencil/checkbox-group-input_9-AKw0biZc.cjs +2045 -0
- package/stencil/checkbox-group-input_9-BewIfW-f.js +13203 -0
- package/stencil/checkbox-group-input_9-CbFpcwPG.js +13237 -0
- package/stencil/{general-input-CQlnWzpy.js → general-input-BEcUF0Mm.js} +1 -1
- package/stencil/general-input-DI0pw0ot.cjs +1 -0
- package/stencil/general-input-DKyA-W8i.js +48 -0
- package/stencil/index-581287aa-CC7128Vz.js +654 -0
- package/stencil/index-581287aa-D5QW29QV.cjs +1 -0
- package/stencil/index-581287aa-D8NTWa_9.js +638 -0
- package/stencil/index-8b4525de-BFiXEsaX.cjs +1 -0
- package/stencil/index-8b4525de-C2xAv-3x.js +708 -0
- package/stencil/index-8b4525de-DeHXGvRF.js +692 -0
- package/stencil/index-a76d30c7-CFX9mSqu.cjs +1 -0
- package/stencil/index-a76d30c7-CQrAWNu0.js +658 -0
- package/stencil/index-a76d30c7-PfqrSVyu.js +631 -0
- package/stencil/index-c0196f50-3kAjMpUS.cjs +1 -0
- package/stencil/index-c0196f50-BjscP7kj.js +697 -0
- package/stencil/index-c0196f50-aE1zPmtS.js +724 -0
- package/stencil/locale-B5abSHU_.cjs +1 -0
- package/stencil/password-input_2-D97O8QAr.cjs +105 -0
- package/stencil/password-input_2-eDchPH-o.js +569 -0
- package/stencil/password-input_2-vTvSUJey.js +569 -0
- package/stencil/{player-change-password-gm2-BaQUJaH1.js → player-change-password-gm2-D4jpQFwb.js} +1 -1
- package/stencil/player-change-password-gm2-DSTqyOhE.js +25 -0
- package/stencil/player-change-password-gm2-Dw3D3ckz.cjs +1 -0
- package/stencil/{player-change-password-gm2-98dcb7bc-pj_6Z40p.js → player-change-password-gm2-e732ee8e-BjoYj-89.js} +1 -1
- package/stencil/player-change-password-gm2-e732ee8e-BqRUxIre.cjs +1 -0
- package/stencil/player-change-password-gm2-e732ee8e-Df6ljnLL.js +253 -0
- package/stencil/player-kyc-verification-B2FHAsrR.cjs +180 -0
- package/stencil/player-kyc-verification-CVqP43FY.js +865 -0
- package/stencil/{player-kyc-verification-BQZdJFEJ.js → player-kyc-verification-D6Au6XVN.js} +1 -1
- package/stencil/{toggle-checkbox-input-Sy9vd4Jp.js → toggle-checkbox-input-BckTBwKu.js} +1 -1
- package/stencil/toggle-checkbox-input-D8fVk4wA.js +46 -0
- package/stencil/toggle-checkbox-input-kw5Y1n3x.cjs +1 -0
- package/stencil/tooltipIcon-ee9760a8-Bd9l1O5C.cjs +1 -0
- package/stencil/user-deposit-withdrawal-BpAi0dc-.js +668 -0
- package/stencil/{user-deposit-withdrawal-CmF0LoNb.js → user-deposit-withdrawal-CrMPR6xn.js} +1 -1
- package/stencil/user-deposit-withdrawal-DrKFN7wp.cjs +59 -0
- package/stencil/{user-transaction-history-BgV-k2Cl.js → user-transaction-history-BgYG3IxS.js} +1 -1
- package/stencil/user-transaction-history-CBxwJE34.cjs +1 -0
- package/stencil/user-transaction-history-D8ebS-DZ.js +355 -0
- package/stencil/{active-mixin-59dfae2a-BphP4pp5.js → vaadin-button-mixin-d131076c-C559kyH3.js} +3523 -3021
- package/stencil/vaadin-button-mixin-d131076c-brSraXp5.js +10277 -0
- package/stencil/vaadin-button-mixin-d131076c-zI_s2YZ5.cjs +2385 -0
- package/stencil/checkbox-group-input_9-i8KmOWKn.js +0 -15610
- package/stencil/index-062e829b-CboMDKTu.js +0 -686
- package/stencil/index-33f005e1-fFxPaeNy.js +0 -632
- package/stencil/index-9b3245b3-rzHgwqlB.js +0 -625
- package/stencil/index-fc58390d-BSwfXuUs.js +0 -691
- package/stencil/password-input_2-sxSehMYk.js +0 -2359
|
@@ -0,0 +1,569 @@
|
|
|
1
|
+
import { r as w, c as p, h as a, g as b } from "./index-8b4525de-C2xAv-3x.js";
|
|
2
|
+
import { t as l } from "./locale-BG_TzyDt.js";
|
|
3
|
+
import { r as d, f as m, m as y, h, T as x, b as c, i as g, a9 as C, g as F, B as V, o as S, L as k, J as E, aa as I, a as M, q as B, I as R, z as T, n as P, j as v, E as D, P as _ } from "./vaadin-button-mixin-d131076c-brSraXp5.js";
|
|
4
|
+
import { t as A } from "./tooltipIcon-ee9760a8-BCCb4EU-.js";
|
|
5
|
+
import { P as ae } from "./player-change-password-gm2-e732ee8e-BjoYj-89.js";
|
|
6
|
+
/**
|
|
7
|
+
* @license
|
|
8
|
+
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
9
|
+
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
10
|
+
*/
|
|
11
|
+
d("vaadin-text-field", m, {
|
|
12
|
+
moduleId: "lumo-text-field-styles"
|
|
13
|
+
});
|
|
14
|
+
/**
|
|
15
|
+
* @license
|
|
16
|
+
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
17
|
+
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
18
|
+
*/
|
|
19
|
+
const N = (t) => class extends P(t) {
|
|
20
|
+
static get properties() {
|
|
21
|
+
return {
|
|
22
|
+
/**
|
|
23
|
+
* Whether the value of the control can be automatically completed by the browser.
|
|
24
|
+
* List of available options at:
|
|
25
|
+
* https://developer.mozilla.org/en/docs/Web/HTML/Element/input#attr-autocomplete
|
|
26
|
+
*/
|
|
27
|
+
autocomplete: {
|
|
28
|
+
type: String
|
|
29
|
+
},
|
|
30
|
+
/**
|
|
31
|
+
* This is a property supported by Safari that is used to control whether
|
|
32
|
+
* autocorrection should be enabled when the user is entering/editing the text.
|
|
33
|
+
* Possible values are:
|
|
34
|
+
* on: Enable autocorrection.
|
|
35
|
+
* off: Disable autocorrection.
|
|
36
|
+
*/
|
|
37
|
+
autocorrect: {
|
|
38
|
+
type: String
|
|
39
|
+
},
|
|
40
|
+
/**
|
|
41
|
+
* This is a property supported by Safari and Chrome that is used to control whether
|
|
42
|
+
* autocapitalization should be enabled when the user is entering/editing the text.
|
|
43
|
+
* Possible values are:
|
|
44
|
+
* characters: Characters capitalization.
|
|
45
|
+
* words: Words capitalization.
|
|
46
|
+
* sentences: Sentences capitalization.
|
|
47
|
+
* none: No capitalization.
|
|
48
|
+
*/
|
|
49
|
+
autocapitalize: {
|
|
50
|
+
type: String,
|
|
51
|
+
reflectToAttribute: !0
|
|
52
|
+
}
|
|
53
|
+
};
|
|
54
|
+
}
|
|
55
|
+
static get delegateAttrs() {
|
|
56
|
+
return [...super.delegateAttrs, "autocapitalize", "autocomplete", "autocorrect"];
|
|
57
|
+
}
|
|
58
|
+
// Workaround for https://github.com/Polymer/polymer/issues/5259
|
|
59
|
+
get __data() {
|
|
60
|
+
return this.__dataValue || {};
|
|
61
|
+
}
|
|
62
|
+
set __data(e) {
|
|
63
|
+
this.__dataValue = e;
|
|
64
|
+
}
|
|
65
|
+
/**
|
|
66
|
+
* @param {HTMLElement} input
|
|
67
|
+
* @protected
|
|
68
|
+
* @override
|
|
69
|
+
*/
|
|
70
|
+
_inputElementChanged(e) {
|
|
71
|
+
super._inputElementChanged(e), e && (e.value && e.value !== this.value && (console.warn(`Please define value on the <${this.localName}> component!`), e.value = ""), this.value && (e.value = this.value));
|
|
72
|
+
}
|
|
73
|
+
/**
|
|
74
|
+
* Override an event listener from `FocusMixin`.
|
|
75
|
+
* @param {boolean} focused
|
|
76
|
+
* @protected
|
|
77
|
+
* @override
|
|
78
|
+
*/
|
|
79
|
+
_setFocused(e) {
|
|
80
|
+
super._setFocused(e), !e && document.hasFocus() && this._requestValidation();
|
|
81
|
+
}
|
|
82
|
+
/**
|
|
83
|
+
* Override an event listener from `InputMixin`
|
|
84
|
+
* to mark as valid after user started typing.
|
|
85
|
+
* @param {Event} event
|
|
86
|
+
* @protected
|
|
87
|
+
* @override
|
|
88
|
+
*/
|
|
89
|
+
_onInput(e) {
|
|
90
|
+
super._onInput(e), this.invalid && this._requestValidation();
|
|
91
|
+
}
|
|
92
|
+
/**
|
|
93
|
+
* Override an observer from `InputMixin` to validate the field
|
|
94
|
+
* when a new value is set programmatically.
|
|
95
|
+
*
|
|
96
|
+
* @param {string | undefined} newValue
|
|
97
|
+
* @param {string | undefined} oldValue
|
|
98
|
+
* @protected
|
|
99
|
+
* @override
|
|
100
|
+
*/
|
|
101
|
+
_valueChanged(e, s) {
|
|
102
|
+
super._valueChanged(e, s), s !== void 0 && this.invalid && this._requestValidation();
|
|
103
|
+
}
|
|
104
|
+
};
|
|
105
|
+
/**
|
|
106
|
+
* @license
|
|
107
|
+
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
108
|
+
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
109
|
+
*/
|
|
110
|
+
const $ = (t) => class extends N(t) {
|
|
111
|
+
static get properties() {
|
|
112
|
+
return {
|
|
113
|
+
/**
|
|
114
|
+
* Maximum number of characters (in Unicode code points) that the user can enter.
|
|
115
|
+
*/
|
|
116
|
+
maxlength: {
|
|
117
|
+
type: Number
|
|
118
|
+
},
|
|
119
|
+
/**
|
|
120
|
+
* Minimum number of characters (in Unicode code points) that the user can enter.
|
|
121
|
+
*/
|
|
122
|
+
minlength: {
|
|
123
|
+
type: Number
|
|
124
|
+
},
|
|
125
|
+
/**
|
|
126
|
+
* A regular expression that the value is checked against.
|
|
127
|
+
* The pattern must match the entire value, not just some subset.
|
|
128
|
+
*/
|
|
129
|
+
pattern: {
|
|
130
|
+
type: String
|
|
131
|
+
}
|
|
132
|
+
};
|
|
133
|
+
}
|
|
134
|
+
static get delegateAttrs() {
|
|
135
|
+
return [...super.delegateAttrs, "maxlength", "minlength", "pattern"];
|
|
136
|
+
}
|
|
137
|
+
static get constraints() {
|
|
138
|
+
return [...super.constraints, "maxlength", "minlength", "pattern"];
|
|
139
|
+
}
|
|
140
|
+
constructor() {
|
|
141
|
+
super(), this._setType("text");
|
|
142
|
+
}
|
|
143
|
+
/** @protected */
|
|
144
|
+
get clearElement() {
|
|
145
|
+
return this.$.clearButton;
|
|
146
|
+
}
|
|
147
|
+
/** @protected */
|
|
148
|
+
ready() {
|
|
149
|
+
super.ready(), this.addController(
|
|
150
|
+
new S(this, (e) => {
|
|
151
|
+
this._setInputElement(e), this._setFocusElement(e), this.stateTarget = e, this.ariaTarget = e;
|
|
152
|
+
})
|
|
153
|
+
), this.addController(new k(this.inputElement, this._labelController));
|
|
154
|
+
}
|
|
155
|
+
};
|
|
156
|
+
/**
|
|
157
|
+
* @license
|
|
158
|
+
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
159
|
+
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
160
|
+
*/
|
|
161
|
+
d("vaadin-text-field", y, { moduleId: "vaadin-text-field-styles" });
|
|
162
|
+
class f extends $(v(D(_))) {
|
|
163
|
+
static get is() {
|
|
164
|
+
return "vaadin-text-field";
|
|
165
|
+
}
|
|
166
|
+
static get template() {
|
|
167
|
+
return h`
|
|
168
|
+
<div class="vaadin-field-container">
|
|
169
|
+
<div part="label">
|
|
170
|
+
<slot name="label"></slot>
|
|
171
|
+
<span part="required-indicator" aria-hidden="true" on-click="focus"></span>
|
|
172
|
+
</div>
|
|
173
|
+
|
|
174
|
+
<vaadin-input-container
|
|
175
|
+
part="input-field"
|
|
176
|
+
readonly="[[readonly]]"
|
|
177
|
+
disabled="[[disabled]]"
|
|
178
|
+
invalid="[[invalid]]"
|
|
179
|
+
theme$="[[_theme]]"
|
|
180
|
+
>
|
|
181
|
+
<slot name="prefix" slot="prefix"></slot>
|
|
182
|
+
<slot name="input"></slot>
|
|
183
|
+
<slot name="suffix" slot="suffix"></slot>
|
|
184
|
+
<div id="clearButton" part="clear-button" slot="suffix" aria-hidden="true"></div>
|
|
185
|
+
</vaadin-input-container>
|
|
186
|
+
|
|
187
|
+
<div part="helper-text">
|
|
188
|
+
<slot name="helper"></slot>
|
|
189
|
+
</div>
|
|
190
|
+
|
|
191
|
+
<div part="error-message">
|
|
192
|
+
<slot name="error-message"></slot>
|
|
193
|
+
</div>
|
|
194
|
+
</div>
|
|
195
|
+
<slot name="tooltip"></slot>
|
|
196
|
+
`;
|
|
197
|
+
}
|
|
198
|
+
/** @protected */
|
|
199
|
+
ready() {
|
|
200
|
+
super.ready(), this._tooltipController = new x(this), this._tooltipController.setPosition("top"), this._tooltipController.setAriaTarget(this.inputElement), this.addController(this._tooltipController);
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
c(f);
|
|
204
|
+
/**
|
|
205
|
+
* @license
|
|
206
|
+
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
207
|
+
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
208
|
+
*/
|
|
209
|
+
const H = g`
|
|
210
|
+
:host {
|
|
211
|
+
position: absolute;
|
|
212
|
+
right: 0;
|
|
213
|
+
top: 0;
|
|
214
|
+
margin: 0;
|
|
215
|
+
padding: 0;
|
|
216
|
+
width: 100%;
|
|
217
|
+
height: 100%;
|
|
218
|
+
min-width: auto;
|
|
219
|
+
background: transparent;
|
|
220
|
+
outline: none;
|
|
221
|
+
}
|
|
222
|
+
`;
|
|
223
|
+
d("vaadin-password-field-button", [C, H], {
|
|
224
|
+
moduleId: "lumo-password-field-button"
|
|
225
|
+
});
|
|
226
|
+
/**
|
|
227
|
+
* @license
|
|
228
|
+
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
229
|
+
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
230
|
+
*/
|
|
231
|
+
const L = g`
|
|
232
|
+
[part='reveal-button']::before {
|
|
233
|
+
content: var(--lumo-icons-eye);
|
|
234
|
+
}
|
|
235
|
+
|
|
236
|
+
:host([password-visible]) [part='reveal-button']::before {
|
|
237
|
+
content: var(--lumo-icons-eye-disabled);
|
|
238
|
+
}
|
|
239
|
+
|
|
240
|
+
/* Make it easy to hide the button across the whole app */
|
|
241
|
+
[part='reveal-button'] {
|
|
242
|
+
position: relative;
|
|
243
|
+
display: var(--lumo-password-field-reveal-button-display, block);
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
[part='reveal-button'][hidden] {
|
|
247
|
+
display: none !important;
|
|
248
|
+
}
|
|
249
|
+
`;
|
|
250
|
+
d("vaadin-password-field", [m, L], { moduleId: "lumo-password-field" });
|
|
251
|
+
/**
|
|
252
|
+
* @license
|
|
253
|
+
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
254
|
+
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
255
|
+
*/
|
|
256
|
+
d("vaadin-password-field-button", F, { moduleId: "vaadin-password-field-button-styles" });
|
|
257
|
+
class q extends V(E(v(_))) {
|
|
258
|
+
static get is() {
|
|
259
|
+
return "vaadin-password-field-button";
|
|
260
|
+
}
|
|
261
|
+
static get template() {
|
|
262
|
+
return h``;
|
|
263
|
+
}
|
|
264
|
+
}
|
|
265
|
+
c(q);
|
|
266
|
+
/**
|
|
267
|
+
* @license
|
|
268
|
+
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
269
|
+
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
270
|
+
*/
|
|
271
|
+
const z = (t) => class extends I(M(B(R(t)))) {
|
|
272
|
+
static get properties() {
|
|
273
|
+
return {
|
|
274
|
+
/**
|
|
275
|
+
* Set to true to hide the eye icon which toggles the password visibility.
|
|
276
|
+
* @attr {boolean} reveal-button-hidden
|
|
277
|
+
*/
|
|
278
|
+
revealButtonHidden: {
|
|
279
|
+
type: Boolean,
|
|
280
|
+
observer: "_revealButtonHiddenChanged",
|
|
281
|
+
value: !1
|
|
282
|
+
},
|
|
283
|
+
/**
|
|
284
|
+
* True if the password is visible ([type=text]).
|
|
285
|
+
* @attr {boolean} password-visible
|
|
286
|
+
*/
|
|
287
|
+
passwordVisible: {
|
|
288
|
+
type: Boolean,
|
|
289
|
+
value: !1,
|
|
290
|
+
reflectToAttribute: !0,
|
|
291
|
+
observer: "_passwordVisibleChanged",
|
|
292
|
+
readOnly: !0
|
|
293
|
+
},
|
|
294
|
+
/**
|
|
295
|
+
* An object with translated strings used for localization.
|
|
296
|
+
* It has the following structure and default values:
|
|
297
|
+
*
|
|
298
|
+
* ```
|
|
299
|
+
* {
|
|
300
|
+
* // Translation of the reveal icon button accessible label
|
|
301
|
+
* reveal: 'Show password'
|
|
302
|
+
* }
|
|
303
|
+
* ```
|
|
304
|
+
*/
|
|
305
|
+
i18n: {
|
|
306
|
+
type: Object,
|
|
307
|
+
value: () => ({
|
|
308
|
+
reveal: "Show password"
|
|
309
|
+
})
|
|
310
|
+
}
|
|
311
|
+
};
|
|
312
|
+
}
|
|
313
|
+
static get observers() {
|
|
314
|
+
return ["__i18nChanged(i18n)"];
|
|
315
|
+
}
|
|
316
|
+
constructor() {
|
|
317
|
+
super(), this._setType("password"), this.__boundRevealButtonClick = this._onRevealButtonClick.bind(this), this.__boundRevealButtonMouseDown = this._onRevealButtonMouseDown.bind(this), this.__lastChange = "";
|
|
318
|
+
}
|
|
319
|
+
/** @protected */
|
|
320
|
+
get slotStyles() {
|
|
321
|
+
const e = this.localName;
|
|
322
|
+
return [
|
|
323
|
+
...super.slotStyles,
|
|
324
|
+
`
|
|
325
|
+
${e} [slot="input"]::-ms-reveal {
|
|
326
|
+
display: none;
|
|
327
|
+
}
|
|
328
|
+
`
|
|
329
|
+
];
|
|
330
|
+
}
|
|
331
|
+
/** @protected */
|
|
332
|
+
get _revealNode() {
|
|
333
|
+
return this._revealButtonController && this._revealButtonController.node;
|
|
334
|
+
}
|
|
335
|
+
/** @protected */
|
|
336
|
+
ready() {
|
|
337
|
+
super.ready(), this._revealPart = this.shadowRoot.querySelector('[part="reveal-button"]'), this._revealButtonController = new T(this, "reveal", "vaadin-password-field-button", {
|
|
338
|
+
initializer: (e) => {
|
|
339
|
+
e.disabled = this.disabled, e.addEventListener("click", this.__boundRevealButtonClick), e.addEventListener("mousedown", this.__boundRevealButtonMouseDown);
|
|
340
|
+
}
|
|
341
|
+
}), this.addController(this._revealButtonController), this.__updateAriaLabel(this.i18n), this._updateToggleState(!1), this._toggleRevealHidden(this.revealButtonHidden), this.inputElement && (this.inputElement.autocapitalize = "off");
|
|
342
|
+
}
|
|
343
|
+
/**
|
|
344
|
+
* Override an event listener inherited from `InputControlMixin`
|
|
345
|
+
* to store the value at the moment of the native `change` event.
|
|
346
|
+
* @param {Event} event
|
|
347
|
+
* @protected
|
|
348
|
+
* @override
|
|
349
|
+
*/
|
|
350
|
+
_onChange(e) {
|
|
351
|
+
super._onChange(e), this.__lastChange = this.inputElement.value;
|
|
352
|
+
}
|
|
353
|
+
/**
|
|
354
|
+
* Override method inherited from `FocusMixin` to mark field as focused
|
|
355
|
+
* when focus moves to the reveal button using Shift Tab.
|
|
356
|
+
* @param {Event} event
|
|
357
|
+
* @return {boolean}
|
|
358
|
+
* @protected
|
|
359
|
+
*/
|
|
360
|
+
_shouldSetFocus(e) {
|
|
361
|
+
return e.target === this.inputElement || e.target === this._revealNode;
|
|
362
|
+
}
|
|
363
|
+
/**
|
|
364
|
+
* Override method inherited from `FocusMixin` to not hide password
|
|
365
|
+
* when focus moves to the reveal button or back to the input.
|
|
366
|
+
* @param {Event} event
|
|
367
|
+
* @return {boolean}
|
|
368
|
+
* @protected
|
|
369
|
+
*/
|
|
370
|
+
_shouldRemoveFocus(e) {
|
|
371
|
+
return !(e.relatedTarget === this._revealNode || e.relatedTarget === this.inputElement && e.target === this._revealNode);
|
|
372
|
+
}
|
|
373
|
+
/**
|
|
374
|
+
* Override method inherited from `FocusMixin` to toggle password visibility.
|
|
375
|
+
* @param {boolean} focused
|
|
376
|
+
* @protected
|
|
377
|
+
* @override
|
|
378
|
+
*/
|
|
379
|
+
_setFocused(e) {
|
|
380
|
+
if (super._setFocused(e), !e)
|
|
381
|
+
this._setPasswordVisible(!1), this.__lastChange !== this.inputElement.value && (this.__lastChange = this.inputElement.value, this.dispatchEvent(new CustomEvent("change", { bubbles: !0 })));
|
|
382
|
+
else {
|
|
383
|
+
const s = this.getRootNode().activeElement === this._revealNode;
|
|
384
|
+
this.toggleAttribute("focus-ring", this._keyboardActive && !s);
|
|
385
|
+
}
|
|
386
|
+
}
|
|
387
|
+
/** @private */
|
|
388
|
+
__updateAriaLabel(e) {
|
|
389
|
+
e && e.reveal && this._revealNode && this._revealNode.setAttribute("aria-label", e.reveal);
|
|
390
|
+
}
|
|
391
|
+
/** @private */
|
|
392
|
+
__i18nChanged(e) {
|
|
393
|
+
this.__updateAriaLabel(e);
|
|
394
|
+
}
|
|
395
|
+
/** @private */
|
|
396
|
+
_revealButtonHiddenChanged(e) {
|
|
397
|
+
this._toggleRevealHidden(e);
|
|
398
|
+
}
|
|
399
|
+
/** @private */
|
|
400
|
+
_togglePasswordVisibility() {
|
|
401
|
+
this._setPasswordVisible(!this.passwordVisible);
|
|
402
|
+
}
|
|
403
|
+
/** @private */
|
|
404
|
+
_onRevealButtonClick() {
|
|
405
|
+
this._togglePasswordVisibility();
|
|
406
|
+
}
|
|
407
|
+
/** @private */
|
|
408
|
+
_onRevealButtonMouseDown(e) {
|
|
409
|
+
e.preventDefault(), this.inputElement.focus();
|
|
410
|
+
}
|
|
411
|
+
/** @private */
|
|
412
|
+
_toggleRevealHidden(e) {
|
|
413
|
+
this._revealNode && (e ? (this._revealPart.setAttribute("hidden", ""), this._revealNode.setAttribute("tabindex", "-1"), this._revealNode.setAttribute("aria-hidden", "true")) : (this._revealPart.removeAttribute("hidden"), this._revealNode.setAttribute("tabindex", "0"), this._revealNode.removeAttribute("aria-hidden")));
|
|
414
|
+
}
|
|
415
|
+
/** @private */
|
|
416
|
+
_updateToggleState(e) {
|
|
417
|
+
this._revealNode && this._revealNode.setAttribute("aria-pressed", e ? "true" : "false");
|
|
418
|
+
}
|
|
419
|
+
/** @private */
|
|
420
|
+
_passwordVisibleChanged(e) {
|
|
421
|
+
this._setType(e ? "text" : "password"), this._updateToggleState(e);
|
|
422
|
+
}
|
|
423
|
+
/**
|
|
424
|
+
* Override method inherited from `DisabledMixin` to synchronize the reveal button
|
|
425
|
+
* disabled state with the password field disabled state.
|
|
426
|
+
* @param {boolean} disabled
|
|
427
|
+
* @param {boolean} oldDisabled
|
|
428
|
+
* @protected
|
|
429
|
+
*/
|
|
430
|
+
_disabledChanged(e, s) {
|
|
431
|
+
super._disabledChanged(e, s), this._revealNode && (this._revealNode.disabled = e);
|
|
432
|
+
}
|
|
433
|
+
};
|
|
434
|
+
/**
|
|
435
|
+
* @license
|
|
436
|
+
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
437
|
+
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
438
|
+
*/
|
|
439
|
+
const O = h`
|
|
440
|
+
<div part="reveal-button" slot="suffix">
|
|
441
|
+
<slot name="reveal"></slot>
|
|
442
|
+
</div>
|
|
443
|
+
`;
|
|
444
|
+
let u;
|
|
445
|
+
class K extends z(f) {
|
|
446
|
+
static get is() {
|
|
447
|
+
return "vaadin-password-field";
|
|
448
|
+
}
|
|
449
|
+
static get template() {
|
|
450
|
+
if (!u) {
|
|
451
|
+
u = super.template.cloneNode(!0);
|
|
452
|
+
const i = O.content.querySelector('[part="reveal-button"]');
|
|
453
|
+
u.content.querySelector('[part="input-field"]').appendChild(i);
|
|
454
|
+
}
|
|
455
|
+
return u;
|
|
456
|
+
}
|
|
457
|
+
}
|
|
458
|
+
c(K);
|
|
459
|
+
const j = '*,*::before,*::after{padding:0;margin:0;box-sizing:border-box}.password{font-family:"Roboto";font-style:normal}.password__wrapper{position:relative;width:100%;display:flex;flex-direction:column;gap:5px}.password__wrapper--autofilled{pointer-events:none}.password__wrapper--autofilled .password__label{color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.password__wrapper--autofilled .password__input::part(input-field){color:var(--emw--color-black, #000000)}.password__wrapper--flex{display:flex;gap:5px}.password__wrapper--relative{position:relative}.password__label{font-family:inherit;font-style:normal;font-weight:500;font-size:16px;line-height:20px;color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.password__label--required::after{content:"*";font-family:inherit;color:var(--emw--login-color-primary, var(--emw--color-primary, #D0046C));margin-left:2px}.password__input{width:inherit;border:none}.password__input[focused]::part(input-field){border-color:var(--emw--login-color-primary, var(--emw--color-primary, #D0046C))}.password__input[invalid]::part(input-field){border:1px solid var(--emw--color-error, var(--emw--color-red, #ed0909))}.password__input::part(input-field){border-radius:4px;background-color:var(--emw--color-white, #FFFFFF);border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--color-black, #000000);background-color:var(--emw--color-white, #FFFFFF);font-family:inherit;font-style:normal;font-weight:300;font-size:16px;line-height:1.5;position:relative;margin-bottom:unset;height:44px;padding:0;width:100%}.password__input::part(reveal-button){position:relative;right:10px}.password__input::part(reveal-button)::before{color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.password__input>input{padding:5px 15px}.password__input>input:placeholder-shown{color:var(--emw--color-gray-150, #828282)}.password__error-message{position:absolute;top:calc(100% + 5px);left:0;color:var(--emw--color-error, var(--emw--color-red, #ed0909))}.password__complexity{position:relative;padding:10px;display:flex;flex-direction:column;gap:20px;justify-content:center;margin-top:20px;font-weight:300;background:var(--emw--color-white, #FFFFFF);-webkit-border-radius:5px;-moz-border-radius:5px;border-radius:5px;height:150px;border:1px solid #B0B0B0;}.password__complexity meter{border-color:transparent;}.password__complexity meter[value="1"]::-moz-meter-bar{background-color:var(--emw--color-valid, #48952a)}.password__complexity meter[value="1"]::-webkit-meter-optimum-value{background-color:var(--emw--color-valid, #48952a)}.password__complexity meter:not([value="1"])::-moz-meter-bar{background-color:var(--emw--color-error, #FD2839)}.password__complexity meter:not([value="1"])::-webkit-meter-optimum-value{background-color:var(--emw--color-error, #FD2839)}.password__complexity--strength{display:flex;justify-content:space-evenly;align-items:center}.password__complexity--strength meter::-moz-meter-bar{background:#B0B0B0}.password__complexity--hidden{display:none}.password__complexity--text-bold{font-weight:500}.password__complexity--checkbox{margin-right:5px}.password__complexity:after{content:"";position:absolute;width:25px;height:25px;border-top:1px solid var(--emw--color-gray-150, #828282);border-right:0 solid var(--emw--color-gray-150, #828282);border-left:1px solid var(--emw--color-gray-150, #828282);border-bottom:0 solid var(--emw--color-gray-150, #828282);bottom:92%;left:50%;margin-left:-25px;transform:rotate(45deg);margin-top:-25px;background-color:var(--emw--color-white, #FFFFFF)}.password__tooltip-icon{width:16px;height:auto}.password__tooltip{position:absolute;top:0;left:20px;background-color:var(--emw--color-white, #FFFFFF);border:1px solid var(--emw--color-gray-150, #828282);color:#2B2D3F;padding:10px;border-radius:5px;opacity:0;transition:opacity 0.3s ease-in-out;z-index:10}.password__tooltip.visible{opacity:1}', J = j, W = class {
|
|
460
|
+
constructor(t) {
|
|
461
|
+
w(this, t), this.sendOriginalValidityState = p(this, "sendOriginalValidityState"), this.sendValidityState = p(this, "sendValidityState"), this.sendInputValue = p(this, "sendInputValue"), this.defaultValue = "", this.clientStyling = "", this.limitStylingAppends = !1, this.showTooltip = !1, this.value = "", this.touched = !1, this.originalValid = !1, this.validationPattern = "", this.duplicateInputValue = null, this.handleInput = (i) => {
|
|
462
|
+
this.value = i.target.value, this.calculateComplexity(this.value), this.showPopup = !0, this.touched = !0, this.debounceTime && clearTimeout(this.debounceTime), this.debounceTime = setTimeout(() => {
|
|
463
|
+
this.isValid = this.setValidity(), this.errorMessage = this.setErrorMessage(), this.emitValueHandler(!0);
|
|
464
|
+
}, 500);
|
|
465
|
+
}, this.handleRevealField = (i) => {
|
|
466
|
+
i.stopPropagation(), window.postMessage({ type: `registrationShow${this.name}` }, window.location.href);
|
|
467
|
+
}, this.handleBlur = (i) => {
|
|
468
|
+
this.value = i.target.value, this.showPopup = !1, this.touched = !0, this.isValid = this.setValidity(), this.errorMessage = this.setErrorMessage();
|
|
469
|
+
}, this.handleFocus = () => {
|
|
470
|
+
this.showPopup = !0, this.calculateComplexity(this.value);
|
|
471
|
+
}, this.setClientStyling = () => {
|
|
472
|
+
let i = document.createElement("style");
|
|
473
|
+
i.innerHTML = this.clientStyling, this.stylingContainer.prepend(i);
|
|
474
|
+
};
|
|
475
|
+
}
|
|
476
|
+
validityChanged() {
|
|
477
|
+
this.validityStateHandler({ valid: this.isValid, name: this.name }), this.emitValue == !0 && this.valueHandler({ name: this.name, value: this.value });
|
|
478
|
+
}
|
|
479
|
+
valueChanged() {
|
|
480
|
+
this.isDuplicateInput || (this.calculateComplexity(this.value), this.sendOriginalValidityState.emit({ name: this.name, valid: this.setValidity() }));
|
|
481
|
+
}
|
|
482
|
+
emitValueHandler(t) {
|
|
483
|
+
t == !0 && this.isValid && this.valueHandler({ name: this.name, value: this.value, type: "duplicate" });
|
|
484
|
+
}
|
|
485
|
+
validityStateHandler(t) {
|
|
486
|
+
this.sendValidityState.emit(t);
|
|
487
|
+
}
|
|
488
|
+
valueHandler(t) {
|
|
489
|
+
this.sendInputValue.emit(t);
|
|
490
|
+
}
|
|
491
|
+
originalValidityChangedHandler(t) {
|
|
492
|
+
this.isDuplicateInput && (t.detail.valid ? (this.originalValid = !0, this.isValid = this.setValidity()) : (this.originalValid = !1, this.isValid = !1, this.value !== "" && (this.errorMessage = this.setErrorMessage())));
|
|
493
|
+
}
|
|
494
|
+
valueChangedHandler(t) {
|
|
495
|
+
this.isDuplicateInput && this.name === t.detail.name + "Duplicate" && (this.duplicateInputValue = t.detail.value, this.touched && (this.isValid = this.setValidity(), this.errorMessage = this.setErrorMessage())), this.name === t.detail.name + "Duplicate" && this.name.replace("Duplicate", "") === t.detail.name && this.touched === !0 && (this.isValid = this.setValidity(), this.errorMessage = this.setErrorMessage());
|
|
496
|
+
}
|
|
497
|
+
handleClickOutside(t) {
|
|
498
|
+
t.composedPath()[0] !== this.tooltipIconReference && t.composedPath()[0] !== this.tooltipReference && (this.showTooltip = !1);
|
|
499
|
+
}
|
|
500
|
+
componentDidRender() {
|
|
501
|
+
!this.limitStylingAppends && this.stylingContainer && (this.clientStyling && this.setClientStyling(), this.limitStylingAppends = !0);
|
|
502
|
+
}
|
|
503
|
+
componentDidLoad() {
|
|
504
|
+
this.inputReference = this.element.shadowRoot.querySelector("input"), this.passwordButton = this.element.shadowRoot.querySelector("vaadin-password-field-button"), this.passwordButton.tabIndex = -1, this.passwordButton.addEventListener("click", (t) => {
|
|
505
|
+
this.handleRevealField(t);
|
|
506
|
+
}), this.defaultValue && (this.value = this.defaultValue, this.calculateComplexity(this.value), this.valueHandler({ name: this.name, value: this.value }), this.isDuplicateInput && (this.duplicateInputValue = this.defaultValue, this.touched = !0)), this.isValid = this.setValidity();
|
|
507
|
+
}
|
|
508
|
+
disconnectedCallback() {
|
|
509
|
+
this.passwordButton.removeEventListener("click", this.handleRevealField);
|
|
510
|
+
}
|
|
511
|
+
calculateComplexity(t) {
|
|
512
|
+
this.passwordComplexity = this.validation.custom.filter((i) => i.rule === "regex").map((i) => {
|
|
513
|
+
const s = new RegExp(i.pattern).test(t);
|
|
514
|
+
return { rule: i.displayName, ruleKey: i.errorKey, passed: s };
|
|
515
|
+
});
|
|
516
|
+
}
|
|
517
|
+
setValidity() {
|
|
518
|
+
var t, i;
|
|
519
|
+
return this.isDuplicateInput && this.duplicateInputValue !== this.value ? !1 : !((t = this.passwordComplexity) === null || t === void 0) && t.every((e) => e.passed) ? (i = this.inputReference) === null || i === void 0 ? void 0 : i.validity.valid : !1;
|
|
520
|
+
}
|
|
521
|
+
setPattern() {
|
|
522
|
+
var t, i;
|
|
523
|
+
if (((t = this.validation.custom) === null || t === void 0 ? void 0 : t.length) > 0)
|
|
524
|
+
return (i = this.validation.custom.find((e) => e.rule === "regex")) === null || i === void 0 ? void 0 : i.pattern;
|
|
525
|
+
}
|
|
526
|
+
setErrorMessage() {
|
|
527
|
+
var t, i, e, s;
|
|
528
|
+
if (this.isDuplicateInput && !this.originalValid)
|
|
529
|
+
return l("invalidOriginalPasswordError", this.language);
|
|
530
|
+
if (this.inputReference.validity.patternMismatch) {
|
|
531
|
+
const r = (t = this.validation.custom.find((o) => o.rule === "regex")) === null || t === void 0 ? void 0 : t.errorKey, n = (i = this.validation.custom.find((o) => o.rule === "regex")) === null || i === void 0 ? void 0 : i.errorMessage;
|
|
532
|
+
return l(`${r}`, this.language) ? l(`${r}`, this.language) : n;
|
|
533
|
+
}
|
|
534
|
+
if (this.inputReference.validity.tooShort || this.inputReference.validity.tooLong)
|
|
535
|
+
return l("lengthError", this.language, { values: { minLength: this.validation.minLength, maxLength: this.validation.maxLength } });
|
|
536
|
+
if (this.inputReference.validity.valueMissing)
|
|
537
|
+
return l("requiredError", this.language);
|
|
538
|
+
if (this.isDuplicateInput && this.duplicateInputValue !== this.value) {
|
|
539
|
+
const r = (e = this.validation.custom.find((o) => o.rule === "duplicate-input")) === null || e === void 0 ? void 0 : e.errorKey, n = (s = this.validation.custom.find((o) => o.rule === "duplicate-input")) === null || s === void 0 ? void 0 : s.errorMessage;
|
|
540
|
+
return l(`${r}`, this.language) ? l(`${r}`, this.language) : n;
|
|
541
|
+
}
|
|
542
|
+
}
|
|
543
|
+
renderTooltip() {
|
|
544
|
+
return this.showTooltip ? a("div", { class: `password__tooltip ${this.showTooltip ? "visible" : ""}`, ref: (t) => this.tooltipReference = t, innerHTML: this.tooltip }) : null;
|
|
545
|
+
}
|
|
546
|
+
renderComplexityPopup() {
|
|
547
|
+
const t = this.passwordComplexity.length, e = this.passwordComplexity.filter((r) => r.passed).length / t, s = this.passwordComplexity.every((r) => r.passed);
|
|
548
|
+
return a("div", { class: `password__complexity ${this.showPopup ? "" : "password__complexity--hidden"}` }, a("div", { class: "password__complexity--strength" }, a("p", { class: "password__complexity--text" }, l("passwordStrength", this.language), " ", a("span", { class: "password__complexity--text-bold" }, l(`${s ? "passwordStrengthStrong" : "passwordStrengthWeak"}`, this.language))), a("meter", { value: e, min: "0", max: "1" })), a("div", null, this.passwordComplexity.map((r, n) => a("div", { key: n }, a("input", { class: "password__complexity--checkbox", type: "checkbox", checked: r.passed, disabled: !0 }), a("span", null, l(`${r.ruleKey}`, this.language) ? l(`${r.ruleKey}`, this.language) : r.rule)))));
|
|
549
|
+
}
|
|
550
|
+
render() {
|
|
551
|
+
let t = "";
|
|
552
|
+
return this.touched && (t = this.isValid == !0 || this.isValid == null ? "" : "text__input--invalid"), a("div", { key: "c704b51efdf53817beb1541b4794e0b11b490a24", class: `password__wrapper ${this.autofilled ? "password__wrapper--autofilled" : ""} ${this.name}__input`, ref: (i) => this.stylingContainer = i }, a("div", { key: "e590afa403084ff95a8735ade400ab81ad16937f", class: "password__wrapper--flex" }, a("label", { key: "9d8db00b59c4b9594538aeacee3ef5a0e678c0e9", class: `password__label ${this.validation.mandatory ? "password__label--required" : ""}`, htmlFor: `${this.name}__input` }, this.displayName), a("div", { key: "bb39f6018cf688fafcd0b5bef91ba079edf09daf", class: "password__wrapper--relative" }, this.tooltip && a("img", { key: "d8dbd086da34a8c7db9b5826654530bdb888c927", class: "password__tooltip-icon", src: A, alt: "", ref: (i) => this.tooltipIconReference = i, onClick: () => this.showTooltip = !this.showTooltip }), this.renderTooltip())), a("vaadin-password-field", { key: "ae1c212d663fe379561b1c514087629409196ac3", type: "password", id: `${this.name}__input`, class: `password__input ${t}`, name: this.name, readOnly: this.autofilled, value: this.defaultValue, required: this.validation.mandatory, maxlength: this.validation.maxLength, minlength: this.validation.minLength, pattern: this.validationPattern, placeholder: `${this.placeholder}`, onInput: this.handleInput, onBlur: this.handleBlur, onFocus: this.handleFocus }), a("small", { key: "2fa1e25239a7314399c16b2f897873b7a31e9f77", class: "password__error-message" }, this.errorMessage), this.passwordComplexity && this.showPopup && !this.isDuplicateInput && this.renderComplexityPopup());
|
|
553
|
+
}
|
|
554
|
+
get element() {
|
|
555
|
+
return b(this);
|
|
556
|
+
}
|
|
557
|
+
static get watchers() {
|
|
558
|
+
return {
|
|
559
|
+
isValid: ["validityChanged"],
|
|
560
|
+
value: ["valueChanged"],
|
|
561
|
+
emitValue: ["emitValueHandler"]
|
|
562
|
+
};
|
|
563
|
+
}
|
|
564
|
+
};
|
|
565
|
+
W.style = J;
|
|
566
|
+
export {
|
|
567
|
+
W as password_input,
|
|
568
|
+
ae as player_change_password_gm2
|
|
569
|
+
};
|