@alfalab/core-components-confirmation 13.9.12 → 13.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/base-confirmation/component.js +5 -2
- package/components/base-confirmation/index.css +2 -2
- package/components/countdown-loader/component.js +1 -1
- package/components/countdown-loader/index.css +2 -2
- package/components/header/component.js +1 -1
- package/components/header/index.css +4 -4
- package/components/index.js +2 -0
- package/components/screens/fatal-error/component.js +1 -1
- package/components/screens/fatal-error/index.css +7 -7
- package/components/screens/hint/component.js +10 -10
- package/components/screens/hint/index.css +13 -13
- package/components/screens/index.d.ts +1 -0
- package/components/screens/index.js +2 -0
- package/components/screens/initial/component.js +8 -5
- package/components/screens/initial/countdown-section.js +1 -1
- package/components/screens/initial/index.css +25 -19
- package/components/screens/temp-block/component.js +2 -2
- package/components/screens/temp-block/index.css +14 -8
- package/components/screens/temp-block-over/component.d.ts +9 -0
- package/components/screens/temp-block-over/component.js +37 -0
- package/components/screens/temp-block-over/index.css +59 -0
- package/components/screens/temp-block-over/index.d.ts +1 -0
- package/components/screens/temp-block-over/index.js +9 -0
- package/{countdown-section-b7271098.js → countdown-section-66246bfb.js} +7 -4
- package/cssm/components/base-confirmation/component.js +4 -1
- package/cssm/components/index.js +2 -0
- package/cssm/components/screens/hint/component.js +9 -9
- package/cssm/components/screens/index.d.ts +1 -0
- package/cssm/components/screens/index.js +2 -0
- package/cssm/components/screens/initial/component.js +7 -4
- package/cssm/components/screens/initial/countdown-section.js +6 -3
- package/cssm/components/screens/initial/index.module.css +7 -0
- package/cssm/components/screens/temp-block/component.js +1 -1
- package/cssm/components/screens/temp-block/index.module.css +7 -0
- package/cssm/components/screens/temp-block-over/component.d.ts +9 -0
- package/cssm/components/screens/temp-block-over/component.js +36 -0
- package/cssm/components/screens/temp-block-over/index.d.ts +1 -0
- package/cssm/components/screens/temp-block-over/index.js +9 -0
- package/cssm/components/screens/temp-block-over/index.module.css +58 -0
- package/cssm/shared/index.js +2 -0
- package/cssm/types.d.ts +13 -2
- package/cssm/types.js +17 -9
- package/esm/components/base-confirmation/component.js +5 -2
- package/esm/components/base-confirmation/index.css +2 -2
- package/esm/components/countdown-loader/component.js +1 -1
- package/esm/components/countdown-loader/index.css +2 -2
- package/esm/components/header/component.js +1 -1
- package/esm/components/header/index.css +4 -4
- package/esm/components/index.js +1 -0
- package/esm/components/screens/fatal-error/component.js +1 -1
- package/esm/components/screens/fatal-error/index.css +7 -7
- package/esm/components/screens/hint/component.js +10 -10
- package/esm/components/screens/hint/index.css +13 -13
- package/esm/components/screens/index.d.ts +1 -0
- package/esm/components/screens/index.js +1 -0
- package/esm/components/screens/initial/component.js +8 -5
- package/esm/components/screens/initial/countdown-section.js +1 -1
- package/esm/components/screens/initial/index.css +25 -19
- package/esm/components/screens/temp-block/component.js +2 -2
- package/esm/components/screens/temp-block/index.css +14 -8
- package/esm/components/screens/temp-block-over/component.d.ts +9 -0
- package/esm/components/screens/temp-block-over/component.js +28 -0
- package/esm/components/screens/temp-block-over/index.css +59 -0
- package/esm/components/screens/temp-block-over/index.d.ts +1 -0
- package/esm/components/screens/temp-block-over/index.js +1 -0
- package/esm/{countdown-section-a99ec7db.js → countdown-section-b11f4c6f.js} +8 -5
- package/esm/mobile/component.mobile.js +1 -1
- package/esm/mobile/mobile.css +2 -2
- package/esm/shared/index.js +1 -0
- package/esm/types.d.ts +13 -2
- package/esm/types.js +17 -9
- package/mobile/component.mobile.js +1 -1
- package/mobile/mobile.css +2 -2
- package/modern/components/base-confirmation/component.js +5 -2
- package/modern/components/base-confirmation/index.css +2 -2
- package/modern/components/countdown-loader/component.js +1 -1
- package/modern/components/countdown-loader/index.css +2 -2
- package/modern/components/header/component.js +1 -1
- package/modern/components/header/index.css +4 -4
- package/modern/components/index.js +1 -0
- package/modern/components/screens/fatal-error/component.js +1 -1
- package/modern/components/screens/fatal-error/index.css +7 -7
- package/modern/components/screens/hint/component.js +10 -10
- package/modern/components/screens/hint/index.css +13 -13
- package/modern/components/screens/index.d.ts +1 -0
- package/modern/components/screens/index.js +1 -0
- package/modern/components/screens/initial/component.js +8 -5
- package/modern/components/screens/initial/countdown-section.js +1 -1
- package/modern/components/screens/initial/index.css +25 -19
- package/modern/components/screens/temp-block/component.js +2 -2
- package/modern/components/screens/temp-block/index.css +14 -8
- package/modern/components/screens/temp-block-over/component.d.ts +9 -0
- package/modern/components/screens/temp-block-over/component.js +26 -0
- package/modern/components/screens/temp-block-over/index.css +59 -0
- package/modern/components/screens/temp-block-over/index.d.ts +1 -0
- package/modern/components/screens/temp-block-over/index.js +1 -0
- package/modern/{countdown-section-7113cf49.js → countdown-section-5721eff6.js} +8 -5
- package/modern/mobile/component.mobile.js +1 -1
- package/modern/mobile/mobile.css +2 -2
- package/modern/shared/index.js +1 -0
- package/modern/types.d.ts +13 -2
- package/modern/types.js +17 -9
- package/moderncssm/components/base-confirmation/component.js +4 -1
- package/moderncssm/components/index.js +1 -0
- package/moderncssm/components/screens/hint/component.js +9 -9
- package/moderncssm/components/screens/index.d.ts +1 -0
- package/moderncssm/components/screens/index.js +1 -0
- package/moderncssm/components/screens/initial/component.js +7 -4
- package/moderncssm/components/screens/initial/countdown-section.js +7 -4
- package/moderncssm/components/screens/initial/index.module.css +9 -0
- package/moderncssm/components/screens/temp-block/component.js +1 -1
- package/moderncssm/components/screens/temp-block/index.module.css +9 -0
- package/moderncssm/components/screens/temp-block-over/component.d.ts +9 -0
- package/moderncssm/components/screens/temp-block-over/component.js +24 -0
- package/moderncssm/components/screens/temp-block-over/index.d.ts +1 -0
- package/moderncssm/components/screens/temp-block-over/index.js +1 -0
- package/moderncssm/components/screens/temp-block-over/index.module.css +42 -0
- package/moderncssm/shared/index.js +1 -0
- package/moderncssm/types.d.ts +13 -2
- package/moderncssm/types.js +17 -9
- package/package.json +1 -1
- package/shared/index.js +2 -0
- package/src/components/base-confirmation/component.tsx +6 -2
- package/src/components/screens/hint/component.tsx +11 -14
- package/src/components/screens/index.ts +1 -0
- package/src/components/screens/initial/component.tsx +9 -5
- package/src/components/screens/initial/countdown-section.tsx +9 -4
- package/src/components/screens/initial/index.module.css +8 -0
- package/src/components/screens/temp-block/component.tsx +1 -2
- package/src/components/screens/temp-block/index.module.css +8 -0
- package/src/components/screens/temp-block-over/component.tsx +55 -0
- package/src/components/screens/temp-block-over/index.module.css +23 -0
- package/src/components/screens/temp-block-over/index.ts +1 -0
- package/src/types.ts +36 -11
- package/types.d.ts +13 -2
- package/types.js +17 -9
- /package/{countdown-section-b7271098.d.ts → countdown-section-66246bfb.d.ts} +0 -0
- /package/esm/{countdown-section-a99ec7db.d.ts → countdown-section-b11f4c6f.d.ts} +0 -0
- /package/modern/{countdown-section-7113cf49.d.ts → countdown-section-5721eff6.d.ts} +0 -0
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
/* hash: 1cf84 */
|
|
2
|
+
:root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
3
|
+
} /* deprecated */ :root {
|
|
4
|
+
--color-light-text-primary: rgba(3, 3, 6, 0.88);
|
|
5
|
+
--color-light-text-secondary: rgba(4, 4, 19, 0.55); /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
6
|
+
} :root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
7
|
+
} :root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
8
|
+
} :root {
|
|
9
|
+
|
|
10
|
+
/* Hard */
|
|
11
|
+
|
|
12
|
+
/* Up */
|
|
13
|
+
|
|
14
|
+
/* Hard up */
|
|
15
|
+
} :root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
16
|
+
|
|
17
|
+
/* новые значения, используйте их */
|
|
18
|
+
} :root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
19
|
+
--gap-2xl: 32px; /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
20
|
+
|
|
21
|
+
/* новые значения, используйте их */
|
|
22
|
+
|
|
23
|
+
/* no-unit может приводить к проблемам в calc (#1559) */
|
|
24
|
+
/* stylelint-disable-next-line length-zero-no-unit */
|
|
25
|
+
--gap-32: var(--gap-2xl);
|
|
26
|
+
} :root {
|
|
27
|
+
--font-family-system: system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Helvetica,
|
|
28
|
+
sans-serif;
|
|
29
|
+
} /* @deprecated */ /* @deprecated */ /* @deprecated */ /* @deprecated */ /* @deprecated */ :root {
|
|
30
|
+
} /* сбрасывает синюю подсветку при нажатии */ :root {
|
|
31
|
+
/* desktop */
|
|
32
|
+
|
|
33
|
+
/* mobile */
|
|
34
|
+
|
|
35
|
+
/* text */
|
|
36
|
+
--confirmation-text-font-size: 16px;
|
|
37
|
+
--confirmation-text-line-height: 24px;
|
|
38
|
+
--confirmation-text-font-weight: 400;
|
|
39
|
+
--confirmation-text-font-family: var(--font-family-system);
|
|
40
|
+
--confirmation-text-color: var(--color-light-text-primary)
|
|
41
|
+
|
|
42
|
+
/* header */
|
|
43
|
+
} .confirmation__component_1fn9p {
|
|
44
|
+
display: flex;
|
|
45
|
+
flex-direction: column;
|
|
46
|
+
} .confirmation__center_1fn9p {
|
|
47
|
+
align-items: center;
|
|
48
|
+
text-align: center;
|
|
49
|
+
} .confirmation__typographyTheme_1fn9p.confirmation__typographyTheme_1fn9p {
|
|
50
|
+
font-size: var(--confirmation-text-font-size);
|
|
51
|
+
line-height: var(--confirmation-text-line-height);
|
|
52
|
+
font-weight: var(--confirmation-text-font-weight);
|
|
53
|
+
font-family: var(--confirmation-text-font-family);
|
|
54
|
+
color: var(--confirmation-text-color);
|
|
55
|
+
} .confirmation__typographyThemeMobile_1fn9p.confirmation__typographyThemeMobile_1fn9p {
|
|
56
|
+
color: var(--color-light-text-secondary);
|
|
57
|
+
} .confirmation__button_1fn9p.confirmation__button_1fn9p {
|
|
58
|
+
margin-top: var(--gap-32);
|
|
59
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./component";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { TempBlockOver } from './component.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import React, { useContext } from 'react';
|
|
1
|
+
import React, { useContext, Fragment } from 'react';
|
|
2
2
|
import cn from 'classnames';
|
|
3
3
|
import { Button } from '@alfalab/core-components-button/modern';
|
|
4
4
|
import { Spinner } from '@alfalab/core-components-spinner/modern';
|
|
@@ -6,15 +6,15 @@ import { Text } from '@alfalab/core-components-typography/modern';
|
|
|
6
6
|
import { ConfirmationContext } from './context.js';
|
|
7
7
|
import { formatMsAsMinutes } from './utils.js';
|
|
8
8
|
|
|
9
|
-
const styles = {"component":"
|
|
9
|
+
const styles = {"component":"confirmation__component_1v2a0","phone":"confirmation__phone_1v2a0","typographyTheme":"confirmation__typographyTheme_1v2a0","typographyThemeMobile":"confirmation__typographyThemeMobile_1v2a0","compact":"confirmation__compact_1v2a0","loaderWrap":"confirmation__loaderWrap_1v2a0","left":"confirmation__left_1v2a0","center":"confirmation__center_1v2a0","codeInput":"confirmation__codeInput_1v2a0","smsBtn":"confirmation__smsBtn_1v2a0","smsComeLink":"confirmation__smsComeLink_1v2a0","countdownContainer":"confirmation__countdownContainer_1v2a0","countdownMobile":"confirmation__countdownMobile_1v2a0","countdownLoaderMobile":"confirmation__countdownLoaderMobile_1v2a0","timeCounter":"confirmation__timeCounter_1v2a0","getCodeButton":"confirmation__getCodeButton_1v2a0","getCodeButtonMobile":"confirmation__getCodeButtonMobile_1v2a0","containerInput":"confirmation__containerInput_1v2a0"};
|
|
10
10
|
require('./components/screens/initial/index.css')
|
|
11
11
|
|
|
12
12
|
const CountdownSection = ({ codeSendHintVisible, timePassed, processing, mobile, handleSmsRetryClick, }) => {
|
|
13
13
|
const { state, texts, timeLeft, blockSmsRetry, breakpoint, client } = useContext(ConfirmationContext);
|
|
14
|
-
const renderText = (
|
|
14
|
+
const renderText = (content) => (React.createElement(Text, { className: cn(styles.countdownContainer, {
|
|
15
15
|
[styles.countdownMobile]: mobile,
|
|
16
16
|
[styles.typographyTheme]: !mobile,
|
|
17
|
-
}), view: mobile ? 'primary-small' : 'primary-medium', tag: 'div' },
|
|
17
|
+
}), view: mobile ? 'primary-small' : 'primary-medium', tag: 'div' }, content));
|
|
18
18
|
if (codeSendHintVisible)
|
|
19
19
|
return renderText(texts.codeSended);
|
|
20
20
|
if (processing) {
|
|
@@ -30,7 +30,10 @@ const CountdownSection = ({ codeSendHintVisible, timePassed, processing, mobile,
|
|
|
30
30
|
if (timePassed) {
|
|
31
31
|
return (React.createElement(Button, { size: mobile ? 'xs' : 'xxs', view: 'secondary', onClick: handleSmsRetryClick, className: cn(styles.getCodeButton, { [styles.getCodeButtonMobile]: mobile }), breakpoint: breakpoint, client: client }, texts.buttonRetry));
|
|
32
32
|
}
|
|
33
|
-
return renderText(
|
|
33
|
+
return renderText(React.createElement(Fragment, null,
|
|
34
|
+
texts.countdown,
|
|
35
|
+
'\u00A0',
|
|
36
|
+
React.createElement("time", { className: styles.timeCounter }, formatMsAsMinutes(timeLeft))));
|
|
34
37
|
};
|
|
35
38
|
|
|
36
39
|
export { CountdownSection as C, styles as s };
|
|
@@ -2,7 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import cn from 'classnames';
|
|
3
3
|
import { BaseConfirmation } from '../components/base-confirmation/component.js';
|
|
4
4
|
|
|
5
|
-
const styles = {"container":"
|
|
5
|
+
const styles = {"container":"confirmation__container_1lw1g"};
|
|
6
6
|
require('./mobile.css')
|
|
7
7
|
|
|
8
8
|
const ConfirmationMobile = ({ className, ...resProps }) => (React.createElement(BaseConfirmation, { mobile: true, className: cn(className, styles.container), ...resProps }));
|
package/modern/mobile/mobile.css
CHANGED
package/modern/shared/index.js
CHANGED
|
@@ -2,6 +2,7 @@ export { Initial } from '../components/screens/initial/component.js';
|
|
|
2
2
|
export { Hint } from '../components/screens/hint/component.js';
|
|
3
3
|
export { FatalError } from '../components/screens/fatal-error/component.js';
|
|
4
4
|
export { TempBlock } from '../components/screens/temp-block/component.js';
|
|
5
|
+
export { TempBlockOver } from '../components/screens/temp-block-over/component.js';
|
|
5
6
|
export { CountdownLoader } from '../components/countdown-loader/component.js';
|
|
6
7
|
export { ConfirmationContext } from '../context.js';
|
|
7
8
|
export { defaultTexts } from '../types.js';
|
package/modern/types.d.ts
CHANGED
|
@@ -117,6 +117,8 @@ type ConfirmationTexts = {
|
|
|
117
117
|
*/
|
|
118
118
|
title?: ReactNode;
|
|
119
119
|
codeError?: string;
|
|
120
|
+
codeErrorExpired?: string;
|
|
121
|
+
codeErrorExpiredEnded?: string;
|
|
120
122
|
codeChecking?: string;
|
|
121
123
|
codeSending?: string;
|
|
122
124
|
codeSended?: string;
|
|
@@ -127,6 +129,9 @@ type ConfirmationTexts = {
|
|
|
127
129
|
/**
|
|
128
130
|
* Экран HINT
|
|
129
131
|
*/
|
|
132
|
+
hintTitle?: string;
|
|
133
|
+
hintDescription?: string;
|
|
134
|
+
hintNotification?: string;
|
|
130
135
|
hintButton?: string;
|
|
131
136
|
domesticPhone?: string;
|
|
132
137
|
internationalPhone?: string;
|
|
@@ -141,9 +146,15 @@ type ConfirmationTexts = {
|
|
|
141
146
|
*/
|
|
142
147
|
tempBlockTitle?: ReactNode;
|
|
143
148
|
tempBlockDescription?: ReactNode;
|
|
149
|
+
/**
|
|
150
|
+
* Экран TEMP_BLOCK_OVER
|
|
151
|
+
*/
|
|
152
|
+
tempBlockOverTitle?: ReactNode;
|
|
153
|
+
tempBlockOverDescription?: ReactNode;
|
|
154
|
+
tempBlockOverButton?: string;
|
|
144
155
|
};
|
|
145
|
-
type ConfirmationScreen = 'INITIAL' | 'HINT' | 'FATAL_ERROR' | 'TEMP_BLOCK';
|
|
146
|
-
type ConfirmationState = 'INITIAL' | 'CODE_CHECKING' | 'CODE_SENDING' | 'CODE_ERROR';
|
|
156
|
+
type ConfirmationScreen = 'INITIAL' | 'HINT' | 'FATAL_ERROR' | 'TEMP_BLOCK' | 'TEMP_BLOCK_OVER';
|
|
157
|
+
type ConfirmationState = 'INITIAL' | 'CODE_CHECKING' | 'CODE_SENDING' | 'CODE_ERROR' | 'CODE_EXPIRED' | 'CODE_EXPIRED_ENDED';
|
|
147
158
|
type ScreensMap = {
|
|
148
159
|
[key: string]: ComponentType;
|
|
149
160
|
};
|
package/modern/types.js
CHANGED
|
@@ -1,19 +1,27 @@
|
|
|
1
1
|
const defaultTexts = {
|
|
2
|
-
title: 'Введите код из\xa0
|
|
3
|
-
codeError: 'Код
|
|
2
|
+
title: 'Введите код из\xa0уведомления',
|
|
3
|
+
codeError: 'Код не подходит, проверьте его',
|
|
4
|
+
codeErrorExpired: 'Код устарел, запросите новый',
|
|
5
|
+
codeErrorExpiredEnded: 'Код устарел',
|
|
4
6
|
codeChecking: '',
|
|
5
7
|
codeSending: '',
|
|
6
|
-
buttonRetry: 'Запросить код
|
|
7
|
-
|
|
8
|
+
buttonRetry: 'Запросить код',
|
|
9
|
+
hintTitle: 'Не\xa0приходит код?',
|
|
10
|
+
hintDescription: 'Если\xa0сменили номер, позвоните нам или обратитесь в\xa0любой офис банка.',
|
|
11
|
+
hintNotification: 'Если номер не\xa0меняли, попробуйте запросить код позже — возможно, перегружен сервис отправки уведомлений.',
|
|
12
|
+
linkToHint: 'Не\xa0приходит код?',
|
|
8
13
|
hintButton: 'Вернуться к\xa0вводу кода',
|
|
9
14
|
noAttemptsLeft: 'Не\xa0осталось попыток запроса кода',
|
|
10
15
|
fatalErrorTitle: 'Ввести код больше нельзя',
|
|
11
|
-
fatalErrorDescription: '
|
|
16
|
+
fatalErrorDescription: 'Мы ограничили следующие попытки ввода, потому\xa0что код был введён неверно больше 5 раз.',
|
|
12
17
|
fatalErrorButton: 'Понятно',
|
|
13
|
-
tempBlockTitle: '
|
|
14
|
-
tempBlockDescription: '
|
|
15
|
-
|
|
16
|
-
|
|
18
|
+
tempBlockTitle: 'Ввести код пока нельзя',
|
|
19
|
+
tempBlockDescription: 'Слишком много неверных попыток. Запросите новый позже',
|
|
20
|
+
tempBlockOverTitle: 'Ввод разблокирован',
|
|
21
|
+
tempBlockOverDescription: 'Теперь можно запросить новый код',
|
|
22
|
+
tempBlockOverButton: 'Запросить новый код',
|
|
23
|
+
codeSended: 'Код отправлен',
|
|
24
|
+
countdown: 'Запросить новый можно через',
|
|
17
25
|
domesticPhone: '8 800 200 00 00',
|
|
18
26
|
internationalPhone: '+7 495 78 888 78',
|
|
19
27
|
};
|
|
@@ -8,6 +8,7 @@ import { Initial } from '../screens/initial/component.js';
|
|
|
8
8
|
import { Hint } from '../screens/hint/component.js';
|
|
9
9
|
import { FatalError } from '../screens/fatal-error/component.js';
|
|
10
10
|
import { TempBlock } from '../screens/temp-block/component.js';
|
|
11
|
+
import { TempBlockOver } from '../screens/temp-block-over/component.js';
|
|
11
12
|
import styles from './index.module.css';
|
|
12
13
|
|
|
13
14
|
const confirmationScreens = {
|
|
@@ -15,6 +16,7 @@ const confirmationScreens = {
|
|
|
15
16
|
HINT: Hint,
|
|
16
17
|
FATAL_ERROR: FatalError,
|
|
17
18
|
TEMP_BLOCK: TempBlock,
|
|
19
|
+
TEMP_BLOCK_OVER: TempBlockOver,
|
|
18
20
|
};
|
|
19
21
|
const BaseConfirmation = ({ state, screen, alignContent = 'left', children, requiredCharAmount = 5, countdownDuration = ONE_MINUTE, tempBlockDuration = ONE_DAY, phone, blockSmsRetry, dataTestId, className, getScreensMap, onInputFinished, onChangeState, onSmsRetryClick, onChangeScreen, onFatalErrorOkButtonClick, onTempBlockFinished, mobile, clearCodeOnError = true, hideCountdownSection = false, breakpoint, client, initialScreenHintSlot, errorVisibleDuration, ...restProps }) => {
|
|
20
22
|
const [timeLeft, startTimer, stopTimer] = useCountdown(countdownDuration);
|
|
@@ -34,7 +36,8 @@ const BaseConfirmation = ({ state, screen, alignContent = 'left', children, requ
|
|
|
34
36
|
/**
|
|
35
37
|
* Останавливаем таймер, если новый экран/состояние не содержит таймер
|
|
36
38
|
*/
|
|
37
|
-
if (!['INITIAL', 'HINT', 'TEMP_BLOCK'].includes(screen) ||
|
|
39
|
+
if (!['INITIAL', 'HINT', 'TEMP_BLOCK', 'TEMP_BLOCK_OVER'].includes(screen) ||
|
|
40
|
+
blockSmsRetry) {
|
|
38
41
|
stopTimer();
|
|
39
42
|
}
|
|
40
43
|
}, [state, screen, blockSmsRetry, stopTimer]);
|
|
@@ -2,4 +2,5 @@ export { Initial } from './screens/initial/component.js';
|
|
|
2
2
|
export { Hint } from './screens/hint/component.js';
|
|
3
3
|
export { FatalError } from './screens/fatal-error/component.js';
|
|
4
4
|
export { TempBlock } from './screens/temp-block/component.js';
|
|
5
|
+
export { TempBlockOver } from './screens/temp-block-over/component.js';
|
|
5
6
|
export { CountdownLoader } from './countdown-loader/component.js';
|
|
@@ -16,34 +16,34 @@ const Hint = ({ mobile }) => {
|
|
|
16
16
|
onChangeState('INITIAL');
|
|
17
17
|
};
|
|
18
18
|
return (React.createElement("div", { className: cn(styles.component, styles[alignContent]) },
|
|
19
|
-
React.createElement(Header, { mobile: mobile },
|
|
19
|
+
React.createElement(Header, { mobile: mobile }, texts.hintTitle),
|
|
20
20
|
React.createElement(Text, { view: 'primary-medium', color: 'primary', className: cn(styles.text, {
|
|
21
21
|
[styles.typographyTheme]: !mobile,
|
|
22
22
|
[styles.typographyThemeMobile]: mobile,
|
|
23
|
-
}) },
|
|
23
|
+
}) }, texts.hintDescription),
|
|
24
24
|
React.createElement("div", { className: cn(styles.phonesWrap, {
|
|
25
25
|
[styles.phonesWrapMobile]: mobile,
|
|
26
26
|
}) },
|
|
27
27
|
React.createElement("div", { className: cn(styles.phoneWrap, { [styles.phoneContentMobile]: mobile }) },
|
|
28
|
-
React.createElement(Link, { href: getPhoneHref(
|
|
28
|
+
React.createElement(Link, { href: getPhoneHref(internationalPhone), underline: false, className: cn(styles.phoneLink, { [styles.typographyThemeMobile]: mobile }) }, internationalPhone),
|
|
29
29
|
React.createElement(Text, { view: 'primary-medium', color: 'primary', className: cn(styles.text, {
|
|
30
30
|
[styles.typographyTheme]: !mobile,
|
|
31
31
|
[styles.typographyThemeMobile]: mobile,
|
|
32
32
|
}) }, mobile
|
|
33
|
-
? '
|
|
34
|
-
: ' \u2014\u00A0
|
|
33
|
+
? 'В\u00A0Москве и\u00A0за\u00A0границей'
|
|
34
|
+
: ' \u2014\u00A0в\u00A0Москве и\u00A0за\u00A0границей')),
|
|
35
35
|
React.createElement("div", { className: cn(styles.phoneWrap, { [styles.phoneContentMobile]: mobile }) },
|
|
36
|
-
React.createElement(Link, { href: getPhoneHref(
|
|
36
|
+
React.createElement(Link, { href: getPhoneHref(domesticPhone), underline: false, className: cn(styles.phoneLink, { [styles.typographyThemeMobile]: mobile }) }, domesticPhone),
|
|
37
37
|
React.createElement(Text, { view: 'primary-medium', color: 'primary', className: cn(styles.text, {
|
|
38
38
|
[styles.typographyTheme]: !mobile,
|
|
39
39
|
[styles.typographyThemeMobile]: mobile,
|
|
40
40
|
}) }, mobile
|
|
41
|
-
? '
|
|
42
|
-
: ' \u2014\u00A0
|
|
41
|
+
? 'Для\u00A0звонков по\u00A0России'
|
|
42
|
+
: ' \u2014\u00A0для звонков по\u00A0России'))),
|
|
43
43
|
React.createElement(Text, { view: 'primary-medium', color: 'primary', className: cn(styles.text, {
|
|
44
44
|
[styles.typographyTheme]: !mobile,
|
|
45
45
|
[styles.typographyThemeMobile]: mobile,
|
|
46
|
-
}) },
|
|
46
|
+
}) }, texts.hintNotification),
|
|
47
47
|
React.createElement(Button, { size: mobile ? 'xs' : 's', view: 'secondary', onClick: handleReturnButtonClick, className: styles.hintButton, breakpoint: breakpoint, client: client }, hintButton)));
|
|
48
48
|
};
|
|
49
49
|
|
|
@@ -2,3 +2,4 @@ export { Initial } from './initial/component.js';
|
|
|
2
2
|
export { Hint } from './hint/component.js';
|
|
3
3
|
export { FatalError } from './fatal-error/component.js';
|
|
4
4
|
export { TempBlock } from './temp-block/component.js';
|
|
5
|
+
export { TempBlockOver } from './temp-block-over/component.js';
|
|
@@ -55,9 +55,6 @@ const Initial = ({ mobile }) => {
|
|
|
55
55
|
if (!inputRef.current) {
|
|
56
56
|
return;
|
|
57
57
|
}
|
|
58
|
-
if (state === 'CODE_ERROR' && prevState !== 'CODE_ERROR') {
|
|
59
|
-
inputRef.current.focus(requiredCharAmount - 1);
|
|
60
|
-
}
|
|
61
58
|
if (prevState === 'CODE_SENDING' && state !== 'CODE_SENDING') {
|
|
62
59
|
inputRef.current.focus();
|
|
63
60
|
}
|
|
@@ -72,6 +69,12 @@ const Initial = ({ mobile }) => {
|
|
|
72
69
|
}
|
|
73
70
|
}, [prevState, state, clearTimer]);
|
|
74
71
|
const getCodeInputError = () => {
|
|
72
|
+
if (state === 'CODE_EXPIRED') {
|
|
73
|
+
return texts.codeErrorExpired || true;
|
|
74
|
+
}
|
|
75
|
+
if (state === 'CODE_EXPIRED_ENDED') {
|
|
76
|
+
return texts.codeErrorExpiredEnded || true;
|
|
77
|
+
}
|
|
75
78
|
if (state === 'CODE_ERROR') {
|
|
76
79
|
return texts.codeError || true;
|
|
77
80
|
}
|
|
@@ -95,7 +98,7 @@ const Initial = ({ mobile }) => {
|
|
|
95
98
|
[styles.typographyTheme]: !mobile,
|
|
96
99
|
[styles.typographyThemeMobile]: mobile,
|
|
97
100
|
}) },
|
|
98
|
-
"\
|
|
101
|
+
"\u041E\u0442\u043F\u0440\u0430\u0432\u0438\u043B\u0438 \u043D\u0430 ",
|
|
99
102
|
phone)) : null,
|
|
100
103
|
React.createElement(ComponentCodeInput, { disabled: processing, error: getCodeInputError(), ref: inputRef, fields: requiredCharAmount, className: cn(styles.containerInput, styles.codeInput), onComplete: handleInputComplete, onChange: handleInputChange, clearCodeOnError: clearCodeOnError, errorVisibleDuration: errorVisibleDuration, onErrorAnimationEnd: handleErrorAnimationEnd }),
|
|
101
104
|
!hideCountdownSection && (React.createElement(CountdownSection, { processing: processing, timePassed: timePassed, codeSendHintVisible: codeSendHintVisible, handleSmsRetryClick: handleSmsRetryClick, mobile: mobile })),
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import React, { useContext } from 'react';
|
|
1
|
+
import React, { useContext, Fragment } from 'react';
|
|
2
2
|
import cn from 'classnames';
|
|
3
3
|
import { Button } from '@alfalab/core-components-button/moderncssm';
|
|
4
4
|
import { Spinner } from '@alfalab/core-components-spinner/moderncssm';
|
|
@@ -9,10 +9,10 @@ import styles from './index.module.css';
|
|
|
9
9
|
|
|
10
10
|
const CountdownSection = ({ codeSendHintVisible, timePassed, processing, mobile, handleSmsRetryClick, }) => {
|
|
11
11
|
const { state, texts, timeLeft, blockSmsRetry, breakpoint, client } = useContext(ConfirmationContext);
|
|
12
|
-
const renderText = (
|
|
12
|
+
const renderText = (content) => (React.createElement(Text, { className: cn(styles.countdownContainer, {
|
|
13
13
|
[styles.countdownMobile]: mobile,
|
|
14
14
|
[styles.typographyTheme]: !mobile,
|
|
15
|
-
}), view: mobile ? 'primary-small' : 'primary-medium', tag: 'div' },
|
|
15
|
+
}), view: mobile ? 'primary-small' : 'primary-medium', tag: 'div' }, content));
|
|
16
16
|
if (codeSendHintVisible)
|
|
17
17
|
return renderText(texts.codeSended);
|
|
18
18
|
if (processing) {
|
|
@@ -28,7 +28,10 @@ const CountdownSection = ({ codeSendHintVisible, timePassed, processing, mobile,
|
|
|
28
28
|
if (timePassed) {
|
|
29
29
|
return (React.createElement(Button, { size: mobile ? 'xs' : 'xxs', view: 'secondary', onClick: handleSmsRetryClick, className: cn(styles.getCodeButton, { [styles.getCodeButtonMobile]: mobile }), breakpoint: breakpoint, client: client }, texts.buttonRetry));
|
|
30
30
|
}
|
|
31
|
-
return renderText(
|
|
31
|
+
return renderText(React.createElement(Fragment, null,
|
|
32
|
+
texts.countdown,
|
|
33
|
+
'\u00A0',
|
|
34
|
+
React.createElement("time", { className: styles.timeCounter }, formatMsAsMinutes(timeLeft))));
|
|
32
35
|
};
|
|
33
36
|
|
|
34
37
|
export { CountdownSection };
|
|
@@ -86,6 +86,15 @@
|
|
|
86
86
|
margin-bottom: var(--gap-16);
|
|
87
87
|
}
|
|
88
88
|
|
|
89
|
+
.timeCounter {
|
|
90
|
+
display: inline-block;
|
|
91
|
+
min-width: 47px;
|
|
92
|
+
color: var(--color-light-text-secondary);
|
|
93
|
+
text-align: left;
|
|
94
|
+
font-feature-settings: lining-nums tabular-nums;
|
|
95
|
+
font-variant-numeric: lining-nums tabular-nums;
|
|
96
|
+
}
|
|
97
|
+
|
|
89
98
|
.getCodeButton {
|
|
90
99
|
position: relative;
|
|
91
100
|
top: var(--gap-4-neg);
|
|
@@ -26,7 +26,7 @@ const TempBlock = ({ mobile }) => {
|
|
|
26
26
|
}) }, texts.tempBlockDescription),
|
|
27
27
|
React.createElement("div", { className: cn(styles.countdownWrap, { [styles.typographyTheme]: !mobile }) },
|
|
28
28
|
React.createElement(CountdownLoader, { progress: 1 - timeLeft / tempBlockDuration, className: styles.loader }),
|
|
29
|
-
formatMsAsMinutes(timeLeft))));
|
|
29
|
+
React.createElement("time", { className: styles.timeCounter }, formatMsAsMinutes(timeLeft)))));
|
|
30
30
|
};
|
|
31
31
|
|
|
32
32
|
export { TempBlock };
|
|
@@ -46,6 +46,15 @@
|
|
|
46
46
|
align-items: center;
|
|
47
47
|
}
|
|
48
48
|
|
|
49
|
+
.timeCounter {
|
|
50
|
+
display: inline-block;
|
|
51
|
+
min-width: 47px;
|
|
52
|
+
color: var(--color-light-text-secondary);
|
|
53
|
+
text-align: left;
|
|
54
|
+
font-feature-settings: lining-nums tabular-nums;
|
|
55
|
+
font-variant-numeric: lining-nums tabular-nums;
|
|
56
|
+
}
|
|
57
|
+
|
|
49
58
|
.loader {
|
|
50
59
|
margin-right: var(--gap-8);
|
|
51
60
|
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import React, { useContext } from 'react';
|
|
2
|
+
import cn from 'classnames';
|
|
3
|
+
import { Button } from '@alfalab/core-components-button/moderncssm';
|
|
4
|
+
import { Text } from '@alfalab/core-components-typography/moderncssm';
|
|
5
|
+
import { ConfirmationContext } from '../../../context.js';
|
|
6
|
+
import { Header } from '../../header/component.js';
|
|
7
|
+
import styles from './index.module.css';
|
|
8
|
+
|
|
9
|
+
const TempBlockOver = ({ mobile }) => {
|
|
10
|
+
const { alignContent, texts, breakpoint, client, onChangeScreen, onChangeState } = useContext(ConfirmationContext);
|
|
11
|
+
const handleReturnButtonClick = () => {
|
|
12
|
+
onChangeScreen('INITIAL');
|
|
13
|
+
onChangeState('INITIAL');
|
|
14
|
+
};
|
|
15
|
+
return (React.createElement("div", { className: cn(styles.component, styles[alignContent]) },
|
|
16
|
+
React.createElement(Header, { mobile: mobile }, texts.tempBlockOverTitle),
|
|
17
|
+
React.createElement(Text, { view: 'primary-medium', color: 'primary', className: cn(styles.description, {
|
|
18
|
+
[styles.typographyTheme]: !mobile,
|
|
19
|
+
[styles.typographyThemeMobile]: mobile,
|
|
20
|
+
}) }, texts.tempBlockOverDescription),
|
|
21
|
+
React.createElement(Button, { size: mobile ? 'xs' : 's', view: 'secondary', onClick: handleReturnButtonClick, className: styles.button, breakpoint: breakpoint, client: client }, texts.tempBlockOverButton)));
|
|
22
|
+
};
|
|
23
|
+
|
|
24
|
+
export { TempBlockOver };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./component";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { TempBlockOver } from './component.js';
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
/* */
|
|
2
|
+
|
|
3
|
+
:root {
|
|
4
|
+
/* desktop */
|
|
5
|
+
|
|
6
|
+
/* mobile */
|
|
7
|
+
|
|
8
|
+
/* text */
|
|
9
|
+
--confirmation-text-font-size: 16px;
|
|
10
|
+
--confirmation-text-line-height: 24px;
|
|
11
|
+
--confirmation-text-font-weight: 400;
|
|
12
|
+
--confirmation-text-font-family: var(--font-family-system);
|
|
13
|
+
--confirmation-text-color: var(--color-light-text-primary)
|
|
14
|
+
|
|
15
|
+
/* header */
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
.component {
|
|
19
|
+
display: flex;
|
|
20
|
+
flex-direction: column;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.center {
|
|
24
|
+
align-items: center;
|
|
25
|
+
text-align: center;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
.typographyTheme.typographyTheme {
|
|
29
|
+
font-size: var(--confirmation-text-font-size);
|
|
30
|
+
line-height: var(--confirmation-text-line-height);
|
|
31
|
+
font-weight: var(--confirmation-text-font-weight);
|
|
32
|
+
font-family: var(--confirmation-text-font-family);
|
|
33
|
+
color: var(--confirmation-text-color);
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
.typographyThemeMobile.typographyThemeMobile {
|
|
37
|
+
color: var(--color-light-text-secondary);
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
.button.button {
|
|
41
|
+
margin-top: var(--gap-32);
|
|
42
|
+
}
|
|
@@ -2,6 +2,7 @@ export { Initial } from '../components/screens/initial/component.js';
|
|
|
2
2
|
export { Hint } from '../components/screens/hint/component.js';
|
|
3
3
|
export { FatalError } from '../components/screens/fatal-error/component.js';
|
|
4
4
|
export { TempBlock } from '../components/screens/temp-block/component.js';
|
|
5
|
+
export { TempBlockOver } from '../components/screens/temp-block-over/component.js';
|
|
5
6
|
export { CountdownLoader } from '../components/countdown-loader/component.js';
|
|
6
7
|
export { ConfirmationContext } from '../context.js';
|
|
7
8
|
export { defaultTexts } from '../types.js';
|
package/moderncssm/types.d.ts
CHANGED
|
@@ -117,6 +117,8 @@ type ConfirmationTexts = {
|
|
|
117
117
|
*/
|
|
118
118
|
title?: ReactNode;
|
|
119
119
|
codeError?: string;
|
|
120
|
+
codeErrorExpired?: string;
|
|
121
|
+
codeErrorExpiredEnded?: string;
|
|
120
122
|
codeChecking?: string;
|
|
121
123
|
codeSending?: string;
|
|
122
124
|
codeSended?: string;
|
|
@@ -127,6 +129,9 @@ type ConfirmationTexts = {
|
|
|
127
129
|
/**
|
|
128
130
|
* Экран HINT
|
|
129
131
|
*/
|
|
132
|
+
hintTitle?: string;
|
|
133
|
+
hintDescription?: string;
|
|
134
|
+
hintNotification?: string;
|
|
130
135
|
hintButton?: string;
|
|
131
136
|
domesticPhone?: string;
|
|
132
137
|
internationalPhone?: string;
|
|
@@ -141,9 +146,15 @@ type ConfirmationTexts = {
|
|
|
141
146
|
*/
|
|
142
147
|
tempBlockTitle?: ReactNode;
|
|
143
148
|
tempBlockDescription?: ReactNode;
|
|
149
|
+
/**
|
|
150
|
+
* Экран TEMP_BLOCK_OVER
|
|
151
|
+
*/
|
|
152
|
+
tempBlockOverTitle?: ReactNode;
|
|
153
|
+
tempBlockOverDescription?: ReactNode;
|
|
154
|
+
tempBlockOverButton?: string;
|
|
144
155
|
};
|
|
145
|
-
type ConfirmationScreen = 'INITIAL' | 'HINT' | 'FATAL_ERROR' | 'TEMP_BLOCK';
|
|
146
|
-
type ConfirmationState = 'INITIAL' | 'CODE_CHECKING' | 'CODE_SENDING' | 'CODE_ERROR';
|
|
156
|
+
type ConfirmationScreen = 'INITIAL' | 'HINT' | 'FATAL_ERROR' | 'TEMP_BLOCK' | 'TEMP_BLOCK_OVER';
|
|
157
|
+
type ConfirmationState = 'INITIAL' | 'CODE_CHECKING' | 'CODE_SENDING' | 'CODE_ERROR' | 'CODE_EXPIRED' | 'CODE_EXPIRED_ENDED';
|
|
147
158
|
type ScreensMap = {
|
|
148
159
|
[key: string]: ComponentType;
|
|
149
160
|
};
|