tekivex-ui 2.3.0 → 2.5.1
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/dist/TkxForm-BWK4LqY3.js +1461 -0
- package/dist/TkxForm-ljQjX7KD.cjs +15 -0
- package/dist/charts.cjs +1 -0
- package/dist/charts.js +480 -0
- package/dist/headless.cjs +1 -0
- package/dist/headless.js +258 -0
- package/dist/index-BINBzXuY.cjs +2 -0
- package/dist/index-eT_U4qB2.js +512 -0
- package/dist/index.cjs +20 -32
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +7942 -8903
- package/dist/src/charts/TkxAreaChart.d.ts +29 -0
- package/dist/src/charts/TkxAreaChart.d.ts.map +1 -0
- package/dist/src/charts/TkxBarChart.d.ts +28 -0
- package/dist/src/charts/TkxBarChart.d.ts.map +1 -0
- package/dist/src/charts/TkxDonutChart.d.ts +23 -0
- package/dist/src/charts/TkxDonutChart.d.ts.map +1 -0
- package/dist/src/charts/TkxLineChart.d.ts +35 -0
- package/dist/src/charts/TkxLineChart.d.ts.map +1 -0
- package/dist/src/charts/TkxPieChart.d.ts +19 -0
- package/dist/src/charts/TkxPieChart.d.ts.map +1 -0
- package/dist/src/charts/TkxRadarChart.d.ts +20 -0
- package/dist/src/charts/TkxRadarChart.d.ts.map +1 -0
- package/dist/src/charts/TkxScatterChart.d.ts +28 -0
- package/dist/src/charts/TkxScatterChart.d.ts.map +1 -0
- package/dist/src/charts/index.d.ts +15 -0
- package/dist/src/charts/index.d.ts.map +1 -0
- package/dist/src/charts/shared.d.ts +33 -0
- package/dist/src/charts/shared.d.ts.map +1 -0
- package/dist/src/components/TkxDataGrid.d.ts +16 -2
- package/dist/src/components/TkxDataGrid.d.ts.map +1 -1
- package/dist/src/components/TkxForm.d.ts +33 -3
- package/dist/src/components/TkxForm.d.ts.map +1 -1
- package/dist/src/components/TkxImage.d.ts.map +1 -1
- package/dist/src/components/TkxTypography.d.ts +1 -1
- package/dist/src/components/TkxTypography.d.ts.map +1 -1
- package/dist/src/engine/tkx.d.ts.map +1 -1
- package/dist/src/headless/index.d.ts +18 -0
- package/dist/src/headless/index.d.ts.map +1 -0
- package/dist/src/headless/useControllable.d.ts +20 -0
- package/dist/src/headless/useControllable.d.ts.map +1 -0
- package/dist/src/headless/useDebounce.d.ts +14 -0
- package/dist/src/headless/useDebounce.d.ts.map +1 -0
- package/dist/src/headless/useDisclosure.d.ts +20 -0
- package/dist/src/headless/useDisclosure.d.ts.map +1 -0
- package/dist/src/headless/useFormState.d.ts +44 -0
- package/dist/src/headless/useFormState.d.ts.map +1 -0
- package/dist/src/headless/useIntersectionObserver.d.ts +23 -0
- package/dist/src/headless/useIntersectionObserver.d.ts.map +1 -0
- package/dist/src/headless/useListSelection.d.ts +29 -0
- package/dist/src/headless/useListSelection.d.ts.map +1 -0
- package/dist/src/headless/useLocalStorage.d.ts +9 -0
- package/dist/src/headless/useLocalStorage.d.ts.map +1 -0
- package/dist/src/headless/useMediaQuery.d.ts +21 -0
- package/dist/src/headless/useMediaQuery.d.ts.map +1 -0
- package/dist/src/headless/useRovingTabIndex.d.ts +33 -0
- package/dist/src/headless/useRovingTabIndex.d.ts.map +1 -0
- package/dist/src/headless/useThrottle.d.ts +9 -0
- package/dist/src/headless/useThrottle.d.ts.map +1 -0
- package/dist/src/i18n/index.d.ts +47 -2
- package/dist/src/i18n/index.d.ts.map +1 -1
- package/dist/src/themes/index.d.ts.map +1 -1
- package/package.json +61 -7
- package/src/charts/TkxAreaChart.tsx +119 -0
- package/src/charts/TkxBarChart.tsx +115 -0
- package/src/charts/TkxDonutChart.tsx +145 -0
- package/src/charts/TkxLineChart.tsx +135 -0
- package/src/charts/TkxPieChart.tsx +82 -0
- package/src/charts/TkxRadarChart.tsx +90 -0
- package/src/charts/TkxScatterChart.tsx +102 -0
- package/src/charts/index.ts +20 -0
- package/src/charts/shared.ts +45 -0
- package/src/components/TkxDataGrid.tsx +532 -268
- package/src/components/TkxForm.tsx +67 -15
- package/src/components/TkxImage.tsx +1 -1
- package/src/components/TkxTypography.tsx +4 -2
- package/src/engine/tkx.ts +60 -3
- package/src/headless/index.ts +44 -0
- package/src/headless/useControllable.ts +40 -0
- package/src/headless/useDebounce.ts +35 -0
- package/src/headless/useDisclosure.ts +28 -0
- package/src/headless/useFormState.ts +111 -0
- package/src/headless/useIntersectionObserver.ts +51 -0
- package/src/headless/useListSelection.ts +101 -0
- package/src/headless/useLocalStorage.ts +46 -0
- package/src/headless/useMediaQuery.ts +37 -0
- package/src/headless/useRovingTabIndex.ts +84 -0
- package/src/headless/useThrottle.ts +46 -0
- package/src/i18n/I18nProvider.tsx +1 -1
- package/src/i18n/index.ts +678 -38
- package/src/themes/index.ts +31 -4
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
export interface UseListSelectionOptions {
|
|
2
|
+
items: string[];
|
|
3
|
+
initialSelected?: string[];
|
|
4
|
+
/** Allow selecting multiple items. Default: true */
|
|
5
|
+
multiple?: boolean;
|
|
6
|
+
}
|
|
7
|
+
export interface UseListSelectionReturn {
|
|
8
|
+
selected: Set<string>;
|
|
9
|
+
isSelected: (id: string) => boolean;
|
|
10
|
+
toggle: (id: string) => void;
|
|
11
|
+
select: (id: string) => void;
|
|
12
|
+
deselect: (id: string) => void;
|
|
13
|
+
selectAll: () => void;
|
|
14
|
+
deselectAll: () => void;
|
|
15
|
+
toggleAll: () => void;
|
|
16
|
+
allSelected: boolean;
|
|
17
|
+
someSelected: boolean;
|
|
18
|
+
selectedCount: number;
|
|
19
|
+
selectedArray: string[];
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* Manages selection state for lists, tables, and grids.
|
|
23
|
+
* Supports single and multi-select modes.
|
|
24
|
+
*
|
|
25
|
+
* @example
|
|
26
|
+
* const { isSelected, toggle, selectedArray } = useListSelection({ items: rows.map(r => r.id) });
|
|
27
|
+
*/
|
|
28
|
+
export declare function useListSelection({ items, initialSelected, multiple, }: UseListSelectionOptions): UseListSelectionReturn;
|
|
29
|
+
//# sourceMappingURL=useListSelection.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useListSelection.d.ts","sourceRoot":"","sources":["../../../src/headless/useListSelection.ts"],"names":[],"mappings":"AAEA,MAAM,WAAW,uBAAuB;IACtC,KAAK,EAAE,MAAM,EAAE,CAAC;IAChB,eAAe,CAAC,EAAE,MAAM,EAAE,CAAC;IAC3B,oDAAoD;IACpD,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAED,MAAM,WAAW,sBAAsB;IACrC,QAAQ,EAAE,GAAG,CAAC,MAAM,CAAC,CAAC;IACtB,UAAU,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,OAAO,CAAC;IACpC,MAAM,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAC;IAC7B,MAAM,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAC;IAC7B,QAAQ,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAC;IAC/B,SAAS,EAAE,MAAM,IAAI,CAAC;IACtB,WAAW,EAAE,MAAM,IAAI,CAAC;IACxB,SAAS,EAAE,MAAM,IAAI,CAAC;IACtB,WAAW,EAAE,OAAO,CAAC;IACrB,YAAY,EAAE,OAAO,CAAC;IACtB,aAAa,EAAE,MAAM,CAAC;IACtB,aAAa,EAAE,MAAM,EAAE,CAAC;CACzB;AAED;;;;;;GAMG;AACH,wBAAgB,gBAAgB,CAAC,EAC/B,KAAK,EACL,eAAoB,EACpB,QAAe,GAChB,EAAE,uBAAuB,GAAG,sBAAsB,CAiElD"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Persists state to localStorage. Falls back to in-memory on parse errors or
|
|
3
|
+
* SSR (where localStorage is unavailable).
|
|
4
|
+
*
|
|
5
|
+
* @example
|
|
6
|
+
* const [theme, setTheme] = useLocalStorage('theme', 'dark');
|
|
7
|
+
*/
|
|
8
|
+
export declare function useLocalStorage<T>(key: string, initialValue: T): [T, (value: T | ((prev: T) => T)) => void, () => void];
|
|
9
|
+
//# sourceMappingURL=useLocalStorage.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useLocalStorage.d.ts","sourceRoot":"","sources":["../../../src/headless/useLocalStorage.ts"],"names":[],"mappings":"AAEA;;;;;;GAMG;AACH,wBAAgB,eAAe,CAAC,CAAC,EAAE,GAAG,EAAE,MAAM,EAAE,YAAY,EAAE,CAAC,GAAG,CAAC,CAAC,EAAE,CAAC,KAAK,EAAE,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,CAAC,KAAK,CAAC,CAAC,KAAK,IAAI,EAAE,MAAM,IAAI,CAAC,CAoCvH"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Reactive media query hook. Returns true while the query matches.
|
|
3
|
+
*
|
|
4
|
+
* @example
|
|
5
|
+
* const isMobile = useMediaQuery('(max-width: 767px)');
|
|
6
|
+
* const isDark = useMediaQuery('(prefers-color-scheme: dark)');
|
|
7
|
+
* const isTouch = useMediaQuery('(hover: none) and (pointer: coarse)');
|
|
8
|
+
*/
|
|
9
|
+
export declare function useMediaQuery(query: string): boolean;
|
|
10
|
+
/** Preset breakpoint hooks matching TekiVex's breakpoint scale. */
|
|
11
|
+
export declare function useBreakpoint(): {
|
|
12
|
+
sm: boolean;
|
|
13
|
+
md: boolean;
|
|
14
|
+
lg: boolean;
|
|
15
|
+
xl: boolean;
|
|
16
|
+
xxl: boolean;
|
|
17
|
+
isMobile: boolean;
|
|
18
|
+
isTablet: boolean;
|
|
19
|
+
isDesktop: boolean;
|
|
20
|
+
};
|
|
21
|
+
//# sourceMappingURL=useMediaQuery.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useMediaQuery.d.ts","sourceRoot":"","sources":["../../../src/headless/useMediaQuery.ts"],"names":[],"mappings":"AAEA;;;;;;;GAOG;AACH,wBAAgB,aAAa,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO,CAgBpD;AAED,mEAAmE;AACnE,wBAAgB,aAAa;;;;;;;;;EAO5B"}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { type KeyboardEvent } from 'react';
|
|
2
|
+
export interface UseRovingTabIndexOptions {
|
|
3
|
+
count: number;
|
|
4
|
+
initialIndex?: number;
|
|
5
|
+
orientation?: 'horizontal' | 'vertical' | 'both';
|
|
6
|
+
/** Wrap around at boundaries. Default: true */
|
|
7
|
+
loop?: boolean;
|
|
8
|
+
}
|
|
9
|
+
export interface UseRovingTabIndexReturn {
|
|
10
|
+
focusedIndex: number;
|
|
11
|
+
setFocusedIndex: (index: number) => void;
|
|
12
|
+
getItemProps: (index: number) => {
|
|
13
|
+
tabIndex: number;
|
|
14
|
+
onKeyDown: (e: KeyboardEvent) => void;
|
|
15
|
+
onFocus: () => void;
|
|
16
|
+
'data-focused': boolean;
|
|
17
|
+
};
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* Implements the WAI-ARIA roving tabIndex pattern for composite widgets
|
|
21
|
+
* (toolbars, tab lists, radio groups, menu items, etc.)
|
|
22
|
+
*
|
|
23
|
+
* Only one item in the group is in the tab sequence at a time.
|
|
24
|
+
* Arrow keys move focus within the group.
|
|
25
|
+
*
|
|
26
|
+
* @example
|
|
27
|
+
* const { getItemProps } = useRovingTabIndex({ count: tabs.length });
|
|
28
|
+
* return tabs.map((tab, i) => (
|
|
29
|
+
* <button key={tab.id} {...getItemProps(i)}>{tab.label}</button>
|
|
30
|
+
* ));
|
|
31
|
+
*/
|
|
32
|
+
export declare function useRovingTabIndex({ count, initialIndex, orientation, loop, }: UseRovingTabIndexOptions): UseRovingTabIndexReturn;
|
|
33
|
+
//# sourceMappingURL=useRovingTabIndex.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useRovingTabIndex.d.ts","sourceRoot":"","sources":["../../../src/headless/useRovingTabIndex.ts"],"names":[],"mappings":"AAAA,OAAO,EAAiC,KAAK,aAAa,EAAE,MAAM,OAAO,CAAC;AAE1E,MAAM,WAAW,wBAAwB;IACvC,KAAK,EAAE,MAAM,CAAC;IACd,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,WAAW,CAAC,EAAE,YAAY,GAAG,UAAU,GAAG,MAAM,CAAC;IACjD,+CAA+C;IAC/C,IAAI,CAAC,EAAE,OAAO,CAAC;CAChB;AAED,MAAM,WAAW,uBAAuB;IACtC,YAAY,EAAE,MAAM,CAAC;IACrB,eAAe,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACzC,YAAY,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK;QAC/B,QAAQ,EAAE,MAAM,CAAC;QACjB,SAAS,EAAE,CAAC,CAAC,EAAE,aAAa,KAAK,IAAI,CAAC;QACtC,OAAO,EAAE,MAAM,IAAI,CAAC;QACpB,cAAc,EAAE,OAAO,CAAC;KACzB,CAAC;CACH;AAED;;;;;;;;;;;;GAYG;AACH,wBAAgB,iBAAiB,CAAC,EAChC,KAAK,EACL,YAAgB,EAChB,WAA0B,EAC1B,IAAW,GACZ,EAAE,wBAAwB,GAAG,uBAAuB,CA4CpD"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Returns a throttled version of the value — updates at most once per interval.
|
|
3
|
+
*/
|
|
4
|
+
export declare function useThrottle<T>(value: T, interval: number): T;
|
|
5
|
+
/**
|
|
6
|
+
* Returns a throttled callback — executes at most once per interval.
|
|
7
|
+
*/
|
|
8
|
+
export declare function useThrottledCallback<T extends (...args: any[]) => any>(fn: T, interval: number): (...args: Parameters<T>) => void;
|
|
9
|
+
//# sourceMappingURL=useThrottle.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useThrottle.d.ts","sourceRoot":"","sources":["../../../src/headless/useThrottle.ts"],"names":[],"mappings":"AAEA;;GAEG;AACH,wBAAgB,WAAW,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,QAAQ,EAAE,MAAM,GAAG,CAAC,CAoB5D;AAED;;GAEG;AACH,wBAAgB,oBAAoB,CAAC,CAAC,SAAS,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,GAAG,EACpE,EAAE,EAAE,CAAC,EACL,QAAQ,EAAE,MAAM,GACf,CAAC,GAAG,IAAI,EAAE,UAAU,CAAC,CAAC,CAAC,KAAK,IAAI,CAYlC"}
|
package/dist/src/i18n/index.d.ts
CHANGED
|
@@ -21,20 +21,65 @@ export interface LocaleStrings {
|
|
|
21
21
|
noData: string;
|
|
22
22
|
sortAscending: string;
|
|
23
23
|
sortDescending: string;
|
|
24
|
+
filterPlaceholder: string;
|
|
25
|
+
exportCsv: string;
|
|
26
|
+
rowsSelected: (n: number) => string;
|
|
24
27
|
}
|
|
25
28
|
export declare const enUS: LocaleStrings;
|
|
26
29
|
export declare const esES: LocaleStrings;
|
|
27
|
-
export declare const
|
|
30
|
+
export declare const ptBR: LocaleStrings;
|
|
31
|
+
export declare const ptPT: LocaleStrings;
|
|
28
32
|
export declare const frFR: LocaleStrings;
|
|
29
33
|
export declare const deDE: LocaleStrings;
|
|
34
|
+
export declare const itIT: LocaleStrings;
|
|
35
|
+
export declare const nlNL: LocaleStrings;
|
|
36
|
+
export declare const plPL: LocaleStrings;
|
|
37
|
+
export declare const ruRU: LocaleStrings;
|
|
38
|
+
export declare const ukUA: LocaleStrings;
|
|
39
|
+
export declare const trTR: LocaleStrings;
|
|
40
|
+
export declare const svSE: LocaleStrings;
|
|
41
|
+
export declare const daDK: LocaleStrings;
|
|
42
|
+
export declare const csCZ: LocaleStrings;
|
|
43
|
+
export declare const huHU: LocaleStrings;
|
|
44
|
+
export declare const arSA: LocaleStrings;
|
|
45
|
+
export declare const heIL: LocaleStrings;
|
|
46
|
+
export declare const faIR: LocaleStrings;
|
|
30
47
|
export declare const jaJP: LocaleStrings;
|
|
48
|
+
export declare const koKR: LocaleStrings;
|
|
49
|
+
export declare const zhCN: LocaleStrings;
|
|
50
|
+
export declare const zhTW: LocaleStrings;
|
|
51
|
+
export declare const thTH: LocaleStrings;
|
|
52
|
+
export declare const viVN: LocaleStrings;
|
|
53
|
+
export declare const idID: LocaleStrings;
|
|
54
|
+
export declare const roRO: LocaleStrings;
|
|
31
55
|
export declare const LOCALES: {
|
|
32
56
|
readonly 'en-US': LocaleStrings;
|
|
33
57
|
readonly 'es-ES': LocaleStrings;
|
|
34
|
-
readonly '
|
|
58
|
+
readonly 'pt-BR': LocaleStrings;
|
|
59
|
+
readonly 'pt-PT': LocaleStrings;
|
|
35
60
|
readonly 'fr-FR': LocaleStrings;
|
|
36
61
|
readonly 'de-DE': LocaleStrings;
|
|
62
|
+
readonly 'it-IT': LocaleStrings;
|
|
63
|
+
readonly 'nl-NL': LocaleStrings;
|
|
64
|
+
readonly 'pl-PL': LocaleStrings;
|
|
65
|
+
readonly 'ru-RU': LocaleStrings;
|
|
66
|
+
readonly 'uk-UA': LocaleStrings;
|
|
67
|
+
readonly 'tr-TR': LocaleStrings;
|
|
68
|
+
readonly 'sv-SE': LocaleStrings;
|
|
69
|
+
readonly 'da-DK': LocaleStrings;
|
|
70
|
+
readonly 'cs-CZ': LocaleStrings;
|
|
71
|
+
readonly 'hu-HU': LocaleStrings;
|
|
72
|
+
readonly 'ar-SA': LocaleStrings;
|
|
73
|
+
readonly 'he-IL': LocaleStrings;
|
|
74
|
+
readonly 'fa-IR': LocaleStrings;
|
|
37
75
|
readonly 'ja-JP': LocaleStrings;
|
|
76
|
+
readonly 'ko-KR': LocaleStrings;
|
|
77
|
+
readonly 'zh-CN': LocaleStrings;
|
|
78
|
+
readonly 'zh-TW': LocaleStrings;
|
|
79
|
+
readonly 'th-TH': LocaleStrings;
|
|
80
|
+
readonly 'vi-VN': LocaleStrings;
|
|
81
|
+
readonly 'id-ID': LocaleStrings;
|
|
82
|
+
readonly 'ro-RO': LocaleStrings;
|
|
38
83
|
};
|
|
39
84
|
export type LocaleCode = keyof typeof LOCALES;
|
|
40
85
|
export declare function isRTL(locale: string): boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/i18n/index.ts"],"names":[],"mappings":"AAIA,MAAM,MAAM,SAAS,GAAG,KAAK,GAAG,KAAK,CAAC;AAItC,MAAM,WAAW,aAAa;IAE5B,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;IAClB,QAAQ,EAAE,MAAM,CAAC;IAGjB,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,KAAK,MAAM,CAAC;IAGhD,iBAAiB,EAAE,MAAM,CAAC;IAC1B,cAAc,EAAE,MAAM,CAAC;IAGvB,UAAU,EAAE,MAAM,CAAC;IACnB,KAAK,EAAE,MAAM,CAAC;IAGd,SAAS,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,MAAM,CAAC;IAGf,MAAM,EAAE,MAAM,CAAC;IACf,aAAa,EAAE,MAAM,CAAC;IACtB,cAAc,EAAE,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/i18n/index.ts"],"names":[],"mappings":"AAIA,MAAM,MAAM,SAAS,GAAG,KAAK,GAAG,KAAK,CAAC;AAItC,MAAM,WAAW,aAAa;IAE5B,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;IAClB,QAAQ,EAAE,MAAM,CAAC;IAGjB,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,KAAK,MAAM,CAAC;IAGhD,iBAAiB,EAAE,MAAM,CAAC;IAC1B,cAAc,EAAE,MAAM,CAAC;IAGvB,UAAU,EAAE,MAAM,CAAC;IACnB,KAAK,EAAE,MAAM,CAAC;IAGd,SAAS,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,MAAM,CAAC;IAGf,MAAM,EAAE,MAAM,CAAC;IACf,aAAa,EAAE,MAAM,CAAC;IACtB,cAAc,EAAE,MAAM,CAAC;IACvB,iBAAiB,EAAE,MAAM,CAAC;IAC1B,SAAS,EAAE,MAAM,CAAC;IAClB,YAAY,EAAE,CAAC,CAAC,EAAE,MAAM,KAAK,MAAM,CAAC;CACrC;AAWD,eAAO,MAAM,IAAI,eAyBf,CAAC;AAGH,eAAO,MAAM,IAAI,eAyBf,CAAC;AAGH,eAAO,MAAM,IAAI,eAyBf,CAAC;AAGH,eAAO,MAAM,IAAI,eAyBf,CAAC;AAGH,eAAO,MAAM,IAAI,eAyBf,CAAC;AAGH,eAAO,MAAM,IAAI,eAyBf,CAAC;AAGH,eAAO,MAAM,IAAI,eAyBf,CAAC;AAGH,eAAO,MAAM,IAAI,eAyBf,CAAC;AAGH,eAAO,MAAM,IAAI,eAyBf,CAAC;AAGH,eAAO,MAAM,IAAI,eAyBf,CAAC;AAGH,eAAO,MAAM,IAAI,eAyBf,CAAC;AAGH,eAAO,MAAM,IAAI,eAyBf,CAAC;AAGH,eAAO,MAAM,IAAI,eAyBf,CAAC;AAGH,eAAO,MAAM,IAAI,eAyBf,CAAC;AAGH,eAAO,MAAM,IAAI,eAyBf,CAAC;AAGH,eAAO,MAAM,IAAI,eAyBf,CAAC;AAGH,eAAO,MAAM,IAAI,eAyBf,CAAC;AAGH,eAAO,MAAM,IAAI,eAyBf,CAAC;AAGH,eAAO,MAAM,IAAI,eAyBf,CAAC;AAGH,eAAO,MAAM,IAAI,eAyBf,CAAC;AAGH,eAAO,MAAM,IAAI,eAyBf,CAAC;AAGH,eAAO,MAAM,IAAI,eAyBf,CAAC;AAGH,eAAO,MAAM,IAAI,eAyBf,CAAC;AAGH,eAAO,MAAM,IAAI,eAyBf,CAAC;AAGH,eAAO,MAAM,IAAI,eAyBf,CAAC;AAGH,eAAO,MAAM,IAAI,eAyBf,CAAC;AAGH,eAAO,MAAM,IAAI,eAyBf,CAAC;AAIH,eAAO,MAAM,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA4BV,CAAC;AAEX,MAAM,MAAM,UAAU,GAAG,MAAM,OAAO,OAAO,CAAC;AAM9C,wBAAgB,KAAK,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAE7C;AAID,MAAM,WAAW,gBAAgB;IAC/B,MAAM,EAAE,UAAU,CAAC;IACnB,SAAS,EAAE,SAAS,CAAC;IACrB,OAAO,EAAE,aAAa,CAAC;CACxB;AAED,eAAO,MAAM,WAAW,2CAItB,CAAC;AAEH,wBAAgB,OAAO,IAAI,gBAAgB,CAE1C;AAED,wBAAgB,SAAS,IAAI,aAAa,CAEzC;AAED,wBAAgB,YAAY,IAAI,SAAS,CAExC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/themes/index.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/themes/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAyD,KAAK,SAAS,EAAiB,MAAM,OAAO,CAAC;AAU7G,MAAM,WAAW,WAAW;IAC1B,EAAE,EAAE,MAAM,CAAC;IACX,OAAO,EAAE,MAAM,CAAC;IAChB,UAAU,EAAE,MAAM,CAAC;IACnB,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,MAAM,CAAC;CACd;AAID,eAAO,MAAM,WAAW,EAAE,WAazB,CAAC;AAEF,eAAO,MAAM,WAAW,EAAE,WAazB,CAAC;AAMF,wBAAgB,WAAW,CAAC,IAAI,EAAE,WAAW,EAAE,SAAS,CAAC,EAAE,OAAO,CAAC,WAAW,CAAC,GAAG,WAAW,CAuB5F;AAID,eAAO,MAAM,YAAY,sCAA0C,CAAC;AAEpE,MAAM,WAAW,kBAAkB;IACjC,KAAK,CAAC,EAAE,WAAW,CAAC;IACpB,QAAQ,EAAE,SAAS,CAAC;CACrB;AAED,wBAAgB,aAAa,CAAC,EAAE,KAAmB,EAAE,QAAQ,EAAE,EAAE,kBAAkB,wFAsClF;AAED,wBAAgB,QAAQ,IAAI,WAAW,CAEtC;AAoCD,MAAM,WAAW,YAAY;IAC3B,EAAE,EAAE,MAAM,CAAC;IACX,GAAG,EAAE,MAAM,CAAC;IACZ,GAAG,EAAE,MAAM,CAAC;IACZ,GAAG,EAAE,MAAM,CAAC;IACZ,GAAG,EAAE,MAAM,CAAC;IACZ,GAAG,EAAE,MAAM,CAAC;IACZ,GAAG,EAAE,MAAM,CAAC;IACZ,GAAG,EAAE,MAAM,CAAC;IACZ,GAAG,EAAE,MAAM,CAAC;IACZ,GAAG,EAAE,MAAM,CAAC;CACb;AAED,wBAAgB,eAAe,CAAC,GAAG,EAAE,MAAM,GAAG,YAAY,CAczD;AAID,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAUb,CAAC;AAIX,eAAO,MAAM,OAAO;;;;;;;;;;;;;;;;;CAiBV,CAAC;AAIX,eAAO,MAAM,WAAW;;;;;;CAMd,CAAC;AAIX,eAAO,MAAM,OAAO;;;;;;;;;CASV,CAAC;AAIX,eAAO,MAAM,MAAM;;;;;;;;;;;;CAYT,CAAC;AAIX,eAAO,MAAM,KAAK;;;;;;;;CAQR,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "tekivex-ui",
|
|
3
|
-
"version": "2.
|
|
4
|
-
"description": "
|
|
3
|
+
"version": "2.5.1",
|
|
4
|
+
"description": "Production-grade React component library — 70+ components, WCAG 2.1 AAA, WAI-ARIA 1.2, built-in charts, headless primitives, zero-runtime CSS engine, TypeScript-first.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.cjs",
|
|
7
7
|
"module": "./dist/index.js",
|
|
@@ -15,11 +15,28 @@
|
|
|
15
15
|
"./styles": "./dist/index.css",
|
|
16
16
|
"./themes": {
|
|
17
17
|
"import": "./dist/themes.js",
|
|
18
|
-
"require": "./dist/themes.cjs"
|
|
18
|
+
"require": "./dist/themes.cjs",
|
|
19
|
+
"types": "./dist/themes.d.ts"
|
|
20
|
+
},
|
|
21
|
+
"./charts": {
|
|
22
|
+
"import": "./dist/charts.js",
|
|
23
|
+
"require": "./dist/charts.cjs",
|
|
24
|
+
"types": "./dist/charts.d.ts"
|
|
25
|
+
},
|
|
26
|
+
"./headless": {
|
|
27
|
+
"import": "./dist/headless.js",
|
|
28
|
+
"require": "./dist/headless.cjs",
|
|
29
|
+
"types": "./dist/headless.d.ts"
|
|
19
30
|
}
|
|
20
31
|
},
|
|
21
|
-
"sideEffects": [
|
|
22
|
-
|
|
32
|
+
"sideEffects": [
|
|
33
|
+
"*.css",
|
|
34
|
+
"./src/styles/global.css"
|
|
35
|
+
],
|
|
36
|
+
"files": [
|
|
37
|
+
"dist",
|
|
38
|
+
"src"
|
|
39
|
+
],
|
|
23
40
|
"scripts": {
|
|
24
41
|
"build": "vite build && tsc --emitDeclarationOnly",
|
|
25
42
|
"dev": "vite",
|
|
@@ -39,6 +56,14 @@
|
|
|
39
56
|
"react": ">=18.0.0",
|
|
40
57
|
"react-dom": ">=18.0.0"
|
|
41
58
|
},
|
|
59
|
+
"peerDependenciesMeta": {
|
|
60
|
+
"recharts": {
|
|
61
|
+
"optional": true
|
|
62
|
+
}
|
|
63
|
+
},
|
|
64
|
+
"dependencies": {
|
|
65
|
+
"recharts": "^2.15.4"
|
|
66
|
+
},
|
|
42
67
|
"devDependencies": {
|
|
43
68
|
"@testing-library/jest-dom": "^6.6.3",
|
|
44
69
|
"@testing-library/react": "^16.1.0",
|
|
@@ -62,14 +87,36 @@
|
|
|
62
87
|
"keywords": [
|
|
63
88
|
"react",
|
|
64
89
|
"component-library",
|
|
90
|
+
"ui-library",
|
|
91
|
+
"design-system",
|
|
65
92
|
"wcag",
|
|
66
93
|
"accessibility",
|
|
94
|
+
"a11y",
|
|
67
95
|
"aria",
|
|
96
|
+
"wai-aria",
|
|
68
97
|
"security",
|
|
98
|
+
"xss-protection",
|
|
69
99
|
"typescript",
|
|
70
|
-
"
|
|
100
|
+
"tailwind-alternative",
|
|
101
|
+
"css-in-js",
|
|
102
|
+
"headless",
|
|
103
|
+
"charts",
|
|
104
|
+
"recharts",
|
|
105
|
+
"data-grid",
|
|
106
|
+
"form",
|
|
107
|
+
"validation",
|
|
108
|
+
"dark-mode",
|
|
109
|
+
"rtl",
|
|
110
|
+
"i18n",
|
|
111
|
+
"animation",
|
|
112
|
+
"tekivex",
|
|
113
|
+
"enterprise",
|
|
114
|
+
"zero-runtime"
|
|
71
115
|
],
|
|
72
|
-
"author":
|
|
116
|
+
"author": {
|
|
117
|
+
"name": "007krcs",
|
|
118
|
+
"url": "https://github.com/007krcs"
|
|
119
|
+
},
|
|
73
120
|
"license": "MIT",
|
|
74
121
|
"homepage": "https://ui.tekivex.com/",
|
|
75
122
|
"repository": {
|
|
@@ -78,5 +125,12 @@
|
|
|
78
125
|
},
|
|
79
126
|
"bugs": {
|
|
80
127
|
"url": "https://github.com/007krcs/tekivex-ui/issues"
|
|
128
|
+
},
|
|
129
|
+
"funding": {
|
|
130
|
+
"type": "github",
|
|
131
|
+
"url": "https://github.com/sponsors/007krcs"
|
|
132
|
+
},
|
|
133
|
+
"engines": {
|
|
134
|
+
"node": ">=18.0.0"
|
|
81
135
|
}
|
|
82
136
|
}
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
import {
|
|
2
|
+
ResponsiveContainer,
|
|
3
|
+
AreaChart,
|
|
4
|
+
Area,
|
|
5
|
+
XAxis,
|
|
6
|
+
YAxis,
|
|
7
|
+
CartesianGrid,
|
|
8
|
+
Tooltip,
|
|
9
|
+
Legend,
|
|
10
|
+
} from 'recharts';
|
|
11
|
+
import { useTheme } from '../themes';
|
|
12
|
+
import { getDefaultColors, tooltipStyle, DEFAULT_MARGIN, type ChartMargin } from './shared';
|
|
13
|
+
|
|
14
|
+
export interface TkxAreaChartSeries {
|
|
15
|
+
key: string;
|
|
16
|
+
label?: string;
|
|
17
|
+
color?: string;
|
|
18
|
+
/** Fill opacity. Default: 0.2 */
|
|
19
|
+
fillOpacity?: number;
|
|
20
|
+
/** Whether to stack this series. Default: false */
|
|
21
|
+
stacked?: boolean;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
export interface TkxAreaChartProps {
|
|
25
|
+
data: Record<string, any>[];
|
|
26
|
+
series: TkxAreaChartSeries[];
|
|
27
|
+
xKey: string;
|
|
28
|
+
height?: number;
|
|
29
|
+
margin?: ChartMargin;
|
|
30
|
+
showGrid?: boolean;
|
|
31
|
+
showLegend?: boolean;
|
|
32
|
+
showTooltip?: boolean;
|
|
33
|
+
/** Smooth curves. Default: true */
|
|
34
|
+
smooth?: boolean;
|
|
35
|
+
xTickFormatter?: (value: any) => string;
|
|
36
|
+
yTickFormatter?: (value: any) => string;
|
|
37
|
+
yDomain?: [number | 'auto' | 'dataMin' | 'dataMax', number | 'auto' | 'dataMin' | 'dataMax'];
|
|
38
|
+
/** aria-label for the chart container */
|
|
39
|
+
ariaLabel?: string;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
export function TkxAreaChart({
|
|
43
|
+
data,
|
|
44
|
+
series,
|
|
45
|
+
xKey,
|
|
46
|
+
height = 300,
|
|
47
|
+
margin = DEFAULT_MARGIN,
|
|
48
|
+
showGrid = true,
|
|
49
|
+
showLegend = true,
|
|
50
|
+
showTooltip = true,
|
|
51
|
+
smooth = true,
|
|
52
|
+
xTickFormatter,
|
|
53
|
+
yTickFormatter,
|
|
54
|
+
yDomain,
|
|
55
|
+
ariaLabel = 'Area chart',
|
|
56
|
+
}: TkxAreaChartProps) {
|
|
57
|
+
const theme = useTheme();
|
|
58
|
+
const colors = getDefaultColors(theme);
|
|
59
|
+
const tt = tooltipStyle(theme);
|
|
60
|
+
|
|
61
|
+
const tickStyle = { fill: theme.textMuted, fontSize: 12 };
|
|
62
|
+
|
|
63
|
+
return (
|
|
64
|
+
<div role="img" aria-label={ariaLabel} style={{ width: '100%', height }}>
|
|
65
|
+
<ResponsiveContainer width="100%" height="100%">
|
|
66
|
+
<AreaChart data={data} margin={margin}>
|
|
67
|
+
{showGrid && (
|
|
68
|
+
<CartesianGrid strokeDasharray="3 3" stroke={theme.border} vertical={false} />
|
|
69
|
+
)}
|
|
70
|
+
<XAxis
|
|
71
|
+
dataKey={xKey}
|
|
72
|
+
tick={tickStyle}
|
|
73
|
+
axisLine={{ stroke: theme.border }}
|
|
74
|
+
tickLine={false}
|
|
75
|
+
tickFormatter={xTickFormatter}
|
|
76
|
+
/>
|
|
77
|
+
<YAxis
|
|
78
|
+
tick={tickStyle}
|
|
79
|
+
axisLine={false}
|
|
80
|
+
tickLine={false}
|
|
81
|
+
tickFormatter={yTickFormatter}
|
|
82
|
+
domain={yDomain}
|
|
83
|
+
/>
|
|
84
|
+
{showTooltip && (
|
|
85
|
+
<Tooltip
|
|
86
|
+
contentStyle={tt.contentStyle}
|
|
87
|
+
labelStyle={tt.labelStyle}
|
|
88
|
+
itemStyle={tt.itemStyle}
|
|
89
|
+
cursor={tt.cursor}
|
|
90
|
+
/>
|
|
91
|
+
)}
|
|
92
|
+
{showLegend && (
|
|
93
|
+
<Legend
|
|
94
|
+
wrapperStyle={{ fontSize: 13, color: theme.textMuted, paddingTop: 8 }}
|
|
95
|
+
/>
|
|
96
|
+
)}
|
|
97
|
+
{series.map((s, i) => {
|
|
98
|
+
const color = s.color ?? colors[i % colors.length];
|
|
99
|
+
return (
|
|
100
|
+
<Area
|
|
101
|
+
key={s.key}
|
|
102
|
+
type={smooth ? 'monotone' : 'linear'}
|
|
103
|
+
dataKey={s.key}
|
|
104
|
+
name={s.label ?? s.key}
|
|
105
|
+
stroke={color}
|
|
106
|
+
strokeWidth={2}
|
|
107
|
+
fill={color}
|
|
108
|
+
fillOpacity={s.fillOpacity ?? 0.2}
|
|
109
|
+
stackId={s.stacked ? 'stack' : undefined}
|
|
110
|
+
dot={false}
|
|
111
|
+
activeDot={{ r: 5, strokeWidth: 0 }}
|
|
112
|
+
/>
|
|
113
|
+
);
|
|
114
|
+
})}
|
|
115
|
+
</AreaChart>
|
|
116
|
+
</ResponsiveContainer>
|
|
117
|
+
</div>
|
|
118
|
+
);
|
|
119
|
+
}
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
import {
|
|
2
|
+
ResponsiveContainer,
|
|
3
|
+
BarChart,
|
|
4
|
+
Bar,
|
|
5
|
+
XAxis,
|
|
6
|
+
YAxis,
|
|
7
|
+
CartesianGrid,
|
|
8
|
+
Tooltip,
|
|
9
|
+
Legend,
|
|
10
|
+
Cell,
|
|
11
|
+
} from 'recharts';
|
|
12
|
+
import { useTheme } from '../themes';
|
|
13
|
+
import { getDefaultColors, tooltipStyle, DEFAULT_MARGIN, type ChartMargin } from './shared';
|
|
14
|
+
|
|
15
|
+
export interface TkxBarChartSeries {
|
|
16
|
+
key: string;
|
|
17
|
+
label?: string;
|
|
18
|
+
color?: string;
|
|
19
|
+
/** Stack ID — bars with the same stackId are stacked. */
|
|
20
|
+
stackId?: string;
|
|
21
|
+
radius?: number | [number, number, number, number];
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
export interface TkxBarChartProps {
|
|
25
|
+
data: Record<string, any>[];
|
|
26
|
+
series: TkxBarChartSeries[];
|
|
27
|
+
xKey: string;
|
|
28
|
+
height?: number;
|
|
29
|
+
margin?: ChartMargin;
|
|
30
|
+
showGrid?: boolean;
|
|
31
|
+
showLegend?: boolean;
|
|
32
|
+
showTooltip?: boolean;
|
|
33
|
+
layout?: 'vertical' | 'horizontal';
|
|
34
|
+
barSize?: number;
|
|
35
|
+
/** Use gradient fill per series. Default: false */
|
|
36
|
+
gradient?: boolean;
|
|
37
|
+
xTickFormatter?: (value: any) => string;
|
|
38
|
+
yTickFormatter?: (value: any) => string;
|
|
39
|
+
ariaLabel?: string;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
export function TkxBarChart({
|
|
43
|
+
data,
|
|
44
|
+
series,
|
|
45
|
+
xKey,
|
|
46
|
+
height = 300,
|
|
47
|
+
margin = DEFAULT_MARGIN,
|
|
48
|
+
showGrid = true,
|
|
49
|
+
showLegend = true,
|
|
50
|
+
showTooltip = true,
|
|
51
|
+
layout = 'horizontal',
|
|
52
|
+
barSize,
|
|
53
|
+
xTickFormatter,
|
|
54
|
+
yTickFormatter,
|
|
55
|
+
ariaLabel = 'Bar chart',
|
|
56
|
+
}: TkxBarChartProps) {
|
|
57
|
+
const theme = useTheme();
|
|
58
|
+
const colors = getDefaultColors(theme);
|
|
59
|
+
const tt = tooltipStyle(theme);
|
|
60
|
+
const tickStyle = { fill: theme.textMuted, fontSize: 12 };
|
|
61
|
+
const isVertical = layout === 'vertical';
|
|
62
|
+
|
|
63
|
+
return (
|
|
64
|
+
<div role="img" aria-label={ariaLabel} style={{ width: '100%', height }}>
|
|
65
|
+
<ResponsiveContainer width="100%" height="100%">
|
|
66
|
+
<BarChart data={data} margin={margin} layout={layout}>
|
|
67
|
+
{showGrid && (
|
|
68
|
+
<CartesianGrid
|
|
69
|
+
strokeDasharray="3 3"
|
|
70
|
+
stroke={theme.border}
|
|
71
|
+
vertical={isVertical}
|
|
72
|
+
horizontal={!isVertical}
|
|
73
|
+
/>
|
|
74
|
+
)}
|
|
75
|
+
{isVertical ? (
|
|
76
|
+
<>
|
|
77
|
+
<YAxis dataKey={xKey} type="category" tick={tickStyle} axisLine={false} tickLine={false} tickFormatter={xTickFormatter} width={100} />
|
|
78
|
+
<XAxis type="number" tick={tickStyle} axisLine={{ stroke: theme.border }} tickLine={false} tickFormatter={yTickFormatter} />
|
|
79
|
+
</>
|
|
80
|
+
) : (
|
|
81
|
+
<>
|
|
82
|
+
<XAxis dataKey={xKey} tick={tickStyle} axisLine={{ stroke: theme.border }} tickLine={false} tickFormatter={xTickFormatter} />
|
|
83
|
+
<YAxis tick={tickStyle} axisLine={false} tickLine={false} tickFormatter={yTickFormatter} />
|
|
84
|
+
</>
|
|
85
|
+
)}
|
|
86
|
+
{showTooltip && (
|
|
87
|
+
<Tooltip
|
|
88
|
+
contentStyle={tt.contentStyle}
|
|
89
|
+
labelStyle={tt.labelStyle}
|
|
90
|
+
itemStyle={tt.itemStyle}
|
|
91
|
+
cursor={{ fill: `${theme.surfaceAlt}` }}
|
|
92
|
+
/>
|
|
93
|
+
)}
|
|
94
|
+
{showLegend && (
|
|
95
|
+
<Legend wrapperStyle={{ fontSize: 13, color: theme.textMuted, paddingTop: 8 }} />
|
|
96
|
+
)}
|
|
97
|
+
{series.map((s, i) => {
|
|
98
|
+
const color = s.color ?? colors[i % colors.length];
|
|
99
|
+
return (
|
|
100
|
+
<Bar
|
|
101
|
+
key={s.key}
|
|
102
|
+
dataKey={s.key}
|
|
103
|
+
name={s.label ?? s.key}
|
|
104
|
+
fill={color}
|
|
105
|
+
stackId={s.stackId}
|
|
106
|
+
maxBarSize={barSize ?? 40}
|
|
107
|
+
radius={s.radius ?? [4, 4, 0, 0]}
|
|
108
|
+
/>
|
|
109
|
+
);
|
|
110
|
+
})}
|
|
111
|
+
</BarChart>
|
|
112
|
+
</ResponsiveContainer>
|
|
113
|
+
</div>
|
|
114
|
+
);
|
|
115
|
+
}
|