@alfalab/core-components-pattern-lock 1.4.3 → 1.4.5
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/Component.js +1 -1
- package/cssm/index.module.css +1 -1
- package/esm/Component.js +1 -1
- package/esm/index.css +12 -12
- package/index.css +12 -12
- package/modern/Component.js +1 -1
- package/modern/index.css +12 -12
- package/package.json +3 -3
- package/Component-89f0cb07.d.ts +0 -38
- package/cssm/Component-89f0cb07.d.ts +0 -38
- package/cssm/typings-89f0cb07.d.ts +0 -93
- package/esm/Component-89f0cb07.d.ts +0 -38
- package/esm/typings-89f0cb07.d.ts +0 -93
- package/modern/Component-89f0cb07.d.ts +0 -38
- package/modern/typings-89f0cb07.d.ts +0 -93
- package/typings-89f0cb07.d.ts +0 -93
package/Component.js
CHANGED
|
@@ -17,7 +17,7 @@ function _interopDefaultCompat (e) { return e && typeof e === 'object' && 'defau
|
|
|
17
17
|
var React__default = /*#__PURE__*/_interopDefaultCompat(React);
|
|
18
18
|
var cn__default = /*#__PURE__*/_interopDefaultCompat(cn);
|
|
19
19
|
|
|
20
|
-
var styles = {"component":"pattern-
|
|
20
|
+
var styles = {"component":"pattern-lock__component_932tc","hidden":"pattern-lock__hidden_932tc","message":"pattern-lock__message_932tc","error":"pattern-lock__error_932tc","forgotBtn":"pattern-lock__forgotBtn_932tc"};
|
|
21
21
|
require('./index.css')
|
|
22
22
|
|
|
23
23
|
var PatternLock = React.forwardRef(function (_a, ref) {
|
package/cssm/index.module.css
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
:root {
|
|
2
2
|
} /* deprecated */ :root {
|
|
3
|
-
--color-light-text-negative: #
|
|
3
|
+
--color-light-text-negative: #ec2e14;
|
|
4
4
|
--color-light-text-primary: #0e0e0e; /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
5
5
|
} :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 */
|
|
6
6
|
} :root {
|
package/esm/Component.js
CHANGED
|
@@ -8,7 +8,7 @@ import { getDataTestId } from '@alfalab/core-components-shared/esm';
|
|
|
8
8
|
import { THEME_STATE, DEFAULT_EXTRA_BOUNDS, OBSERVE_OPTIONS, OBSERVABLE_TOKENS } from './consts.js';
|
|
9
9
|
import { getSizes, getTheme, getColorByToken, getDefaultObserveTarget } from './utils.js';
|
|
10
10
|
|
|
11
|
-
var styles = {"component":"pattern-
|
|
11
|
+
var styles = {"component":"pattern-lock__component_932tc","hidden":"pattern-lock__hidden_932tc","message":"pattern-lock__message_932tc","error":"pattern-lock__error_932tc","forgotBtn":"pattern-lock__forgotBtn_932tc"};
|
|
12
12
|
require('./index.css')
|
|
13
13
|
|
|
14
14
|
var PatternLock = forwardRef(function (_a, ref) {
|
package/esm/index.css
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: 1ne81 */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root {
|
|
4
|
-
--color-light-text-negative: #
|
|
4
|
+
--color-light-text-negative: #ec2e14;
|
|
5
5
|
--color-light-text-primary: #0e0e0e; /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* 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
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 */
|
|
7
7
|
} :root {
|
|
@@ -27,15 +27,15 @@
|
|
|
27
27
|
--size-m-height: 56px;
|
|
28
28
|
} :root {
|
|
29
29
|
--pattern-lock-max-width: 500px;
|
|
30
|
-
} .pattern-
|
|
30
|
+
} .pattern-lock__component_932tc {
|
|
31
31
|
max-width: var(--pattern-lock-max-width);
|
|
32
32
|
margin: var(--gap-xs) 0 var(--gap-xl) 0
|
|
33
|
-
} .pattern-
|
|
33
|
+
} .pattern-lock__component_932tc canvas {
|
|
34
34
|
display: block;
|
|
35
35
|
margin: 0 auto;
|
|
36
|
-
} .pattern-
|
|
36
|
+
} .pattern-lock__hidden_932tc {
|
|
37
37
|
visibility: hidden;
|
|
38
|
-
} .pattern-
|
|
38
|
+
} .pattern-lock__message_932tc {
|
|
39
39
|
font-size: 16px;
|
|
40
40
|
line-height: 24px;
|
|
41
41
|
font-weight: 400;
|
|
@@ -47,27 +47,27 @@
|
|
|
47
47
|
text-overflow: ellipsis;
|
|
48
48
|
white-space: nowrap;
|
|
49
49
|
color: var(--color-light-text-primary);
|
|
50
|
-
} .pattern-
|
|
50
|
+
} .pattern-lock__error_932tc {
|
|
51
51
|
color: var(--color-light-text-negative);
|
|
52
|
-
} .pattern-
|
|
52
|
+
} .pattern-lock__forgotBtn_932tc {
|
|
53
53
|
display: block;
|
|
54
54
|
min-height: var(--size-xs-height);
|
|
55
55
|
margin: var(--gap-xl) auto 0;
|
|
56
56
|
} @media screen and (min-width: 360px) {
|
|
57
|
-
.pattern-
|
|
57
|
+
.pattern-lock__forgotBtn_932tc {
|
|
58
58
|
margin-top: var(--gap-2xl);
|
|
59
59
|
min-height: var(--size-s-height);
|
|
60
60
|
}
|
|
61
61
|
|
|
62
|
-
.pattern-
|
|
62
|
+
.pattern-lock__component_932tc {
|
|
63
63
|
margin-bottom: var(--gap-s);
|
|
64
64
|
}
|
|
65
65
|
} @media screen and (min-width: 390px) {
|
|
66
|
-
.pattern-
|
|
66
|
+
.pattern-lock__forgotBtn_932tc {
|
|
67
67
|
min-height: var(--size-m-height);
|
|
68
68
|
}
|
|
69
69
|
|
|
70
|
-
.pattern-
|
|
70
|
+
.pattern-lock__component_932tc {
|
|
71
71
|
margin-bottom: var(--gap-l);
|
|
72
72
|
}
|
|
73
73
|
}
|
package/index.css
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: 1ne81 */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root {
|
|
4
|
-
--color-light-text-negative: #
|
|
4
|
+
--color-light-text-negative: #ec2e14;
|
|
5
5
|
--color-light-text-primary: #0e0e0e; /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* 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
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 */
|
|
7
7
|
} :root {
|
|
@@ -27,15 +27,15 @@
|
|
|
27
27
|
--size-m-height: 56px;
|
|
28
28
|
} :root {
|
|
29
29
|
--pattern-lock-max-width: 500px;
|
|
30
|
-
} .pattern-
|
|
30
|
+
} .pattern-lock__component_932tc {
|
|
31
31
|
max-width: var(--pattern-lock-max-width);
|
|
32
32
|
margin: var(--gap-xs) 0 var(--gap-xl) 0
|
|
33
|
-
} .pattern-
|
|
33
|
+
} .pattern-lock__component_932tc canvas {
|
|
34
34
|
display: block;
|
|
35
35
|
margin: 0 auto;
|
|
36
|
-
} .pattern-
|
|
36
|
+
} .pattern-lock__hidden_932tc {
|
|
37
37
|
visibility: hidden;
|
|
38
|
-
} .pattern-
|
|
38
|
+
} .pattern-lock__message_932tc {
|
|
39
39
|
font-size: 16px;
|
|
40
40
|
line-height: 24px;
|
|
41
41
|
font-weight: 400;
|
|
@@ -47,27 +47,27 @@
|
|
|
47
47
|
text-overflow: ellipsis;
|
|
48
48
|
white-space: nowrap;
|
|
49
49
|
color: var(--color-light-text-primary);
|
|
50
|
-
} .pattern-
|
|
50
|
+
} .pattern-lock__error_932tc {
|
|
51
51
|
color: var(--color-light-text-negative);
|
|
52
|
-
} .pattern-
|
|
52
|
+
} .pattern-lock__forgotBtn_932tc {
|
|
53
53
|
display: block;
|
|
54
54
|
min-height: var(--size-xs-height);
|
|
55
55
|
margin: var(--gap-xl) auto 0;
|
|
56
56
|
} @media screen and (min-width: 360px) {
|
|
57
|
-
.pattern-
|
|
57
|
+
.pattern-lock__forgotBtn_932tc {
|
|
58
58
|
margin-top: var(--gap-2xl);
|
|
59
59
|
min-height: var(--size-s-height);
|
|
60
60
|
}
|
|
61
61
|
|
|
62
|
-
.pattern-
|
|
62
|
+
.pattern-lock__component_932tc {
|
|
63
63
|
margin-bottom: var(--gap-s);
|
|
64
64
|
}
|
|
65
65
|
} @media screen and (min-width: 390px) {
|
|
66
|
-
.pattern-
|
|
66
|
+
.pattern-lock__forgotBtn_932tc {
|
|
67
67
|
min-height: var(--size-m-height);
|
|
68
68
|
}
|
|
69
69
|
|
|
70
|
-
.pattern-
|
|
70
|
+
.pattern-lock__component_932tc {
|
|
71
71
|
margin-bottom: var(--gap-l);
|
|
72
72
|
}
|
|
73
73
|
}
|
package/modern/Component.js
CHANGED
|
@@ -7,7 +7,7 @@ import { getDataTestId } from '@alfalab/core-components-shared/modern';
|
|
|
7
7
|
import { THEME_STATE, DEFAULT_EXTRA_BOUNDS, OBSERVE_OPTIONS, OBSERVABLE_TOKENS } from './consts.js';
|
|
8
8
|
import { getSizes, getTheme, getColorByToken, getDefaultObserveTarget } from './utils.js';
|
|
9
9
|
|
|
10
|
-
const styles = {"component":"pattern-
|
|
10
|
+
const styles = {"component":"pattern-lock__component_932tc","hidden":"pattern-lock__hidden_932tc","message":"pattern-lock__message_932tc","error":"pattern-lock__error_932tc","forgotBtn":"pattern-lock__forgotBtn_932tc"};
|
|
11
11
|
require('./index.css')
|
|
12
12
|
|
|
13
13
|
const PatternLock = forwardRef(({ observeTokens = false, observerParams = {}, justifyNodes = 'space-between', className, error, dataTestId, forgotCodeBtnText = 'Забыли код?', showForgotCodeBtn = false, onForgotBtnClick, extraBounds = DEFAULT_EXTRA_BOUNDS, message, ...restProps }, ref) => {
|
package/modern/index.css
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: 1ne81 */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root {
|
|
4
|
-
--color-light-text-negative: #
|
|
4
|
+
--color-light-text-negative: #ec2e14;
|
|
5
5
|
--color-light-text-primary: #0e0e0e; /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* 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
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 */
|
|
7
7
|
} :root {
|
|
@@ -27,15 +27,15 @@
|
|
|
27
27
|
--size-m-height: 56px;
|
|
28
28
|
} :root {
|
|
29
29
|
--pattern-lock-max-width: 500px;
|
|
30
|
-
} .pattern-
|
|
30
|
+
} .pattern-lock__component_932tc {
|
|
31
31
|
max-width: var(--pattern-lock-max-width);
|
|
32
32
|
margin: var(--gap-xs) 0 var(--gap-xl) 0
|
|
33
|
-
} .pattern-
|
|
33
|
+
} .pattern-lock__component_932tc canvas {
|
|
34
34
|
display: block;
|
|
35
35
|
margin: 0 auto;
|
|
36
|
-
} .pattern-
|
|
36
|
+
} .pattern-lock__hidden_932tc {
|
|
37
37
|
visibility: hidden;
|
|
38
|
-
} .pattern-
|
|
38
|
+
} .pattern-lock__message_932tc {
|
|
39
39
|
font-size: 16px;
|
|
40
40
|
line-height: 24px;
|
|
41
41
|
font-weight: 400;
|
|
@@ -47,27 +47,27 @@
|
|
|
47
47
|
text-overflow: ellipsis;
|
|
48
48
|
white-space: nowrap;
|
|
49
49
|
color: var(--color-light-text-primary);
|
|
50
|
-
} .pattern-
|
|
50
|
+
} .pattern-lock__error_932tc {
|
|
51
51
|
color: var(--color-light-text-negative);
|
|
52
|
-
} .pattern-
|
|
52
|
+
} .pattern-lock__forgotBtn_932tc {
|
|
53
53
|
display: block;
|
|
54
54
|
min-height: var(--size-xs-height);
|
|
55
55
|
margin: var(--gap-xl) auto 0;
|
|
56
56
|
} @media screen and (min-width: 360px) {
|
|
57
|
-
.pattern-
|
|
57
|
+
.pattern-lock__forgotBtn_932tc {
|
|
58
58
|
margin-top: var(--gap-2xl);
|
|
59
59
|
min-height: var(--size-s-height);
|
|
60
60
|
}
|
|
61
61
|
|
|
62
|
-
.pattern-
|
|
62
|
+
.pattern-lock__component_932tc {
|
|
63
63
|
margin-bottom: var(--gap-s);
|
|
64
64
|
}
|
|
65
65
|
} @media screen and (min-width: 390px) {
|
|
66
|
-
.pattern-
|
|
66
|
+
.pattern-lock__forgotBtn_932tc {
|
|
67
67
|
min-height: var(--size-m-height);
|
|
68
68
|
}
|
|
69
69
|
|
|
70
|
-
.pattern-
|
|
70
|
+
.pattern-lock__component_932tc {
|
|
71
71
|
margin-bottom: var(--gap-l);
|
|
72
72
|
}
|
|
73
73
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@alfalab/core-components-pattern-lock",
|
|
3
|
-
"version": "1.4.
|
|
3
|
+
"version": "1.4.5",
|
|
4
4
|
"description": "Pattern lock",
|
|
5
5
|
"keywords": [],
|
|
6
6
|
"license": "MIT",
|
|
@@ -15,9 +15,9 @@
|
|
|
15
15
|
"react-dom": "^16.9.0 || ^17.0.1 || ^18.0.0"
|
|
16
16
|
},
|
|
17
17
|
"dependencies": {
|
|
18
|
-
"@alfalab/core-components-button": "^
|
|
18
|
+
"@alfalab/core-components-button": "^10.0.0",
|
|
19
19
|
"@alfalab/core-components-gap": "^1.2.0",
|
|
20
|
-
"@alfalab/core-components-shared": "^0.
|
|
20
|
+
"@alfalab/core-components-shared": "^0.8.0",
|
|
21
21
|
"react-canvas-pattern-lock": "^1.1.1",
|
|
22
22
|
"classnames": "^2.3.1",
|
|
23
23
|
"tslib": "^2.4.0"
|
package/Component-89f0cb07.d.ts
DELETED
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import React from "react";
|
|
3
|
-
import { FC } from "react";
|
|
4
|
-
import { CommonButtonProps, PrivateButtonProps } from "./typings-89f0cb07";
|
|
5
|
-
type SpinnerProps = {
|
|
6
|
-
/**
|
|
7
|
-
* Управление видимостью компонента
|
|
8
|
-
*/
|
|
9
|
-
visible?: boolean;
|
|
10
|
-
/**
|
|
11
|
-
* Размер компонента
|
|
12
|
-
*/
|
|
13
|
-
size?: "xs" | "s" | "m";
|
|
14
|
-
/**
|
|
15
|
-
* Дополнительный класс
|
|
16
|
-
*/
|
|
17
|
-
className?: string;
|
|
18
|
-
/**
|
|
19
|
-
* Идентификатор компонента в DOM
|
|
20
|
-
*/
|
|
21
|
-
id?: string;
|
|
22
|
-
/**
|
|
23
|
-
* Идентификатор для систем автоматизированного тестирования
|
|
24
|
-
*/
|
|
25
|
-
dataTestId?: string;
|
|
26
|
-
/**
|
|
27
|
-
* Палитра, в контексте которой используется спиннер
|
|
28
|
-
*/
|
|
29
|
-
colors?: "default" | "inverted";
|
|
30
|
-
};
|
|
31
|
-
declare const Spinner: FC<SpinnerProps>;
|
|
32
|
-
/**
|
|
33
|
-
* Минимальное время отображения лоадера - 500мс,
|
|
34
|
-
* чтобы при быстрых ответах от сервера кнопка не «моргала».
|
|
35
|
-
*/
|
|
36
|
-
declare const LOADER_MIN_DISPLAY_INTERVAL = 500;
|
|
37
|
-
declare const BaseButton: React.ForwardRefExoticComponent<(CommonButtonProps & PrivateButtonProps) & React.RefAttributes<HTMLAnchorElement | HTMLButtonElement>>;
|
|
38
|
-
export { SpinnerProps, Spinner, LOADER_MIN_DISPLAY_INTERVAL, BaseButton };
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import React from "react";
|
|
3
|
-
import { FC } from "react";
|
|
4
|
-
import { CommonButtonProps, PrivateButtonProps } from "./typings-89f0cb07";
|
|
5
|
-
type SpinnerProps = {
|
|
6
|
-
/**
|
|
7
|
-
* Управление видимостью компонента
|
|
8
|
-
*/
|
|
9
|
-
visible?: boolean;
|
|
10
|
-
/**
|
|
11
|
-
* Размер компонента
|
|
12
|
-
*/
|
|
13
|
-
size?: "xs" | "s" | "m";
|
|
14
|
-
/**
|
|
15
|
-
* Дополнительный класс
|
|
16
|
-
*/
|
|
17
|
-
className?: string;
|
|
18
|
-
/**
|
|
19
|
-
* Идентификатор компонента в DOM
|
|
20
|
-
*/
|
|
21
|
-
id?: string;
|
|
22
|
-
/**
|
|
23
|
-
* Идентификатор для систем автоматизированного тестирования
|
|
24
|
-
*/
|
|
25
|
-
dataTestId?: string;
|
|
26
|
-
/**
|
|
27
|
-
* Палитра, в контексте которой используется спиннер
|
|
28
|
-
*/
|
|
29
|
-
colors?: "default" | "inverted";
|
|
30
|
-
};
|
|
31
|
-
declare const Spinner: FC<SpinnerProps>;
|
|
32
|
-
/**
|
|
33
|
-
* Минимальное время отображения лоадера - 500мс,
|
|
34
|
-
* чтобы при быстрых ответах от сервера кнопка не «моргала».
|
|
35
|
-
*/
|
|
36
|
-
declare const LOADER_MIN_DISPLAY_INTERVAL = 500;
|
|
37
|
-
declare const BaseButton: React.ForwardRefExoticComponent<(CommonButtonProps & PrivateButtonProps) & React.RefAttributes<HTMLAnchorElement | HTMLButtonElement>>;
|
|
38
|
-
export { SpinnerProps, Spinner, LOADER_MIN_DISPLAY_INTERVAL, BaseButton };
|
|
@@ -1,93 +0,0 @@
|
|
|
1
|
-
import { AnchorHTMLAttributes, ButtonHTMLAttributes, ElementType, ReactNode } from 'react';
|
|
2
|
-
type StyleColors = {
|
|
3
|
-
default: {
|
|
4
|
-
[key: string]: string;
|
|
5
|
-
};
|
|
6
|
-
inverted: {
|
|
7
|
-
[key: string]: string;
|
|
8
|
-
};
|
|
9
|
-
};
|
|
10
|
-
type ComponentProps = {
|
|
11
|
-
/**
|
|
12
|
-
* Тип кнопки
|
|
13
|
-
* @default secondary
|
|
14
|
-
*/
|
|
15
|
-
view?: 'accent' | 'primary' | 'secondary' | 'tertiary' | 'outlined' | 'filled' | 'transparent' | 'link' | 'ghost';
|
|
16
|
-
/**
|
|
17
|
-
* Слот слева
|
|
18
|
-
*/
|
|
19
|
-
leftAddons?: ReactNode;
|
|
20
|
-
/**
|
|
21
|
-
* Слот справа
|
|
22
|
-
*/
|
|
23
|
-
rightAddons?: ReactNode;
|
|
24
|
-
/**
|
|
25
|
-
* Размер компонента
|
|
26
|
-
* @default m
|
|
27
|
-
*/
|
|
28
|
-
size?: 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl';
|
|
29
|
-
/**
|
|
30
|
-
* Растягивает компонент на ширину контейнера
|
|
31
|
-
* @default false
|
|
32
|
-
*/
|
|
33
|
-
block?: boolean;
|
|
34
|
-
/**
|
|
35
|
-
* Дополнительный класс
|
|
36
|
-
*/
|
|
37
|
-
className?: string;
|
|
38
|
-
/**
|
|
39
|
-
* Дополнительный класс для спиннера
|
|
40
|
-
*/
|
|
41
|
-
spinnerClassName?: string;
|
|
42
|
-
/**
|
|
43
|
-
* Выводит ссылку в виде кнопки
|
|
44
|
-
*/
|
|
45
|
-
href?: string;
|
|
46
|
-
/**
|
|
47
|
-
* Позволяет использовать кастомный компонент для кнопки (например Link из роутера)
|
|
48
|
-
*/
|
|
49
|
-
Component?: ElementType;
|
|
50
|
-
/**
|
|
51
|
-
* Идентификатор для систем автоматизированного тестирования
|
|
52
|
-
*/
|
|
53
|
-
dataTestId?: string;
|
|
54
|
-
/**
|
|
55
|
-
* Показать лоадер
|
|
56
|
-
* @default false
|
|
57
|
-
*/
|
|
58
|
-
loading?: boolean;
|
|
59
|
-
/**
|
|
60
|
-
* Не переносить текст кнопки на новую строку
|
|
61
|
-
* @default false
|
|
62
|
-
*/
|
|
63
|
-
nowrap?: boolean;
|
|
64
|
-
/**
|
|
65
|
-
* Набор цветов для компонента
|
|
66
|
-
*/
|
|
67
|
-
colors?: 'default' | 'inverted';
|
|
68
|
-
/**
|
|
69
|
-
* Дочерние элементы.
|
|
70
|
-
*/
|
|
71
|
-
children?: ReactNode;
|
|
72
|
-
};
|
|
73
|
-
type PrivateButtonProps = {
|
|
74
|
-
/**
|
|
75
|
-
* Основные стили компонента.
|
|
76
|
-
*/
|
|
77
|
-
styles: {
|
|
78
|
-
[key: string]: string;
|
|
79
|
-
};
|
|
80
|
-
/**
|
|
81
|
-
* Стили компонента для default и inverted режима.
|
|
82
|
-
*/
|
|
83
|
-
colorStylesMap: StyleColors;
|
|
84
|
-
};
|
|
85
|
-
type CommonButtonProps = ComponentProps & Partial<AnchorHTMLAttributes<HTMLAnchorElement> | ButtonHTMLAttributes<HTMLButtonElement>>;
|
|
86
|
-
type ButtonProps = CommonButtonProps & {
|
|
87
|
-
/**
|
|
88
|
-
* Контрольная точка, с нее начинается desktop версия
|
|
89
|
-
* @default 1024
|
|
90
|
-
*/
|
|
91
|
-
breakpoint?: number;
|
|
92
|
-
};
|
|
93
|
-
export { StyleColors, ComponentProps, PrivateButtonProps, CommonButtonProps, ButtonProps };
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import React from "react";
|
|
3
|
-
import { FC } from "react";
|
|
4
|
-
import { CommonButtonProps, PrivateButtonProps } from "./typings-89f0cb07";
|
|
5
|
-
type SpinnerProps = {
|
|
6
|
-
/**
|
|
7
|
-
* Управление видимостью компонента
|
|
8
|
-
*/
|
|
9
|
-
visible?: boolean;
|
|
10
|
-
/**
|
|
11
|
-
* Размер компонента
|
|
12
|
-
*/
|
|
13
|
-
size?: "xs" | "s" | "m";
|
|
14
|
-
/**
|
|
15
|
-
* Дополнительный класс
|
|
16
|
-
*/
|
|
17
|
-
className?: string;
|
|
18
|
-
/**
|
|
19
|
-
* Идентификатор компонента в DOM
|
|
20
|
-
*/
|
|
21
|
-
id?: string;
|
|
22
|
-
/**
|
|
23
|
-
* Идентификатор для систем автоматизированного тестирования
|
|
24
|
-
*/
|
|
25
|
-
dataTestId?: string;
|
|
26
|
-
/**
|
|
27
|
-
* Палитра, в контексте которой используется спиннер
|
|
28
|
-
*/
|
|
29
|
-
colors?: "default" | "inverted";
|
|
30
|
-
};
|
|
31
|
-
declare const Spinner: FC<SpinnerProps>;
|
|
32
|
-
/**
|
|
33
|
-
* Минимальное время отображения лоадера - 500мс,
|
|
34
|
-
* чтобы при быстрых ответах от сервера кнопка не «моргала».
|
|
35
|
-
*/
|
|
36
|
-
declare const LOADER_MIN_DISPLAY_INTERVAL = 500;
|
|
37
|
-
declare const BaseButton: React.ForwardRefExoticComponent<(CommonButtonProps & PrivateButtonProps) & React.RefAttributes<HTMLAnchorElement | HTMLButtonElement>>;
|
|
38
|
-
export { SpinnerProps, Spinner, LOADER_MIN_DISPLAY_INTERVAL, BaseButton };
|
|
@@ -1,93 +0,0 @@
|
|
|
1
|
-
import { AnchorHTMLAttributes, ButtonHTMLAttributes, ElementType, ReactNode } from 'react';
|
|
2
|
-
type StyleColors = {
|
|
3
|
-
default: {
|
|
4
|
-
[key: string]: string;
|
|
5
|
-
};
|
|
6
|
-
inverted: {
|
|
7
|
-
[key: string]: string;
|
|
8
|
-
};
|
|
9
|
-
};
|
|
10
|
-
type ComponentProps = {
|
|
11
|
-
/**
|
|
12
|
-
* Тип кнопки
|
|
13
|
-
* @default secondary
|
|
14
|
-
*/
|
|
15
|
-
view?: 'accent' | 'primary' | 'secondary' | 'tertiary' | 'outlined' | 'filled' | 'transparent' | 'link' | 'ghost';
|
|
16
|
-
/**
|
|
17
|
-
* Слот слева
|
|
18
|
-
*/
|
|
19
|
-
leftAddons?: ReactNode;
|
|
20
|
-
/**
|
|
21
|
-
* Слот справа
|
|
22
|
-
*/
|
|
23
|
-
rightAddons?: ReactNode;
|
|
24
|
-
/**
|
|
25
|
-
* Размер компонента
|
|
26
|
-
* @default m
|
|
27
|
-
*/
|
|
28
|
-
size?: 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl';
|
|
29
|
-
/**
|
|
30
|
-
* Растягивает компонент на ширину контейнера
|
|
31
|
-
* @default false
|
|
32
|
-
*/
|
|
33
|
-
block?: boolean;
|
|
34
|
-
/**
|
|
35
|
-
* Дополнительный класс
|
|
36
|
-
*/
|
|
37
|
-
className?: string;
|
|
38
|
-
/**
|
|
39
|
-
* Дополнительный класс для спиннера
|
|
40
|
-
*/
|
|
41
|
-
spinnerClassName?: string;
|
|
42
|
-
/**
|
|
43
|
-
* Выводит ссылку в виде кнопки
|
|
44
|
-
*/
|
|
45
|
-
href?: string;
|
|
46
|
-
/**
|
|
47
|
-
* Позволяет использовать кастомный компонент для кнопки (например Link из роутера)
|
|
48
|
-
*/
|
|
49
|
-
Component?: ElementType;
|
|
50
|
-
/**
|
|
51
|
-
* Идентификатор для систем автоматизированного тестирования
|
|
52
|
-
*/
|
|
53
|
-
dataTestId?: string;
|
|
54
|
-
/**
|
|
55
|
-
* Показать лоадер
|
|
56
|
-
* @default false
|
|
57
|
-
*/
|
|
58
|
-
loading?: boolean;
|
|
59
|
-
/**
|
|
60
|
-
* Не переносить текст кнопки на новую строку
|
|
61
|
-
* @default false
|
|
62
|
-
*/
|
|
63
|
-
nowrap?: boolean;
|
|
64
|
-
/**
|
|
65
|
-
* Набор цветов для компонента
|
|
66
|
-
*/
|
|
67
|
-
colors?: 'default' | 'inverted';
|
|
68
|
-
/**
|
|
69
|
-
* Дочерние элементы.
|
|
70
|
-
*/
|
|
71
|
-
children?: ReactNode;
|
|
72
|
-
};
|
|
73
|
-
type PrivateButtonProps = {
|
|
74
|
-
/**
|
|
75
|
-
* Основные стили компонента.
|
|
76
|
-
*/
|
|
77
|
-
styles: {
|
|
78
|
-
[key: string]: string;
|
|
79
|
-
};
|
|
80
|
-
/**
|
|
81
|
-
* Стили компонента для default и inverted режима.
|
|
82
|
-
*/
|
|
83
|
-
colorStylesMap: StyleColors;
|
|
84
|
-
};
|
|
85
|
-
type CommonButtonProps = ComponentProps & Partial<AnchorHTMLAttributes<HTMLAnchorElement> | ButtonHTMLAttributes<HTMLButtonElement>>;
|
|
86
|
-
type ButtonProps = CommonButtonProps & {
|
|
87
|
-
/**
|
|
88
|
-
* Контрольная точка, с нее начинается desktop версия
|
|
89
|
-
* @default 1024
|
|
90
|
-
*/
|
|
91
|
-
breakpoint?: number;
|
|
92
|
-
};
|
|
93
|
-
export { StyleColors, ComponentProps, PrivateButtonProps, CommonButtonProps, ButtonProps };
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import React from "react";
|
|
3
|
-
import { FC } from "react";
|
|
4
|
-
import { CommonButtonProps, PrivateButtonProps } from "./typings-89f0cb07";
|
|
5
|
-
type SpinnerProps = {
|
|
6
|
-
/**
|
|
7
|
-
* Управление видимостью компонента
|
|
8
|
-
*/
|
|
9
|
-
visible?: boolean;
|
|
10
|
-
/**
|
|
11
|
-
* Размер компонента
|
|
12
|
-
*/
|
|
13
|
-
size?: "xs" | "s" | "m";
|
|
14
|
-
/**
|
|
15
|
-
* Дополнительный класс
|
|
16
|
-
*/
|
|
17
|
-
className?: string;
|
|
18
|
-
/**
|
|
19
|
-
* Идентификатор компонента в DOM
|
|
20
|
-
*/
|
|
21
|
-
id?: string;
|
|
22
|
-
/**
|
|
23
|
-
* Идентификатор для систем автоматизированного тестирования
|
|
24
|
-
*/
|
|
25
|
-
dataTestId?: string;
|
|
26
|
-
/**
|
|
27
|
-
* Палитра, в контексте которой используется спиннер
|
|
28
|
-
*/
|
|
29
|
-
colors?: "default" | "inverted";
|
|
30
|
-
};
|
|
31
|
-
declare const Spinner: FC<SpinnerProps>;
|
|
32
|
-
/**
|
|
33
|
-
* Минимальное время отображения лоадера - 500мс,
|
|
34
|
-
* чтобы при быстрых ответах от сервера кнопка не «моргала».
|
|
35
|
-
*/
|
|
36
|
-
declare const LOADER_MIN_DISPLAY_INTERVAL = 500;
|
|
37
|
-
declare const BaseButton: React.ForwardRefExoticComponent<(CommonButtonProps & PrivateButtonProps) & React.RefAttributes<HTMLAnchorElement | HTMLButtonElement>>;
|
|
38
|
-
export { SpinnerProps, Spinner, LOADER_MIN_DISPLAY_INTERVAL, BaseButton };
|
|
@@ -1,93 +0,0 @@
|
|
|
1
|
-
import { AnchorHTMLAttributes, ButtonHTMLAttributes, ElementType, ReactNode } from 'react';
|
|
2
|
-
type StyleColors = {
|
|
3
|
-
default: {
|
|
4
|
-
[key: string]: string;
|
|
5
|
-
};
|
|
6
|
-
inverted: {
|
|
7
|
-
[key: string]: string;
|
|
8
|
-
};
|
|
9
|
-
};
|
|
10
|
-
type ComponentProps = {
|
|
11
|
-
/**
|
|
12
|
-
* Тип кнопки
|
|
13
|
-
* @default secondary
|
|
14
|
-
*/
|
|
15
|
-
view?: 'accent' | 'primary' | 'secondary' | 'tertiary' | 'outlined' | 'filled' | 'transparent' | 'link' | 'ghost';
|
|
16
|
-
/**
|
|
17
|
-
* Слот слева
|
|
18
|
-
*/
|
|
19
|
-
leftAddons?: ReactNode;
|
|
20
|
-
/**
|
|
21
|
-
* Слот справа
|
|
22
|
-
*/
|
|
23
|
-
rightAddons?: ReactNode;
|
|
24
|
-
/**
|
|
25
|
-
* Размер компонента
|
|
26
|
-
* @default m
|
|
27
|
-
*/
|
|
28
|
-
size?: 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl';
|
|
29
|
-
/**
|
|
30
|
-
* Растягивает компонент на ширину контейнера
|
|
31
|
-
* @default false
|
|
32
|
-
*/
|
|
33
|
-
block?: boolean;
|
|
34
|
-
/**
|
|
35
|
-
* Дополнительный класс
|
|
36
|
-
*/
|
|
37
|
-
className?: string;
|
|
38
|
-
/**
|
|
39
|
-
* Дополнительный класс для спиннера
|
|
40
|
-
*/
|
|
41
|
-
spinnerClassName?: string;
|
|
42
|
-
/**
|
|
43
|
-
* Выводит ссылку в виде кнопки
|
|
44
|
-
*/
|
|
45
|
-
href?: string;
|
|
46
|
-
/**
|
|
47
|
-
* Позволяет использовать кастомный компонент для кнопки (например Link из роутера)
|
|
48
|
-
*/
|
|
49
|
-
Component?: ElementType;
|
|
50
|
-
/**
|
|
51
|
-
* Идентификатор для систем автоматизированного тестирования
|
|
52
|
-
*/
|
|
53
|
-
dataTestId?: string;
|
|
54
|
-
/**
|
|
55
|
-
* Показать лоадер
|
|
56
|
-
* @default false
|
|
57
|
-
*/
|
|
58
|
-
loading?: boolean;
|
|
59
|
-
/**
|
|
60
|
-
* Не переносить текст кнопки на новую строку
|
|
61
|
-
* @default false
|
|
62
|
-
*/
|
|
63
|
-
nowrap?: boolean;
|
|
64
|
-
/**
|
|
65
|
-
* Набор цветов для компонента
|
|
66
|
-
*/
|
|
67
|
-
colors?: 'default' | 'inverted';
|
|
68
|
-
/**
|
|
69
|
-
* Дочерние элементы.
|
|
70
|
-
*/
|
|
71
|
-
children?: ReactNode;
|
|
72
|
-
};
|
|
73
|
-
type PrivateButtonProps = {
|
|
74
|
-
/**
|
|
75
|
-
* Основные стили компонента.
|
|
76
|
-
*/
|
|
77
|
-
styles: {
|
|
78
|
-
[key: string]: string;
|
|
79
|
-
};
|
|
80
|
-
/**
|
|
81
|
-
* Стили компонента для default и inverted режима.
|
|
82
|
-
*/
|
|
83
|
-
colorStylesMap: StyleColors;
|
|
84
|
-
};
|
|
85
|
-
type CommonButtonProps = ComponentProps & Partial<AnchorHTMLAttributes<HTMLAnchorElement> | ButtonHTMLAttributes<HTMLButtonElement>>;
|
|
86
|
-
type ButtonProps = CommonButtonProps & {
|
|
87
|
-
/**
|
|
88
|
-
* Контрольная точка, с нее начинается desktop версия
|
|
89
|
-
* @default 1024
|
|
90
|
-
*/
|
|
91
|
-
breakpoint?: number;
|
|
92
|
-
};
|
|
93
|
-
export { StyleColors, ComponentProps, PrivateButtonProps, CommonButtonProps, ButtonProps };
|
package/typings-89f0cb07.d.ts
DELETED
|
@@ -1,93 +0,0 @@
|
|
|
1
|
-
import { AnchorHTMLAttributes, ButtonHTMLAttributes, ElementType, ReactNode } from 'react';
|
|
2
|
-
type StyleColors = {
|
|
3
|
-
default: {
|
|
4
|
-
[key: string]: string;
|
|
5
|
-
};
|
|
6
|
-
inverted: {
|
|
7
|
-
[key: string]: string;
|
|
8
|
-
};
|
|
9
|
-
};
|
|
10
|
-
type ComponentProps = {
|
|
11
|
-
/**
|
|
12
|
-
* Тип кнопки
|
|
13
|
-
* @default secondary
|
|
14
|
-
*/
|
|
15
|
-
view?: 'accent' | 'primary' | 'secondary' | 'tertiary' | 'outlined' | 'filled' | 'transparent' | 'link' | 'ghost';
|
|
16
|
-
/**
|
|
17
|
-
* Слот слева
|
|
18
|
-
*/
|
|
19
|
-
leftAddons?: ReactNode;
|
|
20
|
-
/**
|
|
21
|
-
* Слот справа
|
|
22
|
-
*/
|
|
23
|
-
rightAddons?: ReactNode;
|
|
24
|
-
/**
|
|
25
|
-
* Размер компонента
|
|
26
|
-
* @default m
|
|
27
|
-
*/
|
|
28
|
-
size?: 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl';
|
|
29
|
-
/**
|
|
30
|
-
* Растягивает компонент на ширину контейнера
|
|
31
|
-
* @default false
|
|
32
|
-
*/
|
|
33
|
-
block?: boolean;
|
|
34
|
-
/**
|
|
35
|
-
* Дополнительный класс
|
|
36
|
-
*/
|
|
37
|
-
className?: string;
|
|
38
|
-
/**
|
|
39
|
-
* Дополнительный класс для спиннера
|
|
40
|
-
*/
|
|
41
|
-
spinnerClassName?: string;
|
|
42
|
-
/**
|
|
43
|
-
* Выводит ссылку в виде кнопки
|
|
44
|
-
*/
|
|
45
|
-
href?: string;
|
|
46
|
-
/**
|
|
47
|
-
* Позволяет использовать кастомный компонент для кнопки (например Link из роутера)
|
|
48
|
-
*/
|
|
49
|
-
Component?: ElementType;
|
|
50
|
-
/**
|
|
51
|
-
* Идентификатор для систем автоматизированного тестирования
|
|
52
|
-
*/
|
|
53
|
-
dataTestId?: string;
|
|
54
|
-
/**
|
|
55
|
-
* Показать лоадер
|
|
56
|
-
* @default false
|
|
57
|
-
*/
|
|
58
|
-
loading?: boolean;
|
|
59
|
-
/**
|
|
60
|
-
* Не переносить текст кнопки на новую строку
|
|
61
|
-
* @default false
|
|
62
|
-
*/
|
|
63
|
-
nowrap?: boolean;
|
|
64
|
-
/**
|
|
65
|
-
* Набор цветов для компонента
|
|
66
|
-
*/
|
|
67
|
-
colors?: 'default' | 'inverted';
|
|
68
|
-
/**
|
|
69
|
-
* Дочерние элементы.
|
|
70
|
-
*/
|
|
71
|
-
children?: ReactNode;
|
|
72
|
-
};
|
|
73
|
-
type PrivateButtonProps = {
|
|
74
|
-
/**
|
|
75
|
-
* Основные стили компонента.
|
|
76
|
-
*/
|
|
77
|
-
styles: {
|
|
78
|
-
[key: string]: string;
|
|
79
|
-
};
|
|
80
|
-
/**
|
|
81
|
-
* Стили компонента для default и inverted режима.
|
|
82
|
-
*/
|
|
83
|
-
colorStylesMap: StyleColors;
|
|
84
|
-
};
|
|
85
|
-
type CommonButtonProps = ComponentProps & Partial<AnchorHTMLAttributes<HTMLAnchorElement> | ButtonHTMLAttributes<HTMLButtonElement>>;
|
|
86
|
-
type ButtonProps = CommonButtonProps & {
|
|
87
|
-
/**
|
|
88
|
-
* Контрольная точка, с нее начинается desktop версия
|
|
89
|
-
* @default 1024
|
|
90
|
-
*/
|
|
91
|
-
breakpoint?: number;
|
|
92
|
-
};
|
|
93
|
-
export { StyleColors, ComponentProps, PrivateButtonProps, CommonButtonProps, ButtonProps };
|