@docsplain-kit/core 0.0.25 → 0.0.27

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.
@@ -0,0 +1,56 @@
1
+ import { ReactNode } from 'react';
2
+ import { Colors, Sizes } from '../types';
3
+ export interface TabListProps {
4
+ /**
5
+ * The content of the tab list (Tab components)
6
+ */
7
+ children?: ReactNode;
8
+ /**
9
+ * The currently selected tab value
10
+ */
11
+ selectedValue?: string;
12
+ /**
13
+ * Callback when a tab is selected
14
+ */
15
+ onTabSelect?: (value: string) => void;
16
+ /**
17
+ * The size of the tabs
18
+ */
19
+ size?: Sizes;
20
+ /**
21
+ * The color theme of the tabs
22
+ */
23
+ color?: Colors;
24
+ /**
25
+ * Whether to show overflow indicators
26
+ */
27
+ showOverflow?: boolean;
28
+ /**
29
+ * Maximum number of visible tabs before overflow
30
+ */
31
+ maxVisibleTabs?: number;
32
+ /**
33
+ * Additional CSS classes
34
+ */
35
+ className?: string;
36
+ /**
37
+ * Test ID for testing
38
+ */
39
+ dataTestId?: string;
40
+ /**
41
+ * ARIA label for accessibility
42
+ */
43
+ ariaLabel?: string;
44
+ /**
45
+ * ID for the tab list
46
+ */
47
+ id?: string;
48
+ /**
49
+ * Whether the tab list is vertical
50
+ */
51
+ vertical?: boolean;
52
+ /**
53
+ * Whether to show scroll buttons
54
+ */
55
+ showScrollButtons?: boolean;
56
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ exports.__esModule = true;
3
+ //# sourceMappingURL=tab-list.props.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tab-list.props.js","sourceRoot":"","sources":["../../tab-list/tab-list.props.ts"],"names":[],"mappings":""}
@@ -0,0 +1,17 @@
1
+ import { Sizes } from '../types';
2
+ export declare const TAB_LIST_SIZES: {
3
+ tiny: string;
4
+ small: string;
5
+ medium: string;
6
+ large: string;
7
+ huge: string;
8
+ };
9
+ export declare const SCROLL_BUTTON_SIZES: {
10
+ tiny: string;
11
+ small: string;
12
+ medium: string;
13
+ large: string;
14
+ huge: string;
15
+ };
16
+ export declare const getTabListStyles: (size: Sizes) => string;
17
+ export declare const getScrollButtonStyles: (size: Sizes, disabled: boolean) => string;
@@ -0,0 +1,31 @@
1
+ "use strict";
2
+ exports.__esModule = true;
3
+ exports.getScrollButtonStyles = exports.getTabListStyles = exports.SCROLL_BUTTON_SIZES = exports.TAB_LIST_SIZES = void 0;
4
+ exports.TAB_LIST_SIZES = {
5
+ tiny: 'gap-1',
6
+ small: 'gap-1.5',
7
+ medium: 'gap-2',
8
+ large: 'gap-2.5',
9
+ huge: 'gap-3'
10
+ };
11
+ exports.SCROLL_BUTTON_SIZES = {
12
+ tiny: 'w-6 h-6',
13
+ small: 'w-8 h-8',
14
+ medium: 'w-10 h-10',
15
+ large: 'w-12 h-12',
16
+ huge: 'w-14 h-14'
17
+ };
18
+ var getTabListStyles = function (size) {
19
+ var baseStyles = 'flex items-center relative';
20
+ var sizeStyles = exports.TAB_LIST_SIZES[size];
21
+ return "".concat(baseStyles, " ").concat(sizeStyles);
22
+ };
23
+ exports.getTabListStyles = getTabListStyles;
24
+ var getScrollButtonStyles = function (size, disabled) {
25
+ var baseStyles = 'flex items-center justify-center bg-white border border-control-300 rounded transition-all duration-200 hover:bg-control-50 focus:outline-none focus:ring-2 focus:ring-primary-500';
26
+ var sizeStyles = exports.SCROLL_BUTTON_SIZES[size];
27
+ var disabledStyles = disabled ? 'opacity-50 cursor-not-allowed' : 'cursor-pointer';
28
+ return "".concat(baseStyles, " ").concat(sizeStyles, " ").concat(disabledStyles);
29
+ };
30
+ exports.getScrollButtonStyles = getScrollButtonStyles;
31
+ //# sourceMappingURL=tab-list.style.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tab-list.style.js","sourceRoot":"","sources":["../../tab-list/tab-list.style.ts"],"names":[],"mappings":";;;AAEa,QAAA,cAAc,GAAG;IAC5B,IAAI,EAAE,OAAO;IACb,KAAK,EAAE,SAAS;IAChB,MAAM,EAAE,OAAO;IACf,KAAK,EAAE,SAAS;IAChB,IAAI,EAAE,OAAO;CACd,CAAC;AAEW,QAAA,mBAAmB,GAAG;IACjC,IAAI,EAAE,SAAS;IACf,KAAK,EAAE,SAAS;IAChB,MAAM,EAAE,WAAW;IACnB,KAAK,EAAE,WAAW;IAClB,IAAI,EAAE,WAAW;CAClB,CAAC;AAEK,IAAM,gBAAgB,GAAG,UAAC,IAAW;IAC1C,IAAM,UAAU,GAAG,4BAA4B,CAAC;IAChD,IAAM,UAAU,GAAG,sBAAc,CAAC,IAAI,CAAC,CAAC;IAExC,OAAO,UAAG,UAAU,cAAI,UAAU,CAAE,CAAC;AACvC,CAAC,CAAC;AALW,QAAA,gBAAgB,oBAK3B;AAEK,IAAM,qBAAqB,GAAG,UAAC,IAAW,EAAE,QAAiB;IAClE,IAAM,UAAU,GAAG,oLAAoL,CAAC;IACxM,IAAM,UAAU,GAAG,2BAAmB,CAAC,IAAI,CAAC,CAAC;IAC7C,IAAM,cAAc,GAAG,QAAQ,CAAC,CAAC,CAAC,+BAA+B,CAAC,CAAC,CAAC,gBAAgB,CAAC;IAErF,OAAO,UAAG,UAAU,cAAI,UAAU,cAAI,cAAc,CAAE,CAAC;AACzD,CAAC,CAAC;AANW,QAAA,qBAAqB,yBAMhC"}