shared-design-system 1.2.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/README.md +258 -0
- package/dist/components/Alert.d.ts +9 -0
- package/dist/components/Alert.js +58 -0
- package/dist/components/Alert.js.map +1 -0
- package/dist/components/Avatar.d.ts +8 -0
- package/dist/components/Avatar.js +43 -0
- package/dist/components/Avatar.js.map +1 -0
- package/dist/components/Badge.d.ts +5 -0
- package/dist/components/Badge.js +55 -0
- package/dist/components/Badge.js.map +1 -0
- package/dist/components/Breadcrumbs.d.ts +10 -0
- package/dist/components/Breadcrumbs.js +31 -0
- package/dist/components/Breadcrumbs.js.map +1 -0
- package/dist/components/Button.d.ts +7 -0
- package/dist/components/Button.js +77 -0
- package/dist/components/Button.js.map +1 -0
- package/dist/components/Card.d.ts +8 -0
- package/dist/components/Card.js +39 -0
- package/dist/components/Card.js.map +1 -0
- package/dist/components/ConfirmModal.d.ts +12 -0
- package/dist/components/ConfirmModal.js +53 -0
- package/dist/components/ConfirmModal.js.map +1 -0
- package/dist/components/Divider.d.ts +6 -0
- package/dist/components/Divider.js +35 -0
- package/dist/components/Divider.js.map +1 -0
- package/dist/components/InputComponents.d.ts +23 -0
- package/dist/components/InputComponents.js +83 -0
- package/dist/components/InputComponents.js.map +1 -0
- package/dist/components/ListComponents.d.ts +13 -0
- package/dist/components/ListComponents.js +28 -0
- package/dist/components/ListComponents.js.map +1 -0
- package/dist/components/LoadingSpinner.d.ts +7 -0
- package/dist/components/LoadingSpinner.js +21 -0
- package/dist/components/LoadingSpinner.js.map +1 -0
- package/dist/components/Progress.d.ts +9 -0
- package/dist/components/Progress.js +43 -0
- package/dist/components/Progress.js.map +1 -0
- package/dist/components/Radio.d.ts +21 -0
- package/dist/components/Radio.js +51 -0
- package/dist/components/Radio.js.map +1 -0
- package/dist/components/ReadOnlyField.d.ts +6 -0
- package/dist/components/ReadOnlyField.js +21 -0
- package/dist/components/ReadOnlyField.js.map +1 -0
- package/dist/components/Skeleton.d.ts +7 -0
- package/dist/components/Skeleton.js +28 -0
- package/dist/components/Skeleton.js.map +1 -0
- package/dist/components/Stack.d.ts +9 -0
- package/dist/components/Stack.js +28 -0
- package/dist/components/Stack.js.map +1 -0
- package/dist/components/Steps.d.ts +14 -0
- package/dist/components/Steps.js +84 -0
- package/dist/components/Steps.js.map +1 -0
- package/dist/components/Switch.d.ts +5 -0
- package/dist/components/Switch.js +39 -0
- package/dist/components/Switch.js.map +1 -0
- package/dist/components/Table.d.ts +31 -0
- package/dist/components/Table.js +54 -0
- package/dist/components/Table.js.map +1 -0
- package/dist/components/Tabs.d.ts +15 -0
- package/dist/components/Tabs.js +42 -0
- package/dist/components/Tabs.js.map +1 -0
- package/dist/components/Tag.d.ts +7 -0
- package/dist/components/Tag.js +43 -0
- package/dist/components/Tag.js.map +1 -0
- package/dist/components/Tooltip.d.ts +6 -0
- package/dist/components/Tooltip.js +43 -0
- package/dist/components/Tooltip.js.map +1 -0
- package/dist/components/Typography.d.ts +16 -0
- package/dist/components/Typography.js +68 -0
- package/dist/components/Typography.js.map +1 -0
- package/dist/index.d.ts +48 -0
- package/dist/index.js +29 -0
- package/dist/index.js.map +1 -0
- package/dist/tokens.d.ts +69 -0
- package/dist/tokens.js +69 -0
- package/dist/tokens.js.map +1 -0
- package/package.json +45 -0
- package/tailwind.preset.js +23 -0
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import { tokens } from '../tokens';
|
|
4
|
+
export const Steps = ({ current = 0, items = [], direction = 'horizontal', className = '', style = {}, }) => {
|
|
5
|
+
const containerStyle = {
|
|
6
|
+
display: 'flex',
|
|
7
|
+
flexDirection: direction === 'vertical' ? 'column' : 'row',
|
|
8
|
+
gap: tokens.spacing['4'],
|
|
9
|
+
width: '100%',
|
|
10
|
+
...style,
|
|
11
|
+
};
|
|
12
|
+
return (_jsx("div", { style: containerStyle, className: className, children: items.map((item, index) => {
|
|
13
|
+
const status = index < current ? 'finish' : index === current ? 'process' : 'wait';
|
|
14
|
+
return (_jsx(React.Fragment, { children: _jsx(StepItemComponent, { index: index, status: status, title: item.title, description: item.description, direction: direction, isLast: index === items.length - 1 }) }, index));
|
|
15
|
+
}) }));
|
|
16
|
+
};
|
|
17
|
+
const getColors = (status) => {
|
|
18
|
+
switch (status) {
|
|
19
|
+
case 'finish':
|
|
20
|
+
return { main: tokens.color.primary, bg: tokens.color.primaryLight, text: tokens.color.primary };
|
|
21
|
+
case 'process':
|
|
22
|
+
return { main: tokens.color.primary, bg: tokens.color.primary, text: '#ffffff' };
|
|
23
|
+
case 'wait':
|
|
24
|
+
default:
|
|
25
|
+
return { main: tokens.color.border, bg: tokens.color.surfaceAlt, text: tokens.color.textMuted };
|
|
26
|
+
}
|
|
27
|
+
};
|
|
28
|
+
const StepItemComponent = ({ index, status, title, description, direction, isLast, }) => {
|
|
29
|
+
const isHorizontal = direction === 'horizontal';
|
|
30
|
+
const c = getColors(status);
|
|
31
|
+
const itemStyle = {
|
|
32
|
+
display: 'flex',
|
|
33
|
+
flexDirection: isHorizontal ? 'column' : 'row',
|
|
34
|
+
flex: isHorizontal ? (isLast ? 'none' : 1) : 'none',
|
|
35
|
+
alignItems: isHorizontal ? 'center' : 'flex-start',
|
|
36
|
+
gap: tokens.spacing['2'],
|
|
37
|
+
position: 'relative',
|
|
38
|
+
minWidth: isHorizontal ? (isLast ? 'auto' : '150px') : 'auto',
|
|
39
|
+
marginBottom: isHorizontal ? 0 : isLast ? 0 : tokens.spacing['8'],
|
|
40
|
+
};
|
|
41
|
+
const iconStyle = {
|
|
42
|
+
width: '32px',
|
|
43
|
+
height: '32px',
|
|
44
|
+
borderRadius: '50%',
|
|
45
|
+
display: 'flex',
|
|
46
|
+
alignItems: 'center',
|
|
47
|
+
justifyContent: 'center',
|
|
48
|
+
border: `2px solid ${c.main}`,
|
|
49
|
+
backgroundColor: c.bg,
|
|
50
|
+
color: c.text,
|
|
51
|
+
fontSize: tokens.font.sm,
|
|
52
|
+
fontWeight: tokens.font.weightBold,
|
|
53
|
+
zIndex: 2,
|
|
54
|
+
flexShrink: 0,
|
|
55
|
+
};
|
|
56
|
+
const lineStyle = {
|
|
57
|
+
position: 'absolute',
|
|
58
|
+
backgroundColor: status === 'finish' ? tokens.color.primary : tokens.color.border,
|
|
59
|
+
zIndex: 1,
|
|
60
|
+
...(isHorizontal
|
|
61
|
+
? {
|
|
62
|
+
height: '2px',
|
|
63
|
+
top: '16px',
|
|
64
|
+
left: 'calc(50% + 20px)',
|
|
65
|
+
right: 'calc(-50% + 20px)',
|
|
66
|
+
}
|
|
67
|
+
: {
|
|
68
|
+
width: '2px',
|
|
69
|
+
left: '16px',
|
|
70
|
+
top: '36px',
|
|
71
|
+
bottom: '-20px',
|
|
72
|
+
}),
|
|
73
|
+
};
|
|
74
|
+
return (_jsxs("div", { style: itemStyle, children: [!isLast && _jsx("div", { style: lineStyle }), _jsx("div", { style: iconStyle, children: status === 'finish' ? (_jsx("svg", { width: "18", height: "18", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 3, children: _jsx("polyline", { points: "20 6 9 17 4 12" }) })) : (index + 1) }), _jsxs("div", { style: {
|
|
75
|
+
textAlign: isHorizontal ? 'center' : 'left',
|
|
76
|
+
marginTop: isHorizontal ? tokens.spacing['2'] : '4px',
|
|
77
|
+
paddingLeft: isHorizontal ? 0 : tokens.spacing['2'],
|
|
78
|
+
}, children: [_jsx("div", { style: {
|
|
79
|
+
fontSize: tokens.font.sm,
|
|
80
|
+
fontWeight: status === 'process' ? tokens.font.weightBold : tokens.font.weightMedium,
|
|
81
|
+
color: status === 'wait' ? tokens.color.textMuted : tokens.color.text,
|
|
82
|
+
}, children: title }), description && (_jsx("div", { style: { fontSize: tokens.font.xs, color: tokens.color.textMuted, marginTop: '2px' }, children: description }))] })] }));
|
|
83
|
+
};
|
|
84
|
+
//# sour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AAQ,EAAE,MAAM,CAAC,IAAI,CAAC,EAAE,EAAE,KAAK,EAAE,MAAM,CAAC,KAAK,CAAC,SAAS,EAAE,SAAS,EAAE,KAAK,EAAE,YACtF,WAAW,GACR,CACP,IACG,IACF,CACP,CAAC;AACJ,CAAC,CAAC"}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { tokens } from '../tokens';
|
|
3
|
+
export const Switch = ({ checked, onChange, disabled = false, label, className = '', style = {}, ...props }) => {
|
|
4
|
+
const containerStyle = {
|
|
5
|
+
display: 'inline-flex',
|
|
6
|
+
alignItems: 'center',
|
|
7
|
+
gap: tokens.spacing[3],
|
|
8
|
+
cursor: disabled ? 'not-allowed' : 'pointer',
|
|
9
|
+
opacity: disabled ? 0.6 : 1,
|
|
10
|
+
...style
|
|
11
|
+
};
|
|
12
|
+
const trackStyle = {
|
|
13
|
+
position: 'relative',
|
|
14
|
+
width: '44px',
|
|
15
|
+
height: '24px',
|
|
16
|
+
backgroundColor: checked ? tokens.color.primary : tokens.color.border,
|
|
17
|
+
borderRadius: tokens.radius.full,
|
|
18
|
+
transition: tokens.transition.normal,
|
|
19
|
+
flexShrink: 0
|
|
20
|
+
};
|
|
21
|
+
const thumbStyle = {
|
|
22
|
+
position: 'absolute',
|
|
23
|
+
top: '2px',
|
|
24
|
+
left: checked ? '22px' : '2px',
|
|
25
|
+
width: '20px',
|
|
26
|
+
height: '20px',
|
|
27
|
+
backgroundColor: 'white',
|
|
28
|
+
borderRadius: '50%',
|
|
29
|
+
transition: tokens.transition.normal,
|
|
30
|
+
boxShadow: '0 1px 3px rgba(0,0,0,0.2)'
|
|
31
|
+
};
|
|
32
|
+
return (_jsxs("label", { style: containerStyle, className: className, children: [_jsxs("div", { style: { position: 'relative' }, children: [_jsx("input", { type: "checkbox", checked: checked, onChange: onChange, disabled: disabled, style: {
|
|
33
|
+
position: 'absolute',
|
|
34
|
+
opacity: 0,
|
|
35
|
+
width: 0,
|
|
36
|
+
height: 0
|
|
37
|
+
}, ...props }), _jsx("div", { style: trackStyle, children: _jsx("div", { style: thumbStyle }) })] }), label && _jsx("span", { style: { fontSize: tokens.font.sm, fontWeight: tokens.font.weightMedium, color: tokens.color.text }, children: label })] }));
|
|
38
|
+
};
|
|
39
|
+
//# sourceMappingURL=Switch.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Switch.js","sourceRoot":"","sources":["../../src/components/Switch.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,MAAM,EAAE,MAAM,WAAW,CAAC;AAMnC,MAAM,CAAC,MAAM,MAAM,GAA0B,CAAC,EAC5C,OAAO,EACP,QAAQ,EACR,QAAQ,GAAG,KAAK,EAChB,KAAK,EACL,SAAS,GAAG,EAAE,EACd,KAAK,GAAG,EAAE,EACV,GAAG,KAAK,EACT,EAAE,EAAE;IACH,MAAM,cAAc,GAAwB;QAC1C,OAAO,EAAE,aAAa;QACtB,UAAU,EAAE,QAAQ;QACpB,GAAG,EAAE,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC;QACtB,MAAM,EAAE,QAAQ,CAAC,CAAC,CAAC,aAAa,CAAC,CAAC,CAAC,SAAS;QAC5C,OAAO,EAAE,QAAQ,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;QAC3B,GAAG,KAAK;KACT,CAAC;IAEF,MAAM,UAAU,GAAwB;QACtC,QAAQ,EAAE,UAAU;QACpB,KAAK,EAAE,MAAM;QACb,MAAM,EAAE,MAAM;QACd,eAAe,EAAE,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,MAAM;QACrE,YAAY,EAAE,MAAM,CAAC,MAAM,CAAC,IAAI;QAChC,UAAU,EAAE,MAAM,CAAC,UAAU,CAAC,MAAM;QACpC,UAAU,EAAE,CAAC;KACd,CAAC;IAEF,MAAM,UAAU,GAAwB;QACtC,QAAQ,EAAE,UAAU;QACpB,GAAG,EAAE,KAAK;QACV,IAAI,EAAE,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,KAAK;QAC9B,KAAK,EAAE,MAAM;QACb,MAAM,EAAE,MAAM;QACd,eAAe,EAAE,OAAO;QACxB,YAAY,EAAE,KAAK;QACnB,UAAU,EAAE,MAAM,CAAC,UAAU,CAAC,MAAM;QACpC,SAAS,EAAE,2BAA2B;KACvC,CAAC;IAEF,OAAO,CACL,iBAAO,KAAK,EAAE,cAAc,EAAE,SAAS,EAAE,SAAS,aAChD,eAAK,KAAK,EAAE,EAAE,QAAQ,EAAE,UAAU,EAAE,aAClC,gBACE,IAAI,EAAC,UAAU,EACf,OAAO,EAAE,OAAO,EAChB,QAAQ,EAAE,QAAQ,EAClB,QAAQ,EAAE,QAAQ,EAClB,KAAK,EAAE;4BACL,QAAQ,EAAE,UAAU;4BACpB,OAAO,EAAE,CAAC;4BACV,KAAK,EAAE,CAAC;4BACR,MAAM,EAAE,CAAC;yBACV,KACG,KAAK,GACT,EACF,cAAK,KAAK,EAAE,UAAU,YACpB,cAAK,KAAK,EAAE,UAAU,GAAI,GACtB,IACF,EACL,KAAK,IAAI,eAAM,KAAK,EAAE,EAAE,QAAQ,EAAE,MAAM,CAAC,IAAI,CAAC,EAAE,EAAE,UAAU,EAAE,MAAM,CAAC,IAAI,CAAC,YAAY,EAAE,KAAK,EAAE,MAAM,CAAC,KAAK,CAAC,IAAI,EAAE,YAAG,KAAK,GAAQ,IAC7H,CACT,CAAC;AACJ,CAAC,CAAC"}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export interface TableContainerProps {
|
|
3
|
+
children: React.ReactNode;
|
|
4
|
+
className?: string;
|
|
5
|
+
style?: React.CSSProperties;
|
|
6
|
+
}
|
|
7
|
+
export declare const TableContainer: React.FC<TableContainerProps>;
|
|
8
|
+
export interface THeadProps {
|
|
9
|
+
children: React.ReactNode;
|
|
10
|
+
}
|
|
11
|
+
export declare const THead: React.FC<THeadProps>;
|
|
12
|
+
export interface TBodyProps {
|
|
13
|
+
children: React.ReactNode;
|
|
14
|
+
}
|
|
15
|
+
export declare const TBody: React.FC<TBodyProps>;
|
|
16
|
+
export interface TRProps {
|
|
17
|
+
children: React.ReactNode;
|
|
18
|
+
onClick?: React.MouseEventHandler<HTMLTableRowElement>;
|
|
19
|
+
active?: boolean;
|
|
20
|
+
}
|
|
21
|
+
export declare const TR: React.FC<TRProps>;
|
|
22
|
+
export interface THProps {
|
|
23
|
+
children?: React.ReactNode;
|
|
24
|
+
style?: React.CSSProperties;
|
|
25
|
+
}
|
|
26
|
+
export declare const TH: React.FC<THProps>;
|
|
27
|
+
export interface TDProps {
|
|
28
|
+
children?: React.ReactNode;
|
|
29
|
+
style?: React.CSSProperties;
|
|
30
|
+
}
|
|
31
|
+
export declare const TD: React.FC<TDProps>;
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { tokens } from '../tokens';
|
|
3
|
+
export const TableContainer = ({ children, className = '', style = {} }) => (_jsx("div", { style: {
|
|
4
|
+
width: '100%',
|
|
5
|
+
overflowX: 'auto',
|
|
6
|
+
backgroundColor: tokens.color.surface,
|
|
7
|
+
borderRadius: tokens.radius.xl,
|
|
8
|
+
border: `1px solid ${tokens.color.border}`,
|
|
9
|
+
boxShadow: tokens.shadow.sm,
|
|
10
|
+
...style,
|
|
11
|
+
}, className: className, children: _jsx("table", { style: {
|
|
12
|
+
width: '100%',
|
|
13
|
+
borderCollapse: 'collapse',
|
|
14
|
+
textAlign: 'left',
|
|
15
|
+
fontSize: tokens.font.sm,
|
|
16
|
+
fontFamily: tokens.font.family,
|
|
17
|
+
}, children: children }) }));
|
|
18
|
+
export const THead = ({ children }) => (_jsx("thead", { style: {
|
|
19
|
+
backgroundColor: tokens.color.surfaceAlt,
|
|
20
|
+
borderBottom: `2px solid ${tokens.color.border}`,
|
|
21
|
+
}, children: children }));
|
|
22
|
+
export const TBody = ({ children }) => (_jsx("tbody", { style: { backgroundColor: tokens.color.surface }, children: children }));
|
|
23
|
+
export const TR = ({ children, onClick, active = false }) => (_jsx("tr", { onClick: onClick, style: {
|
|
24
|
+
borderBottom: `1px solid ${tokens.color.surfaceAlt}`,
|
|
25
|
+
backgroundColor: active ? tokens.color.primaryLight + '44' : 'transparent',
|
|
26
|
+
transition: tokens.transition.fast,
|
|
27
|
+
cursor: onClick ? 'pointer' : 'default',
|
|
28
|
+
}, onMouseEnter: onClick
|
|
29
|
+
? (e) => {
|
|
30
|
+
e.currentTarget.style.backgroundColor = tokens.color.surfaceAlt;
|
|
31
|
+
}
|
|
32
|
+
: undefined, onMouseLeave: onClick
|
|
33
|
+
? (e) => {
|
|
34
|
+
e.currentTarget.style.backgroundColor = active
|
|
35
|
+
? tokens.color.primaryLight + '44'
|
|
36
|
+
: 'transparent';
|
|
37
|
+
}
|
|
38
|
+
: undefined, children: children }));
|
|
39
|
+
export const TH = ({ children, style = {} }) => (_jsx("th", { style: {
|
|
40
|
+
padding: `${tokens.spacing['4']} ${tokens.spacing['4']}`,
|
|
41
|
+
fontWeight: tokens.font.weightBold,
|
|
42
|
+
color: tokens.color.textMuted,
|
|
43
|
+
textTransform: 'uppercase',
|
|
44
|
+
letterSpacing: '0.05em',
|
|
45
|
+
fontSize: tokens.font.xs,
|
|
46
|
+
...style,
|
|
47
|
+
}, children: children }));
|
|
48
|
+
export const TD = ({ children, style = {} }) => (_jsx("td", { style: {
|
|
49
|
+
padding: `${tokens.spacing['4']} ${tokens.spacing['4']}`,
|
|
50
|
+
color: tokens.color.text,
|
|
51
|
+
verticalAlign: 'middle',
|
|
52
|
+
...style,
|
|
53
|
+
}, children: children }));
|
|
54
|
+
//# sourceMappingURL=Table.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Table.js","sourceRoot":"","s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SAAS;QAC7B,aAAa,EAAE,WAAW;QAC1B,aAAa,EAAE,QAAQ;QACvB,QAAQ,EAAE,MAAM,CAAC,IAAI,CAAC,EAAE;QACxB,GAAG,KAAK;KACT,YAEA,QAAQ,GACN,CACN,CAAC;AAOF,MAAM,CAAC,MAAM,EAAE,GAAsB,CAAC,EAAE,QAAQ,EAAE,KAAK,GAAG,EAAE,EAAE,EAAE,EAAE,CAAC,CACjE,aACE,KAAK,EAAE;QACL,OAAO,EAAE,GAAG,MAAM,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,GAAG,CAAC,EAAE;QACxD,KAAK,EAAE,MAAM,CAAC,KAAK,CAAC,IAAI;QACxB,aAAa,EAAE,QAAQ;QACvB,GAAG,KAAK;KACT,YAEA,QAAQ,GACN,CACN,CAAC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export interface TabProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
3
|
+
label: string;
|
|
4
|
+
value: any;
|
|
5
|
+
icon?: React.ReactNode;
|
|
6
|
+
active?: boolean;
|
|
7
|
+
variant?: 'standard' | 'pills';
|
|
8
|
+
}
|
|
9
|
+
export interface TabsProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
10
|
+
value: any;
|
|
11
|
+
onChange: (value: any) => void;
|
|
12
|
+
variant?: 'standard' | 'pills';
|
|
13
|
+
}
|
|
14
|
+
export declare const Tabs: React.FC<TabsProps>;
|
|
15
|
+
export declare const Tab: React.FC<TabProps>;
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import { tokens } from '../tokens';
|
|
4
|
+
export const Tabs = ({ value, onChange, children, variant = 'standard', className = '', style = {} }) => {
|
|
5
|
+
const containerStyle = {
|
|
6
|
+
display: 'flex',
|
|
7
|
+
borderBottom: variant === 'standard' ? `1px solid ${tokens.color.border}` : 'none',
|
|
8
|
+
gap: tokens.spacing[4],
|
|
9
|
+
width: '100%',
|
|
10
|
+
overflowX: 'auto',
|
|
11
|
+
...style
|
|
12
|
+
};
|
|
13
|
+
return (_jsx("div", { style: containerStyle, className: className, children: React.Children.map(children, child => {
|
|
14
|
+
if (!React.isValidElement(child))
|
|
15
|
+
return null;
|
|
16
|
+
return React.cloneElement(child, {
|
|
17
|
+
active: child.props.value === value,
|
|
18
|
+
onClick: () => onChange(child.props.value),
|
|
19
|
+
variant
|
|
20
|
+
});
|
|
21
|
+
}) }));
|
|
22
|
+
};
|
|
23
|
+
export const Tab = ({ label, value, icon, active, onClick, variant, className = '', style = {} }) => {
|
|
24
|
+
const tabStyle = {
|
|
25
|
+
display: 'flex',
|
|
26
|
+
alignItems: 'center',
|
|
27
|
+
gap: tokens.spacing[2],
|
|
28
|
+
padding: `${tokens.spacing[3]} ${tokens.spacing[4]}`,
|
|
29
|
+
fontSize: tokens.font.sm,
|
|
30
|
+
fontWeight: active ? tokens.font.weightBold : tokens.font.weightMedium,
|
|
31
|
+
color: active ? tokens.color.primary : tokens.color.textMuted,
|
|
32
|
+
cursor: 'pointer',
|
|
33
|
+
borderBottom: active && variant === 'standard' ? `2px solid ${tokens.color.primary}` : '2px solid transparent',
|
|
34
|
+
transition: tokens.transition.fast,
|
|
35
|
+
backgroundColor: active && variant === 'pills' ? tokens.color.primaryLight : 'transparent',
|
|
36
|
+
borderRadius: variant === 'pills' ? tokens.radius.md : '0',
|
|
37
|
+
whiteSpace: 'nowrap',
|
|
38
|
+
...style
|
|
39
|
+
};
|
|
40
|
+
return (_jsxs("div", { style: tabStyle, onClick: onClick, className: className, children: [icon && _jsx("span", { style: { display: 'flex' }, children: icon }), label] }));
|
|
41
|
+
};
|
|
42
|
+
//# sourceMappingURL=Tabs.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Tabs.js","sourceRoot":"","sources":["../../src/components/Tabs.tsx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C;AACJ,CAAC,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export interface TagProps extends React.HTMLAttributes<HTMLSpanElement> {
|
|
3
|
+
color?: 'primary' | 'success' | 'warning' | 'danger' | 'info' | 'slate';
|
|
4
|
+
variant?: 'light' | 'solid' | 'outline';
|
|
5
|
+
onClose?: () => void;
|
|
6
|
+
}
|
|
7
|
+
export declare const Tag: React.FC<TagProps>;
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { tokens } from '../tokens';
|
|
3
|
+
export const Tag = ({ children, color = 'slate', variant = 'light', className = '', style = {}, onClose, ...props }) => {
|
|
4
|
+
const getColorScheme = () => {
|
|
5
|
+
switch (color) {
|
|
6
|
+
case 'primary': return { bg: tokens.color.primary, text: '#ffffff', lightBg: tokens.color.primaryLight, lightText: tokens.color.primary };
|
|
7
|
+
case 'success': return { bg: tokens.color.success, text: '#ffffff', lightBg: tokens.color.successBg, lightText: tokens.color.success };
|
|
8
|
+
case 'warning': return { bg: tokens.color.warning, text: '#ffffff', lightBg: tokens.color.warningBg, lightText: tokens.color.warning };
|
|
9
|
+
case 'danger': return { bg: tokens.color.danger, text: '#ffffff', lightBg: tokens.color.dangerBg, lightText: tokens.color.danger };
|
|
10
|
+
case 'info': return { bg: tokens.color.info, text: '#ffffff', lightBg: tokens.color.infoBg, lightText: tokens.color.info };
|
|
11
|
+
case 'slate':
|
|
12
|
+
default: return { bg: tokens.color.text, text: '#ffffff', lightBg: tokens.color.surfaceAlt, lightText: tokens.color.textMuted };
|
|
13
|
+
}
|
|
14
|
+
};
|
|
15
|
+
const c = getColorScheme();
|
|
16
|
+
const baseStyle = {
|
|
17
|
+
display: 'inline-flex',
|
|
18
|
+
alignItems: 'center',
|
|
19
|
+
gap: tokens.spacing[1],
|
|
20
|
+
padding: `2px ${tokens.spacing[2]}`,
|
|
21
|
+
borderRadius: tokens.radius.sm,
|
|
22
|
+
fontSize: '11px',
|
|
23
|
+
fontWeight: tokens.font.weightBold,
|
|
24
|
+
backgroundColor: variant === 'solid' ? c.bg : c.lightBg,
|
|
25
|
+
color: variant === 'solid' ? c.text : c.lightText,
|
|
26
|
+
border: variant === 'outline' ? `1px solid ${c.bg}` : '1px solid transparent',
|
|
27
|
+
transition: tokens.transition.fast,
|
|
28
|
+
userSelect: 'none',
|
|
29
|
+
...style
|
|
30
|
+
};
|
|
31
|
+
if (variant === 'outline') {
|
|
32
|
+
baseStyle.backgroundColor = 'transparent';
|
|
33
|
+
baseStyle.color = c.lightText;
|
|
34
|
+
}
|
|
35
|
+
return (_jsxs("span", { style: baseStyle, className: className, ...props, children: [children, onClose && (_jsx("span", { onClick: (e) => { e.stopPropagation(); onClose(); }, style: {
|
|
36
|
+
cursor: 'pointer',
|
|
37
|
+
marginLeft: '2px',
|
|
38
|
+
display: 'inline-flex',
|
|
39
|
+
opacity: 0.7,
|
|
40
|
+
transition: 'opacity 0.2s'
|
|
41
|
+
}, onMouseEnter: (e) => e.currentTarget.style.opacity = '1', onMouseLeave: (e) => e.currentTarget.style.opacity = '0.7', children: _jsx("svg", { width: "10", height: "10", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "3", children: _jsx("path", { d: "M18 6L6 18M6 6l12 12" }) }) }))] }));
|
|
42
|
+
};
|
|
43
|
+
//# sourceMappingURL=Tag.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Tag.js","sourceRoot":"","sources":["../../src/components/Tag.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,MAAM,EAAE,MAAM,WAAW,CAAC;AAQnC,MAAM,CAAC,MAAM,GAAG,GAAuB,CAAC,EACtC,QAAQ,EACR,KAAK,GAAG,OAAO,EACf,OAAO,GAAG,OAAO,EACjB,SAAS,GAAG,EAAE,EACd,KAAK,GAAG,EAAE,EACV,OAAO,EACP,GAAG,KAAK,EACT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EACR,OAAO,IAAI,CACV,eACE,OAAO,EAAE,CAAC,CAAC,EAAE,EAAE,GAAG,CAAC,CAAC,eAAe,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,CAAC,CAAC,EACnD,KAAK,EAAE;oBACL,MAAM,EAAE,SAAS;oBACjB,UAAU,EAAE,KAAK;oBACjB,OAAO,EAAE,aAAa;oBACtB,OAAO,EAAE,GAAG;oBACZ,UAAU,EAAE,cAAc;iBAC3B,EACD,YAAY,EAAE,CAAC,CAAC,EAAE,EAAE,CAAE,CAAC,CAAC,aAA6B,CAAC,KAAK,CAAC,OAAO,GAAG,GAAG,EACzE,YAAY,EAAE,CAAC,CAAC,EAAE,EAAE,CAAE,CAAC,CAAC,aAA6B,CAAC,KAAK,CAAC,OAAO,GAAG,KAAK,YAE3E,cAAK,KAAK,EAAC,IAAI,EAAC,MAAM,EAAC,IAAI,EAAC,OAAO,EAAC,WAAW,EAAC,IAAI,EAAC,MAAM,EAAC,MAAM,EAAC,cAAc,EAAC,WAAW,EAAC,GAAG,YAAC,eAAM,CAAC,EAAC,sBAAsB,GAAG,GAAM,GACpI,CACR,IACI,CACR,CAAC;AACJ,CAAC,CAAC"}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { useState } from 'react';
|
|
3
|
+
import { tokens } from '../tokens';
|
|
4
|
+
export const Tooltip = ({ children, title, position = 'top', className = '', style = {} }) => {
|
|
5
|
+
const [isVisible, setIsVisible] = useState(false);
|
|
6
|
+
const containerStyle = {
|
|
7
|
+
position: 'relative',
|
|
8
|
+
display: 'inline-flex',
|
|
9
|
+
...style
|
|
10
|
+
};
|
|
11
|
+
const getPositionStyles = () => {
|
|
12
|
+
switch (position) {
|
|
13
|
+
case 'bottom':
|
|
14
|
+
return { top: '100%', left: '50%', transform: 'translateX(-50%)', marginTop: '8px' };
|
|
15
|
+
case 'left':
|
|
16
|
+
return { top: '50%', right: '100%', transform: 'translateY(-50%)', marginRight: '8px' };
|
|
17
|
+
case 'right':
|
|
18
|
+
return { top: '50%', left: '100%', transform: 'translateY(-50%)', marginLeft: '8px' };
|
|
19
|
+
case 'top':
|
|
20
|
+
default:
|
|
21
|
+
return { bottom: '100%', left: '50%', transform: 'translateX(-50%)', marginBottom: '8px' };
|
|
22
|
+
}
|
|
23
|
+
};
|
|
24
|
+
const tooltipStyle = {
|
|
25
|
+
position: 'absolute',
|
|
26
|
+
backgroundColor: tokens.color.text,
|
|
27
|
+
color: 'white',
|
|
28
|
+
padding: `${tokens.spacing[1]} ${tokens.spacing[3]}`,
|
|
29
|
+
borderRadius: tokens.radius.sm,
|
|
30
|
+
fontSize: '11px',
|
|
31
|
+
fontWeight: tokens.font.weightMedium,
|
|
32
|
+
whiteSpace: 'nowrap',
|
|
33
|
+
pointerEvents: 'none',
|
|
34
|
+
opacity: isVisible ? 1 : 0,
|
|
35
|
+
visibility: isVisible ? 'visible' : 'hidden',
|
|
36
|
+
transition: tokens.transition.fast,
|
|
37
|
+
zIndex: 1000,
|
|
38
|
+
boxShadow: tokens.shadow.md,
|
|
39
|
+
...getPositionStyles()
|
|
40
|
+
};
|
|
41
|
+
return (_jsxs("div", { style: containerStyle, className: className, onMouseEnter: () => setIsVisible(true), onMouseLeave: () => setIsVisible(false), children: [children, title && _jsx("div", { style: tooltipStyle, children: title })] }));
|
|
42
|
+
};
|
|
43
|
+
//# sourceMappingURL=Tooltip.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Tooltip.js","sourceRoot":"","sources":["../../src/components/Tooltip.tsx"],"names":[],"mappings":";AAAA,OAAc,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACxC,OAAO,EAAE,MAAM,EAAE,MAAM,WAAW,CAAC;AAOnC,MAAM,CAAC,MAAM,OAAO,GAA2B,CAAC,EAC9C,QAAQ,EACR,KAAK,EACL,QAAQ,GAAG,KAAK,EAChB,SAAS,GAAG,EA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CAAC,IAAI,CAAC,YAAY;QACpC,UAAU,EAAE,QAAiB;QAC7B,aAAa,EAAE,MAAe;QAC9B,OAAO,EAAE,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAC1B,UAAU,EAAE,SAAS,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,QAAQ;QAC5C,UAAU,EAAE,MAAM,CAAC,UAAU,CAAC,IAAI;QAClC,MAAM,EAAE,IAAI;QACZ,SAAS,EAAE,MAAM,CAAC,MAAM,CAAC,EAAE;QAC3B,GAAG,iBAAiB,EAAE;KACvB,CAAC;IAEF,OAAO,CACL,eACE,KAAK,EAAE,cAAc,EACrB,SAAS,EAAE,SAAS,EACpB,YAAY,EAAE,GAAG,EAAE,CAAC,YAAY,CAAC,IAAI,CAAC,EACtC,YAAY,EAAE,GAAG,EAAE,CAAC,YAAY,CAAC,KAAK,CAAC,aAEtC,QAAQ,EACR,KAAK,IAAI,cAAK,KAAK,EAAE,YAAY,YAAG,KAAK,GAAO,IAC7C,CACP,CAAC;AACJ,CAAC,CAAC"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { tokens } from '../tokens';
|
|
3
|
+
export interface HeadingProps extends React.HTMLAttributes<HTMLHeadingElement> {
|
|
4
|
+
level?: 1 | 2 | 3 | 4;
|
|
5
|
+
}
|
|
6
|
+
export declare const Heading: React.FC<HeadingProps>;
|
|
7
|
+
export interface TextProps extends React.HTMLAttributes<HTMLParagraphElement> {
|
|
8
|
+
size?: keyof typeof tokens.font;
|
|
9
|
+
weight?: 'normal' | 'medium' | 'semibold' | 'bold';
|
|
10
|
+
color?: 'default' | 'muted' | 'disabled' | 'primary' | 'danger';
|
|
11
|
+
}
|
|
12
|
+
export declare const Text: React.FC<TextProps>;
|
|
13
|
+
export interface SectionHeaderProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
14
|
+
title: string;
|
|
15
|
+
}
|
|
16
|
+
export declare const SectionHeader: React.FC<SectionHeaderProps>;
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import { tokens } from '../tokens';
|
|
4
|
+
export const Heading = ({ level = 2, children, className = '', style = {}, ...props }) => {
|
|
5
|
+
const getFontSize = () => {
|
|
6
|
+
switch (level) {
|
|
7
|
+
case 1: return tokens.font['2xl'];
|
|
8
|
+
case 2: return tokens.font.xl;
|
|
9
|
+
case 3: return tokens.font.lg;
|
|
10
|
+
case 4: return tokens.font.md;
|
|
11
|
+
default: return tokens.font.base;
|
|
12
|
+
}
|
|
13
|
+
};
|
|
14
|
+
const baseStyle = {
|
|
15
|
+
fontFamily: tokens.font.family,
|
|
16
|
+
fontWeight: tokens.font.weightBold,
|
|
17
|
+
color: tokens.color.text,
|
|
18
|
+
fontSize: getFontSize(),
|
|
19
|
+
margin: 0,
|
|
20
|
+
lineHeight: 1.2,
|
|
21
|
+
...style
|
|
22
|
+
};
|
|
23
|
+
const tag = `h${level}`;
|
|
24
|
+
return React.createElement(tag, { style: baseStyle, className, ...props }, children);
|
|
25
|
+
};
|
|
26
|
+
export const Text = ({ size = 'base', weight = 'normal', color = 'default', children, className = '', style = {}, ...props }) => {
|
|
27
|
+
const getFontSize = () => tokens.font[size] || tokens.font.base;
|
|
28
|
+
const getWeight = () => {
|
|
29
|
+
if (weight === 'medium')
|
|
30
|
+
return tokens.font.weightMedium;
|
|
31
|
+
if (weight === 'semibold')
|
|
32
|
+
return tokens.font.weightSemibold;
|
|
33
|
+
if (weight === 'bold')
|
|
34
|
+
return tokens.font.weightBold;
|
|
35
|
+
return tokens.font.weightNormal;
|
|
36
|
+
};
|
|
37
|
+
const getColor = () => {
|
|
38
|
+
if (color === 'muted')
|
|
39
|
+
return tokens.color.textMuted;
|
|
40
|
+
if (color === 'disabled')
|
|
41
|
+
return tokens.color.textDisabled;
|
|
42
|
+
if (color === 'primary')
|
|
43
|
+
return tokens.color.primary;
|
|
44
|
+
if (color === 'danger')
|
|
45
|
+
return tokens.color.danger;
|
|
46
|
+
return tokens.color.text;
|
|
47
|
+
};
|
|
48
|
+
const baseStyle = {
|
|
49
|
+
fontFamily: tokens.font.family,
|
|
50
|
+
fontSize: getFontSize(),
|
|
51
|
+
fontWeight: getWeight(),
|
|
52
|
+
color: getColor(),
|
|
53
|
+
margin: 0,
|
|
54
|
+
lineHeight: 1.5,
|
|
55
|
+
...style
|
|
56
|
+
};
|
|
57
|
+
return _jsx("p", { style: baseStyle, className: className, ...props, children: children });
|
|
58
|
+
};
|
|
59
|
+
export const SectionHeader = ({ title, className = '', style = {} }) => (_jsxs("div", { style: { display: 'flex', alignItems: 'center', margin: `${tokens.spacing[6]} 0`, ...style }, className: className, children: [_jsx("h4", { style: {
|
|
60
|
+
fontSize: tokens.font.sm,
|
|
61
|
+
fontWeight: tokens.font.weightBold,
|
|
62
|
+
color: tokens.color.textMuted,
|
|
63
|
+
textTransform: 'uppercase',
|
|
64
|
+
letterSpacing: '0.1em',
|
|
65
|
+
marginRight: tokens.spacing[4],
|
|
66
|
+
margin: 0,
|
|
67
|
+
}, children: title }), _jsx("div", { style: { flex: 1, height: '1px', backgroundColor: tokens.color.border } })] }));
|
|
68
|
+
//# sourceMappingURL=Typography.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Typography.js","sourceRoot":"","sources":["../../src/components/Typography.tsx"],"names":[],"mappings":";AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,MAAM,EAAE,MAAM,WAAW,CAAC;AAMnC,MAAM,CAAC,MAAM,OAAO,GAA2B,CAAC,EAC9C,KAAK,GAAG,CAAC,EACT,QAAQ,EACR,SAAS,GAAG,EAAE,EACd,KAAK,GAAG,EAAE,EACV,GAAG,KAAK,EACT,EAAE,EAAE;IACH,MAAM,WAAW,GAAG,GAAG,EAAE;QACvB,QAAO,KAAK,EA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KAAK,EAAE,EAAE,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,EAAE,GAAG,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC,IAAI,EAAE,GAAG,KAAK,EAAE,EAAE,SAAS,EAAE,SAAS,aACrH,aAAI,KAAK,EAAE;gBACT,QAAQ,EAAE,MAAM,CAAC,IAAI,CAAC,EAAE;gBACxB,UAAU,EAAE,MAAM,CAAC,IAAI,CAAC,UAAU;gBAClC,KAAK,EAAE,MAAM,CAAC,KAAK,CAAC,SAAS;gBAC7B,aAAa,EAAE,WAAoB;gBACnC,aAAa,EAAE,OAAO;gBACtB,WAAW,EAAE,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC;gBAC9B,MAAM,EAAE,CAAC;aACV,YACE,KAAK,GACH,EACL,cAAK,KAAK,EAAE,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,eAAe,EAAE,MAAM,CAAC,KAAK,CAAC,MAAM,EAAE,GAAQ,IAChF,CACP,CAAC"}
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
export { Button } from './components/Button';
|
|
2
|
+
export type { ButtonProps } from './components/Button';
|
|
3
|
+
export { ConfirmModal } from './components/ConfirmModal';
|
|
4
|
+
export type { ConfirmModalProps } from './components/ConfirmModal';
|
|
5
|
+
export { Badge } from './components/Badge';
|
|
6
|
+
export type { BadgeProps } from './components/Badge';
|
|
7
|
+
export { Card } from './components/Card';
|
|
8
|
+
export type { CardProps } from './components/Card';
|
|
9
|
+
export { Input, Textarea, Select, Checkbox } from './components/InputComponents';
|
|
10
|
+
export type { InputProps, TextareaProps, SelectProps, CheckboxProps } from './components/InputComponents';
|
|
11
|
+
export { Heading, Text, SectionHeader } from './components/Typography';
|
|
12
|
+
export type { HeadingProps, TextProps, SectionHeaderProps } from './components/Typography';
|
|
13
|
+
export { LoadingSpinner } from './components/LoadingSpinner';
|
|
14
|
+
export type { LoadingSpinnerProps } from './components/LoadingSpinner';
|
|
15
|
+
export { ReadOnlyField } from './components/ReadOnlyField';
|
|
16
|
+
export type { ReadOnlyFieldProps } from './components/ReadOnlyField';
|
|
17
|
+
export { Avatar } from './components/Avatar';
|
|
18
|
+
export type { AvatarProps } from './components/Avatar';
|
|
19
|
+
export { Switch } from './components/Switch';
|
|
20
|
+
export type { SwitchProps } from './components/Switch';
|
|
21
|
+
export { Tabs, Tab } from './components/Tabs';
|
|
22
|
+
export type { TabsProps, TabProps } from './components/Tabs';
|
|
23
|
+
export { Breadcrumbs } from './components/Breadcrumbs';
|
|
24
|
+
export type { BreadcrumbsProps } from './components/Breadcrumbs';
|
|
25
|
+
export { Divider } from './components/Divider';
|
|
26
|
+
export type { DividerProps } from './components/Divider';
|
|
27
|
+
export { Skeleton } from './components/Skeleton';
|
|
28
|
+
export type { SkeletonProps } from './components/Skeleton';
|
|
29
|
+
export { Tooltip } from './components/Tooltip';
|
|
30
|
+
export type { TooltipProps } from './components/Tooltip';
|
|
31
|
+
export { Stack } from './components/Stack';
|
|
32
|
+
export type { StackProps } from './components/Stack';
|
|
33
|
+
export { Alert } from './components/Alert';
|
|
34
|
+
export type { AlertProps } from './components/Alert';
|
|
35
|
+
export { Progress } from './components/Progress';
|
|
36
|
+
export type { ProgressProps } from './components/Progress';
|
|
37
|
+
export { Tag } from './components/Tag';
|
|
38
|
+
export type { TagProps } from './components/Tag';
|
|
39
|
+
export { List, ListItem } from './components/ListComponents';
|
|
40
|
+
export type { ListProps, ListItemProps } from './components/ListComponents';
|
|
41
|
+
export { TableContainer, THead, TBody, TR, TH, TD } from './components/Table';
|
|
42
|
+
export type { TableContainerProps, THeadProps, TBodyProps, TRProps, THProps, TDProps } from './components/Table';
|
|
43
|
+
export { Radio, RadioGroup } from './components/Radio';
|
|
44
|
+
export type { RadioProps, RadioGroupProps } from './components/Radio';
|
|
45
|
+
export { Steps } from './components/Steps';
|
|
46
|
+
export type { StepsProps, StepItem, StepStatus } from './components/Steps';
|
|
47
|
+
export { tokens } from './tokens';
|
|
48
|
+
export type { DesignTokens, ColorTokens, RadiusTokens, ShadowTokens, FontTokens, SpacingTokens, TransitionTokens } from './tokens';
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
// ─── Phase 1 Components ───────────────────────────────────────────────────────
|
|
2
|
+
export { Button } from './components/Button';
|
|
3
|
+
export { ConfirmModal } from './components/ConfirmModal';
|
|
4
|
+
export { Badge } from './components/Badge';
|
|
5
|
+
export { Card } from './components/Card';
|
|
6
|
+
export { Input, Textarea, Select, Checkbox } from './components/InputComponents';
|
|
7
|
+
export { Heading, Text, SectionHeader } from './components/Typography';
|
|
8
|
+
export { LoadingSpinner } from './components/LoadingSpinner';
|
|
9
|
+
export { ReadOnlyField } from './components/ReadOnlyField';
|
|
10
|
+
// ─── Phase 2 Components ───────────────────────────────────────────────────────
|
|
11
|
+
export { Avatar } from './components/Avatar';
|
|
12
|
+
export { Switch } from './components/Switch';
|
|
13
|
+
export { Tabs, Tab } from './components/Tabs';
|
|
14
|
+
export { Breadcrumbs } from './components/Breadcrumbs';
|
|
15
|
+
export { Divider } from './components/Divider';
|
|
16
|
+
export { Skeleton } from './components/Skeleton';
|
|
17
|
+
export { Tooltip } from './components/Tooltip';
|
|
18
|
+
// ─── Phase 3 Components ───────────────────────────────────────────────────────
|
|
19
|
+
export { Stack } from './components/Stack';
|
|
20
|
+
export { Alert } from './components/Alert';
|
|
21
|
+
export { Progress } from './components/Progress';
|
|
22
|
+
export { Tag } from './components/Tag';
|
|
23
|
+
export { List, ListItem } from './components/ListComponents';
|
|
24
|
+
export { TableContainer, THead, TBody, TR, TH, TD } from './components/Table';
|
|
25
|
+
export { Radio, RadioGroup } from './components/Radio';
|
|
26
|
+
export { Steps } from './components/Steps';
|
|
27
|
+
// ─── Design Tokens ────────────────────────────────────────────────────────────
|
|
28
|
+
export { tokens } from './tokens';
|
|
29
|
+
//# sourceMappingURL=index.js.map
|
|
@@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