@alfalab/core-components-tab-bar 2.0.7 → 2.1.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/Component.js +1 -1
- package/components/tab/Component.js +1 -1
- package/components/tab/index.css +12 -10
- package/cssm/components/tab/index.module.css +4 -2
- package/esm/Component.js +1 -1
- package/esm/components/tab/Component.js +1 -1
- package/esm/components/tab/index.css +12 -10
- package/esm/index.css +5 -5
- package/index.css +5 -5
- package/modern/Component.js +1 -1
- package/modern/components/tab/Component.js +1 -1
- package/modern/components/tab/index.css +12 -10
- package/modern/index.css +5 -5
- package/moderncssm/Component.d.ts +7 -0
- package/moderncssm/Component.js +26 -0
- package/moderncssm/components/tab/Component.d.ts +5 -0
- package/moderncssm/components/tab/Component.js +29 -0
- package/moderncssm/components/tab/index.d.ts +1 -0
- package/moderncssm/components/tab/index.js +1 -0
- package/moderncssm/components/tab/index.module.css +66 -0
- package/moderncssm/consts.d.ts +9 -0
- package/moderncssm/consts.js +10 -0
- package/moderncssm/index.d.ts +2 -0
- package/moderncssm/index.js +1 -0
- package/moderncssm/index.module.css +23 -0
- package/moderncssm/shared/index.d.ts +1 -0
- package/moderncssm/shared/index.js +1 -0
- package/moderncssm/types.d.ts +107 -0
- package/moderncssm/types.js +1 -0
- package/moderncssm/utils.d.ts +5 -0
- package/moderncssm/utils.js +10 -0
- package/package.json +5 -5
- package/src/components/tab/index.module.css +3 -3
- package/src/index.module.css +1 -1
package/Component.js
CHANGED
|
@@ -13,7 +13,7 @@ function _interopDefaultCompat (e) { return e && typeof e === 'object' && 'defau
|
|
|
13
13
|
var React__default = /*#__PURE__*/_interopDefaultCompat(React);
|
|
14
14
|
var cn__default = /*#__PURE__*/_interopDefaultCompat(cn);
|
|
15
15
|
|
|
16
|
-
var styles = {"component":"tab-
|
|
16
|
+
var styles = {"component":"tab-bar__component_1vfmj","modal-bg-primary":"tab-bar__modal-bg-primary_1vfmj","modal-bg-alt-primary":"tab-bar__modal-bg-alt-primary_1vfmj","border":"tab-bar__border_1vfmj"};
|
|
17
17
|
require('./index.css')
|
|
18
18
|
|
|
19
19
|
var TabBarComponent = React.forwardRef(function (_a, ref) {
|
|
@@ -14,7 +14,7 @@ function _interopDefaultCompat (e) { return e && typeof e === 'object' && 'defau
|
|
|
14
14
|
var React__default = /*#__PURE__*/_interopDefaultCompat(React);
|
|
15
15
|
var cn__default = /*#__PURE__*/_interopDefaultCompat(cn);
|
|
16
16
|
|
|
17
|
-
var styles = {"component":"tab-
|
|
17
|
+
var styles = {"component":"tab-bar__component_q3xl2","primary":"tab-bar__primary_q3xl2","secondary":"tab-bar__secondary_q3xl2","icon":"tab-bar__icon_q3xl2","label":"tab-bar__label_q3xl2","labelSelected":"tab-bar__labelSelected_q3xl2","indicator":"tab-bar__indicator_q3xl2"};
|
|
18
18
|
require('./index.css')
|
|
19
19
|
|
|
20
20
|
var TabComponent = React.forwardRef(function (_a, ref) {
|
package/components/tab/index.css
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: 1gdpb */
|
|
2
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
3
|
} /* deprecated */ :root {
|
|
4
4
|
--color-light-accent-primary: #ef3124;
|
|
@@ -22,9 +22,11 @@
|
|
|
22
22
|
--gap-xs: 8px; /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
23
23
|
|
|
24
24
|
/* новые значения, используйте их */
|
|
25
|
+
--gap-4: var(--gap-2xs);
|
|
26
|
+
--gap-8: var(--gap-xs);
|
|
25
27
|
} :root {
|
|
26
28
|
} :root {
|
|
27
|
-
} .tab-
|
|
29
|
+
} .tab-bar__component_q3xl2 {
|
|
28
30
|
box-sizing: border-box;
|
|
29
31
|
background-color: transparent;
|
|
30
32
|
-webkit-tap-highlight-color: transparent;
|
|
@@ -46,19 +48,19 @@
|
|
|
46
48
|
flex-direction: column;
|
|
47
49
|
flex: 1 0 0;
|
|
48
50
|
align-items: center;
|
|
49
|
-
padding: var(--gap-
|
|
51
|
+
padding: var(--gap-8) 0;
|
|
50
52
|
color: var(--color-light-neutral-translucent-700);
|
|
51
|
-
} .tab-
|
|
53
|
+
} .tab-bar__primary_q3xl2 {
|
|
52
54
|
color: var(--color-light-accent-primary);
|
|
53
|
-
} .tab-
|
|
55
|
+
} .tab-bar__secondary_q3xl2 {
|
|
54
56
|
color: var(--color-light-accent-secondary);
|
|
55
|
-
} .tab-
|
|
57
|
+
} .tab-bar__icon_q3xl2 {
|
|
56
58
|
display: flex;
|
|
57
59
|
align-items: center;
|
|
58
60
|
justify-content: center;
|
|
59
61
|
flex-grow: 1;
|
|
60
62
|
width: 100%;
|
|
61
|
-
} .tab-
|
|
63
|
+
} .tab-bar__label_q3xl2 {
|
|
62
64
|
-webkit-line-clamp: 1;
|
|
63
65
|
display: -webkit-box;
|
|
64
66
|
-webkit-box-orient: vertical;
|
|
@@ -67,12 +69,12 @@
|
|
|
67
69
|
flex-shrink: 0;
|
|
68
70
|
|
|
69
71
|
color: var(--color-light-text-secondary);
|
|
70
|
-
} .tab-
|
|
72
|
+
} .tab-bar__labelSelected_q3xl2 {
|
|
71
73
|
color: inherit;
|
|
72
|
-
} .tab-
|
|
74
|
+
} .tab-bar__indicator_q3xl2 {
|
|
73
75
|
position: absolute;
|
|
74
76
|
top: 3px;
|
|
75
|
-
left: calc(50% + var(--gap-
|
|
77
|
+
left: calc(50% + var(--gap-4));
|
|
76
78
|
height: 16px;
|
|
77
79
|
min-width: 16px;
|
|
78
80
|
}
|
|
@@ -21,6 +21,8 @@
|
|
|
21
21
|
--gap-xs: 8px; /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
22
22
|
|
|
23
23
|
/* новые значения, используйте их */
|
|
24
|
+
--gap-4: var(--gap-2xs);
|
|
25
|
+
--gap-8: var(--gap-xs);
|
|
24
26
|
} :root {
|
|
25
27
|
} :root {
|
|
26
28
|
} .component {
|
|
@@ -45,7 +47,7 @@
|
|
|
45
47
|
flex-direction: column;
|
|
46
48
|
flex: 1 0 0;
|
|
47
49
|
align-items: center;
|
|
48
|
-
padding: var(--gap-
|
|
50
|
+
padding: var(--gap-8) 0;
|
|
49
51
|
color: var(--color-light-neutral-translucent-700);
|
|
50
52
|
} .primary {
|
|
51
53
|
color: var(--color-light-accent-primary);
|
|
@@ -71,7 +73,7 @@
|
|
|
71
73
|
} .indicator {
|
|
72
74
|
position: absolute;
|
|
73
75
|
top: 3px;
|
|
74
|
-
left: calc(50% + var(--gap-
|
|
76
|
+
left: calc(50% + var(--gap-4));
|
|
75
77
|
height: 16px;
|
|
76
78
|
min-width: 16px;
|
|
77
79
|
}
|
package/esm/Component.js
CHANGED
|
@@ -4,7 +4,7 @@ import cn from 'classnames';
|
|
|
4
4
|
import { getDataTestId } from '@alfalab/core-components-shared/esm';
|
|
5
5
|
import { Tab } from './components/tab/Component.js';
|
|
6
6
|
|
|
7
|
-
var styles = {"component":"tab-
|
|
7
|
+
var styles = {"component":"tab-bar__component_1vfmj","modal-bg-primary":"tab-bar__modal-bg-primary_1vfmj","modal-bg-alt-primary":"tab-bar__modal-bg-alt-primary_1vfmj","border":"tab-bar__border_1vfmj"};
|
|
8
8
|
require('./index.css')
|
|
9
9
|
|
|
10
10
|
var TabBarComponent = forwardRef(function (_a, ref) {
|
|
@@ -5,7 +5,7 @@ import { Indicator } from '@alfalab/core-components-indicator/esm';
|
|
|
5
5
|
import { Typography } from '@alfalab/core-components-typography/esm';
|
|
6
6
|
import { INDICATOR_BORDER_COLOR, INDICATOR_BG_COLOR } from '../../consts.js';
|
|
7
7
|
|
|
8
|
-
var styles = {"component":"tab-
|
|
8
|
+
var styles = {"component":"tab-bar__component_q3xl2","primary":"tab-bar__primary_q3xl2","secondary":"tab-bar__secondary_q3xl2","icon":"tab-bar__icon_q3xl2","label":"tab-bar__label_q3xl2","labelSelected":"tab-bar__labelSelected_q3xl2","indicator":"tab-bar__indicator_q3xl2"};
|
|
9
9
|
require('./index.css')
|
|
10
10
|
|
|
11
11
|
var TabComponent = forwardRef(function (_a, ref) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: 1gdpb */
|
|
2
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
3
|
} /* deprecated */ :root {
|
|
4
4
|
--color-light-accent-primary: #ef3124;
|
|
@@ -22,9 +22,11 @@
|
|
|
22
22
|
--gap-xs: 8px; /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
23
23
|
|
|
24
24
|
/* новые значения, используйте их */
|
|
25
|
+
--gap-4: var(--gap-2xs);
|
|
26
|
+
--gap-8: var(--gap-xs);
|
|
25
27
|
} :root {
|
|
26
28
|
} :root {
|
|
27
|
-
} .tab-
|
|
29
|
+
} .tab-bar__component_q3xl2 {
|
|
28
30
|
box-sizing: border-box;
|
|
29
31
|
background-color: transparent;
|
|
30
32
|
-webkit-tap-highlight-color: transparent;
|
|
@@ -46,19 +48,19 @@
|
|
|
46
48
|
flex-direction: column;
|
|
47
49
|
flex: 1 0 0;
|
|
48
50
|
align-items: center;
|
|
49
|
-
padding: var(--gap-
|
|
51
|
+
padding: var(--gap-8) 0;
|
|
50
52
|
color: var(--color-light-neutral-translucent-700);
|
|
51
|
-
} .tab-
|
|
53
|
+
} .tab-bar__primary_q3xl2 {
|
|
52
54
|
color: var(--color-light-accent-primary);
|
|
53
|
-
} .tab-
|
|
55
|
+
} .tab-bar__secondary_q3xl2 {
|
|
54
56
|
color: var(--color-light-accent-secondary);
|
|
55
|
-
} .tab-
|
|
57
|
+
} .tab-bar__icon_q3xl2 {
|
|
56
58
|
display: flex;
|
|
57
59
|
align-items: center;
|
|
58
60
|
justify-content: center;
|
|
59
61
|
flex-grow: 1;
|
|
60
62
|
width: 100%;
|
|
61
|
-
} .tab-
|
|
63
|
+
} .tab-bar__label_q3xl2 {
|
|
62
64
|
-webkit-line-clamp: 1;
|
|
63
65
|
display: -webkit-box;
|
|
64
66
|
-webkit-box-orient: vertical;
|
|
@@ -67,12 +69,12 @@
|
|
|
67
69
|
flex-shrink: 0;
|
|
68
70
|
|
|
69
71
|
color: var(--color-light-text-secondary);
|
|
70
|
-
} .tab-
|
|
72
|
+
} .tab-bar__labelSelected_q3xl2 {
|
|
71
73
|
color: inherit;
|
|
72
|
-
} .tab-
|
|
74
|
+
} .tab-bar__indicator_q3xl2 {
|
|
73
75
|
position: absolute;
|
|
74
76
|
top: 3px;
|
|
75
|
-
left: calc(50% + var(--gap-
|
|
77
|
+
left: calc(50% + var(--gap-4));
|
|
76
78
|
height: 16px;
|
|
77
79
|
min-width: 16px;
|
|
78
80
|
}
|
package/esm/index.css
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: fulgz */
|
|
2
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
3
|
} /* deprecated */ :root {
|
|
4
4
|
--color-light-base-bg-alt-primary: #f2f3f5;
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
/* новые значения, используйте их */
|
|
22
22
|
} :root {
|
|
23
23
|
} :root {
|
|
24
|
-
} .tab-
|
|
24
|
+
} .tab-bar__component_1vfmj {
|
|
25
25
|
display: flex;
|
|
26
26
|
justify-content: center;
|
|
27
27
|
height: 64px;
|
|
@@ -29,10 +29,10 @@
|
|
|
29
29
|
box-sizing: border-box;
|
|
30
30
|
overflow: hidden;
|
|
31
31
|
transition: box-shadow 0.2s ease
|
|
32
|
-
} .tab-
|
|
32
|
+
} .tab-bar__component_1vfmj.tab-bar__modal-bg-primary_1vfmj {
|
|
33
33
|
background-color: var(--color-light-base-bg-primary);
|
|
34
|
-
} .tab-
|
|
34
|
+
} .tab-bar__component_1vfmj.tab-bar__modal-bg-alt-primary_1vfmj {
|
|
35
35
|
background-color: var(--color-light-base-bg-alt-primary);
|
|
36
|
-
} .tab-
|
|
36
|
+
} .tab-bar__border_1vfmj {
|
|
37
37
|
box-shadow: 0 -1px 0 0 var(--color-light-neutral-translucent-300);
|
|
38
38
|
}
|
package/index.css
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: fulgz */
|
|
2
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
3
|
} /* deprecated */ :root {
|
|
4
4
|
--color-light-base-bg-alt-primary: #f2f3f5;
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
/* новые значения, используйте их */
|
|
22
22
|
} :root {
|
|
23
23
|
} :root {
|
|
24
|
-
} .tab-
|
|
24
|
+
} .tab-bar__component_1vfmj {
|
|
25
25
|
display: flex;
|
|
26
26
|
justify-content: center;
|
|
27
27
|
height: 64px;
|
|
@@ -29,10 +29,10 @@
|
|
|
29
29
|
box-sizing: border-box;
|
|
30
30
|
overflow: hidden;
|
|
31
31
|
transition: box-shadow 0.2s ease
|
|
32
|
-
} .tab-
|
|
32
|
+
} .tab-bar__component_1vfmj.tab-bar__modal-bg-primary_1vfmj {
|
|
33
33
|
background-color: var(--color-light-base-bg-primary);
|
|
34
|
-
} .tab-
|
|
34
|
+
} .tab-bar__component_1vfmj.tab-bar__modal-bg-alt-primary_1vfmj {
|
|
35
35
|
background-color: var(--color-light-base-bg-alt-primary);
|
|
36
|
-
} .tab-
|
|
36
|
+
} .tab-bar__border_1vfmj {
|
|
37
37
|
box-shadow: 0 -1px 0 0 var(--color-light-neutral-translucent-300);
|
|
38
38
|
}
|
package/modern/Component.js
CHANGED
|
@@ -3,7 +3,7 @@ import cn from 'classnames';
|
|
|
3
3
|
import { getDataTestId } from '@alfalab/core-components-shared/modern';
|
|
4
4
|
import { Tab } from './components/tab/Component.js';
|
|
5
5
|
|
|
6
|
-
const styles = {"component":"tab-
|
|
6
|
+
const styles = {"component":"tab-bar__component_1vfmj","modal-bg-primary":"tab-bar__modal-bg-primary_1vfmj","modal-bg-alt-primary":"tab-bar__modal-bg-alt-primary_1vfmj","border":"tab-bar__border_1vfmj"};
|
|
7
7
|
require('./index.css')
|
|
8
8
|
|
|
9
9
|
const TabBarComponent = forwardRef(({ children, className, selectedId, border, dataTestId, tabClassNames, onChange, accentColor = 'primary', bgColor = 'modal-bg-primary', ...restProps }, ref) => {
|
|
@@ -4,7 +4,7 @@ import { Indicator } from '@alfalab/core-components-indicator/modern';
|
|
|
4
4
|
import { Typography } from '@alfalab/core-components-typography/modern';
|
|
5
5
|
import { INDICATOR_BORDER_COLOR, INDICATOR_BG_COLOR } from '../../consts.js';
|
|
6
6
|
|
|
7
|
-
const styles = {"component":"tab-
|
|
7
|
+
const styles = {"component":"tab-bar__component_q3xl2","primary":"tab-bar__primary_q3xl2","secondary":"tab-bar__secondary_q3xl2","icon":"tab-bar__icon_q3xl2","label":"tab-bar__label_q3xl2","labelSelected":"tab-bar__labelSelected_q3xl2","indicator":"tab-bar__indicator_q3xl2"};
|
|
8
8
|
require('./index.css')
|
|
9
9
|
|
|
10
10
|
const TabComponent = forwardRef(({ showIndicator, indicatorProps, label, icon, id, selected, onChange, onClick, tabClassNames = {}, dataTestId, className, labelClassName, selectedClassName, iconClassName, href, Component = href ? 'a' : 'button', accentColor = 'primary', bgColor = 'modal-bg-primary', ...restProps }, ref) => {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: 1gdpb */
|
|
2
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
3
|
} /* deprecated */ :root {
|
|
4
4
|
--color-light-accent-primary: #ef3124;
|
|
@@ -22,9 +22,11 @@
|
|
|
22
22
|
--gap-xs: 8px; /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
23
23
|
|
|
24
24
|
/* новые значения, используйте их */
|
|
25
|
+
--gap-4: var(--gap-2xs);
|
|
26
|
+
--gap-8: var(--gap-xs);
|
|
25
27
|
} :root {
|
|
26
28
|
} :root {
|
|
27
|
-
} .tab-
|
|
29
|
+
} .tab-bar__component_q3xl2 {
|
|
28
30
|
box-sizing: border-box;
|
|
29
31
|
background-color: transparent;
|
|
30
32
|
-webkit-tap-highlight-color: transparent;
|
|
@@ -46,19 +48,19 @@
|
|
|
46
48
|
flex-direction: column;
|
|
47
49
|
flex: 1 0 0;
|
|
48
50
|
align-items: center;
|
|
49
|
-
padding: var(--gap-
|
|
51
|
+
padding: var(--gap-8) 0;
|
|
50
52
|
color: var(--color-light-neutral-translucent-700);
|
|
51
|
-
} .tab-
|
|
53
|
+
} .tab-bar__primary_q3xl2 {
|
|
52
54
|
color: var(--color-light-accent-primary);
|
|
53
|
-
} .tab-
|
|
55
|
+
} .tab-bar__secondary_q3xl2 {
|
|
54
56
|
color: var(--color-light-accent-secondary);
|
|
55
|
-
} .tab-
|
|
57
|
+
} .tab-bar__icon_q3xl2 {
|
|
56
58
|
display: flex;
|
|
57
59
|
align-items: center;
|
|
58
60
|
justify-content: center;
|
|
59
61
|
flex-grow: 1;
|
|
60
62
|
width: 100%;
|
|
61
|
-
} .tab-
|
|
63
|
+
} .tab-bar__label_q3xl2 {
|
|
62
64
|
-webkit-line-clamp: 1;
|
|
63
65
|
display: -webkit-box;
|
|
64
66
|
-webkit-box-orient: vertical;
|
|
@@ -67,12 +69,12 @@
|
|
|
67
69
|
flex-shrink: 0;
|
|
68
70
|
|
|
69
71
|
color: var(--color-light-text-secondary);
|
|
70
|
-
} .tab-
|
|
72
|
+
} .tab-bar__labelSelected_q3xl2 {
|
|
71
73
|
color: inherit;
|
|
72
|
-
} .tab-
|
|
74
|
+
} .tab-bar__indicator_q3xl2 {
|
|
73
75
|
position: absolute;
|
|
74
76
|
top: 3px;
|
|
75
|
-
left: calc(50% + var(--gap-
|
|
77
|
+
left: calc(50% + var(--gap-4));
|
|
76
78
|
height: 16px;
|
|
77
79
|
min-width: 16px;
|
|
78
80
|
}
|
package/modern/index.css
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: fulgz */
|
|
2
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
3
|
} /* deprecated */ :root {
|
|
4
4
|
--color-light-base-bg-alt-primary: #f2f3f5;
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
/* новые значения, используйте их */
|
|
22
22
|
} :root {
|
|
23
23
|
} :root {
|
|
24
|
-
} .tab-
|
|
24
|
+
} .tab-bar__component_1vfmj {
|
|
25
25
|
display: flex;
|
|
26
26
|
justify-content: center;
|
|
27
27
|
height: 64px;
|
|
@@ -29,10 +29,10 @@
|
|
|
29
29
|
box-sizing: border-box;
|
|
30
30
|
overflow: hidden;
|
|
31
31
|
transition: box-shadow 0.2s ease
|
|
32
|
-
} .tab-
|
|
32
|
+
} .tab-bar__component_1vfmj.tab-bar__modal-bg-primary_1vfmj {
|
|
33
33
|
background-color: var(--color-light-base-bg-primary);
|
|
34
|
-
} .tab-
|
|
34
|
+
} .tab-bar__component_1vfmj.tab-bar__modal-bg-alt-primary_1vfmj {
|
|
35
35
|
background-color: var(--color-light-base-bg-alt-primary);
|
|
36
|
-
} .tab-
|
|
36
|
+
} .tab-bar__border_1vfmj {
|
|
37
37
|
box-shadow: 0 -1px 0 0 var(--color-light-neutral-translucent-300);
|
|
38
38
|
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import { TabBarProps } from "./types";
|
|
4
|
+
declare const TabBar: React.ForwardRefExoticComponent<TabBarProps & React.RefAttributes<HTMLDivElement>> & {
|
|
5
|
+
Tab: React.ForwardRefExoticComponent<import("./types").TabProps & React.RefAttributes<HTMLElement>>;
|
|
6
|
+
};
|
|
7
|
+
export { TabBar };
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import React, { forwardRef, Children, cloneElement } from 'react';
|
|
2
|
+
import cn from 'classnames';
|
|
3
|
+
import { getDataTestId } from '@alfalab/core-components-shared/moderncssm';
|
|
4
|
+
import { Tab } from './components/tab/Component.js';
|
|
5
|
+
import styles from './index.module.css';
|
|
6
|
+
|
|
7
|
+
const TabBarComponent = forwardRef(({ children, className, selectedId, border, dataTestId, tabClassNames, onChange, accentColor = 'primary', bgColor = 'modal-bg-primary', ...restProps }, ref) => {
|
|
8
|
+
if (Children.count(children) > 5) {
|
|
9
|
+
// eslint-disable-next-line no-console
|
|
10
|
+
console.error('Компонент TabBar не может содержать больше 5 табов');
|
|
11
|
+
}
|
|
12
|
+
return (React.createElement("nav", { "data-test-id": dataTestId, ...restProps, ref: ref, className: cn(styles.component, styles[bgColor], className, {
|
|
13
|
+
[styles.border]: border,
|
|
14
|
+
}) }, Children.map(children, (tab) => cloneElement(tab, {
|
|
15
|
+
bgColor,
|
|
16
|
+
accentColor,
|
|
17
|
+
selected: tab.props.id === selectedId,
|
|
18
|
+
onChange,
|
|
19
|
+
tabClassNames,
|
|
20
|
+
dataTestId: getDataTestId(dataTestId, 'tab'),
|
|
21
|
+
}))));
|
|
22
|
+
});
|
|
23
|
+
TabBarComponent.displayName = 'TabBarComponent';
|
|
24
|
+
const TabBar = Object.assign(TabBarComponent, { Tab });
|
|
25
|
+
|
|
26
|
+
export { TabBar };
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import React, { forwardRef, isValidElement, cloneElement } from 'react';
|
|
2
|
+
import cn from 'classnames';
|
|
3
|
+
import { Indicator } from '@alfalab/core-components-indicator/moderncssm';
|
|
4
|
+
import { Typography } from '@alfalab/core-components-typography/moderncssm';
|
|
5
|
+
import { INDICATOR_BORDER_COLOR, INDICATOR_BG_COLOR } from '../../consts.js';
|
|
6
|
+
import styles from './index.module.css';
|
|
7
|
+
|
|
8
|
+
const TabComponent = forwardRef(({ showIndicator, indicatorProps, label, icon, id, selected, onChange, onClick, tabClassNames = {}, dataTestId, className, labelClassName, selectedClassName, iconClassName, href, Component = href ? 'a' : 'button', accentColor = 'primary', bgColor = 'modal-bg-primary', ...restProps }, ref) => {
|
|
9
|
+
const handleClick = (event) => {
|
|
10
|
+
onChange?.(id);
|
|
11
|
+
onClick?.(event);
|
|
12
|
+
};
|
|
13
|
+
const { className: commonClassName, labelClassName: commonLabelClassName, selectedClassName: commonSelectedClassName, iconClassName: commonIconClassName, } = tabClassNames;
|
|
14
|
+
return (React.createElement(Component, { "data-test-id": dataTestId, tabIndex: 0, ...(Component === 'button' ? { type: 'button' } : null), ...restProps, href: href, id: id, ref: ref, className: cn(styles.component, commonClassName, className, selected && commonSelectedClassName, selected && selectedClassName, {
|
|
15
|
+
[styles[accentColor]]: selected,
|
|
16
|
+
}), onClick: handleClick },
|
|
17
|
+
React.createElement("div", { className: cn(styles.icon, commonIconClassName, iconClassName) }, isValidElement(icon) ? cloneElement(icon, { selected }) : icon),
|
|
18
|
+
React.createElement(Typography.Text, { weight: 'medium', view: 'secondary-small', className: cn(styles.label, commonLabelClassName, labelClassName, {
|
|
19
|
+
[styles.labelSelected]: selected,
|
|
20
|
+
}) }, isValidElement(label) ? cloneElement(label, { selected }) : label),
|
|
21
|
+
showIndicator && (React.createElement("div", { className: styles.indicator },
|
|
22
|
+
React.createElement(Indicator, { ...indicatorProps, height: indicatorProps?.value ? 16 : undefined, border: {
|
|
23
|
+
width: 2,
|
|
24
|
+
color: INDICATOR_BORDER_COLOR[bgColor],
|
|
25
|
+
}, backgroundColor: INDICATOR_BG_COLOR[accentColor] })))));
|
|
26
|
+
});
|
|
27
|
+
const Tab = TabComponent;
|
|
28
|
+
|
|
29
|
+
export { Tab };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./Component";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Tab } from './Component.js';
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
/* */
|
|
2
|
+
|
|
3
|
+
.component {
|
|
4
|
+
box-sizing: border-box;
|
|
5
|
+
background-color: transparent;
|
|
6
|
+
-webkit-tap-highlight-color: transparent;
|
|
7
|
+
outline: none;
|
|
8
|
+
border: 0;
|
|
9
|
+
margin: 0;
|
|
10
|
+
box-shadow: none;
|
|
11
|
+
border-radius: 0;
|
|
12
|
+
-webkit-user-select: none;
|
|
13
|
+
user-select: none;
|
|
14
|
+
vertical-align: middle;
|
|
15
|
+
appearance: none;
|
|
16
|
+
text-decoration: none;
|
|
17
|
+
min-width: 0;
|
|
18
|
+
cursor: pointer;
|
|
19
|
+
|
|
20
|
+
position: relative;
|
|
21
|
+
display: inline-flex;
|
|
22
|
+
flex-direction: column;
|
|
23
|
+
flex: 1 0 0;
|
|
24
|
+
align-items: center;
|
|
25
|
+
padding: var(--gap-8) 0;
|
|
26
|
+
color: var(--color-light-neutral-translucent-700);
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
.primary {
|
|
30
|
+
color: var(--color-light-accent-primary);
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
.secondary {
|
|
34
|
+
color: var(--color-light-accent-secondary);
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
.icon {
|
|
38
|
+
display: flex;
|
|
39
|
+
align-items: center;
|
|
40
|
+
justify-content: center;
|
|
41
|
+
flex-grow: 1;
|
|
42
|
+
width: 100%;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
.label {
|
|
46
|
+
-webkit-line-clamp: 1;
|
|
47
|
+
display: -webkit-box;
|
|
48
|
+
-webkit-box-orient: vertical;
|
|
49
|
+
overflow: hidden;
|
|
50
|
+
word-break: break-all;
|
|
51
|
+
flex-shrink: 0;
|
|
52
|
+
|
|
53
|
+
color: var(--color-light-text-secondary);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
.labelSelected {
|
|
57
|
+
color: inherit;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
.indicator {
|
|
61
|
+
position: absolute;
|
|
62
|
+
top: 3px;
|
|
63
|
+
left: calc(50% + var(--gap-4));
|
|
64
|
+
height: 16px;
|
|
65
|
+
min-width: 16px;
|
|
66
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
const INDICATOR_BORDER_COLOR = {
|
|
2
|
+
'modal-bg-primary': 'var(--color-light-base-bg-primary)',
|
|
3
|
+
'modal-bg-alt-primary': 'var(--color-light-base-bg-alt-primary)',
|
|
4
|
+
};
|
|
5
|
+
const INDICATOR_BG_COLOR = {
|
|
6
|
+
primary: 'var(--color-light-accent-primary)',
|
|
7
|
+
secondary: 'var(--color-light-accent-secondary)',
|
|
8
|
+
};
|
|
9
|
+
|
|
10
|
+
export { INDICATOR_BG_COLOR, INDICATOR_BORDER_COLOR };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { TabBar } from './Component.js';
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/* */
|
|
2
|
+
|
|
3
|
+
.component {
|
|
4
|
+
display: flex;
|
|
5
|
+
justify-content: center;
|
|
6
|
+
height: 64px;
|
|
7
|
+
max-height: 64px;
|
|
8
|
+
box-sizing: border-box;
|
|
9
|
+
overflow: hidden;
|
|
10
|
+
transition: box-shadow 0.2s ease
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.component.modal-bg-primary {
|
|
14
|
+
background-color: var(--color-light-base-bg-primary);
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
.component.modal-bg-alt-primary {
|
|
18
|
+
background-color: var(--color-light-base-bg-alt-primary);
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.border {
|
|
22
|
+
box-shadow: 0 -1px 0 0 var(--color-light-neutral-translucent-300);
|
|
23
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { getTabBarTestIds } from "../utils";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { getTabBarTestIds } from '../utils.js';
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
import { AllHTMLAttributes, ElementType, ForwardRefExoticComponent, HTMLAttributes, ReactElement, ReactNode, RefAttributes } from 'react';
|
|
2
|
+
import { IndicatorProps } from "@alfalab/core-components-indicator";
|
|
3
|
+
type TabElementType = ReactElement<TabProps, ForwardRefExoticComponent<TabProps & RefAttributes<HTMLElement>>>;
|
|
4
|
+
interface TabBarProps extends Omit<HTMLAttributes<HTMLDivElement>, 'onChange'> {
|
|
5
|
+
/**
|
|
6
|
+
* Дополнительный класс
|
|
7
|
+
*/
|
|
8
|
+
className?: string;
|
|
9
|
+
/**
|
|
10
|
+
* Идентификатор для систем автоматизированного тестирования.
|
|
11
|
+
* Для таба используется модификатор -tab
|
|
12
|
+
*/
|
|
13
|
+
dataTestId?: string;
|
|
14
|
+
/**
|
|
15
|
+
* Дополнительные классы для таба.
|
|
16
|
+
*/
|
|
17
|
+
tabClassNames?: {
|
|
18
|
+
/**
|
|
19
|
+
* Дополнительный класс таба
|
|
20
|
+
*/
|
|
21
|
+
className?: string;
|
|
22
|
+
/**
|
|
23
|
+
* Дополнительный класс таба в выбранном состоянии
|
|
24
|
+
*/
|
|
25
|
+
selectedClassName?: string;
|
|
26
|
+
/**
|
|
27
|
+
* Дополнительный класс подписи
|
|
28
|
+
*/
|
|
29
|
+
labelClassName?: string;
|
|
30
|
+
/**
|
|
31
|
+
* Дополнительный класс враппера иконки
|
|
32
|
+
*/
|
|
33
|
+
iconClassName?: string;
|
|
34
|
+
};
|
|
35
|
+
/**
|
|
36
|
+
* Список табов
|
|
37
|
+
*/
|
|
38
|
+
children: TabElementType[];
|
|
39
|
+
/**
|
|
40
|
+
* Идентификатор выбранного таба
|
|
41
|
+
*/
|
|
42
|
+
selectedId?: string;
|
|
43
|
+
/**
|
|
44
|
+
* Включает верхний бордер
|
|
45
|
+
*/
|
|
46
|
+
border?: boolean;
|
|
47
|
+
/**
|
|
48
|
+
* Обработчик изменения выбранного таба
|
|
49
|
+
*/
|
|
50
|
+
onChange?: (id: string) => void;
|
|
51
|
+
/**
|
|
52
|
+
* Цвет активного таба
|
|
53
|
+
*/
|
|
54
|
+
accentColor?: 'primary' | 'secondary';
|
|
55
|
+
/**
|
|
56
|
+
* Цвет фона
|
|
57
|
+
*/
|
|
58
|
+
bgColor?: 'modal-bg-primary' | 'modal-bg-alt-primary';
|
|
59
|
+
}
|
|
60
|
+
type AdditionalTabProps = Record<string, unknown>;
|
|
61
|
+
interface TabProps extends Omit<AllHTMLAttributes<unknown>, 'onChange' | 'label'>, AdditionalTabProps {
|
|
62
|
+
/**
|
|
63
|
+
* Кастомный компонент таба.
|
|
64
|
+
* @default button
|
|
65
|
+
*/
|
|
66
|
+
Component?: ElementType;
|
|
67
|
+
/**
|
|
68
|
+
* Идентификатор таба
|
|
69
|
+
*/
|
|
70
|
+
id: string;
|
|
71
|
+
/**
|
|
72
|
+
* Лейбл
|
|
73
|
+
*/
|
|
74
|
+
label: ReactNode;
|
|
75
|
+
/**
|
|
76
|
+
* Иконка
|
|
77
|
+
*/
|
|
78
|
+
icon: ReactNode;
|
|
79
|
+
/**
|
|
80
|
+
* Показать индикатор
|
|
81
|
+
*/
|
|
82
|
+
showIndicator?: boolean;
|
|
83
|
+
/**
|
|
84
|
+
* Свойства индикатора
|
|
85
|
+
*/
|
|
86
|
+
indicatorProps?: Omit<IndicatorProps, 'color' | 'backgroundColor' | 'border' | 'view' | 'size' | 'height'>;
|
|
87
|
+
/**
|
|
88
|
+
* Дополнительный класс таба
|
|
89
|
+
*/
|
|
90
|
+
className?: string;
|
|
91
|
+
/**
|
|
92
|
+
* Дополнительный класс таба в выбранном состоянии
|
|
93
|
+
*/
|
|
94
|
+
selectedClassName?: string;
|
|
95
|
+
/**
|
|
96
|
+
* Дополнительный класс подписи
|
|
97
|
+
*/
|
|
98
|
+
labelClassName?: string;
|
|
99
|
+
/**
|
|
100
|
+
* Дополнительный класс враппера иконки
|
|
101
|
+
*/
|
|
102
|
+
iconClassName?: string;
|
|
103
|
+
}
|
|
104
|
+
interface PrivateTabProps extends Pick<TabBarProps, 'tabClassNames' | 'onChange' | 'dataTestId' | 'accentColor' | 'bgColor'> {
|
|
105
|
+
selected: boolean;
|
|
106
|
+
}
|
|
107
|
+
export { TabBarProps, TabProps, PrivateTabProps };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@alfalab/core-components-tab-bar",
|
|
3
|
-
"version": "2.0
|
|
3
|
+
"version": "2.1.0",
|
|
4
4
|
"description": "",
|
|
5
5
|
"keywords": [],
|
|
6
6
|
"license": "MIT",
|
|
@@ -15,12 +15,12 @@
|
|
|
15
15
|
"react-dom": ">=16.8.0"
|
|
16
16
|
},
|
|
17
17
|
"dependencies": {
|
|
18
|
-
"@alfalab/core-components-typography": "^4.
|
|
19
|
-
"@alfalab/core-components-indicator": "^2.
|
|
18
|
+
"@alfalab/core-components-typography": "^4.10.0",
|
|
19
|
+
"@alfalab/core-components-indicator": "^2.2.0",
|
|
20
20
|
"@alfalab/core-components-shared": "^0.12.0",
|
|
21
21
|
"classnames": "^2.3.1",
|
|
22
22
|
"tslib": "^2.4.0"
|
|
23
23
|
},
|
|
24
|
-
"themesVersion": "13.0
|
|
25
|
-
"varsVersion": "9.
|
|
24
|
+
"themesVersion": "13.1.0",
|
|
25
|
+
"varsVersion": "9.12.0"
|
|
26
26
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
@import '@alfalab/core-components-
|
|
1
|
+
@import '@alfalab/core-components-vars/src/index.css';
|
|
2
2
|
|
|
3
3
|
.component {
|
|
4
4
|
@mixin button-reset;
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
flex-direction: column;
|
|
9
9
|
flex: 1 0 0;
|
|
10
10
|
align-items: center;
|
|
11
|
-
padding: var(--gap-
|
|
11
|
+
padding: var(--gap-8) 0;
|
|
12
12
|
color: var(--color-light-neutral-translucent-700);
|
|
13
13
|
}
|
|
14
14
|
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
.indicator {
|
|
44
44
|
position: absolute;
|
|
45
45
|
top: 3px;
|
|
46
|
-
left: calc(50% + var(--gap-
|
|
46
|
+
left: calc(50% + var(--gap-4));
|
|
47
47
|
height: 16px;
|
|
48
48
|
min-width: 16px;
|
|
49
49
|
}
|
package/src/index.module.css
CHANGED