@alfalab/core-components-confirmation 8.3.0 → 9.0.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.
Files changed (42) hide show
  1. package/CHANGELOG.md +70 -0
  2. package/dist/component.js +2 -2
  3. package/dist/components/code-input/component.js +2 -1
  4. package/dist/components/code-input/index.css +13 -9
  5. package/dist/components/countdown/component.js +1 -1
  6. package/dist/components/countdown/index.css +13 -13
  7. package/dist/components/countdown-loader/component.js +1 -1
  8. package/dist/components/countdown-loader/index.css +2 -2
  9. package/dist/components/overlimit/component.js +1 -1
  10. package/dist/components/overlimit/index.css +9 -9
  11. package/dist/components/sign-confirmation/component.js +2 -2
  12. package/dist/components/sign-confirmation/index.css +13 -13
  13. package/dist/cssm/component.js +1 -1
  14. package/dist/cssm/components/code-input/component.js +1 -0
  15. package/dist/cssm/components/code-input/index.module.css +4 -0
  16. package/dist/cssm/components/sign-confirmation/component.js +1 -1
  17. package/dist/esm/component.js +2 -2
  18. package/dist/esm/components/code-input/component.js +2 -1
  19. package/dist/esm/components/code-input/index.css +13 -9
  20. package/dist/esm/components/countdown/component.js +1 -1
  21. package/dist/esm/components/countdown/index.css +13 -13
  22. package/dist/esm/components/countdown-loader/component.js +1 -1
  23. package/dist/esm/components/countdown-loader/index.css +2 -2
  24. package/dist/esm/components/overlimit/component.js +1 -1
  25. package/dist/esm/components/overlimit/index.css +9 -9
  26. package/dist/esm/components/sign-confirmation/component.js +2 -2
  27. package/dist/esm/components/sign-confirmation/index.css +13 -13
  28. package/dist/esm/index.css +14 -14
  29. package/dist/index.css +14 -14
  30. package/dist/modern/component.js +2 -2
  31. package/dist/modern/components/code-input/component.js +2 -1
  32. package/dist/modern/components/code-input/index.css +13 -9
  33. package/dist/modern/components/countdown/component.js +1 -1
  34. package/dist/modern/components/countdown/index.css +13 -13
  35. package/dist/modern/components/countdown-loader/component.js +1 -1
  36. package/dist/modern/components/countdown-loader/index.css +2 -2
  37. package/dist/modern/components/overlimit/component.js +1 -1
  38. package/dist/modern/components/overlimit/index.css +9 -9
  39. package/dist/modern/components/sign-confirmation/component.js +2 -2
  40. package/dist/modern/components/sign-confirmation/index.css +13 -13
  41. package/dist/modern/index.css +14 -14
  42. package/package.json +4 -4
package/CHANGELOG.md CHANGED
@@ -3,6 +3,76 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [9.0.0](https://github.com/alfa-laboratory/core-components/compare/@alfalab/core-components-confirmation@8.5.1...@alfalab/core-components-confirmation@9.0.0) (2021-11-26)
7
+
8
+
9
+ ### Features
10
+
11
+ * **button:** добавлена кнопка размера 40px, изменены скругления ([#886](https://github.com/alfa-laboratory/core-components/issues/886)) ([88e657a](https://github.com/alfa-laboratory/core-components/commit/88e657a9f0f68b8b58f6e9437053954ee984f83c)), closes [#890](https://github.com/alfa-laboratory/core-components/issues/890)
12
+
13
+
14
+ ### BREAKING CHANGES
15
+
16
+ * **button:** Кнопка размера xs теперь имеет размер 40px. Тем, кто использовал размер xs, надо
17
+ заменить размер на xxs. Можно воспользоваться codemod.
18
+
19
+ * feat(codemod): add button xs to xxs transformer
20
+
21
+ * feat(tag): добавлен тэг размера 40px, изменены отступы
22
+
23
+ Добавлен тэг размером 40px, изменены отступы. Тем, кто использовал размер xs, надо заменить размер
24
+ на xxs.
25
+ * **button:** Тэг размера xs теперь имеет размер 40px. Тем, кто использовал размер xs, надо
26
+ заменить размер на xxs. Можно воспользоваться codemod.
27
+
28
+ * test: update screenshots
29
+
30
+ * test: update screenshots
31
+
32
+ * feat(button): linter fix
33
+
34
+ * feat(button): fix min-width
35
+
36
+ * feat(tag): remove vertical paddings
37
+
38
+ * feat(tag): remove vertical paddings
39
+
40
+ * feat(button): updates
41
+
42
+
43
+
44
+
45
+
46
+ ## [8.5.1](https://github.com/alfa-laboratory/core-components/compare/@alfalab/core-components-confirmation@8.5.0...@alfalab/core-components-confirmation@8.5.1) (2021-11-16)
47
+
48
+ **Note:** Version bump only for package @alfalab/core-components-confirmation
49
+
50
+
51
+
52
+
53
+
54
+ # [8.5.0](https://github.com/alfa-laboratory/core-components/compare/@alfalab/core-components-confirmation@8.4.0...@alfalab/core-components-confirmation@8.5.0) (2021-10-18)
55
+
56
+
57
+ ### Features
58
+
59
+ * **confirmation:** compact code-input if slotsCount > 6 ([99be0e1](https://github.com/alfa-laboratory/core-components/commit/99be0e1744d9782824756c8992fd4b986a589dd7))
60
+
61
+
62
+
63
+
64
+
65
+ # [8.4.0](https://github.com/alfa-laboratory/core-components/compare/@alfalab/core-components-confirmation@8.3.0...@alfalab/core-components-confirmation@8.4.0) (2021-10-11)
66
+
67
+
68
+ ### Features
69
+
70
+ * проставлен role=alert для ошибок ([#850](https://github.com/alfa-laboratory/core-components/issues/850)) ([dc634a3](https://github.com/alfa-laboratory/core-components/commit/dc634a3d008accfab10192ce234c12ef0ecc7fa9))
71
+
72
+
73
+
74
+
75
+
6
76
  # [8.3.0](https://github.com/alfa-laboratory/core-components/compare/@alfalab/core-components-confirmation@8.2.2...@alfalab/core-components-confirmation@8.3.0) (2021-09-27)
7
77
 
8
78
 
package/dist/component.js CHANGED
@@ -22,7 +22,7 @@ function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'defau
22
22
  var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
23
23
  var cn__default = /*#__PURE__*/_interopDefaultLegacy(cn);
24
24
 
25
- var styles = {"component":"confirmation__component_4oaka","error":"confirmation__error_4oaka","errorHeader":"confirmation__errorHeader_4oaka","errorText":"confirmation__errorText_4oaka","phoneHintWrap":"confirmation__phoneHintWrap_4oaka","phoneHintText":"confirmation__phoneHintText_4oaka","phonesWrap":"confirmation__phonesWrap_4oaka","phoneWrap":"confirmation__phoneWrap_4oaka","phoneDescription":"confirmation__phoneDescription_4oaka","center":"confirmation__center_4oaka"};
25
+ var styles = {"component":"confirmation__component_h92d1","error":"confirmation__error_h92d1","errorHeader":"confirmation__errorHeader_h92d1","errorText":"confirmation__errorText_h92d1","phoneHintWrap":"confirmation__phoneHintWrap_h92d1","phoneHintText":"confirmation__phoneHintText_h92d1","phonesWrap":"confirmation__phonesWrap_h92d1","phoneWrap":"confirmation__phoneWrap_h92d1","phoneDescription":"confirmation__phoneDescription_h92d1","center":"confirmation__center_h92d1"};
26
26
  require('./index.css')
27
27
 
28
28
  var Confirmation = React.forwardRef(function (_a, ref) {
@@ -80,7 +80,7 @@ var Confirmation = React.forwardRef(function (_a, ref) {
80
80
  return (React__default['default'].createElement("div", { className: cn__default['default'](styles.component, styles[alignContent], className), ref: ref, "data-test-id": dataTestId },
81
81
  shouldShowSignComponent && (React__default['default'].createElement(components_signConfirmation_component.SignConfirmation, { codeChecking: codeChecking, codeSending: codeSending, smsHintVisible: !codeChecking, additionalContent: additionalContent, requiredCharAmount: requiredCharAmount, hasSmsCountdown: hasSmsCountdown, countdownDuration: countdownDuration, phone: phone, code: code, hasPhoneMask: hasPhoneMask, errorText: nonFatalError || '', error: error, title: signTitle, buttonRetryText: buttonRetryText, inputRef: inputRef, codeCheckingText: codeCheckingText, codeSendingText: codeSendingText, alignContent: alignContent, noAttemptsLeftMessage: noAttemptsLeftMessage, countdownContent: countdownContent, onInputFinished: onInputFinished, onInputChange: onInputChange, onSmsRetryClick: handleSmsRetryClick, onCountdownFinished: handleCountdownFinished, onSmsHintLinkClick: handleSmsHintLinkClick })),
82
82
  shouldShowOverlimitError && (React__default['default'].createElement(components_overlimit_component.Overlimit, { duration: overlimitCountdownDuration, title: overlimitTitle, text: overlimitText, hasFatalError: errorOverlimitIsFatal, buttonRetryText: buttonRetryText, onOverlimitRepeatSms: handleOverlimitSmsRetryClick, onOverlimitCountdownFinished: handleOverlimitCountdownFinished })),
83
- shouldShowFatalError && (React__default['default'].createElement("div", { className: styles.error },
83
+ shouldShowFatalError && (React__default['default'].createElement("div", { className: styles.error, role: 'alert' },
84
84
  React__default['default'].createElement("span", { className: styles.errorHeader }, errorTitle),
85
85
  React__default['default'].createElement("span", { className: styles.errorText }, errorText),
86
86
  React__default['default'].createElement(coreComponentsButton.Button, { size: 'xs', view: 'secondary', onClick: handleErrorSmsRetryClick }, buttonErrorText))),
@@ -35,7 +35,7 @@ function __spreadArrays() {
35
35
  return r;
36
36
  }
37
37
 
38
- var styles = {"component":"confirmation__component_b1i9a","input":"confirmation__input_b1i9a","hasError":"confirmation__hasError_b1i9a","center":"confirmation__center_b1i9a","disabled":"confirmation__disabled_b1i9a","shake":"confirmation__shake_b1i9a"};
38
+ var styles = {"component":"confirmation__component_qz435","input":"confirmation__input_qz435","hasError":"confirmation__hasError_qz435","center":"confirmation__center_qz435","disabled":"confirmation__disabled_qz435","compact":"confirmation__compact_qz435","shake":"confirmation__shake_qz435"};
39
39
  require('./index.css')
40
40
 
41
41
  var Input = function (_a) {
@@ -151,6 +151,7 @@ var CodeInput = React.forwardRef(function (_a, ref) {
151
151
  }, [value.length, prevValue.length, slotsCount, focus]);
152
152
  return (React__default['default'].createElement("div", { className: cn__default['default'](styles.component, className, (_b = {},
153
153
  _b[styles.shake] = Boolean(error),
154
+ _b[styles.compact] = slotsCount > 6,
154
155
  _b)) }, new Array(slotsCount).fill('').map(function (_, index) { return (React__default['default'].createElement(Input, { value: value, index: index, error: error, processing: processing, slotsCount: slotsCount, alignContent: alignContent, handleChange: handleChange, handleInputKeyDown: handleInputKeyDown, setRef: setRef, focus: focus,
155
156
  // eslint-disable-next-line react/no-array-index-key
156
157
  key: index })); })));
@@ -1,4 +1,4 @@
1
- /* hash: b1i9a */
1
+ /* hash: y4w3u */
2
2
  :root {
3
3
  --color-light-bg-negative-muted: #feebea;
4
4
  --color-light-bg-secondary: #f3f4f5;
@@ -41,10 +41,10 @@
41
41
  --confirmation-input-bg-color: var(--color-light-bg-secondary);
42
42
  --confirmation-input-error-bg-color: var(--color-light-bg-negative-muted);
43
43
  }
44
- .confirmation__component_b1i9a {
44
+ .confirmation__component_qz435 {
45
45
  display: flex;
46
46
  }
47
- .confirmation__input_b1i9a {
47
+ .confirmation__input_qz435 {
48
48
  flex-shrink: 0;
49
49
  width: 36px;
50
50
  height: 48px;
@@ -61,19 +61,23 @@
61
61
  font-weight: var(--confirmation-input-font-weight);
62
62
  font-family: var(--confirmation-input-font-family)
63
63
  }
64
- .confirmation__input_b1i9a.confirmation__hasError_b1i9a {
64
+ .confirmation__input_qz435.confirmation__hasError_qz435 {
65
65
  color: var(--confirmation-error-color);
66
66
  caret-color: var(--confirmation-input-text-color);
67
67
  background-color: var(--confirmation-input-error-bg-color);
68
68
  }
69
- .confirmation__input_b1i9a.confirmation__center_b1i9a {
69
+ .confirmation__input_qz435.confirmation__center_qz435 {
70
70
  margin: 0 var(--gap-2xs);
71
71
  }
72
- .confirmation__input_b1i9a.confirmation__disabled_b1i9a {
72
+ .confirmation__input_qz435.confirmation__disabled_qz435 {
73
73
  color: var(--color-light-text-tertiary);
74
74
  opacity: 1;
75
75
  }
76
- @keyframes confirmation__shake_b1i9a {
76
+ .confirmation__compact_qz435 .confirmation__input_qz435 {
77
+ width: 28px;
78
+ height: 40px;
79
+ }
80
+ @keyframes confirmation__shake_qz435 {
77
81
  0% {
78
82
  transform: translateX(0);
79
83
  }
@@ -90,6 +94,6 @@
90
94
  transform: translateX(0);
91
95
  }
92
96
  }
93
- .confirmation__shake_b1i9a {
94
- animation: confirmation__shake_b1i9a 0.15s linear 0s 3;
97
+ .confirmation__shake_qz435 {
98
+ animation: confirmation__shake_qz435 0.15s linear 0s 3;
95
99
  }
@@ -14,7 +14,7 @@ function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'defau
14
14
  var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
15
15
  var cn__default = /*#__PURE__*/_interopDefaultLegacy(cn);
16
16
 
17
- var styles = {"component":"confirmation__component_6ndzw","hasError":"confirmation__hasError_6ndzw","getCodeButton":"confirmation__getCodeButton_6ndzw","info":"confirmation__info_6ndzw","customContent":"confirmation__customContent_6ndzw","loaderWrap":"confirmation__loaderWrap_6ndzw","loader":"confirmation__loader_6ndzw","center":"confirmation__center_6ndzw","timePassed":"confirmation__timePassed_6ndzw","noAttemptsLeftMessage":"confirmation__noAttemptsLeftMessage_6ndzw"};
17
+ var styles = {"component":"confirmation__component_16vm7","hasError":"confirmation__hasError_16vm7","getCodeButton":"confirmation__getCodeButton_16vm7","info":"confirmation__info_16vm7","customContent":"confirmation__customContent_16vm7","loaderWrap":"confirmation__loaderWrap_16vm7","loader":"confirmation__loader_16vm7","center":"confirmation__center_16vm7","timePassed":"confirmation__timePassed_16vm7","noAttemptsLeftMessage":"confirmation__noAttemptsLeftMessage_16vm7"};
18
18
  require('./index.css')
19
19
 
20
20
  /**
@@ -1,4 +1,4 @@
1
- /* hash: 6ndzw */
1
+ /* hash: 1il47 */
2
2
  :root {
3
3
  --color-light-text-secondary: #546272;
4
4
  }
@@ -34,7 +34,7 @@
34
34
 
35
35
  /* input */
36
36
  }
37
- .confirmation__component_6ndzw {
37
+ .confirmation__component_16vm7 {
38
38
  font-size: var(--confirmation-text-font-size);
39
39
  line-height: var(--confirmation-text-line-height);
40
40
  font-weight: var(--confirmation-text-font-weight);
@@ -47,39 +47,39 @@
47
47
  margin-top: var(--gap-3xl);
48
48
  color: var(--confirmation-text-color);
49
49
  }
50
- .confirmation__hasError_6ndzw .confirmation__getCodeButton_6ndzw {
50
+ .confirmation__hasError_16vm7 .confirmation__getCodeButton_16vm7 {
51
51
  margin-top: 0;
52
52
  }
53
- .confirmation__hasError_6ndzw .confirmation__info_6ndzw {
53
+ .confirmation__hasError_16vm7 .confirmation__info_16vm7 {
54
54
  margin-top: 0;
55
55
  }
56
- .confirmation__hasError_6ndzw .confirmation__customContent_6ndzw {
56
+ .confirmation__hasError_16vm7 .confirmation__customContent_16vm7 {
57
57
  margin-bottom: var(--gap-2xl);
58
58
  }
59
- .confirmation__info_6ndzw {
59
+ .confirmation__info_16vm7 {
60
60
  margin: var(--gap-2xs) 0;
61
61
  }
62
- .confirmation__loaderWrap_6ndzw {
62
+ .confirmation__loaderWrap_16vm7 {
63
63
  display: flex;
64
64
  align-items: center;
65
65
  margin-bottom: var(--gap-xs);
66
66
  }
67
- .confirmation__loader_6ndzw {
67
+ .confirmation__loader_16vm7 {
68
68
  margin-right: var(--gap-xs);
69
69
  }
70
- .confirmation__center_6ndzw {
70
+ .confirmation__center_16vm7 {
71
71
  align-items: center
72
72
  }
73
- .confirmation__center_6ndzw .confirmation__loaderWrap_6ndzw {
73
+ .confirmation__center_16vm7 .confirmation__loaderWrap_16vm7 {
74
74
  justify-content: center;
75
75
  }
76
- .confirmation__timePassed_6ndzw {
76
+ .confirmation__timePassed_16vm7 {
77
77
  display: flex;
78
78
  min-width: 3em;
79
79
  }
80
- .confirmation__getCodeButton_6ndzw {
80
+ .confirmation__getCodeButton_16vm7 {
81
81
  margin-top: var(--gap-2xl);
82
82
  }
83
- .confirmation__noAttemptsLeftMessage_6ndzw {
83
+ .confirmation__noAttemptsLeftMessage_16vm7 {
84
84
  margin: var(--gap-2xs) 0 var(--gap-xs);
85
85
  }
@@ -8,7 +8,7 @@ function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'defau
8
8
 
9
9
  var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
10
10
 
11
- var styles = {"circle":"confirmation__circle_4r9p5"};
11
+ var styles = {"circle":"confirmation__circle_1o76t"};
12
12
  require('./index.css')
13
13
 
14
14
  var SIZE = 16;
@@ -1,4 +1,4 @@
1
- /* hash: 4r9p5 */
1
+ /* hash: ajx5l */
2
2
  :root {
3
3
  --color-light-graphic-tertiary: #b6bcc3;
4
4
  }
@@ -19,7 +19,7 @@
19
19
 
20
20
  /* input */
21
21
  }
22
- .confirmation__circle_4r9p5 {
22
+ .confirmation__circle_1o76t {
23
23
  fill: transparent;
24
24
  stroke: var(--color-light-graphic-tertiary);
25
25
  stroke-width: 2px;
@@ -15,7 +15,7 @@ function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'defau
15
15
 
16
16
  var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
17
17
 
18
- var styles = {"component":"confirmation__component_3dv1y","title":"confirmation__title_3dv1y","description":"confirmation__description_3dv1y","countdown":"confirmation__countdown_3dv1y","loader":"confirmation__loader_3dv1y","timePassed":"confirmation__timePassed_3dv1y","getCodeButton":"confirmation__getCodeButton_3dv1y","alertIcon":"confirmation__alertIcon_3dv1y"};
18
+ var styles = {"component":"confirmation__component_370bh","title":"confirmation__title_370bh","description":"confirmation__description_370bh","countdown":"confirmation__countdown_370bh","loader":"confirmation__loader_370bh","timePassed":"confirmation__timePassed_370bh","getCodeButton":"confirmation__getCodeButton_370bh","alertIcon":"confirmation__alertIcon_370bh"};
19
19
  require('./index.css')
20
20
 
21
21
  var Overlimit = function (_a) {
@@ -1,4 +1,4 @@
1
- /* hash: 3dv1y */
1
+ /* hash: evxzn */
2
2
  :root {
3
3
  --color-static-status-red: #d91d0b;
4
4
  }
@@ -45,12 +45,12 @@
45
45
 
46
46
  /* input */
47
47
  }
48
- .confirmation__component_3dv1y {
48
+ .confirmation__component_370bh {
49
49
  display: flex;
50
50
  flex-direction: column;
51
51
  align-items: center;
52
52
  }
53
- .confirmation__title_3dv1y {
53
+ .confirmation__title_370bh {
54
54
  font-size: var(--confirmation-title-font-size);
55
55
  line-height: var(--confirmation-title-line-height);
56
56
  font-weight: var(--confirmation-title-font-weight);
@@ -60,30 +60,30 @@
60
60
 
61
61
  margin-bottom: var(--gap-3xl);
62
62
  }
63
- .confirmation__description_3dv1y {
63
+ .confirmation__description_370bh {
64
64
  font-size: var(--confirmation-text-font-size);
65
65
  line-height: var(--confirmation-text-line-height);
66
66
  font-weight: var(--confirmation-text-font-weight);
67
67
  font-family: var(--confirmation-text-font-family);
68
68
  color: var(--confirmation-text-color);
69
69
  }
70
- .confirmation__countdown_3dv1y {
70
+ .confirmation__countdown_370bh {
71
71
  display: flex;
72
72
  align-items: center;
73
73
  justify-content: center;
74
74
  margin-top: var(--gap-2xs);
75
75
  }
76
- .confirmation__loader_3dv1y {
76
+ .confirmation__loader_370bh {
77
77
  margin-right: var(--gap-xs);
78
78
  }
79
- .confirmation__timePassed_3dv1y {
79
+ .confirmation__timePassed_370bh {
80
80
  display: flex;
81
81
  min-width: 3em;
82
82
  }
83
- .confirmation__getCodeButton_3dv1y {
83
+ .confirmation__getCodeButton_370bh {
84
84
  margin-top: var(--gap-2xl);
85
85
  }
86
- .confirmation__alertIcon_3dv1y {
86
+ .confirmation__alertIcon_370bh {
87
87
  text-align: center;
88
88
  margin-bottom: var(--gap-xl);
89
89
  color: var(--color-static-status-red);
@@ -19,7 +19,7 @@ function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'defau
19
19
  var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
20
20
  var cn__default = /*#__PURE__*/_interopDefaultLegacy(cn);
21
21
 
22
- var styles = {"component":"confirmation__component_1nv3s","countdown":"confirmation__countdown_1nv3s","hidden":"confirmation__hidden_1nv3s","header":"confirmation__header_1nv3s","inputContainer":"confirmation__inputContainer_1nv3s","smsComeLinkWrap":"confirmation__smsComeLinkWrap_1nv3s","smsComeLink":"confirmation__smsComeLink_1nv3s","error":"confirmation__error_1nv3s","loaderWrap":"confirmation__loaderWrap_1nv3s","loaderText":"confirmation__loaderText_1nv3s","center":"confirmation__center_1nv3s","codeInput":"confirmation__codeInput_1nv3s"};
22
+ var styles = {"component":"confirmation__component_1q5is","countdown":"confirmation__countdown_1q5is","hidden":"confirmation__hidden_1q5is","header":"confirmation__header_1q5is","inputContainer":"confirmation__inputContainer_1q5is","smsComeLinkWrap":"confirmation__smsComeLinkWrap_1q5is","smsComeLink":"confirmation__smsComeLink_1q5is","error":"confirmation__error_1q5is","loaderWrap":"confirmation__loaderWrap_1q5is","loaderText":"confirmation__loaderText_1q5is","center":"confirmation__center_1q5is","codeInput":"confirmation__codeInput_1q5is"};
23
23
  require('./index.css')
24
24
 
25
25
  var SignConfirmation = function (_a) {
@@ -48,7 +48,7 @@ var SignConfirmation = function (_a) {
48
48
  typeof title === 'string' ? React__default['default'].createElement("span", { className: styles.header }, title) : title,
49
49
  React__default['default'].createElement("div", { className: styles.inputContainer },
50
50
  React__default['default'].createElement(components_codeInput_component.CodeInput, { processing: processing, error: error, value: inputValue, ref: inputRef, slotsCount: requiredCharAmount, className: styles.codeInput, alignContent: alignContent, handleChange: handleInputChange, handleInputKeyDown: handleInputKeyDown }),
51
- displayedError && React__default['default'].createElement("div", { className: styles.error }, displayedError)),
51
+ displayedError && (React__default['default'].createElement("div", { className: styles.error, role: 'alert' }, displayedError))),
52
52
  processing && (React__default['default'].createElement("div", { className: styles.loaderWrap },
53
53
  React__default['default'].createElement(coreComponentsLoader.Loader, null),
54
54
  React__default['default'].createElement("span", { className: styles.loaderText }, codeChecking ? codeCheckingText : codeSendingText))),
@@ -1,4 +1,4 @@
1
- /* hash: 1nv3s */
1
+ /* hash: 19hj1 */
2
2
  :root {
3
3
  --color-light-text-negative: #d91d0b;
4
4
  --color-light-text-primary: #0b1f35;
@@ -43,20 +43,20 @@
43
43
 
44
44
  /* input */
45
45
  }
46
- .confirmation__component_1nv3s {
46
+ .confirmation__component_1q5is {
47
47
  display: flex;
48
48
  flex-direction: column;
49
49
  }
50
- .confirmation__countdown_1nv3s {
50
+ .confirmation__countdown_1q5is {
51
51
  max-height: 300px;
52
52
  overflow: hidden;
53
53
  transition: max-height 0.15s ease;
54
54
  }
55
- .confirmation__hidden_1nv3s {
55
+ .confirmation__hidden_1q5is {
56
56
  opacity: 0;
57
57
  max-height: 0;
58
58
  }
59
- .confirmation__header_1nv3s {
59
+ .confirmation__header_1q5is {
60
60
  font-size: var(--confirmation-title-font-size);
61
61
  line-height: var(--confirmation-title-line-height);
62
62
  font-weight: var(--confirmation-title-font-weight);
@@ -67,19 +67,19 @@
67
67
  margin-bottom: var(--gap-3xl);
68
68
  color: var(--confirmation-title-color);
69
69
  }
70
- .confirmation__inputContainer_1nv3s {
70
+ .confirmation__inputContainer_1q5is {
71
71
  display: flex;
72
72
  flex-direction: column;
73
73
  }
74
- .confirmation__smsComeLinkWrap_1nv3s {
74
+ .confirmation__smsComeLinkWrap_1q5is {
75
75
  margin-top: var(--gap-l);
76
76
  }
77
- .confirmation__smsComeLink_1nv3s {
77
+ .confirmation__smsComeLink_1q5is {
78
78
  font-size: 14px;
79
79
  line-height: 20px;
80
80
  font-weight: 400;
81
81
  }
82
- .confirmation__error_1nv3s {
82
+ .confirmation__error_1q5is {
83
83
  font-size: 14px;
84
84
  line-height: 20px;
85
85
  font-weight: 400;
@@ -87,12 +87,12 @@
87
87
  margin-top: var(--gap-xs);
88
88
  color: var(--confirmation-error-color);
89
89
  }
90
- .confirmation__loaderWrap_1nv3s {
90
+ .confirmation__loaderWrap_1q5is {
91
91
  display: flex;
92
92
  align-items: center;
93
93
  margin: var(--gap-3xl) 0 var(--gap-xs);
94
94
  }
95
- .confirmation__loaderText_1nv3s {
95
+ .confirmation__loaderText_1q5is {
96
96
  font-size: var(--confirmation-text-font-size);
97
97
  line-height: var(--confirmation-text-line-height);
98
98
  font-weight: var(--confirmation-text-font-weight);
@@ -102,7 +102,7 @@
102
102
  margin-left: var(--gap-s);
103
103
  color: var(--confirmation-text-color);
104
104
  }
105
- .confirmation__center_1nv3s .confirmation__codeInput_1nv3s,
106
- .confirmation__center_1nv3s .confirmation__loaderWrap_1nv3s {
105
+ .confirmation__center_1q5is .confirmation__codeInput_1q5is,
106
+ .confirmation__center_1q5is .confirmation__loaderWrap_1q5is {
107
107
  justify-content: center;
108
108
  }
@@ -84,7 +84,7 @@ var Confirmation = React.forwardRef(function (_a, ref) {
84
84
  return (React__default['default'].createElement("div", { className: cn__default['default'](styles__default['default'].component, styles__default['default'][alignContent], className), ref: ref, "data-test-id": dataTestId },
85
85
  shouldShowSignComponent && (React__default['default'].createElement(components_signConfirmation_component.SignConfirmation, { codeChecking: codeChecking, codeSending: codeSending, smsHintVisible: !codeChecking, additionalContent: additionalContent, requiredCharAmount: requiredCharAmount, hasSmsCountdown: hasSmsCountdown, countdownDuration: countdownDuration, phone: phone, code: code, hasPhoneMask: hasPhoneMask, errorText: nonFatalError || '', error: error, title: signTitle, buttonRetryText: buttonRetryText, inputRef: inputRef, codeCheckingText: codeCheckingText, codeSendingText: codeSendingText, alignContent: alignContent, noAttemptsLeftMessage: noAttemptsLeftMessage, countdownContent: countdownContent, onInputFinished: onInputFinished, onInputChange: onInputChange, onSmsRetryClick: handleSmsRetryClick, onCountdownFinished: handleCountdownFinished, onSmsHintLinkClick: handleSmsHintLinkClick })),
86
86
  shouldShowOverlimitError && (React__default['default'].createElement(components_overlimit_component.Overlimit, { duration: overlimitCountdownDuration, title: overlimitTitle, text: overlimitText, hasFatalError: errorOverlimitIsFatal, buttonRetryText: buttonRetryText, onOverlimitRepeatSms: handleOverlimitSmsRetryClick, onOverlimitCountdownFinished: handleOverlimitCountdownFinished })),
87
- shouldShowFatalError && (React__default['default'].createElement("div", { className: styles__default['default'].error },
87
+ shouldShowFatalError && (React__default['default'].createElement("div", { className: styles__default['default'].error, role: 'alert' },
88
88
  React__default['default'].createElement("span", { className: styles__default['default'].errorHeader }, errorTitle),
89
89
  React__default['default'].createElement("span", { className: styles__default['default'].errorText }, errorText),
90
90
  React__default['default'].createElement(coreComponentsButton.Button, { size: 'xs', view: 'secondary', onClick: handleErrorSmsRetryClick }, buttonErrorText))),
@@ -150,6 +150,7 @@ var CodeInput = React.forwardRef(function (_a, ref) {
150
150
  }, [value.length, prevValue.length, slotsCount, focus]);
151
151
  return (React__default['default'].createElement("div", { className: cn__default['default'](styles__default['default'].component, className, (_b = {},
152
152
  _b[styles__default['default'].shake] = Boolean(error),
153
+ _b[styles__default['default'].compact] = slotsCount > 6,
153
154
  _b)) }, new Array(slotsCount).fill('').map(function (_, index) { return (React__default['default'].createElement(Input, { value: value, index: index, error: error, processing: processing, slotsCount: slotsCount, alignContent: alignContent, handleChange: handleChange, handleInputKeyDown: handleInputKeyDown, setRef: setRef, focus: focus,
154
155
  // eslint-disable-next-line react/no-array-index-key
155
156
  key: index })); })));
@@ -72,6 +72,10 @@
72
72
  color: var(--color-light-text-tertiary);
73
73
  opacity: 1;
74
74
  }
75
+ .compact .input {
76
+ width: 28px;
77
+ height: 40px;
78
+ }
75
79
  @keyframes shake {
76
80
  0% {
77
81
  transform: translateX(0);
@@ -50,7 +50,7 @@ var SignConfirmation = function (_a) {
50
50
  typeof title === 'string' ? React__default['default'].createElement("span", { className: styles__default['default'].header }, title) : title,
51
51
  React__default['default'].createElement("div", { className: styles__default['default'].inputContainer },
52
52
  React__default['default'].createElement(components_codeInput_component.CodeInput, { processing: processing, error: error, value: inputValue, ref: inputRef, slotsCount: requiredCharAmount, className: styles__default['default'].codeInput, alignContent: alignContent, handleChange: handleInputChange, handleInputKeyDown: handleInputKeyDown }),
53
- displayedError && React__default['default'].createElement("div", { className: styles__default['default'].error }, displayedError)),
53
+ displayedError && (React__default['default'].createElement("div", { className: styles__default['default'].error, role: 'alert' }, displayedError))),
54
54
  processing && (React__default['default'].createElement("div", { className: styles__default['default'].loaderWrap },
55
55
  React__default['default'].createElement(coreComponentsLoader.Loader, null),
56
56
  React__default['default'].createElement("span", { className: styles__default['default'].loaderText }, codeChecking ? codeCheckingText : codeSendingText))),
@@ -13,7 +13,7 @@ import { SignConfirmation } from './components/sign-confirmation/component.js';
13
13
  import '@alfalab/icons-glyph';
14
14
  import { Overlimit } from './components/overlimit/component.js';
15
15
 
16
- var styles = {"component":"confirmation__component_4oaka","error":"confirmation__error_4oaka","errorHeader":"confirmation__errorHeader_4oaka","errorText":"confirmation__errorText_4oaka","phoneHintWrap":"confirmation__phoneHintWrap_4oaka","phoneHintText":"confirmation__phoneHintText_4oaka","phonesWrap":"confirmation__phonesWrap_4oaka","phoneWrap":"confirmation__phoneWrap_4oaka","phoneDescription":"confirmation__phoneDescription_4oaka","center":"confirmation__center_4oaka"};
16
+ var styles = {"component":"confirmation__component_h92d1","error":"confirmation__error_h92d1","errorHeader":"confirmation__errorHeader_h92d1","errorText":"confirmation__errorText_h92d1","phoneHintWrap":"confirmation__phoneHintWrap_h92d1","phoneHintText":"confirmation__phoneHintText_h92d1","phonesWrap":"confirmation__phonesWrap_h92d1","phoneWrap":"confirmation__phoneWrap_h92d1","phoneDescription":"confirmation__phoneDescription_h92d1","center":"confirmation__center_h92d1"};
17
17
  require('./index.css')
18
18
 
19
19
  var Confirmation = forwardRef(function (_a, ref) {
@@ -71,7 +71,7 @@ var Confirmation = forwardRef(function (_a, ref) {
71
71
  return (React.createElement("div", { className: cn(styles.component, styles[alignContent], className), ref: ref, "data-test-id": dataTestId },
72
72
  shouldShowSignComponent && (React.createElement(SignConfirmation, { codeChecking: codeChecking, codeSending: codeSending, smsHintVisible: !codeChecking, additionalContent: additionalContent, requiredCharAmount: requiredCharAmount, hasSmsCountdown: hasSmsCountdown, countdownDuration: countdownDuration, phone: phone, code: code, hasPhoneMask: hasPhoneMask, errorText: nonFatalError || '', error: error, title: signTitle, buttonRetryText: buttonRetryText, inputRef: inputRef, codeCheckingText: codeCheckingText, codeSendingText: codeSendingText, alignContent: alignContent, noAttemptsLeftMessage: noAttemptsLeftMessage, countdownContent: countdownContent, onInputFinished: onInputFinished, onInputChange: onInputChange, onSmsRetryClick: handleSmsRetryClick, onCountdownFinished: handleCountdownFinished, onSmsHintLinkClick: handleSmsHintLinkClick })),
73
73
  shouldShowOverlimitError && (React.createElement(Overlimit, { duration: overlimitCountdownDuration, title: overlimitTitle, text: overlimitText, hasFatalError: errorOverlimitIsFatal, buttonRetryText: buttonRetryText, onOverlimitRepeatSms: handleOverlimitSmsRetryClick, onOverlimitCountdownFinished: handleOverlimitCountdownFinished })),
74
- shouldShowFatalError && (React.createElement("div", { className: styles.error },
74
+ shouldShowFatalError && (React.createElement("div", { className: styles.error, role: 'alert' },
75
75
  React.createElement("span", { className: styles.errorHeader }, errorTitle),
76
76
  React.createElement("span", { className: styles.errorText }, errorText),
77
77
  React.createElement(Button, { size: 'xs', view: 'secondary', onClick: handleErrorSmsRetryClick }, buttonErrorText))),
@@ -26,7 +26,7 @@ function __spreadArrays() {
26
26
  return r;
27
27
  }
28
28
 
29
- var styles = {"component":"confirmation__component_b1i9a","input":"confirmation__input_b1i9a","hasError":"confirmation__hasError_b1i9a","center":"confirmation__center_b1i9a","disabled":"confirmation__disabled_b1i9a","shake":"confirmation__shake_b1i9a"};
29
+ var styles = {"component":"confirmation__component_qz435","input":"confirmation__input_qz435","hasError":"confirmation__hasError_qz435","center":"confirmation__center_qz435","disabled":"confirmation__disabled_qz435","compact":"confirmation__compact_qz435","shake":"confirmation__shake_qz435"};
30
30
  require('./index.css')
31
31
 
32
32
  var Input = function (_a) {
@@ -142,6 +142,7 @@ var CodeInput = forwardRef(function (_a, ref) {
142
142
  }, [value.length, prevValue.length, slotsCount, focus]);
143
143
  return (React.createElement("div", { className: cn(styles.component, className, (_b = {},
144
144
  _b[styles.shake] = Boolean(error),
145
+ _b[styles.compact] = slotsCount > 6,
145
146
  _b)) }, new Array(slotsCount).fill('').map(function (_, index) { return (React.createElement(Input, { value: value, index: index, error: error, processing: processing, slotsCount: slotsCount, alignContent: alignContent, handleChange: handleChange, handleInputKeyDown: handleInputKeyDown, setRef: setRef, focus: focus,
146
147
  // eslint-disable-next-line react/no-array-index-key
147
148
  key: index })); })));
@@ -1,4 +1,4 @@
1
- /* hash: b1i9a */
1
+ /* hash: y4w3u */
2
2
  :root {
3
3
  --color-light-bg-negative-muted: #feebea;
4
4
  --color-light-bg-secondary: #f3f4f5;
@@ -41,10 +41,10 @@
41
41
  --confirmation-input-bg-color: var(--color-light-bg-secondary);
42
42
  --confirmation-input-error-bg-color: var(--color-light-bg-negative-muted);
43
43
  }
44
- .confirmation__component_b1i9a {
44
+ .confirmation__component_qz435 {
45
45
  display: flex;
46
46
  }
47
- .confirmation__input_b1i9a {
47
+ .confirmation__input_qz435 {
48
48
  flex-shrink: 0;
49
49
  width: 36px;
50
50
  height: 48px;
@@ -61,19 +61,23 @@
61
61
  font-weight: var(--confirmation-input-font-weight);
62
62
  font-family: var(--confirmation-input-font-family)
63
63
  }
64
- .confirmation__input_b1i9a.confirmation__hasError_b1i9a {
64
+ .confirmation__input_qz435.confirmation__hasError_qz435 {
65
65
  color: var(--confirmation-error-color);
66
66
  caret-color: var(--confirmation-input-text-color);
67
67
  background-color: var(--confirmation-input-error-bg-color);
68
68
  }
69
- .confirmation__input_b1i9a.confirmation__center_b1i9a {
69
+ .confirmation__input_qz435.confirmation__center_qz435 {
70
70
  margin: 0 var(--gap-2xs);
71
71
  }
72
- .confirmation__input_b1i9a.confirmation__disabled_b1i9a {
72
+ .confirmation__input_qz435.confirmation__disabled_qz435 {
73
73
  color: var(--color-light-text-tertiary);
74
74
  opacity: 1;
75
75
  }
76
- @keyframes confirmation__shake_b1i9a {
76
+ .confirmation__compact_qz435 .confirmation__input_qz435 {
77
+ width: 28px;
78
+ height: 40px;
79
+ }
80
+ @keyframes confirmation__shake_qz435 {
77
81
  0% {
78
82
  transform: translateX(0);
79
83
  }
@@ -90,6 +94,6 @@
90
94
  transform: translateX(0);
91
95
  }
92
96
  }
93
- .confirmation__shake_b1i9a {
94
- animation: confirmation__shake_b1i9a 0.15s linear 0s 3;
97
+ .confirmation__shake_qz435 {
98
+ animation: confirmation__shake_qz435 0.15s linear 0s 3;
95
99
  }
@@ -5,7 +5,7 @@ import { phoneNumber } from '@alfalab/utils';
5
5
  import { usePrevious } from '@alfalab/hooks';
6
6
  import { CountdownLoader } from '../countdown-loader/component.js';
7
7
 
8
- var styles = {"component":"confirmation__component_6ndzw","hasError":"confirmation__hasError_6ndzw","getCodeButton":"confirmation__getCodeButton_6ndzw","info":"confirmation__info_6ndzw","customContent":"confirmation__customContent_6ndzw","loaderWrap":"confirmation__loaderWrap_6ndzw","loader":"confirmation__loader_6ndzw","center":"confirmation__center_6ndzw","timePassed":"confirmation__timePassed_6ndzw","noAttemptsLeftMessage":"confirmation__noAttemptsLeftMessage_6ndzw"};
8
+ var styles = {"component":"confirmation__component_16vm7","hasError":"confirmation__hasError_16vm7","getCodeButton":"confirmation__getCodeButton_16vm7","info":"confirmation__info_16vm7","customContent":"confirmation__customContent_16vm7","loaderWrap":"confirmation__loaderWrap_16vm7","loader":"confirmation__loader_16vm7","center":"confirmation__center_16vm7","timePassed":"confirmation__timePassed_16vm7","noAttemptsLeftMessage":"confirmation__noAttemptsLeftMessage_16vm7"};
9
9
  require('./index.css')
10
10
 
11
11
  /**