@alfalab/core-components-tabs 8.0.7 → 8.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/collapsible.d.ts +1 -6
- package/collapsible.js +5 -16
- package/components/primary-tablist/Component.collapsible.d.ts +2 -2
- package/components/primary-tablist/Component.collapsible.js +11 -11
- package/components/primary-tablist/Component.d.ts +2 -2
- package/components/primary-tablist/Component.desktop.js +8 -2
- package/components/primary-tablist/Component.js +8 -2
- package/components/primary-tablist/Component.mobile.js +12 -4
- package/components/primary-tablist/Component.responsive.js +7 -2
- package/components/primary-tablist/index.css +31 -29
- package/components/primary-tablist/mobile.css +34 -32
- package/components/scroll-controls/Component.d.ts +11 -0
- package/components/scroll-controls/Component.js +53 -0
- package/components/scroll-controls/index.css +94 -0
- package/components/scroll-controls/index.d.ts +1 -0
- package/components/scroll-controls/index.js +17 -0
- package/components/scroll-controls/utils.d.ts +7 -0
- package/components/scroll-controls/utils.js +56 -0
- package/components/scrollable-container/Component.d.ts +14 -2
- package/components/scrollable-container/Component.js +45 -8
- package/components/scrollable-container/index.css +10 -6
- package/components/scrollable-container/index.js +7 -0
- package/components/secondary-tablist/Component.d.ts +2 -2
- package/components/secondary-tablist/Component.desktop.js +8 -2
- package/components/secondary-tablist/Component.js +9 -3
- package/components/secondary-tablist/Component.mobile.d.ts +2 -2
- package/components/secondary-tablist/Component.mobile.js +10 -4
- package/components/secondary-tablist/Component.responsive.d.ts +1 -1
- package/components/secondary-tablist/Component.responsive.js +9 -3
- package/components/secondary-tablist/index.css +11 -11
- package/components/secondary-tablist/mobile.css +13 -13
- package/components/tab/Component.js +1 -1
- package/components/tab/index.css +3 -3
- package/components/tabs/Component.collapsible.d.ts +6 -0
- package/components/tabs/{Component.collabsible.desktop.js → Component.collapsible.js} +5 -6
- package/components/tabs/Component.d.ts +1 -1
- package/components/tabs/Component.desktop.js +8 -2
- package/components/tabs/Component.js +2 -2
- package/components/tabs/Component.mobile.d.ts +1 -1
- package/components/tabs/Component.mobile.js +8 -3
- package/components/tabs/Component.responsive.js +8 -3
- package/cssm/collapsible.d.ts +1 -6
- package/cssm/collapsible.js +4 -15
- package/cssm/components/primary-tablist/Component.collapsible.d.ts +2 -2
- package/cssm/components/primary-tablist/Component.collapsible.js +12 -11
- package/cssm/components/primary-tablist/Component.d.ts +2 -2
- package/cssm/components/primary-tablist/Component.desktop.js +8 -1
- package/cssm/components/primary-tablist/Component.js +9 -2
- package/cssm/components/primary-tablist/Component.mobile.js +8 -1
- package/cssm/components/primary-tablist/Component.responsive.js +7 -0
- package/cssm/components/primary-tablist/index.module.css +2 -0
- package/cssm/components/scroll-controls/Component.d.ts +11 -0
- package/cssm/components/scroll-controls/Component.js +52 -0
- package/cssm/components/scroll-controls/index.d.ts +1 -0
- package/cssm/components/scroll-controls/index.js +18 -0
- package/cssm/components/scroll-controls/index.module.css +93 -0
- package/cssm/components/scroll-controls/utils.d.ts +7 -0
- package/cssm/components/scroll-controls/utils.js +56 -0
- package/cssm/components/scrollable-container/Component.d.ts +14 -2
- package/cssm/components/scrollable-container/Component.js +45 -7
- package/cssm/components/scrollable-container/index.js +8 -0
- package/cssm/components/scrollable-container/index.module.css +5 -1
- package/cssm/components/secondary-tablist/Component.d.ts +2 -2
- package/cssm/components/secondary-tablist/Component.desktop.js +8 -1
- package/cssm/components/secondary-tablist/Component.js +10 -3
- package/cssm/components/secondary-tablist/Component.mobile.d.ts +2 -2
- package/cssm/components/secondary-tablist/Component.mobile.js +9 -2
- package/cssm/components/secondary-tablist/Component.responsive.d.ts +1 -1
- package/cssm/components/secondary-tablist/Component.responsive.js +9 -2
- package/cssm/components/tabs/Component.collapsible.d.ts +6 -0
- package/cssm/components/tabs/{Component.collabsible.desktop.js → Component.collapsible.js} +4 -5
- package/cssm/components/tabs/Component.d.ts +1 -1
- package/cssm/components/tabs/Component.desktop.js +7 -0
- package/cssm/components/tabs/Component.js +2 -2
- package/cssm/components/tabs/Component.mobile.d.ts +1 -1
- package/cssm/components/tabs/Component.mobile.js +7 -0
- package/cssm/components/tabs/Component.responsive.js +7 -0
- package/cssm/desktop.js +7 -0
- package/cssm/index-c76d6398.d.ts +0 -1
- package/cssm/index-f12ee135.d.ts +6 -2
- package/cssm/index.js +7 -0
- package/cssm/mobile.js +7 -0
- package/cssm/shared.js +8 -1
- package/cssm/typings.d.ts +13 -2
- package/desktop.js +8 -2
- package/esm/collapsible.d.ts +1 -6
- package/esm/collapsible.js +4 -10
- package/esm/components/primary-tablist/Component.collapsible.d.ts +2 -2
- package/esm/components/primary-tablist/Component.collapsible.js +11 -11
- package/esm/components/primary-tablist/Component.d.ts +2 -2
- package/esm/components/primary-tablist/Component.desktop.js +8 -2
- package/esm/components/primary-tablist/Component.js +8 -2
- package/esm/components/primary-tablist/Component.mobile.js +11 -3
- package/esm/components/primary-tablist/Component.responsive.js +7 -2
- package/esm/components/primary-tablist/index.css +31 -29
- package/esm/components/primary-tablist/mobile.css +34 -32
- package/esm/components/scroll-controls/Component.d.ts +11 -0
- package/esm/components/scroll-controls/Component.js +43 -0
- package/esm/components/scroll-controls/index.css +94 -0
- package/esm/components/scroll-controls/index.d.ts +1 -0
- package/esm/components/scroll-controls/index.js +9 -0
- package/esm/components/scroll-controls/utils.d.ts +7 -0
- package/esm/components/scroll-controls/utils.js +50 -0
- package/esm/components/scrollable-container/Component.d.ts +14 -2
- package/esm/components/scrollable-container/Component.js +46 -9
- package/esm/components/scrollable-container/index.css +10 -6
- package/esm/components/scrollable-container/index.js +7 -0
- package/esm/components/secondary-tablist/Component.d.ts +2 -2
- package/esm/components/secondary-tablist/Component.desktop.js +8 -2
- package/esm/components/secondary-tablist/Component.js +9 -3
- package/esm/components/secondary-tablist/Component.mobile.d.ts +2 -2
- package/esm/components/secondary-tablist/Component.mobile.js +10 -4
- package/esm/components/secondary-tablist/Component.responsive.d.ts +1 -1
- package/esm/components/secondary-tablist/Component.responsive.js +9 -3
- package/esm/components/secondary-tablist/index.css +11 -11
- package/esm/components/secondary-tablist/mobile.css +13 -13
- package/esm/components/tab/Component.js +1 -1
- package/esm/components/tab/index.css +3 -3
- package/esm/components/tabs/Component.collapsible.d.ts +6 -0
- package/esm/components/tabs/{Component.collabsible.desktop.js → Component.collapsible.js} +5 -6
- package/esm/components/tabs/Component.d.ts +1 -1
- package/esm/components/tabs/Component.desktop.js +8 -2
- package/esm/components/tabs/Component.js +2 -2
- package/esm/components/tabs/Component.mobile.d.ts +1 -1
- package/esm/components/tabs/Component.mobile.js +8 -3
- package/esm/components/tabs/Component.responsive.js +8 -3
- package/esm/desktop.js +8 -2
- package/esm/index-c76d6398.d.ts +0 -1
- package/esm/index-f12ee135.d.ts +6 -2
- package/esm/index.js +8 -3
- package/esm/index.module-7fe2e8dc.js +4 -0
- package/esm/index.module-fbff2d78.js +4 -0
- package/esm/mobile.js +8 -3
- package/esm/shared.js +7 -1
- package/esm/typings.d.ts +13 -2
- package/index-c76d6398.d.ts +0 -1
- package/index-f12ee135.d.ts +6 -2
- package/index.js +8 -3
- package/index.module-447ba3e0.js +6 -0
- package/index.module-ee99c069.js +6 -0
- package/mobile.js +8 -3
- package/modern/collapsible.d.ts +1 -6
- package/modern/collapsible.js +4 -10
- package/modern/components/primary-tablist/Component.collapsible.d.ts +2 -2
- package/modern/components/primary-tablist/Component.collapsible.js +11 -11
- package/modern/components/primary-tablist/Component.d.ts +2 -2
- package/modern/components/primary-tablist/Component.desktop.js +8 -2
- package/modern/components/primary-tablist/Component.js +8 -2
- package/modern/components/primary-tablist/Component.mobile.js +11 -3
- package/modern/components/primary-tablist/Component.responsive.js +7 -2
- package/modern/components/primary-tablist/index.css +31 -29
- package/modern/components/primary-tablist/mobile.css +34 -32
- package/modern/components/scroll-controls/Component.d.ts +11 -0
- package/modern/components/scroll-controls/Component.js +40 -0
- package/modern/components/scroll-controls/index.css +94 -0
- package/modern/components/scroll-controls/index.d.ts +1 -0
- package/modern/components/scroll-controls/index.js +8 -0
- package/modern/components/scroll-controls/utils.d.ts +7 -0
- package/modern/components/scroll-controls/utils.js +50 -0
- package/modern/components/scrollable-container/Component.d.ts +14 -2
- package/modern/components/scrollable-container/Component.js +44 -9
- package/modern/components/scrollable-container/index.css +10 -6
- package/modern/components/scrollable-container/index.js +6 -0
- package/modern/components/secondary-tablist/Component.d.ts +2 -2
- package/modern/components/secondary-tablist/Component.desktop.js +8 -2
- package/modern/components/secondary-tablist/Component.js +9 -3
- package/modern/components/secondary-tablist/Component.mobile.d.ts +2 -2
- package/modern/components/secondary-tablist/Component.mobile.js +9 -3
- package/modern/components/secondary-tablist/Component.responsive.d.ts +1 -1
- package/modern/components/secondary-tablist/Component.responsive.js +9 -3
- package/modern/components/secondary-tablist/index.css +11 -11
- package/modern/components/secondary-tablist/mobile.css +13 -13
- package/modern/components/tab/Component.js +1 -1
- package/modern/components/tab/index.css +3 -3
- package/modern/components/tabs/Component.collapsible.d.ts +6 -0
- package/modern/components/tabs/{Component.collabsible.desktop.js → Component.collapsible.js} +4 -5
- package/modern/components/tabs/Component.d.ts +1 -1
- package/modern/components/tabs/Component.desktop.js +8 -2
- package/modern/components/tabs/Component.js +2 -2
- package/modern/components/tabs/Component.mobile.d.ts +1 -1
- package/modern/components/tabs/Component.mobile.js +8 -3
- package/modern/components/tabs/Component.responsive.js +8 -3
- package/modern/desktop.js +8 -2
- package/modern/index-c76d6398.d.ts +0 -1
- package/modern/index-f12ee135.d.ts +6 -2
- package/modern/index.js +8 -3
- package/modern/index.module-22ff4191.js +4 -0
- package/modern/index.module-3f8f9d5d.js +4 -0
- package/modern/mobile.js +8 -3
- package/modern/shared.js +6 -0
- package/modern/typings.d.ts +13 -2
- package/package.json +5 -2
- package/shared.js +7 -1
- package/src/collapsible.ts +1 -9
- package/src/components/primary-tablist/Component.collapsible.tsx +6 -7
- package/src/components/primary-tablist/Component.desktop.tsx +1 -1
- package/src/components/primary-tablist/Component.mobile.tsx +6 -1
- package/src/components/primary-tablist/Component.tsx +6 -2
- package/src/components/primary-tablist/index.module.css +4 -0
- package/src/components/scroll-controls/Component.tsx +78 -0
- package/src/components/scroll-controls/index.module.css +68 -0
- package/src/components/scroll-controls/index.ts +1 -0
- package/src/components/scroll-controls/utils.ts +60 -0
- package/src/components/scrollable-container/Component.tsx +81 -12
- package/src/components/scrollable-container/index.module.css +7 -1
- package/src/components/secondary-tablist/Component.desktop.tsx +1 -0
- package/src/components/secondary-tablist/Component.mobile.tsx +4 -2
- package/src/components/secondary-tablist/Component.responsive.tsx +1 -2
- package/src/components/secondary-tablist/Component.tsx +10 -2
- package/src/components/tabs/Component.collapsible.tsx +15 -0
- package/src/components/tabs/Component.mobile.tsx +1 -1
- package/src/components/tabs/Component.tsx +4 -0
- package/src/typings.ts +16 -0
- package/typings.d.ts +13 -2
- package/components/primary-tablist/Component.collapsible.desktop.d.ts +0 -5
- package/components/primary-tablist/Component.collapsible.desktop.js +0 -32
- package/components/primary-tablist/Component.collapsible.mobile.d.ts +0 -6
- package/components/primary-tablist/Component.collapsible.mobile.js +0 -35
- package/components/primary-tablist/Component.collapsible.responsive.d.ts +0 -5
- package/components/primary-tablist/Component.collapsible.responsive.js +0 -36
- package/components/tabs/Component.collabsible.desktop.d.ts +0 -6
- package/components/tabs/Component.collapsible.mobile.d.ts +0 -6
- package/components/tabs/Component.collapsible.mobile.js +0 -35
- package/components/tabs/Component.collapsible.responsive.d.ts +0 -6
- package/components/tabs/Component.collapsible.responsive.js +0 -37
- package/cssm/components/primary-tablist/Component.collapsible.desktop.d.ts +0 -5
- package/cssm/components/primary-tablist/Component.collapsible.desktop.js +0 -33
- package/cssm/components/primary-tablist/Component.collapsible.mobile.d.ts +0 -6
- package/cssm/components/primary-tablist/Component.collapsible.mobile.js +0 -37
- package/cssm/components/primary-tablist/Component.collapsible.responsive.d.ts +0 -5
- package/cssm/components/primary-tablist/Component.collapsible.responsive.js +0 -36
- package/cssm/components/tabs/Component.collabsible.desktop.d.ts +0 -6
- package/cssm/components/tabs/Component.collapsible.mobile.d.ts +0 -6
- package/cssm/components/tabs/Component.collapsible.mobile.js +0 -35
- package/cssm/components/tabs/Component.collapsible.responsive.d.ts +0 -6
- package/cssm/components/tabs/Component.collapsible.responsive.js +0 -37
- package/esm/components/primary-tablist/Component.collapsible.desktop.d.ts +0 -5
- package/esm/components/primary-tablist/Component.collapsible.desktop.js +0 -24
- package/esm/components/primary-tablist/Component.collapsible.mobile.d.ts +0 -6
- package/esm/components/primary-tablist/Component.collapsible.mobile.js +0 -26
- package/esm/components/primary-tablist/Component.collapsible.responsive.d.ts +0 -5
- package/esm/components/primary-tablist/Component.collapsible.responsive.js +0 -28
- package/esm/components/tabs/Component.collabsible.desktop.d.ts +0 -6
- package/esm/components/tabs/Component.collapsible.mobile.d.ts +0 -6
- package/esm/components/tabs/Component.collapsible.mobile.js +0 -27
- package/esm/components/tabs/Component.collapsible.responsive.d.ts +0 -6
- package/esm/components/tabs/Component.collapsible.responsive.js +0 -29
- package/esm/index.module-07ecf2f2.js +0 -4
- package/esm/index.module-bf43c7e6.js +0 -4
- package/esm/mobile.module-28188e8d.js +0 -4
- package/index.module-3691700d.js +0 -6
- package/index.module-dce6bd4b.js +0 -6
- package/mobile.module-e4053729.js +0 -6
- package/modern/components/primary-tablist/Component.collapsible.desktop.d.ts +0 -5
- package/modern/components/primary-tablist/Component.collapsible.desktop.js +0 -20
- package/modern/components/primary-tablist/Component.collapsible.mobile.d.ts +0 -6
- package/modern/components/primary-tablist/Component.collapsible.mobile.js +0 -25
- package/modern/components/primary-tablist/Component.collapsible.responsive.d.ts +0 -5
- package/modern/components/primary-tablist/Component.collapsible.responsive.js +0 -26
- package/modern/components/tabs/Component.collabsible.desktop.d.ts +0 -6
- package/modern/components/tabs/Component.collapsible.mobile.d.ts +0 -6
- package/modern/components/tabs/Component.collapsible.mobile.js +0 -23
- package/modern/components/tabs/Component.collapsible.responsive.d.ts +0 -6
- package/modern/components/tabs/Component.collapsible.responsive.js +0 -25
- package/modern/index.module-2a3e44bc.js +0 -4
- package/modern/index.module-5aa4033e.js +0 -4
- package/modern/mobile.module-47eb0ef0.js +0 -4
- package/src/components/primary-tablist/Component.collapsible.desktop.tsx +0 -11
- package/src/components/primary-tablist/Component.collapsible.mobile.tsx +0 -27
- package/src/components/primary-tablist/Component.collapsible.responsive.tsx +0 -34
- package/src/components/tabs/Component.collabsible.desktop.tsx +0 -15
- package/src/components/tabs/Component.collapsible.mobile.tsx +0 -15
- package/src/components/tabs/Component.collapsible.responsive.tsx +0 -12
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: 1kolo */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :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 */
|
|
4
4
|
} :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 */
|
|
@@ -42,20 +42,24 @@
|
|
|
42
42
|
/* size l */
|
|
43
43
|
|
|
44
44
|
/* size xl */
|
|
45
|
-
} .
|
|
45
|
+
} .tabs__scrollableContainerWrapper_v4p4z {
|
|
46
|
+
display: flex;
|
|
47
|
+
} .tabs__container_v4p4z {
|
|
46
48
|
position: relative;
|
|
47
49
|
overflow-x: auto;
|
|
48
50
|
overflow-y: hidden;
|
|
49
51
|
scroll-behavior: smooth;
|
|
50
52
|
scrollbar-width: none;
|
|
53
|
+
flex: 1;
|
|
51
54
|
|
|
52
55
|
/* focus-outline fix */
|
|
53
56
|
margin: var(--gap-2xs-neg) 0 var(--gap-2xs-neg) var(--gap-2xs-neg);
|
|
54
57
|
padding: var(--gap-2xs) 0 var(--gap-2xs) var(--gap-2xs)
|
|
55
|
-
} .
|
|
58
|
+
} .tabs__container_v4p4z::-webkit-scrollbar {
|
|
56
59
|
display: none;
|
|
57
|
-
} .
|
|
60
|
+
} .tabs__container_v4p4z > * {
|
|
58
61
|
flex-shrink: 0;
|
|
59
|
-
} .
|
|
60
|
-
|
|
62
|
+
} .tabs__fullWidthScroll_v4p4z {
|
|
63
|
+
padding-left: 0;
|
|
64
|
+
margin: var(--gap-2xs-neg) var(--gap-m-neg);
|
|
61
65
|
}
|
|
@@ -2,3 +2,9 @@ export { ScrollableContainer } from './Component.js';
|
|
|
2
2
|
import 'react';
|
|
3
3
|
import 'classnames';
|
|
4
4
|
import 'compute-scroll-into-view';
|
|
5
|
+
import '../scroll-controls/Component.js';
|
|
6
|
+
import 'lodash.debounce';
|
|
7
|
+
import '@alfalab/core-components-icon-button/modern';
|
|
8
|
+
import '@alfalab/icons-glyph/ChevronLeftMIcon';
|
|
9
|
+
import '@alfalab/icons-glyph/ChevronRightMIcon';
|
|
10
|
+
import '../scroll-controls/utils.js';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import { SecondaryTabListProps, Styles } from "../../typings";
|
|
4
|
-
declare const SecondaryTabList: ({ styles, className, containerClassName, size, titles, selectedId, scrollable, fullWidthScroll, tagSize, onChange, dataTestId, TagComponent, }: SecondaryTabListProps & Styles) => React.JSX.Element;
|
|
3
|
+
import { PlatformProps, SecondaryTabListProps, Styles } from "../../typings";
|
|
4
|
+
declare const SecondaryTabList: ({ styles, className, containerClassName, size, titles, selectedId, scrollable, fullWidthScroll, tagSize, onChange, dataTestId, TagComponent, platform, tagShape, tagView, }: SecondaryTabListProps & Styles & PlatformProps) => React.JSX.Element;
|
|
5
5
|
export { SecondaryTabList };
|
|
@@ -1,13 +1,19 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { TagDesktop } from '@alfalab/core-components-tag/modern/desktop';
|
|
3
3
|
import { SecondaryTabList } from './Component.js';
|
|
4
|
-
import { c as commonStyles } from '../../index.module-
|
|
4
|
+
import { c as commonStyles } from '../../index.module-3f8f9d5d.js';
|
|
5
5
|
import 'classnames';
|
|
6
6
|
import '../../hooks/use-tabs.js';
|
|
7
7
|
import '@alfalab/core-components-shared/modern';
|
|
8
8
|
import '../scrollable-container/Component.js';
|
|
9
9
|
import 'compute-scroll-into-view';
|
|
10
|
+
import '../scroll-controls/Component.js';
|
|
11
|
+
import 'lodash.debounce';
|
|
12
|
+
import '@alfalab/core-components-icon-button/modern';
|
|
13
|
+
import '@alfalab/icons-glyph/ChevronLeftMIcon';
|
|
14
|
+
import '@alfalab/icons-glyph/ChevronRightMIcon';
|
|
15
|
+
import '../scroll-controls/utils.js';
|
|
10
16
|
|
|
11
|
-
const SecondaryTabListDesktop = ({ size = 's', ...restProps }) => (React.createElement(SecondaryTabList, { ...restProps, TagComponent: TagDesktop, size: size, styles: commonStyles, tagSize: size }));
|
|
17
|
+
const SecondaryTabListDesktop = ({ size = 's', ...restProps }) => (React.createElement(SecondaryTabList, { ...restProps, TagComponent: TagDesktop, size: size, styles: commonStyles, tagSize: size, platform: 'desktop' }));
|
|
12
18
|
|
|
13
19
|
export { SecondaryTabListDesktop };
|
|
@@ -4,8 +4,14 @@ import { useTabs } from '../../hooks/use-tabs.js';
|
|
|
4
4
|
import { ScrollableContainer } from '../scrollable-container/Component.js';
|
|
5
5
|
import '@alfalab/core-components-shared/modern';
|
|
6
6
|
import 'compute-scroll-into-view';
|
|
7
|
+
import '../scroll-controls/Component.js';
|
|
8
|
+
import 'lodash.debounce';
|
|
9
|
+
import '@alfalab/core-components-icon-button/modern';
|
|
10
|
+
import '@alfalab/icons-glyph/ChevronLeftMIcon';
|
|
11
|
+
import '@alfalab/icons-glyph/ChevronRightMIcon';
|
|
12
|
+
import '../scroll-controls/utils.js';
|
|
7
13
|
|
|
8
|
-
const SecondaryTabList = ({ styles = {}, className, containerClassName, size, titles = [], selectedId = titles.length ? titles[0].id : undefined, scrollable = true, fullWidthScroll, tagSize = 'xs', onChange, dataTestId, TagComponent, }) => {
|
|
14
|
+
const SecondaryTabList = ({ styles = {}, className, containerClassName, size, titles = [], selectedId = titles.length ? titles[0].id : undefined, scrollable = true, fullWidthScroll, tagSize = 'xs', onChange, dataTestId, TagComponent, platform, tagShape, tagView, }) => {
|
|
9
15
|
const { focusedTab, selectedTab, getTabListItemProps } = useTabs({
|
|
10
16
|
titles,
|
|
11
17
|
selectedId,
|
|
@@ -19,10 +25,10 @@ const SecondaryTabList = ({ styles = {}, className, containerClassName, size, ti
|
|
|
19
25
|
}) }, titles.map((item, index) => {
|
|
20
26
|
if (item.hidden)
|
|
21
27
|
return null;
|
|
22
|
-
return (React.createElement(TagComponent, { ...getTabListItemProps(index), key: item.id, className: cn(styles.title, item.toggleClassName), checked: item.id === selectedId, size: tagSize, rightAddons: item.rightAddons }, item.title));
|
|
28
|
+
return (React.createElement(TagComponent, { ...getTabListItemProps(index), shape: tagShape, view: tagView, key: item.id, className: cn(styles.title, item.toggleClassName), checked: item.id === selectedId, size: tagSize, rightAddons: item.rightAddons }, item.title));
|
|
23
29
|
})));
|
|
24
30
|
};
|
|
25
|
-
return scrollable ? (React.createElement(ScrollableContainer, { activeChild: focusedTab || selectedTab, containerClassName: containerClassName, fullWidthScroll: fullWidthScroll }, renderContent())) : (React.createElement("div", { className: cn(styles.container, containerClassName) }, renderContent()));
|
|
31
|
+
return scrollable ? (React.createElement(ScrollableContainer, { activeChild: focusedTab || selectedTab, containerClassName: containerClassName, fullWidthScroll: fullWidthScroll, view: 'secondary', size: size, platform: platform }, renderContent())) : (React.createElement("div", { className: cn(styles.container, containerClassName) }, renderContent()));
|
|
26
32
|
};
|
|
27
33
|
|
|
28
34
|
export { SecondaryTabList };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { SecondaryTabListProps } from "../../typings";
|
|
4
|
-
type SecondaryTabListMobileProps = Omit<SecondaryTabListProps, '
|
|
5
|
-
declare const SecondaryTabListMobile: ({ className, ...restProps }: SecondaryTabListMobileProps) => React.JSX.Element;
|
|
4
|
+
type SecondaryTabListMobileProps = Omit<SecondaryTabListProps, 'tagSize'>;
|
|
5
|
+
declare const SecondaryTabListMobile: ({ className, size, ...restProps }: SecondaryTabListMobileProps) => React.JSX.Element;
|
|
6
6
|
export { SecondaryTabListMobileProps, SecondaryTabListMobile };
|
|
@@ -2,19 +2,25 @@ import React from 'react';
|
|
|
2
2
|
import cn from 'classnames';
|
|
3
3
|
import { TagMobile } from '@alfalab/core-components-tag/modern/mobile';
|
|
4
4
|
import { SecondaryTabList } from './Component.js';
|
|
5
|
-
import { c as commonStyles } from '../../index.module-
|
|
5
|
+
import { c as commonStyles } from '../../index.module-3f8f9d5d.js';
|
|
6
6
|
import '../../hooks/use-tabs.js';
|
|
7
7
|
import '@alfalab/core-components-shared/modern';
|
|
8
8
|
import '../scrollable-container/Component.js';
|
|
9
9
|
import 'compute-scroll-into-view';
|
|
10
|
+
import '../scroll-controls/Component.js';
|
|
11
|
+
import 'lodash.debounce';
|
|
12
|
+
import '@alfalab/core-components-icon-button/modern';
|
|
13
|
+
import '@alfalab/icons-glyph/ChevronLeftMIcon';
|
|
14
|
+
import '@alfalab/icons-glyph/ChevronRightMIcon';
|
|
15
|
+
import '../scroll-controls/utils.js';
|
|
10
16
|
|
|
11
|
-
const mobileStyles = {"title":"
|
|
17
|
+
const mobileStyles = {"title":"tabs__title_1889x tabs__title_tc0jp","mobile":"tabs__mobile_1889x"};
|
|
12
18
|
require('./mobile.css')
|
|
13
19
|
|
|
14
20
|
const styles = {
|
|
15
21
|
...commonStyles,
|
|
16
22
|
...mobileStyles,
|
|
17
23
|
};
|
|
18
|
-
const SecondaryTabListMobile = ({ className, ...restProps }) => (React.createElement(SecondaryTabList, { ...restProps, TagComponent: TagMobile, styles: styles, className: cn(className, styles.mobile), tagSize: '
|
|
24
|
+
const SecondaryTabListMobile = ({ className, size, ...restProps }) => (React.createElement(SecondaryTabList, { ...restProps, TagComponent: TagMobile, styles: styles, className: cn(className, styles.mobile), tagSize: size, platform: 'mobile' }));
|
|
19
25
|
|
|
20
26
|
export { SecondaryTabListMobile };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { SecondaryTabListProps } from "../../typings";
|
|
4
|
-
declare const SecondaryTabListResponsive: ({
|
|
4
|
+
declare const SecondaryTabListResponsive: ({ defaultMatchMediaValue, fullWidthScroll, breakpoint, ...restProps }: SecondaryTabListProps) => React.JSX.Element;
|
|
5
5
|
export { SecondaryTabListResponsive };
|
|
@@ -9,12 +9,18 @@ import '../../hooks/use-tabs.js';
|
|
|
9
9
|
import '@alfalab/core-components-shared/modern';
|
|
10
10
|
import '../scrollable-container/Component.js';
|
|
11
11
|
import 'compute-scroll-into-view';
|
|
12
|
-
import '
|
|
12
|
+
import '../scroll-controls/Component.js';
|
|
13
|
+
import 'lodash.debounce';
|
|
14
|
+
import '@alfalab/core-components-icon-button/modern';
|
|
15
|
+
import '@alfalab/icons-glyph/ChevronLeftMIcon';
|
|
16
|
+
import '@alfalab/icons-glyph/ChevronRightMIcon';
|
|
17
|
+
import '../scroll-controls/utils.js';
|
|
18
|
+
import '../../index.module-3f8f9d5d.js';
|
|
13
19
|
import '@alfalab/core-components-tag/modern/mobile';
|
|
14
20
|
|
|
15
|
-
const SecondaryTabListResponsive = ({
|
|
21
|
+
const SecondaryTabListResponsive = ({ defaultMatchMediaValue, fullWidthScroll, breakpoint = 1024, ...restProps }) => {
|
|
16
22
|
const [isDesktop] = useMatchMedia(`(min-width: ${breakpoint}px)`, defaultMatchMediaValue);
|
|
17
|
-
return isDesktop ? (React.createElement(SecondaryTabListDesktop, {
|
|
23
|
+
return isDesktop ? (React.createElement(SecondaryTabListDesktop, { ...restProps })) : (React.createElement(SecondaryTabListMobile, { fullWidthScroll: fullWidthScroll, ...restProps }));
|
|
18
24
|
};
|
|
19
25
|
|
|
20
26
|
export { SecondaryTabListResponsive };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: 3thre */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :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 */
|
|
4
4
|
} :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 */
|
|
@@ -50,29 +50,29 @@
|
|
|
50
50
|
|
|
51
51
|
/* size xl */
|
|
52
52
|
--secondary-tablist-xl-gaps: var(--gap-m);
|
|
53
|
-
} .
|
|
53
|
+
} .tabs__component_tc0jp {
|
|
54
54
|
position: relative;
|
|
55
55
|
display: inline-flex;
|
|
56
|
-
} .
|
|
56
|
+
} .tabs__fullWidthScroll_tc0jp {
|
|
57
57
|
margin: 0 var(--gap-m);
|
|
58
|
-
} .
|
|
58
|
+
} .tabs__container_tc0jp {
|
|
59
59
|
overflow: hidden;
|
|
60
60
|
|
|
61
61
|
/* focus-outline fix */
|
|
62
62
|
margin: var(--gap-2xs-neg) 0 var(--gap-2xs-neg) var(--gap-2xs-neg);
|
|
63
63
|
padding: var(--gap-2xs) 0 var(--gap-2xs) var(--gap-2xs);
|
|
64
|
-
} .
|
|
64
|
+
} .tabs__title_tc0jp {
|
|
65
65
|
white-space: nowrap;
|
|
66
|
-
} /* sizes */ .
|
|
66
|
+
} /* sizes */ .tabs__xxs_tc0jp .tabs__title_tc0jp + .tabs__title_tc0jp {
|
|
67
67
|
margin-left: var(--secondary-tablist-xxs-gaps);
|
|
68
|
-
} .
|
|
68
|
+
} .tabs__xs_tc0jp .tabs__title_tc0jp + .tabs__title_tc0jp {
|
|
69
69
|
margin-left: var(--secondary-tablist-xs-gaps);
|
|
70
|
-
} .
|
|
70
|
+
} .tabs__s_tc0jp .tabs__title_tc0jp + .tabs__title_tc0jp {
|
|
71
71
|
margin-left: var(--secondary-tablist-s-gaps);
|
|
72
|
-
} .
|
|
72
|
+
} .tabs__m_tc0jp .tabs__title_tc0jp + .tabs__title_tc0jp {
|
|
73
73
|
margin-left: var(--secondary-tablist-m-gaps);
|
|
74
|
-
} .
|
|
74
|
+
} .tabs__l_tc0jp .tabs__title_tc0jp + .tabs__title_tc0jp {
|
|
75
75
|
margin-left: var(--secondary-tablist-l-gaps);
|
|
76
|
-
} .
|
|
76
|
+
} .tabs__xl_tc0jp .tabs__title_tc0jp + .tabs__title_tc0jp {
|
|
77
77
|
margin-left: var(--secondary-tablist-xl-gaps);
|
|
78
78
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: lza89 */
|
|
2
2
|
:root {
|
|
3
3
|
}/* deprecated */: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 */
|
|
4
4
|
}: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 */
|
|
@@ -51,30 +51,30 @@
|
|
|
51
51
|
|
|
52
52
|
/* size xl */
|
|
53
53
|
--secondary-tablist-xl-gaps: var(--gap-m);
|
|
54
|
-
}.
|
|
54
|
+
}.tabs__component_tc0jp {
|
|
55
55
|
position: relative;
|
|
56
56
|
display: inline-flex;
|
|
57
|
-
}.
|
|
57
|
+
}.tabs__fullWidthScroll_tc0jp {
|
|
58
58
|
margin: 0 var(--gap-m);
|
|
59
|
-
}.
|
|
59
|
+
}.tabs__container_tc0jp {
|
|
60
60
|
overflow: hidden;
|
|
61
61
|
|
|
62
62
|
/* focus-outline fix */
|
|
63
63
|
margin: var(--gap-2xs-neg) 0 var(--gap-2xs-neg) var(--gap-2xs-neg);
|
|
64
64
|
padding: var(--gap-2xs) 0 var(--gap-2xs) var(--gap-2xs);
|
|
65
|
-
}.
|
|
65
|
+
}.tabs__title_tc0jp {
|
|
66
66
|
white-space: nowrap;
|
|
67
|
-
}/* sizes */.
|
|
67
|
+
}/* sizes */.tabs__xxs_tc0jp .tabs__title_tc0jp + .tabs__title_tc0jp {
|
|
68
68
|
margin-left: var(--secondary-tablist-xxs-gaps);
|
|
69
|
-
}.
|
|
69
|
+
}.tabs__xs_tc0jp .tabs__title_tc0jp + .tabs__title_tc0jp {
|
|
70
70
|
margin-left: var(--secondary-tablist-xs-gaps);
|
|
71
|
-
}.
|
|
71
|
+
}.tabs__s_tc0jp .tabs__title_tc0jp + .tabs__title_tc0jp {
|
|
72
72
|
margin-left: var(--secondary-tablist-s-gaps);
|
|
73
|
-
}.
|
|
73
|
+
}.tabs__m_tc0jp .tabs__title_tc0jp + .tabs__title_tc0jp {
|
|
74
74
|
margin-left: var(--secondary-tablist-m-gaps);
|
|
75
|
-
}.
|
|
75
|
+
}.tabs__l_tc0jp .tabs__title_tc0jp + .tabs__title_tc0jp {
|
|
76
76
|
margin-left: var(--secondary-tablist-l-gaps);
|
|
77
|
-
}.
|
|
77
|
+
}.tabs__xl_tc0jp .tabs__title_tc0jp + .tabs__title_tc0jp {
|
|
78
78
|
margin-left: var(--secondary-tablist-xl-gaps);
|
|
79
79
|
} :root {
|
|
80
80
|
--color-dark-indigo: #0b1f35;
|
|
@@ -979,7 +979,7 @@
|
|
|
979
979
|
|
|
980
980
|
/* size xl */
|
|
981
981
|
--secondary-tablist-xl-gaps: var(--gap-m);
|
|
982
|
-
} .
|
|
983
|
-
} .
|
|
982
|
+
} .tabs__title_1889x {
|
|
983
|
+
} .tabs__mobile_1889x .tabs__title_1889x + .tabs__title_1889x {
|
|
984
984
|
margin-left: var(--secondary-tablist-mobile-gaps);
|
|
985
985
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import cn from 'classnames';
|
|
3
3
|
|
|
4
|
-
const styles = {"component":"
|
|
4
|
+
const styles = {"component":"tabs__component_k9tti","hidden":"tabs__hidden_k9tti"};
|
|
5
5
|
require('./index.css')
|
|
6
6
|
|
|
7
7
|
const Tab = ({ children, hidden, className, disabled, dataTestId }) => children ? (React.createElement("div", { className: cn(styles.component, {
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import { TabsProps } from "../../typings";
|
|
4
|
+
type TabsCollapsibleProps = Omit<TabsProps, 'TabList' | 'fullWidthScroll' | 'scrollable' | 'view'>;
|
|
5
|
+
declare const TabsCollapsible: ({ ...restProps }: TabsCollapsibleProps) => React.JSX.Element;
|
|
6
|
+
export { TabsCollapsibleProps, TabsCollapsible };
|
package/modern/components/tabs/{Component.collabsible.desktop.js → Component.collapsible.js}
RENAMED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { CollapsiblePrimaryTabList } from '../primary-tablist/Component.collapsible.js';
|
|
3
3
|
import { Tabs } from './Component.js';
|
|
4
|
-
import '../primary-tablist/Component.collapsible.js';
|
|
5
4
|
import 'classnames';
|
|
6
5
|
import '@alfalab/core-components-badge/modern';
|
|
7
6
|
import '@alfalab/core-components-keyboard-focusable/modern';
|
|
@@ -15,8 +14,8 @@ import '../../hooks/use-tabs.js';
|
|
|
15
14
|
import '@alfalab/core-components-shared/modern';
|
|
16
15
|
import '../../synthetic-events.js';
|
|
17
16
|
import '../title/Component.js';
|
|
18
|
-
import '../../index.module-
|
|
17
|
+
import '../../index.module-22ff4191.js';
|
|
19
18
|
|
|
20
|
-
const
|
|
19
|
+
const TabsCollapsible = ({ ...restProps }) => (React.createElement(Tabs, { TabList: CollapsiblePrimaryTabList, ...restProps }));
|
|
21
20
|
|
|
22
|
-
export {
|
|
21
|
+
export { TabsCollapsible };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { TabsProps } from "../../typings";
|
|
4
|
-
declare const Tabs: ({ TabList, className, containerClassName, size, defaultMatchMediaValue, children, selectedId, scrollable, collapsedTabsIds, fullWidthScroll, keepMounted, dataTestId, onChange, breakpoint, }: Omit<TabsProps, 'view'>) => React.JSX.Element;
|
|
4
|
+
declare const Tabs: ({ TabList, className, containerClassName, size, defaultMatchMediaValue, children, selectedId, scrollable, collapsedTabsIds, fullWidthScroll, keepMounted, dataTestId, onChange, breakpoint, tagShape, tagView, }: Omit<TabsProps, 'view'>) => React.JSX.Element;
|
|
5
5
|
export { Tabs };
|
|
@@ -9,11 +9,17 @@ import '../../hooks/use-tabs.js';
|
|
|
9
9
|
import '@alfalab/core-components-shared/modern';
|
|
10
10
|
import '../scrollable-container/Component.js';
|
|
11
11
|
import 'compute-scroll-into-view';
|
|
12
|
+
import '../scroll-controls/Component.js';
|
|
13
|
+
import 'lodash.debounce';
|
|
14
|
+
import '@alfalab/core-components-icon-button/modern';
|
|
15
|
+
import '@alfalab/icons-glyph/ChevronLeftMIcon';
|
|
16
|
+
import '@alfalab/icons-glyph/ChevronRightMIcon';
|
|
17
|
+
import '../scroll-controls/utils.js';
|
|
12
18
|
import '../title/Component.js';
|
|
13
|
-
import '../../index.module-
|
|
19
|
+
import '../../index.module-22ff4191.js';
|
|
14
20
|
import '@alfalab/core-components-tag/modern/desktop';
|
|
15
21
|
import '../secondary-tablist/Component.js';
|
|
16
|
-
import '../../index.module-
|
|
22
|
+
import '../../index.module-3f8f9d5d.js';
|
|
17
23
|
|
|
18
24
|
const views = {
|
|
19
25
|
primary: PrimaryTabListDesktop,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React, { cloneElement } from 'react';
|
|
2
2
|
|
|
3
|
-
const Tabs = ({ TabList, className, containerClassName, size, defaultMatchMediaValue, children, selectedId, scrollable, collapsedTabsIds, fullWidthScroll = false, keepMounted = false, dataTestId, onChange, breakpoint = 1024, }) => {
|
|
3
|
+
const Tabs = ({ TabList, className, containerClassName, size, defaultMatchMediaValue, children, selectedId, scrollable, collapsedTabsIds, fullWidthScroll = false, keepMounted = false, dataTestId, onChange, breakpoint = 1024, tagShape, tagView, }) => {
|
|
4
4
|
const tabsArray = React.Children.toArray(children);
|
|
5
5
|
const titles = tabsArray.map(({ props: { title, id, rightAddons, disabled, hidden, toggleClassName, dataTestId: toggleTestId, }, }) => ({
|
|
6
6
|
title,
|
|
@@ -13,7 +13,7 @@ const Tabs = ({ TabList, className, containerClassName, size, defaultMatchMediaV
|
|
|
13
13
|
}));
|
|
14
14
|
const tabs = tabsArray.filter((tab) => tab.props.id === selectedId || tab.props.keepMounted || keepMounted);
|
|
15
15
|
return (React.createElement("div", { className: className },
|
|
16
|
-
React.createElement(TabList, { containerClassName: containerClassName, size: size, titles: titles, selectedId: selectedId, scrollable: scrollable, collapsedTabsIds: collapsedTabsIds, onChange: onChange, dataTestId: dataTestId, defaultMatchMediaValue: defaultMatchMediaValue, fullWidthScroll: fullWidthScroll, breakpoint: breakpoint }),
|
|
16
|
+
React.createElement(TabList, { containerClassName: containerClassName, size: size, titles: titles, selectedId: selectedId, scrollable: scrollable, collapsedTabsIds: collapsedTabsIds, onChange: onChange, dataTestId: dataTestId, defaultMatchMediaValue: defaultMatchMediaValue, fullWidthScroll: fullWidthScroll, breakpoint: breakpoint, tagShape: tagShape, tagView: tagView }),
|
|
17
17
|
tabs.map((tab) => cloneElement(tab, { hidden: tab.props.id !== selectedId }))));
|
|
18
18
|
};
|
|
19
19
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { TabsProps } from "../../typings";
|
|
4
|
-
type TabsMobileProps = Omit<TabsProps, 'TabList' | '
|
|
4
|
+
type TabsMobileProps = Omit<TabsProps, 'TabList' | 'collapsedTabsIds'>;
|
|
5
5
|
declare const TabsMobile: ({ view, scrollable, ...restProps }: TabsMobileProps) => React.JSX.Element;
|
|
6
6
|
export { TabsMobileProps, TabsMobile };
|
|
@@ -9,12 +9,17 @@ import '../../hooks/use-tabs.js';
|
|
|
9
9
|
import '@alfalab/core-components-shared/modern';
|
|
10
10
|
import '../scrollable-container/Component.js';
|
|
11
11
|
import 'compute-scroll-into-view';
|
|
12
|
+
import '../scroll-controls/Component.js';
|
|
13
|
+
import 'lodash.debounce';
|
|
14
|
+
import '@alfalab/core-components-icon-button/modern';
|
|
15
|
+
import '@alfalab/icons-glyph/ChevronLeftMIcon';
|
|
16
|
+
import '@alfalab/icons-glyph/ChevronRightMIcon';
|
|
17
|
+
import '../scroll-controls/utils.js';
|
|
12
18
|
import '../title/Component.js';
|
|
13
|
-
import '../../index.module-
|
|
14
|
-
import '../../mobile.module-47eb0ef0.js';
|
|
19
|
+
import '../../index.module-22ff4191.js';
|
|
15
20
|
import '@alfalab/core-components-tag/modern/mobile';
|
|
16
21
|
import '../secondary-tablist/Component.js';
|
|
17
|
-
import '../../index.module-
|
|
22
|
+
import '../../index.module-3f8f9d5d.js';
|
|
18
23
|
|
|
19
24
|
const views = {
|
|
20
25
|
primary: PrimaryTabListMobile,
|
|
@@ -11,14 +11,19 @@ import '../../hooks/use-tabs.js';
|
|
|
11
11
|
import '@alfalab/core-components-shared/modern';
|
|
12
12
|
import '../scrollable-container/Component.js';
|
|
13
13
|
import 'compute-scroll-into-view';
|
|
14
|
+
import '../scroll-controls/Component.js';
|
|
15
|
+
import 'lodash.debounce';
|
|
16
|
+
import '@alfalab/core-components-icon-button/modern';
|
|
17
|
+
import '@alfalab/icons-glyph/ChevronLeftMIcon';
|
|
18
|
+
import '@alfalab/icons-glyph/ChevronRightMIcon';
|
|
19
|
+
import '../scroll-controls/utils.js';
|
|
14
20
|
import '../title/Component.js';
|
|
15
|
-
import '../../index.module-
|
|
21
|
+
import '../../index.module-22ff4191.js';
|
|
16
22
|
import '../primary-tablist/Component.mobile.js';
|
|
17
|
-
import '../../mobile.module-47eb0ef0.js';
|
|
18
23
|
import '../secondary-tablist/Component.desktop.js';
|
|
19
24
|
import '@alfalab/core-components-tag/modern/desktop';
|
|
20
25
|
import '../secondary-tablist/Component.js';
|
|
21
|
-
import '../../index.module-
|
|
26
|
+
import '../../index.module-3f8f9d5d.js';
|
|
22
27
|
import '../secondary-tablist/Component.mobile.js';
|
|
23
28
|
import '@alfalab/core-components-tag/modern/mobile';
|
|
24
29
|
|
package/modern/desktop.js
CHANGED
|
@@ -10,9 +10,15 @@ import './hooks/use-tabs.js';
|
|
|
10
10
|
import '@alfalab/core-components-shared/modern';
|
|
11
11
|
import './components/scrollable-container/Component.js';
|
|
12
12
|
import 'compute-scroll-into-view';
|
|
13
|
+
import './components/scroll-controls/Component.js';
|
|
14
|
+
import 'lodash.debounce';
|
|
15
|
+
import '@alfalab/core-components-icon-button/modern';
|
|
16
|
+
import '@alfalab/icons-glyph/ChevronLeftMIcon';
|
|
17
|
+
import '@alfalab/icons-glyph/ChevronRightMIcon';
|
|
18
|
+
import './components/scroll-controls/utils.js';
|
|
13
19
|
import './components/title/Component.js';
|
|
14
|
-
import './index.module-
|
|
20
|
+
import './index.module-22ff4191.js';
|
|
15
21
|
import '@alfalab/core-components-tag/modern/desktop';
|
|
16
22
|
import './components/secondary-tablist/Component.js';
|
|
17
|
-
import './index.module-
|
|
23
|
+
import './index.module-3f8f9d5d.js';
|
|
18
24
|
import './components/tabs/Component.js';
|
|
@@ -137,5 +137,4 @@ type NavigationBarProps = {
|
|
|
137
137
|
declare const NavigationBar: React.ForwardRefExoticComponent<NavigationBarProps & React.RefAttributes<HTMLDivElement>>;
|
|
138
138
|
export { NavigationBar };
|
|
139
139
|
export * from "./Component-63dec22f";
|
|
140
|
-
export * from "./Component-8b2c2707";
|
|
141
140
|
export type { NavigationBarProps };
|
|
@@ -269,9 +269,13 @@ type BottomSheetProps = {
|
|
|
269
269
|
*/
|
|
270
270
|
onOffsetChange?: (offset: number, percent: number) => void;
|
|
271
271
|
/**
|
|
272
|
-
* Вызывается
|
|
272
|
+
* Вызывается в начале свайпа
|
|
273
273
|
*/
|
|
274
|
-
|
|
274
|
+
onSwipeStart?: (event: HandledEvents) => void;
|
|
275
|
+
/**
|
|
276
|
+
* Вызывается после окончания свайпа
|
|
277
|
+
*/
|
|
278
|
+
onSwipeEnd?: (event: HandledEvents | null) => void;
|
|
275
279
|
};
|
|
276
280
|
declare const BottomSheet: React.ForwardRefExoticComponent<BottomSheetProps & React.RefAttributes<HTMLDivElement>>;
|
|
277
281
|
declare const TIMEOUT = 500;
|
package/modern/index.js
CHANGED
|
@@ -12,14 +12,19 @@ import './hooks/use-tabs.js';
|
|
|
12
12
|
import '@alfalab/core-components-shared/modern';
|
|
13
13
|
import './components/scrollable-container/Component.js';
|
|
14
14
|
import 'compute-scroll-into-view';
|
|
15
|
+
import './components/scroll-controls/Component.js';
|
|
16
|
+
import 'lodash.debounce';
|
|
17
|
+
import '@alfalab/core-components-icon-button/modern';
|
|
18
|
+
import '@alfalab/icons-glyph/ChevronLeftMIcon';
|
|
19
|
+
import '@alfalab/icons-glyph/ChevronRightMIcon';
|
|
20
|
+
import './components/scroll-controls/utils.js';
|
|
15
21
|
import './components/title/Component.js';
|
|
16
|
-
import './index.module-
|
|
22
|
+
import './index.module-22ff4191.js';
|
|
17
23
|
import './components/primary-tablist/Component.mobile.js';
|
|
18
|
-
import './mobile.module-47eb0ef0.js';
|
|
19
24
|
import './components/secondary-tablist/Component.desktop.js';
|
|
20
25
|
import '@alfalab/core-components-tag/modern/desktop';
|
|
21
26
|
import './components/secondary-tablist/Component.js';
|
|
22
|
-
import './index.module-
|
|
27
|
+
import './index.module-3f8f9d5d.js';
|
|
23
28
|
import './components/secondary-tablist/Component.mobile.js';
|
|
24
29
|
import '@alfalab/core-components-tag/modern/mobile';
|
|
25
30
|
import './components/tabs/Component.js';
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
const commonStyles = {"component":"tabs__component_1u3uq","fullWidthScroll":"tabs__fullWidthScroll_1u3uq","container":"tabs__container_1u3uq","title":"tabs__title_1u3uq","disabled":"tabs__disabled_1u3uq","focused":"tabs__focused_1u3uq","collapsed":"tabs__collapsed_1u3uq","selected":"tabs__selected_1u3uq","line":"tabs__line_1u3uq","option":"tabs__option_1u3uq","s":"tabs__s_1u3uq","xs":"tabs__xs_1u3uq","xxs":"tabs__xxs_1u3uq","pickerWrapper":"tabs__pickerWrapper_1u3uq","m":"tabs__m_1u3uq","l":"tabs__l_1u3uq","xl":"tabs__xl_1u3uq","rightAddons":"tabs__rightAddons_1u3uq"};
|
|
2
|
+
require('./components/primary-tablist/index.css')
|
|
3
|
+
|
|
4
|
+
export { commonStyles as c };
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
const commonStyles = {"component":"tabs__component_tc0jp","fullWidthScroll":"tabs__fullWidthScroll_tc0jp","container":"tabs__container_tc0jp","title":"tabs__title_tc0jp","xxs":"tabs__xxs_tc0jp","xs":"tabs__xs_tc0jp","s":"tabs__s_tc0jp","m":"tabs__m_tc0jp","l":"tabs__l_tc0jp","xl":"tabs__xl_tc0jp"};
|
|
2
|
+
require('./components/secondary-tablist/index.css')
|
|
3
|
+
|
|
4
|
+
export { commonStyles as c };
|
package/modern/mobile.js
CHANGED
|
@@ -10,10 +10,15 @@ import './hooks/use-tabs.js';
|
|
|
10
10
|
import '@alfalab/core-components-shared/modern';
|
|
11
11
|
import './components/scrollable-container/Component.js';
|
|
12
12
|
import 'compute-scroll-into-view';
|
|
13
|
+
import './components/scroll-controls/Component.js';
|
|
14
|
+
import 'lodash.debounce';
|
|
15
|
+
import '@alfalab/core-components-icon-button/modern';
|
|
16
|
+
import '@alfalab/icons-glyph/ChevronLeftMIcon';
|
|
17
|
+
import '@alfalab/icons-glyph/ChevronRightMIcon';
|
|
18
|
+
import './components/scroll-controls/utils.js';
|
|
13
19
|
import './components/title/Component.js';
|
|
14
|
-
import './index.module-
|
|
15
|
-
import './mobile.module-47eb0ef0.js';
|
|
20
|
+
import './index.module-22ff4191.js';
|
|
16
21
|
import '@alfalab/core-components-tag/modern/mobile';
|
|
17
22
|
import './components/secondary-tablist/Component.js';
|
|
18
|
-
import './index.module-
|
|
23
|
+
import './index.module-3f8f9d5d.js';
|
|
19
24
|
import './components/tabs/Component.js';
|
package/modern/shared.js
CHANGED
|
@@ -4,6 +4,12 @@ export { useCollapsibleElements } from './hooks/use-collapsible-elements.js';
|
|
|
4
4
|
import 'react';
|
|
5
5
|
import 'classnames';
|
|
6
6
|
import 'compute-scroll-into-view';
|
|
7
|
+
import './components/scroll-controls/Component.js';
|
|
8
|
+
import 'lodash.debounce';
|
|
9
|
+
import '@alfalab/core-components-icon-button/modern';
|
|
10
|
+
import '@alfalab/icons-glyph/ChevronLeftMIcon';
|
|
11
|
+
import '@alfalab/icons-glyph/ChevronRightMIcon';
|
|
12
|
+
import './components/scroll-controls/utils.js';
|
|
7
13
|
import '@alfalab/core-components-shared/modern';
|
|
8
14
|
import '@juggle/resize-observer';
|
|
9
15
|
import '@alfalab/hooks';
|
package/modern/typings.d.ts
CHANGED
|
@@ -69,6 +69,14 @@ type TabsProps = {
|
|
|
69
69
|
* @default 1024
|
|
70
70
|
*/
|
|
71
71
|
breakpoint?: number;
|
|
72
|
+
/**
|
|
73
|
+
* Форма тега (для view secondary только)
|
|
74
|
+
*/
|
|
75
|
+
tagShape?: TagProps['shape'];
|
|
76
|
+
/**
|
|
77
|
+
* Стиль тега (для view secondary только)
|
|
78
|
+
*/
|
|
79
|
+
tagView?: TagProps['view'];
|
|
72
80
|
};
|
|
73
81
|
type TabProps = {
|
|
74
82
|
/**
|
|
@@ -123,7 +131,7 @@ type TabListTitle = {
|
|
|
123
131
|
collapsed?: boolean;
|
|
124
132
|
dataTestId?: string;
|
|
125
133
|
};
|
|
126
|
-
type TabListProps = Pick<TabsProps, 'className' | 'containerClassName' | 'size' | 'defaultMatchMediaValue' | 'selectedId' | 'scrollable' | 'collapsedTabsIds' | 'onChange' | 'dataTestId' | 'fullWidthScroll'> & {
|
|
134
|
+
type TabListProps = Pick<TabsProps, 'className' | 'containerClassName' | 'size' | 'defaultMatchMediaValue' | 'selectedId' | 'scrollable' | 'collapsedTabsIds' | 'onChange' | 'dataTestId' | 'fullWidthScroll' | 'tagShape' | 'tagView'> & {
|
|
127
135
|
/**
|
|
128
136
|
* Заголовки табов
|
|
129
137
|
*/
|
|
@@ -144,4 +152,7 @@ type Styles = {
|
|
|
144
152
|
[key: string]: string;
|
|
145
153
|
};
|
|
146
154
|
};
|
|
147
|
-
|
|
155
|
+
type PlatformProps = {
|
|
156
|
+
platform: 'desktop' | 'mobile';
|
|
157
|
+
};
|
|
158
|
+
export { SelectedId, TabsProps, TabProps, TabListTitle, TabListProps, SecondaryTabListProps, UseTabsProps, Styles, PlatformProps };
|