@everymatrix/general-input-hsl 0.0.1

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.
Files changed (95) hide show
  1. package/dist/cjs/app-globals-3a1e7e63.js +5 -0
  2. package/dist/cjs/checkbox-group-input_13.cjs.entry.js +7303 -0
  3. package/dist/cjs/general-input-hsl-2832e412.js +5800 -0
  4. package/dist/cjs/general-input-hsl.cjs.js +25 -0
  5. package/dist/cjs/index-6f821b8d.js +1299 -0
  6. package/dist/cjs/index.cjs.js +10 -0
  7. package/dist/cjs/loader.cjs.js +15 -0
  8. package/dist/collection/collection-manifest.json +24 -0
  9. package/dist/collection/components/checkbox-group-input/checkbox-group-input.css +89 -0
  10. package/dist/collection/components/checkbox-group-input/checkbox-group-input.js +390 -0
  11. package/dist/collection/components/checkbox-input/checkbox-input.css +78 -0
  12. package/dist/collection/components/checkbox-input/checkbox-input.js +344 -0
  13. package/dist/collection/components/date-input/date-input.css +101 -0
  14. package/dist/collection/components/date-input/date-input.js +466 -0
  15. package/dist/collection/components/email-input/email-input.css +95 -0
  16. package/dist/collection/components/email-input/email-input.js +429 -0
  17. package/dist/collection/components/general-input-hsl/general-input-hsl.css +4 -0
  18. package/dist/collection/components/general-input-hsl/general-input-hsl.js +438 -0
  19. package/dist/collection/components/general-input-hsl/index.js +1 -0
  20. package/dist/collection/components/number-input/number-input.css +102 -0
  21. package/dist/collection/components/number-input/number-input.js +393 -0
  22. package/dist/collection/components/password-input/password-input.css +193 -0
  23. package/dist/collection/components/password-input/password-input.js +573 -0
  24. package/dist/collection/components/radio-input/radio-input.css +43 -0
  25. package/dist/collection/components/radio-input/radio-input.js +319 -0
  26. package/dist/collection/components/select-input/select-input.css +121 -0
  27. package/dist/collection/components/select-input/select-input.js +488 -0
  28. package/dist/collection/components/tel-input/tel-input.css +145 -0
  29. package/dist/collection/components/tel-input/tel-input.js +468 -0
  30. package/dist/collection/components/text-input/text-input.css +97 -0
  31. package/dist/collection/components/text-input/text-input.js +489 -0
  32. package/dist/collection/components/toggle-checkbox-input/toggle-checkbox-input.css +82 -0
  33. package/dist/collection/components/toggle-checkbox-input/toggle-checkbox-input.js +366 -0
  34. package/dist/collection/components/twofa-input/twofa-input.css +56 -0
  35. package/dist/collection/components/twofa-input/twofa-input.js +495 -0
  36. package/dist/collection/index.js +1 -0
  37. package/dist/collection/utils/locale.utils.js +81 -0
  38. package/dist/collection/utils/tooltipIcon.svg +5 -0
  39. package/dist/collection/utils/types.js +1 -0
  40. package/dist/collection/utils/utils.js +3 -0
  41. package/dist/esm/app-globals-0f993ce5.js +3 -0
  42. package/dist/esm/checkbox-group-input_13.entry.js +7288 -0
  43. package/dist/esm/general-input-hsl-31f19ad0.js +5797 -0
  44. package/dist/esm/general-input-hsl.js +20 -0
  45. package/dist/esm/index-8598bfb7.js +1270 -0
  46. package/dist/esm/index.js +2 -0
  47. package/dist/esm/loader.js +11 -0
  48. package/dist/general-input-hsl/app-globals-0f993ce5.js +1 -0
  49. package/dist/general-input-hsl/checkbox-group-input_13.entry.js +1 -0
  50. package/dist/general-input-hsl/general-input-hsl-31f19ad0.js +5614 -0
  51. package/dist/general-input-hsl/general-input-hsl.esm.js +1 -0
  52. package/dist/general-input-hsl/index-8598bfb7.js +2 -0
  53. package/dist/general-input-hsl/index.esm.js +1 -0
  54. package/dist/index.cjs.js +1 -0
  55. package/dist/index.js +1 -0
  56. package/dist/stencil.config.dev.js +19 -0
  57. package/dist/stencil.config.js +19 -0
  58. package/dist/storybook/main.js +43 -0
  59. package/dist/storybook/preview.js +9 -0
  60. package/dist/types/Users/maria.bumbar/Desktop/Widgets & Template/widgets-monorepo/packages/stencil/general-input-hsl/.stencil/libs/common/src/storybook/storybook-utils.d.ts +39 -0
  61. package/dist/types/Users/maria.bumbar/Desktop/Widgets & Template/widgets-monorepo/packages/stencil/general-input-hsl/.stencil/packages/stencil/general-input-hsl/stencil.config.d.ts +2 -0
  62. package/dist/types/Users/maria.bumbar/Desktop/Widgets & Template/widgets-monorepo/packages/stencil/general-input-hsl/.stencil/packages/stencil/general-input-hsl/stencil.config.dev.d.ts +2 -0
  63. package/dist/types/Users/maria.bumbar/Desktop/Widgets & Template/widgets-monorepo/packages/stencil/general-input-hsl/.stencil/packages/stencil/general-input-hsl/storybook/main.d.ts +3 -0
  64. package/dist/types/Users/maria.bumbar/Desktop/Widgets & Template/widgets-monorepo/packages/stencil/general-input-hsl/.stencil/packages/stencil/general-input-hsl/storybook/preview.d.ts +70 -0
  65. package/dist/types/Users/maria.bumbar/Desktop/Widgets & Template/widgets-monorepo/packages/stencil/general-input-hsl/.stencil/tools/plugins/index.d.ts +3 -0
  66. package/dist/types/Users/maria.bumbar/Desktop/Widgets & Template/widgets-monorepo/packages/stencil/general-input-hsl/.stencil/tools/plugins/stencil-clean-deps-plugin.d.ts +5 -0
  67. package/dist/types/Users/maria.bumbar/Desktop/Widgets & Template/widgets-monorepo/packages/stencil/general-input-hsl/.stencil/tools/plugins/vite-chunk-plugin.d.ts +6 -0
  68. package/dist/types/Users/maria.bumbar/Desktop/Widgets & Template/widgets-monorepo/packages/stencil/general-input-hsl/.stencil/tools/plugins/vite-clean-deps-plugin.d.ts +4 -0
  69. package/dist/types/components/checkbox-group-input/checkbox-group-input.d.ts +74 -0
  70. package/dist/types/components/checkbox-input/checkbox-input.d.ts +67 -0
  71. package/dist/types/components/date-input/date-input.d.ts +89 -0
  72. package/dist/types/components/email-input/email-input.d.ts +81 -0
  73. package/dist/types/components/general-input-hsl/general-input-hsl.d.ts +84 -0
  74. package/dist/types/components/general-input-hsl/index.d.ts +1 -0
  75. package/dist/types/components/number-input/number-input.d.ts +75 -0
  76. package/dist/types/components/password-input/password-input.d.ts +97 -0
  77. package/dist/types/components/radio-input/radio-input.d.ts +60 -0
  78. package/dist/types/components/select-input/select-input.d.ts +85 -0
  79. package/dist/types/components/tel-input/tel-input.d.ts +89 -0
  80. package/dist/types/components/text-input/text-input.d.ts +86 -0
  81. package/dist/types/components/toggle-checkbox-input/toggle-checkbox-input.d.ts +73 -0
  82. package/dist/types/components/twofa-input/twofa-input.d.ts +84 -0
  83. package/dist/types/components.d.ts +1599 -0
  84. package/dist/types/index.d.ts +1 -0
  85. package/dist/types/stencil-public-runtime.d.ts +1674 -0
  86. package/dist/types/utils/locale.utils.d.ts +13 -0
  87. package/dist/types/utils/types.d.ts +111 -0
  88. package/dist/types/utils/utils.d.ts +1 -0
  89. package/loader/cdn.js +1 -0
  90. package/loader/index.cjs.js +1 -0
  91. package/loader/index.d.ts +24 -0
  92. package/loader/index.es2017.js +1 -0
  93. package/loader/index.js +2 -0
  94. package/loader/package.json +11 -0
  95. package/package.json +27 -0
@@ -0,0 +1,466 @@
1
+ import { h } from "@stencil/core";
2
+ import { translate } from "../../utils/locale.utils";
3
+ import tooltipIcon from "../../utils/tooltipIcon.svg";
4
+ import dateFnsFormat from "date-fns/format";
5
+ import dateFnsParse from "date-fns/parse";
6
+ import { isBefore, isAfter, isMatch } from "date-fns";
7
+ export class DateInput {
8
+ constructor() {
9
+ this.touched = false;
10
+ this.formatDate = (dateParts) => {
11
+ const { year, month, day } = dateParts;
12
+ const date = new Date(year, month, day);
13
+ return dateFnsFormat(date, this.dateFormat);
14
+ };
15
+ this.parseDate = (inputValue) => {
16
+ const date = dateFnsParse(inputValue, this.dateFormat, new Date());
17
+ return { year: date.getFullYear(), month: date.getMonth(), day: date.getDate() };
18
+ };
19
+ this.setClientStyling = () => {
20
+ let sheet = document.createElement('style');
21
+ sheet.innerHTML = this.clientStyling;
22
+ this.stylingContainer.prepend(sheet);
23
+ };
24
+ this.name = undefined;
25
+ this.displayName = undefined;
26
+ this.placeholder = undefined;
27
+ this.validation = undefined;
28
+ this.defaultValue = undefined;
29
+ this.autofilled = undefined;
30
+ this.tooltip = undefined;
31
+ this.language = undefined;
32
+ this.emitValue = undefined;
33
+ this.clientStyling = '';
34
+ this.dateFormat = 'yyyy-MM-dd';
35
+ this.emitOnClick = false;
36
+ this.errorMessage = undefined;
37
+ this.isValid = undefined;
38
+ this.limitStylingAppends = false;
39
+ this.showTooltip = false;
40
+ }
41
+ get formattedValue() {
42
+ if (!this.value)
43
+ return '';
44
+ const parsedDate = dateFnsParse(this.value, 'yyyy-MM-dd', new Date());
45
+ return dateFnsFormat(parsedDate, this.dateFormat);
46
+ }
47
+ handleStylingChange(newValue, oldValue) {
48
+ if (newValue !== oldValue)
49
+ this.setClientStyling();
50
+ }
51
+ validityChanged() {
52
+ this.validityStateHandler({ valid: this.isValid, name: this.name });
53
+ if (this.emitValue == true) {
54
+ this.valueHandler({ name: this.name, value: this.value });
55
+ }
56
+ }
57
+ validityStateHandler(inputStateEvent) {
58
+ this.sendValidityState.emit(inputStateEvent);
59
+ }
60
+ emitValueHandler(newValue) {
61
+ if (newValue == true && this.isValid) {
62
+ this.valueHandler({ name: this.name, value: this.value });
63
+ }
64
+ }
65
+ valueHandler(inputValueEvent) {
66
+ this.sendInputValue.emit(inputValueEvent);
67
+ }
68
+ handleClickOutside(event) {
69
+ if (event.composedPath()[0] === this.tooltipIconReference)
70
+ return;
71
+ if (event.composedPath()[0] !== this.tooltipReference)
72
+ this.showTooltip = false;
73
+ }
74
+ connectedCallback() {
75
+ var _a, _b;
76
+ this.minDate = dateFnsParse(((_a = this.validation.min) === null || _a === void 0 ? void 0 : _a.toString()) || '', 'yyyy-MM-dd', new Date());
77
+ this.maxDate = dateFnsParse(((_b = this.validation.max) === null || _b === void 0 ? void 0 : _b.toString()) || '', 'yyyy-MM-dd', new Date());
78
+ }
79
+ componentDidRender() {
80
+ // start custom styling area
81
+ if (!this.limitStylingAppends && this.stylingContainer) {
82
+ if (this.clientStyling)
83
+ this.setClientStyling();
84
+ this.limitStylingAppends = true;
85
+ }
86
+ // end custom styling area
87
+ }
88
+ componentDidLoad() {
89
+ this.datePicker = this.element.shadowRoot.querySelector('vaadin-date-picker');
90
+ this.inputReference = this.element.shadowRoot.querySelector('input');
91
+ if (this.datePicker) {
92
+ const calendarButton = this.datePicker.shadowRoot.querySelector('[part="toggle-button"]');
93
+ if (calendarButton) {
94
+ calendarButton.addEventListener('click', () => this.handleCalendarIconClick());
95
+ }
96
+ // Add listener for dropdown close
97
+ this.datePicker.addEventListener('opened-changed', (event) => {
98
+ if (event.detail.value === true) {
99
+ this.errorMessage = '';
100
+ }
101
+ else {
102
+ this.isValid = this.setValidity();
103
+ this.errorMessage = this.setErrorMessage();
104
+ this.touched = true;
105
+ }
106
+ });
107
+ }
108
+ this.datePicker.i18n = Object.assign(Object.assign({}, this.datePicker.i18n), { formatDate: this.formatDate, parseDate: this.parseDate });
109
+ this.isValid = this.setValidity();
110
+ if (this.defaultValue) {
111
+ this.value = this.defaultValue;
112
+ this.valueHandler({ name: this.name, value: this.value });
113
+ }
114
+ }
115
+ handleCalendarIconClick() {
116
+ if (this.datePicker.opened && this.emitOnClick) {
117
+ window.postMessage({ type: `registration${this.name}Clicked` }, window.location.href);
118
+ }
119
+ }
120
+ handleInput(event) {
121
+ this.value = event.target.value;
122
+ this.touched = true;
123
+ this.valueAsDate = dateFnsParse(this.value || '', 'yyyy-MM-dd', new Date());
124
+ this.isValid = this.setValidity();
125
+ this.errorMessage = this.setErrorMessage();
126
+ this.emitValueHandler(true);
127
+ }
128
+ setValidity() {
129
+ if (isBefore(this.valueAsDate, this.minDate) || isAfter(this.valueAsDate, this.maxDate) || !isMatch(this.formattedValue, this.dateFormat)) {
130
+ return false;
131
+ }
132
+ else {
133
+ return this.inputReference.validity.valid;
134
+ }
135
+ }
136
+ setErrorMessage() {
137
+ if (this.inputReference.validity.valueMissing) {
138
+ return translate('requiredError', this.language);
139
+ }
140
+ if (this.inputReference.validity.rangeUnderflow || this.inputReference.validity.rangeOverflow) {
141
+ return translate('dateError', this.language, { values: { min: this.validation.min, max: this.validation.max } });
142
+ }
143
+ if (isBefore(this.valueAsDate, this.minDate) || isAfter(this.valueAsDate, this.maxDate)) {
144
+ return translate('dateError2', this.language);
145
+ }
146
+ if (!isMatch(this.formattedValue, this.dateFormat)) {
147
+ return translate('dateFormatError', this.language);
148
+ }
149
+ }
150
+ renderTooltip() {
151
+ if (this.showTooltip) {
152
+ return (h("div", { class: `date__tooltip ${this.showTooltip ? 'visible' : ''}`, ref: (el) => this.tooltipReference = el, innerHTML: this.tooltip }));
153
+ }
154
+ return null;
155
+ }
156
+ render() {
157
+ let invalidClass = '';
158
+ if (this.touched) {
159
+ invalidClass = this.isValid == true || this.isValid == undefined ? '' : 'text__input--invalid';
160
+ }
161
+ return h("div", { key: 'ccbdcfd1e145373d0fb24f7c1e6e5ae1184a80f2', class: `date__wrapper ${this.autofilled ? 'date__wrapper--autofilled' : ''} ${this.name}__input`, ref: el => this.stylingContainer = el }, h("label", { key: '960db248a2f7418ed87b25de57b58cc8a4902a25', class: `date__label ${this.validation.mandatory ? 'date__label--required' : ''}}`, htmlFor: `${this.name}__input` }, this.displayName, " ", this.validation.mandatory ? '*' : ''), h("vaadin-date-picker", { key: '660961b240cc0cff03d8d4bf3687b398cd07befd', id: `${this.name}__input`, type: 'date', class: `date__input ${invalidClass}`, value: this.defaultValue, readOnly: this.autofilled, placeholder: `${this.placeholder}`, required: this.validation.mandatory, max: this.validation.max, min: this.validation.min, onChange: (e) => this.handleInput(e) }), h("small", { key: 'ba06bb3d85bb4441ae92a642464a47b798b287eb', class: 'date__error-message' }, this.errorMessage), this.tooltip &&
162
+ h("img", { key: '7ccb422e319e2a08963e99b242495ba9115517bd', class: 'date__tooltip-icon', src: tooltipIcon, alt: "", ref: (el) => this.tooltipIconReference = el, onClick: () => this.showTooltip = !this.showTooltip }), this.renderTooltip());
163
+ }
164
+ static get is() { return "date-input"; }
165
+ static get encapsulation() { return "shadow"; }
166
+ static get originalStyleUrls() {
167
+ return {
168
+ "$": ["date-input.scss"]
169
+ };
170
+ }
171
+ static get styleUrls() {
172
+ return {
173
+ "$": ["date-input.css"]
174
+ };
175
+ }
176
+ static get properties() {
177
+ return {
178
+ "name": {
179
+ "type": "string",
180
+ "mutable": false,
181
+ "complexType": {
182
+ "original": "string",
183
+ "resolved": "string",
184
+ "references": {}
185
+ },
186
+ "required": false,
187
+ "optional": false,
188
+ "docs": {
189
+ "tags": [],
190
+ "text": "Name of the input."
191
+ },
192
+ "attribute": "name",
193
+ "reflect": true
194
+ },
195
+ "displayName": {
196
+ "type": "string",
197
+ "mutable": false,
198
+ "complexType": {
199
+ "original": "string",
200
+ "resolved": "string",
201
+ "references": {}
202
+ },
203
+ "required": false,
204
+ "optional": false,
205
+ "docs": {
206
+ "tags": [],
207
+ "text": "Name of input to be shown to the user."
208
+ },
209
+ "attribute": "display-name",
210
+ "reflect": true
211
+ },
212
+ "placeholder": {
213
+ "type": "string",
214
+ "mutable": false,
215
+ "complexType": {
216
+ "original": "string",
217
+ "resolved": "string",
218
+ "references": {}
219
+ },
220
+ "required": false,
221
+ "optional": false,
222
+ "docs": {
223
+ "tags": [],
224
+ "text": "Placeholder text to be shown."
225
+ },
226
+ "attribute": "placeholder",
227
+ "reflect": true
228
+ },
229
+ "validation": {
230
+ "type": "unknown",
231
+ "mutable": false,
232
+ "complexType": {
233
+ "original": "ValidationSchema",
234
+ "resolved": "ValidationSchema",
235
+ "references": {
236
+ "ValidationSchema": {
237
+ "location": "import",
238
+ "path": "../../utils/types",
239
+ "id": "../../../../packages/stencil/general-input-hsl/src/utils/types.ts::ValidationSchema"
240
+ }
241
+ }
242
+ },
243
+ "required": false,
244
+ "optional": false,
245
+ "docs": {
246
+ "tags": [],
247
+ "text": "Object of validation rules for the input."
248
+ }
249
+ },
250
+ "defaultValue": {
251
+ "type": "string",
252
+ "mutable": false,
253
+ "complexType": {
254
+ "original": "string",
255
+ "resolved": "string",
256
+ "references": {}
257
+ },
258
+ "required": false,
259
+ "optional": false,
260
+ "docs": {
261
+ "tags": [],
262
+ "text": "Default value for the input."
263
+ },
264
+ "attribute": "default-value",
265
+ "reflect": true
266
+ },
267
+ "autofilled": {
268
+ "type": "boolean",
269
+ "mutable": false,
270
+ "complexType": {
271
+ "original": "boolean",
272
+ "resolved": "boolean",
273
+ "references": {}
274
+ },
275
+ "required": false,
276
+ "optional": false,
277
+ "docs": {
278
+ "tags": [],
279
+ "text": "Boolean. Determines if input should be readonly."
280
+ },
281
+ "attribute": "autofilled",
282
+ "reflect": true
283
+ },
284
+ "tooltip": {
285
+ "type": "string",
286
+ "mutable": false,
287
+ "complexType": {
288
+ "original": "string",
289
+ "resolved": "string",
290
+ "references": {}
291
+ },
292
+ "required": false,
293
+ "optional": false,
294
+ "docs": {
295
+ "tags": [],
296
+ "text": "Tooltip text."
297
+ },
298
+ "attribute": "tooltip",
299
+ "reflect": true
300
+ },
301
+ "language": {
302
+ "type": "string",
303
+ "mutable": false,
304
+ "complexType": {
305
+ "original": "string",
306
+ "resolved": "string",
307
+ "references": {}
308
+ },
309
+ "required": false,
310
+ "optional": false,
311
+ "docs": {
312
+ "tags": [],
313
+ "text": "Currently selected language."
314
+ },
315
+ "attribute": "language",
316
+ "reflect": true
317
+ },
318
+ "emitValue": {
319
+ "type": "boolean",
320
+ "mutable": false,
321
+ "complexType": {
322
+ "original": "boolean",
323
+ "resolved": "boolean",
324
+ "references": {}
325
+ },
326
+ "required": false,
327
+ "optional": false,
328
+ "docs": {
329
+ "tags": [],
330
+ "text": "State passed down from the parent element. Will trigger the input to send it's value through an event."
331
+ },
332
+ "attribute": "emit-value",
333
+ "reflect": true
334
+ },
335
+ "clientStyling": {
336
+ "type": "string",
337
+ "mutable": false,
338
+ "complexType": {
339
+ "original": "string",
340
+ "resolved": "string",
341
+ "references": {}
342
+ },
343
+ "required": false,
344
+ "optional": false,
345
+ "docs": {
346
+ "tags": [],
347
+ "text": "Client custom styling via inline style"
348
+ },
349
+ "attribute": "client-styling",
350
+ "reflect": true,
351
+ "defaultValue": "''"
352
+ },
353
+ "dateFormat": {
354
+ "type": "string",
355
+ "mutable": false,
356
+ "complexType": {
357
+ "original": "string",
358
+ "resolved": "string",
359
+ "references": {}
360
+ },
361
+ "required": false,
362
+ "optional": false,
363
+ "docs": {
364
+ "tags": [],
365
+ "text": "Date format for date picker."
366
+ },
367
+ "attribute": "date-format",
368
+ "reflect": true,
369
+ "defaultValue": "'yyyy-MM-dd'"
370
+ },
371
+ "emitOnClick": {
372
+ "type": "boolean",
373
+ "mutable": false,
374
+ "complexType": {
375
+ "original": "boolean",
376
+ "resolved": "boolean",
377
+ "references": {}
378
+ },
379
+ "required": false,
380
+ "optional": false,
381
+ "docs": {
382
+ "tags": [],
383
+ "text": "Emit event on click"
384
+ },
385
+ "attribute": "emit-on-click",
386
+ "reflect": true,
387
+ "defaultValue": "false"
388
+ }
389
+ };
390
+ }
391
+ static get states() {
392
+ return {
393
+ "errorMessage": {},
394
+ "isValid": {},
395
+ "limitStylingAppends": {},
396
+ "showTooltip": {}
397
+ };
398
+ }
399
+ static get events() {
400
+ return [{
401
+ "method": "sendValidityState",
402
+ "name": "sendValidityState",
403
+ "bubbles": true,
404
+ "cancelable": true,
405
+ "composed": true,
406
+ "docs": {
407
+ "tags": [],
408
+ "text": ""
409
+ },
410
+ "complexType": {
411
+ "original": "InputStateEvent",
412
+ "resolved": "InputStateEvent",
413
+ "references": {
414
+ "InputStateEvent": {
415
+ "location": "import",
416
+ "path": "../../utils/types",
417
+ "id": "../../../../packages/stencil/general-input-hsl/src/utils/types.ts::InputStateEvent"
418
+ }
419
+ }
420
+ }
421
+ }, {
422
+ "method": "sendInputValue",
423
+ "name": "sendInputValue",
424
+ "bubbles": true,
425
+ "cancelable": true,
426
+ "composed": true,
427
+ "docs": {
428
+ "tags": [],
429
+ "text": ""
430
+ },
431
+ "complexType": {
432
+ "original": "InputValueEvent",
433
+ "resolved": "InputValueEvent",
434
+ "references": {
435
+ "InputValueEvent": {
436
+ "location": "import",
437
+ "path": "../../utils/types",
438
+ "id": "../../../../packages/stencil/general-input-hsl/src/utils/types.ts::InputValueEvent"
439
+ }
440
+ }
441
+ }
442
+ }];
443
+ }
444
+ static get elementRef() { return "element"; }
445
+ static get watchers() {
446
+ return [{
447
+ "propName": "clientStyling",
448
+ "methodName": "handleStylingChange"
449
+ }, {
450
+ "propName": "isValid",
451
+ "methodName": "validityChanged"
452
+ }, {
453
+ "propName": "emitValue",
454
+ "methodName": "emitValueHandler"
455
+ }];
456
+ }
457
+ static get listeners() {
458
+ return [{
459
+ "name": "click",
460
+ "method": "handleClickOutside",
461
+ "target": "document",
462
+ "capture": false,
463
+ "passive": false
464
+ }];
465
+ }
466
+ }
@@ -0,0 +1,95 @@
1
+ *,
2
+ *::before,
3
+ *::after {
4
+ padding: 0;
5
+ margin: 0;
6
+ box-sizing: border-box;
7
+ }
8
+
9
+ .email {
10
+ font-family: "Roboto";
11
+ font-style: normal;
12
+ }
13
+ .email__wrapper {
14
+ position: relative;
15
+ width: 100%;
16
+ }
17
+ .email__wrapper--autofilled {
18
+ pointer-events: none;
19
+ }
20
+ .email__wrapper--autofilled .email__label {
21
+ color: var(--emw--registration-typography, var(--emw--color-black, #000000));
22
+ }
23
+ .email__wrapper--autofilled .email__input {
24
+ color: var(--emw--color-black, #000000);
25
+ }
26
+ .email__wrapper--flex {
27
+ display: flex;
28
+ gap: 5px;
29
+ }
30
+ .email__wrapper--relative {
31
+ position: relative;
32
+ }
33
+ .email__label {
34
+ font-family: inherit;
35
+ font-style: normal;
36
+ font-weight: 500;
37
+ font-size: 16px;
38
+ line-height: 20px;
39
+ color: var(--emw--registration-typography, var(--emw--color-black, #000000));
40
+ }
41
+ .email__label--required::after {
42
+ content: "*";
43
+ font-family: inherit;
44
+ color: var(--emw--login-color-primary, var(--emw--color-primary, #22B04E));
45
+ margin-left: 2px;
46
+ }
47
+ .email__input {
48
+ font-family: inherit;
49
+ border-radius: 4px;
50
+ width: 100%;
51
+ height: 40px;
52
+ border: 2px solid var(--emw--color-gray-100, #E6E6E6);
53
+ color: var(--emw--color-black, #000000);
54
+ border-radius: 5px;
55
+ box-sizing: border-box;
56
+ font-size: 16px;
57
+ font-weight: 300;
58
+ line-height: 1.5;
59
+ padding: 10px;
60
+ }
61
+ .email__input:focus {
62
+ outline-color: var(--emw--login-color-primary, var(--emw--color-primary, #22B04E));
63
+ }
64
+ .email__input--invalid {
65
+ border: 1px solid var(--emw--color-error, var(--emw--color-red, #ed0909));
66
+ }
67
+ .email__input::placeholder {
68
+ color: var(--emw--color-gray-150, #828282);
69
+ }
70
+ .email__error-message {
71
+ position: absolute;
72
+ top: calc(100% + 5px);
73
+ left: 0;
74
+ color: var(--emw--color-error, var(--emw--color-red, #ed0909));
75
+ }
76
+ .email__tooltip-icon {
77
+ width: 16px;
78
+ height: auto;
79
+ }
80
+ .email__tooltip {
81
+ position: absolute;
82
+ top: 0;
83
+ left: 20px;
84
+ background-color: var(--emw--color-white, #FFFFFF);
85
+ border: 1px solid var(--emw--color-gray-100, #E6E6E6);
86
+ color: var(--emw--registration-typography, var(--emw--color-black, #000000));
87
+ padding: 10px;
88
+ border-radius: 5px;
89
+ opacity: 0;
90
+ transition: opacity 0.3s ease-in-out;
91
+ z-index: 10;
92
+ }
93
+ .email__tooltip.visible {
94
+ opacity: 1;
95
+ }