@teja-app/ui 0.0.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/README.md +169 -0
- package/dist/components/Button/Button.d.ts +13 -0
- package/dist/components/Button/Button.d.ts.map +1 -0
- package/dist/components/Button/Button.types.d.ts +18 -0
- package/dist/components/Button/Button.types.d.ts.map +1 -0
- package/dist/components/Button/index.d.ts +3 -0
- package/dist/components/Button/index.d.ts.map +1 -0
- package/dist/components/index.d.ts +5 -0
- package/dist/components/index.d.ts.map +1 -0
- package/dist/hooks/index.cjs +2 -0
- package/dist/hooks/index.cjs.map +1 -0
- package/dist/hooks/index.d.ts +10 -0
- package/dist/hooks/index.d.ts.map +1 -0
- package/dist/hooks/index.js +2 -0
- package/dist/hooks/index.js.map +1 -0
- package/dist/index.cjs +96 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.ts +13 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +96 -0
- package/dist/index.js.map +1 -0
- package/dist/tailwind/colors.d.ts +46 -0
- package/dist/tailwind/colors.d.ts.map +1 -0
- package/dist/tailwind/index.cjs +138 -0
- package/dist/tailwind/index.cjs.map +1 -0
- package/dist/tailwind/index.d.ts +17 -0
- package/dist/tailwind/index.d.ts.map +1 -0
- package/dist/tailwind/index.js +138 -0
- package/dist/tailwind/index.js.map +1 -0
- package/dist/tailwind/preset.d.ts +20 -0
- package/dist/tailwind/preset.d.ts.map +1 -0
- package/dist/tailwind/spacing.d.ts +53 -0
- package/dist/tailwind/spacing.d.ts.map +1 -0
- package/dist/tailwind/typography.d.ts +41 -0
- package/dist/tailwind/typography.d.ts.map +1 -0
- package/dist/utils/cn.d.ts +12 -0
- package/dist/utils/cn.d.ts.map +1 -0
- package/dist/utils/index.cjs +3027 -0
- package/dist/utils/index.cjs.map +1 -0
- package/dist/utils/index.d.ts +10 -0
- package/dist/utils/index.d.ts.map +1 -0
- package/dist/utils/index.js +3027 -0
- package/dist/utils/index.js.map +1 -0
- package/package.json +121 -0
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
|
+
const colors = {
|
|
4
|
+
// Brand colors
|
|
5
|
+
brand: {
|
|
6
|
+
primary: "#2563EB",
|
|
7
|
+
"primary-hover": "#1D4ED8",
|
|
8
|
+
secondary: "#64748B"
|
|
9
|
+
},
|
|
10
|
+
// Semantic colors
|
|
11
|
+
success: {
|
|
12
|
+
DEFAULT: "#16A34A",
|
|
13
|
+
light: "#DCFCE7"
|
|
14
|
+
},
|
|
15
|
+
warning: {
|
|
16
|
+
DEFAULT: "#CA8A04",
|
|
17
|
+
light: "#FEF9C3"
|
|
18
|
+
},
|
|
19
|
+
error: {
|
|
20
|
+
DEFAULT: "#DC2626",
|
|
21
|
+
light: "#FEE2E2"
|
|
22
|
+
},
|
|
23
|
+
info: {
|
|
24
|
+
DEFAULT: "#2563EB",
|
|
25
|
+
light: "#DBEAFE"
|
|
26
|
+
},
|
|
27
|
+
// Neutral colors
|
|
28
|
+
neutral: {
|
|
29
|
+
50: "#F8FAFC",
|
|
30
|
+
100: "#F1F5F9",
|
|
31
|
+
200: "#E2E8F0",
|
|
32
|
+
300: "#CBD5E1",
|
|
33
|
+
500: "#64748B",
|
|
34
|
+
700: "#334155",
|
|
35
|
+
900: "#0F172A"
|
|
36
|
+
},
|
|
37
|
+
// Status colors (for sessions/notes)
|
|
38
|
+
status: {
|
|
39
|
+
scheduled: "#3B82F6",
|
|
40
|
+
completed: "#16A34A",
|
|
41
|
+
cancelled: "#6B7280",
|
|
42
|
+
"no-show": "#EF4444",
|
|
43
|
+
draft: "#F59E0B",
|
|
44
|
+
signed: "#16A34A"
|
|
45
|
+
}
|
|
46
|
+
};
|
|
47
|
+
const fontFamily = {
|
|
48
|
+
sans: ["Inter", "system-ui", "sans-serif"],
|
|
49
|
+
mono: ["JetBrains Mono", "monospace"]
|
|
50
|
+
};
|
|
51
|
+
const fontSize = {
|
|
52
|
+
xs: ["0.75rem", { lineHeight: "1rem" }],
|
|
53
|
+
sm: ["0.875rem", { lineHeight: "1.25rem" }],
|
|
54
|
+
base: ["1rem", { lineHeight: "1.5rem" }],
|
|
55
|
+
lg: ["1.125rem", { lineHeight: "1.75rem" }],
|
|
56
|
+
xl: ["1.25rem", { lineHeight: "1.75rem" }],
|
|
57
|
+
"2xl": ["1.5rem", { lineHeight: "2rem" }],
|
|
58
|
+
"3xl": ["2rem", { lineHeight: "2.5rem" }]
|
|
59
|
+
};
|
|
60
|
+
const fontWeight = {
|
|
61
|
+
normal: "400",
|
|
62
|
+
medium: "500",
|
|
63
|
+
semibold: "600",
|
|
64
|
+
bold: "700"
|
|
65
|
+
};
|
|
66
|
+
const spacing = {
|
|
67
|
+
0: "0",
|
|
68
|
+
1: "0.25rem",
|
|
69
|
+
2: "0.5rem",
|
|
70
|
+
3: "0.75rem",
|
|
71
|
+
4: "1rem",
|
|
72
|
+
5: "1.25rem",
|
|
73
|
+
6: "1.5rem",
|
|
74
|
+
8: "2rem",
|
|
75
|
+
10: "2.5rem",
|
|
76
|
+
12: "3rem"
|
|
77
|
+
};
|
|
78
|
+
const borderRadius = {
|
|
79
|
+
none: "0",
|
|
80
|
+
sm: "0.25rem",
|
|
81
|
+
md: "0.375rem",
|
|
82
|
+
lg: "0.5rem",
|
|
83
|
+
xl: "0.75rem",
|
|
84
|
+
full: "9999px"
|
|
85
|
+
};
|
|
86
|
+
const boxShadow = {
|
|
87
|
+
sm: "0 1px 2px rgba(0, 0, 0, 0.05)",
|
|
88
|
+
md: "0 4px 6px rgba(0, 0, 0, 0.1)",
|
|
89
|
+
lg: "0 10px 15px rgba(0, 0, 0, 0.1)",
|
|
90
|
+
xl: "0 20px 25px rgba(0, 0, 0, 0.15)"
|
|
91
|
+
};
|
|
92
|
+
const zIndex = {
|
|
93
|
+
base: "0",
|
|
94
|
+
dropdown: "10",
|
|
95
|
+
sticky: "20",
|
|
96
|
+
drawer: "30",
|
|
97
|
+
modal: "40",
|
|
98
|
+
toast: "50",
|
|
99
|
+
tooltip: "60"
|
|
100
|
+
};
|
|
101
|
+
const transitionDuration = {
|
|
102
|
+
fast: "100ms",
|
|
103
|
+
normal: "150ms",
|
|
104
|
+
slow: "300ms"
|
|
105
|
+
};
|
|
106
|
+
const transitionTimingFunction = {
|
|
107
|
+
default: "ease-out",
|
|
108
|
+
bounce: "cubic-bezier(0.34, 1.56, 0.64, 1)"
|
|
109
|
+
};
|
|
110
|
+
const preset = {
|
|
111
|
+
theme: {
|
|
112
|
+
extend: {
|
|
113
|
+
colors,
|
|
114
|
+
fontFamily,
|
|
115
|
+
fontSize,
|
|
116
|
+
fontWeight,
|
|
117
|
+
spacing,
|
|
118
|
+
borderRadius,
|
|
119
|
+
boxShadow,
|
|
120
|
+
zIndex,
|
|
121
|
+
transitionDuration,
|
|
122
|
+
transitionTimingFunction
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
};
|
|
126
|
+
exports.borderRadius = borderRadius;
|
|
127
|
+
exports.boxShadow = boxShadow;
|
|
128
|
+
exports.colors = colors;
|
|
129
|
+
exports.default = preset;
|
|
130
|
+
exports.fontFamily = fontFamily;
|
|
131
|
+
exports.fontSize = fontSize;
|
|
132
|
+
exports.fontWeight = fontWeight;
|
|
133
|
+
exports.preset = preset;
|
|
134
|
+
exports.spacing = spacing;
|
|
135
|
+
exports.transitionDuration = transitionDuration;
|
|
136
|
+
exports.transitionTimingFunction = transitionTimingFunction;
|
|
137
|
+
exports.zIndex = zIndex;
|
|
138
|
+
//# sourceMappingURL=index.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.cjs","sources":["../../src/tailwind/colors.ts","../../src/tailwind/typography.ts","../../src/tailwind/spacing.ts","../../src/tailwind/preset.ts"],"sourcesContent":["/**\n * Design token colors for the Teja UI component library.\n * Based on /business/ux/Patterns/Design-Tokens.md\n */\n\nexport const colors = {\n // Brand colors\n brand: {\n primary: '#2563EB',\n 'primary-hover': '#1D4ED8',\n secondary: '#64748B',\n },\n\n // Semantic colors\n success: {\n DEFAULT: '#16A34A',\n light: '#DCFCE7',\n },\n warning: {\n DEFAULT: '#CA8A04',\n light: '#FEF9C3',\n },\n error: {\n DEFAULT: '#DC2626',\n light: '#FEE2E2',\n },\n info: {\n DEFAULT: '#2563EB',\n light: '#DBEAFE',\n },\n\n // Neutral colors\n neutral: {\n 50: '#F8FAFC',\n 100: '#F1F5F9',\n 200: '#E2E8F0',\n 300: '#CBD5E1',\n 500: '#64748B',\n 700: '#334155',\n 900: '#0F172A',\n },\n\n // Status colors (for sessions/notes)\n status: {\n scheduled: '#3B82F6',\n completed: '#16A34A',\n cancelled: '#6B7280',\n 'no-show': '#EF4444',\n draft: '#F59E0B',\n signed: '#16A34A',\n },\n} as const;\n\nexport type Colors = typeof colors;\n","/**\n * Typography design tokens for the Teja UI component library.\n * Based on /business/ux/Patterns/Design-Tokens.md\n */\n\nexport const fontFamily = {\n sans: ['Inter', 'system-ui', 'sans-serif'],\n mono: ['JetBrains Mono', 'monospace'],\n} as const;\n\nexport const fontSize = {\n xs: ['0.75rem', { lineHeight: '1rem' }],\n sm: ['0.875rem', { lineHeight: '1.25rem' }],\n base: ['1rem', { lineHeight: '1.5rem' }],\n lg: ['1.125rem', { lineHeight: '1.75rem' }],\n xl: ['1.25rem', { lineHeight: '1.75rem' }],\n '2xl': ['1.5rem', { lineHeight: '2rem' }],\n '3xl': ['2rem', { lineHeight: '2.5rem' }],\n} as const;\n\nexport const fontWeight = {\n normal: '400',\n medium: '500',\n semibold: '600',\n bold: '700',\n} as const;\n\nexport type FontFamily = typeof fontFamily;\nexport type FontSize = typeof fontSize;\nexport type FontWeight = typeof fontWeight;\n","/**\n * Spacing and layout design tokens for the Teja UI component library.\n * Based on /business/ux/Patterns/Design-Tokens.md\n */\n\nexport const spacing = {\n 0: '0',\n 1: '0.25rem',\n 2: '0.5rem',\n 3: '0.75rem',\n 4: '1rem',\n 5: '1.25rem',\n 6: '1.5rem',\n 8: '2rem',\n 10: '2.5rem',\n 12: '3rem',\n} as const;\n\nexport const borderRadius = {\n none: '0',\n sm: '0.25rem',\n md: '0.375rem',\n lg: '0.5rem',\n xl: '0.75rem',\n full: '9999px',\n} as const;\n\nexport const boxShadow = {\n sm: '0 1px 2px rgba(0, 0, 0, 0.05)',\n md: '0 4px 6px rgba(0, 0, 0, 0.1)',\n lg: '0 10px 15px rgba(0, 0, 0, 0.1)',\n xl: '0 20px 25px rgba(0, 0, 0, 0.15)',\n} as const;\n\nexport const zIndex = {\n base: '0',\n dropdown: '10',\n sticky: '20',\n drawer: '30',\n modal: '40',\n toast: '50',\n tooltip: '60',\n} as const;\n\nexport const transitionDuration = {\n fast: '100ms',\n normal: '150ms',\n slow: '300ms',\n} as const;\n\nexport const transitionTimingFunction = {\n default: 'ease-out',\n bounce: 'cubic-bezier(0.34, 1.56, 0.64, 1)',\n} as const;\n\nexport type Spacing = typeof spacing;\nexport type BorderRadius = typeof borderRadius;\nexport type BoxShadow = typeof boxShadow;\nexport type ZIndex = typeof zIndex;\n","/**\n * Tailwind CSS preset for the Teja UI component library.\n *\n * Usage in consumer apps:\n * ```ts\n * import tejaPreset from '@teja-app/ui/tailwind';\n *\n * export default {\n * presets: [tejaPreset],\n * content: [\n * \"./src/**\\/*.{js,ts,jsx,tsx}\",\n * \"./node_modules/@teja-app/ui/dist/**\\/*.{js,mjs}\",\n * ],\n * };\n * ```\n */\n\nimport type { Config } from 'tailwindcss';\nimport { colors } from './colors';\nimport { fontFamily, fontSize, fontWeight } from './typography';\nimport {\n spacing,\n borderRadius,\n boxShadow,\n zIndex,\n transitionDuration,\n transitionTimingFunction,\n} from './spacing';\n\nconst preset: Partial<Config> = {\n theme: {\n extend: {\n colors,\n fontFamily,\n fontSize,\n fontWeight,\n spacing,\n borderRadius,\n boxShadow,\n zIndex,\n transitionDuration,\n transitionTimingFunction,\n },\n },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Q;AAAA,EACR,UAAU;AAAA,EACV,MAAM;AACR;ACpBO,MAAM,UAAU;AAAA,EACrB,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,IAAI;AAAA,EACJ,IAAI;AACN;AAEO,MAAM,eAAe;AAAA,EAC1B,MAAM;AAAA,EACN,IAAI;AAAA,EACJ,IAAI;AAAA,EACJ,IAAI;AAAA,EACJ,IAAI;AAAA,EACJ,MAAM;AACR;AAEO,MAAM,YAAY;AAAA,EACvB,IAAI;AAAA,EACJ,IAAI;AAAA,EACJ,IAAI;AAAA,EACJ,IAAI;AACN;AAEO,MAAM,SAAS;AAAA,EACpB,MAAM;AAAA,EACN,UAAU;AAAA,EACV,QAAQ;AAAA,EACR,QAAQ;AAAA,EACR,OAAO;AAAA,EACP,OAAO;AAAA,EACP,SAAS;AACX;AAEO,MAAM,qBAAqB;AAAA,EAChC,MAAM;AAAA,EACN,QAAQ;AAAA,EACR,MAAM;AACR;AAEO,MAAM,2BAA2B;AAAA,EACtC,SAAS;AAAA,EACT,QAAQ;AACV;ACxBA,MAAM,SAA0B;AAAA,EAC9B,OAAO;AAAA,IACL,QAAQ;AAAA,MACN;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,IAAA;AAAA,EACF;AAEJ;;;;;;;;;;;;;"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Tailwind configuration exports for @teja-app/ui
|
|
3
|
+
*
|
|
4
|
+
* Usage:
|
|
5
|
+
* ```ts
|
|
6
|
+
* import tejaPreset from '@teja-app/ui/tailwind';
|
|
7
|
+
* ```
|
|
8
|
+
*/
|
|
9
|
+
export { default } from './preset';
|
|
10
|
+
export { default as preset } from './preset';
|
|
11
|
+
export { colors } from './colors';
|
|
12
|
+
export type { Colors } from './colors';
|
|
13
|
+
export { fontFamily, fontSize, fontWeight } from './typography';
|
|
14
|
+
export type { FontFamily, FontSize, FontWeight } from './typography';
|
|
15
|
+
export { spacing, borderRadius, boxShadow, zIndex, transitionDuration, transitionTimingFunction, } from './spacing';
|
|
16
|
+
export type { Spacing, BorderRadius, BoxShadow, ZIndex } from './spacing';
|
|
17
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/tailwind/index.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC;AACnC,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,UAAU,CAAC;AAE7C,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAClC,YAAY,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAEvC,OAAO,EAAE,UAAU,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAChE,YAAY,EAAE,UAAU,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAErE,OAAO,EACL,OAAO,EACP,YAAY,EACZ,SAAS,EACT,MAAM,EACN,kBAAkB,EAClB,wBAAwB,GACzB,MAAM,WAAW,CAAC;AACnB,YAAY,EAAE,OAAO,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,WAAW,CAAC"}
|
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
const colors = {
|
|
2
|
+
// Brand colors
|
|
3
|
+
brand: {
|
|
4
|
+
primary: "#2563EB",
|
|
5
|
+
"primary-hover": "#1D4ED8",
|
|
6
|
+
secondary: "#64748B"
|
|
7
|
+
},
|
|
8
|
+
// Semantic colors
|
|
9
|
+
success: {
|
|
10
|
+
DEFAULT: "#16A34A",
|
|
11
|
+
light: "#DCFCE7"
|
|
12
|
+
},
|
|
13
|
+
warning: {
|
|
14
|
+
DEFAULT: "#CA8A04",
|
|
15
|
+
light: "#FEF9C3"
|
|
16
|
+
},
|
|
17
|
+
error: {
|
|
18
|
+
DEFAULT: "#DC2626",
|
|
19
|
+
light: "#FEE2E2"
|
|
20
|
+
},
|
|
21
|
+
info: {
|
|
22
|
+
DEFAULT: "#2563EB",
|
|
23
|
+
light: "#DBEAFE"
|
|
24
|
+
},
|
|
25
|
+
// Neutral colors
|
|
26
|
+
neutral: {
|
|
27
|
+
50: "#F8FAFC",
|
|
28
|
+
100: "#F1F5F9",
|
|
29
|
+
200: "#E2E8F0",
|
|
30
|
+
300: "#CBD5E1",
|
|
31
|
+
500: "#64748B",
|
|
32
|
+
700: "#334155",
|
|
33
|
+
900: "#0F172A"
|
|
34
|
+
},
|
|
35
|
+
// Status colors (for sessions/notes)
|
|
36
|
+
status: {
|
|
37
|
+
scheduled: "#3B82F6",
|
|
38
|
+
completed: "#16A34A",
|
|
39
|
+
cancelled: "#6B7280",
|
|
40
|
+
"no-show": "#EF4444",
|
|
41
|
+
draft: "#F59E0B",
|
|
42
|
+
signed: "#16A34A"
|
|
43
|
+
}
|
|
44
|
+
};
|
|
45
|
+
const fontFamily = {
|
|
46
|
+
sans: ["Inter", "system-ui", "sans-serif"],
|
|
47
|
+
mono: ["JetBrains Mono", "monospace"]
|
|
48
|
+
};
|
|
49
|
+
const fontSize = {
|
|
50
|
+
xs: ["0.75rem", { lineHeight: "1rem" }],
|
|
51
|
+
sm: ["0.875rem", { lineHeight: "1.25rem" }],
|
|
52
|
+
base: ["1rem", { lineHeight: "1.5rem" }],
|
|
53
|
+
lg: ["1.125rem", { lineHeight: "1.75rem" }],
|
|
54
|
+
xl: ["1.25rem", { lineHeight: "1.75rem" }],
|
|
55
|
+
"2xl": ["1.5rem", { lineHeight: "2rem" }],
|
|
56
|
+
"3xl": ["2rem", { lineHeight: "2.5rem" }]
|
|
57
|
+
};
|
|
58
|
+
const fontWeight = {
|
|
59
|
+
normal: "400",
|
|
60
|
+
medium: "500",
|
|
61
|
+
semibold: "600",
|
|
62
|
+
bold: "700"
|
|
63
|
+
};
|
|
64
|
+
const spacing = {
|
|
65
|
+
0: "0",
|
|
66
|
+
1: "0.25rem",
|
|
67
|
+
2: "0.5rem",
|
|
68
|
+
3: "0.75rem",
|
|
69
|
+
4: "1rem",
|
|
70
|
+
5: "1.25rem",
|
|
71
|
+
6: "1.5rem",
|
|
72
|
+
8: "2rem",
|
|
73
|
+
10: "2.5rem",
|
|
74
|
+
12: "3rem"
|
|
75
|
+
};
|
|
76
|
+
const borderRadius = {
|
|
77
|
+
none: "0",
|
|
78
|
+
sm: "0.25rem",
|
|
79
|
+
md: "0.375rem",
|
|
80
|
+
lg: "0.5rem",
|
|
81
|
+
xl: "0.75rem",
|
|
82
|
+
full: "9999px"
|
|
83
|
+
};
|
|
84
|
+
const boxShadow = {
|
|
85
|
+
sm: "0 1px 2px rgba(0, 0, 0, 0.05)",
|
|
86
|
+
md: "0 4px 6px rgba(0, 0, 0, 0.1)",
|
|
87
|
+
lg: "0 10px 15px rgba(0, 0, 0, 0.1)",
|
|
88
|
+
xl: "0 20px 25px rgba(0, 0, 0, 0.15)"
|
|
89
|
+
};
|
|
90
|
+
const zIndex = {
|
|
91
|
+
base: "0",
|
|
92
|
+
dropdown: "10",
|
|
93
|
+
sticky: "20",
|
|
94
|
+
drawer: "30",
|
|
95
|
+
modal: "40",
|
|
96
|
+
toast: "50",
|
|
97
|
+
tooltip: "60"
|
|
98
|
+
};
|
|
99
|
+
const transitionDuration = {
|
|
100
|
+
fast: "100ms",
|
|
101
|
+
normal: "150ms",
|
|
102
|
+
slow: "300ms"
|
|
103
|
+
};
|
|
104
|
+
const transitionTimingFunction = {
|
|
105
|
+
default: "ease-out",
|
|
106
|
+
bounce: "cubic-bezier(0.34, 1.56, 0.64, 1)"
|
|
107
|
+
};
|
|
108
|
+
const preset = {
|
|
109
|
+
theme: {
|
|
110
|
+
extend: {
|
|
111
|
+
colors,
|
|
112
|
+
fontFamily,
|
|
113
|
+
fontSize,
|
|
114
|
+
fontWeight,
|
|
115
|
+
spacing,
|
|
116
|
+
borderRadius,
|
|
117
|
+
boxShadow,
|
|
118
|
+
zIndex,
|
|
119
|
+
transitionDuration,
|
|
120
|
+
transitionTimingFunction
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
};
|
|
124
|
+
export {
|
|
125
|
+
borderRadius,
|
|
126
|
+
boxShadow,
|
|
127
|
+
colors,
|
|
128
|
+
preset as default,
|
|
129
|
+
fontFamily,
|
|
130
|
+
fontSize,
|
|
131
|
+
fontWeight,
|
|
132
|
+
preset,
|
|
133
|
+
spacing,
|
|
134
|
+
transitionDuration,
|
|
135
|
+
transitionTimingFunction,
|
|
136
|
+
zIndex
|
|
137
|
+
};
|
|
138
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../src/tailwind/colors.ts","../../src/tailwind/typography.ts","../../src/tailwind/spacing.ts","../../src/tailwind/preset.ts"],"sourcesContent":["/**\n * Design token colors for the Teja UI component library.\n * Based on /business/ux/Patterns/Design-Tokens.md\n */\n\nexport const colors = {\n // Brand colors\n brand: {\n primary: '#2563EB',\n 'primary-hover': '#1D4ED8',\n secondary: '#64748B',\n },\n\n // Semantic colors\n success: {\n DEFAULT: '#16A34A',\n light: '#DCFCE7',\n },\n warning: {\n DEFAULT: '#CA8A04',\n light: '#FEF9C3',\n },\n error: {\n DEFAULT: '#DC2626',\n light: '#FEE2E2',\n },\n info: {\n DEFAULT: '#2563EB',\n light: '#DBEAFE',\n },\n\n // Neutral colors\n neutral: {\n 50: '#F8FAFC',\n 100: '#F1F5F9',\n 200: '#E2E8F0',\n 300: '#CBD5E1',\n 500: '#64748B',\n 700: '#334155',\n 900: '#0F172A',\n },\n\n // Status colors (for sessions/notes)\n status: {\n scheduled: '#3B82F6',\n completed: '#16A34A',\n cancelled: '#6B7280',\n 'no-show': '#EF4444',\n draft: '#F59E0B',\n signed: '#16A34A',\n },\n} as const;\n\nexport type Colors = typeof colors;\n","/**\n * Typography design tokens for the Teja UI component library.\n * Based on /business/ux/Patterns/Design-Tokens.md\n */\n\nexport const fontFamily = {\n sans: ['Inter', 'system-ui', 'sans-serif'],\n mono: ['JetBrains Mono', 'monospace'],\n} as const;\n\nexport const fontSize = {\n xs: ['0.75rem', { lineHeight: '1rem' }],\n sm: ['0.875rem', { lineHeight: '1.25rem' }],\n base: ['1rem', { lineHeight: '1.5rem' }],\n lg: ['1.125rem', { lineHeight: '1.75rem' }],\n xl: ['1.25rem', { lineHeight: '1.75rem' }],\n '2xl': ['1.5rem', { lineHeight: '2rem' }],\n '3xl': ['2rem', { lineHeight: '2.5rem' }],\n} as const;\n\nexport const fontWeight = {\n normal: '400',\n medium: '500',\n semibold: '600',\n bold: '700',\n} as const;\n\nexport type FontFamily = typeof fontFamily;\nexport type FontSize = typeof fontSize;\nexport type FontWeight = typeof fontWeight;\n","/**\n * Spacing and layout design tokens for the Teja UI component library.\n * Based on /business/ux/Patterns/Design-Tokens.md\n */\n\nexport const spacing = {\n 0: '0',\n 1: '0.25rem',\n 2: '0.5rem',\n 3: '0.75rem',\n 4: '1rem',\n 5: '1.25rem',\n 6: '1.5rem',\n 8: '2rem',\n 10: '2.5rem',\n 12: '3rem',\n} as const;\n\nexport const borderRadius = {\n none: '0',\n sm: '0.25rem',\n md: '0.375rem',\n lg: '0.5rem',\n xl: '0.75rem',\n full: '9999px',\n} as const;\n\nexport const boxShadow = {\n sm: '0 1px 2px rgba(0, 0, 0, 0.05)',\n md: '0 4px 6px rgba(0, 0, 0, 0.1)',\n lg: '0 10px 15px rgba(0, 0, 0, 0.1)',\n xl: '0 20px 25px rgba(0, 0, 0, 0.15)',\n} as const;\n\nexport const zIndex = {\n base: '0',\n dropdown: '10',\n sticky: '20',\n drawer: '30',\n modal: '40',\n toast: '50',\n tooltip: '60',\n} as const;\n\nexport const transitionDuration = {\n fast: '100ms',\n normal: '150ms',\n slow: '300ms',\n} as const;\n\nexport const transitionTimingFunction = {\n default: 'ease-out',\n bounce: 'cubic-bezier(0.34, 1.56, 0.64, 1)',\n} as const;\n\nexport type Spacing = typeof spacing;\nexport type BorderRadius = typeof borderRadius;\nexport type BoxShadow = typeof boxShadow;\nexport type ZIndex = typeof zIndex;\n","/**\n * Tailwind CSS preset for the Teja UI component library.\n *\n * Usage in consumer apps:\n * ```ts\n * import tejaPreset from '@teja-app/ui/tailwind';\n *\n * export default {\n * presets: [tejaPreset],\n * content: [\n * \"./src/**\\/*.{js,ts,jsx,tsx}\",\n * \"./node_modules/@teja-app/ui/dist/**\\/*.{js,mjs}\",\n * ],\n * };\n * ```\n */\n\nimport type { Config } from 'tailwindcss';\nimport { colors } from './colors';\nimport { fontFamily, fontSize, fontWeight } from './typography';\nimport {\n spacing,\n borderRadius,\n boxShadow,\n zIndex,\n transitionDuration,\n transitionTimingFunction,\n} from './spacing';\n\nconst preset: Partial<Config> = {\n theme: {\n extend: {\n colors,\n fontFamily,\n fontSize,\n fontWeight,\n spacing,\n borderRadius,\n boxShadow,\n zIndex,\n transitionDuration,\n transitionTimingFunction,\n },\n },\n};\n\nexport default preset;\n"],"names":[],"mappings":"AAKO,MAAM,SAAS;AAAA;AAAA,EAEpB,OAAO;AAAA,IACL,SAAS;AAAA,IACT,iBAAiB;AAAA,IACjB,WAAW;AAAA,EAAA;AAAA;AAAA,EAIb,SAAS;AAAA,IACP,SAAS;AAAA,IACT,OAAO;AAAA,EAAA;AAAA,EAET,SAAS;AAAA,IACP,SAAS;AAAA,IACT,OAAO;AAAA,EAAA;AAAA,EAET,OAAO;AAAA,IACL,SAAS;AAAA,IACT,OAAO;AAAA,EAAA;AAAA,EAET,MAAM;AAAA,IACJ,SAAS;AAAA,IACT,OAAO;AAAA,EAAA;AAAA;AAAA,EAIT,SAAS;AAAA,IACP,IAAI;AAAA,IACJ,KAAK;AAAA,IACL,KAAK;AAA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AAA,EACpB,MAAM;AAAA,EACN,UAAU;AAAA,EACV,QAAQ;AAAA,EACR,QAAQ;AAAA,EACR,OAAO;AAAA,EACP,OAAO;AAAA,EACP,SAAS;AACX;AAEO,MAAM,qBAAqB;AAAA,EAChC,MAAM;AAAA,EACN,QAAQ;AAAA,EACR,MAAM;AACR;AAEO,MAAM,2BAA2B;AAAA,EACtC,SAAS;AAAA,EACT,QAAQ;AACV;ACxBA,MAAM,SAA0B;AAAA,EAC9B,OAAO;AAAA,IACL,QAAQ;AAAA,MACN;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,IAAA;AAAA,EACF;AAEJ;"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Tailwind CSS preset for the Teja UI component library.
|
|
3
|
+
*
|
|
4
|
+
* Usage in consumer apps:
|
|
5
|
+
* ```ts
|
|
6
|
+
* import tejaPreset from '@teja-app/ui/tailwind';
|
|
7
|
+
*
|
|
8
|
+
* export default {
|
|
9
|
+
* presets: [tejaPreset],
|
|
10
|
+
* content: [
|
|
11
|
+
* "./src/**\/*.{js,ts,jsx,tsx}",
|
|
12
|
+
* "./node_modules/@teja-app/ui/dist/**\/*.{js,mjs}",
|
|
13
|
+
* ],
|
|
14
|
+
* };
|
|
15
|
+
* ```
|
|
16
|
+
*/
|
|
17
|
+
import type { Config } from 'tailwindcss';
|
|
18
|
+
declare const preset: Partial<Config>;
|
|
19
|
+
export default preset;
|
|
20
|
+
//# sourceMappingURL=preset.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"preset.d.ts","sourceRoot":"","sources":["../../src/tailwind/preset.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAEH,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AAY1C,QAAA,MAAM,MAAM,EAAE,OAAO,CAAC,MAAM,CAe3B,CAAC;AAEF,eAAe,MAAM,CAAC"}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Spacing and layout design tokens for the Teja UI component library.
|
|
3
|
+
* Based on /business/ux/Patterns/Design-Tokens.md
|
|
4
|
+
*/
|
|
5
|
+
export declare const spacing: {
|
|
6
|
+
readonly 0: "0";
|
|
7
|
+
readonly 1: "0.25rem";
|
|
8
|
+
readonly 2: "0.5rem";
|
|
9
|
+
readonly 3: "0.75rem";
|
|
10
|
+
readonly 4: "1rem";
|
|
11
|
+
readonly 5: "1.25rem";
|
|
12
|
+
readonly 6: "1.5rem";
|
|
13
|
+
readonly 8: "2rem";
|
|
14
|
+
readonly 10: "2.5rem";
|
|
15
|
+
readonly 12: "3rem";
|
|
16
|
+
};
|
|
17
|
+
export declare const borderRadius: {
|
|
18
|
+
readonly none: "0";
|
|
19
|
+
readonly sm: "0.25rem";
|
|
20
|
+
readonly md: "0.375rem";
|
|
21
|
+
readonly lg: "0.5rem";
|
|
22
|
+
readonly xl: "0.75rem";
|
|
23
|
+
readonly full: "9999px";
|
|
24
|
+
};
|
|
25
|
+
export declare const boxShadow: {
|
|
26
|
+
readonly sm: "0 1px 2px rgba(0, 0, 0, 0.05)";
|
|
27
|
+
readonly md: "0 4px 6px rgba(0, 0, 0, 0.1)";
|
|
28
|
+
readonly lg: "0 10px 15px rgba(0, 0, 0, 0.1)";
|
|
29
|
+
readonly xl: "0 20px 25px rgba(0, 0, 0, 0.15)";
|
|
30
|
+
};
|
|
31
|
+
export declare const zIndex: {
|
|
32
|
+
readonly base: "0";
|
|
33
|
+
readonly dropdown: "10";
|
|
34
|
+
readonly sticky: "20";
|
|
35
|
+
readonly drawer: "30";
|
|
36
|
+
readonly modal: "40";
|
|
37
|
+
readonly toast: "50";
|
|
38
|
+
readonly tooltip: "60";
|
|
39
|
+
};
|
|
40
|
+
export declare const transitionDuration: {
|
|
41
|
+
readonly fast: "100ms";
|
|
42
|
+
readonly normal: "150ms";
|
|
43
|
+
readonly slow: "300ms";
|
|
44
|
+
};
|
|
45
|
+
export declare const transitionTimingFunction: {
|
|
46
|
+
readonly default: "ease-out";
|
|
47
|
+
readonly bounce: "cubic-bezier(0.34, 1.56, 0.64, 1)";
|
|
48
|
+
};
|
|
49
|
+
export type Spacing = typeof spacing;
|
|
50
|
+
export type BorderRadius = typeof borderRadius;
|
|
51
|
+
export type BoxShadow = typeof boxShadow;
|
|
52
|
+
export type ZIndex = typeof zIndex;
|
|
53
|
+
//# sourceMappingURL=spacing.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"spacing.d.ts","sourceRoot":"","sources":["../../src/tailwind/spacing.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,eAAO,MAAM,OAAO;;;;;;;;;;;CAWV,CAAC;AAEX,eAAO,MAAM,YAAY;;;;;;;CAOf,CAAC;AAEX,eAAO,MAAM,SAAS;;;;;CAKZ,CAAC;AAEX,eAAO,MAAM,MAAM;;;;;;;;CAQT,CAAC;AAEX,eAAO,MAAM,kBAAkB;;;;CAIrB,CAAC;AAEX,eAAO,MAAM,wBAAwB;;;CAG3B,CAAC;AAEX,MAAM,MAAM,OAAO,GAAG,OAAO,OAAO,CAAC;AACrC,MAAM,MAAM,YAAY,GAAG,OAAO,YAAY,CAAC;AAC/C,MAAM,MAAM,SAAS,GAAG,OAAO,SAAS,CAAC;AACzC,MAAM,MAAM,MAAM,GAAG,OAAO,MAAM,CAAC"}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Typography design tokens for the Teja UI component library.
|
|
3
|
+
* Based on /business/ux/Patterns/Design-Tokens.md
|
|
4
|
+
*/
|
|
5
|
+
export declare const fontFamily: {
|
|
6
|
+
readonly sans: readonly ["Inter", "system-ui", "sans-serif"];
|
|
7
|
+
readonly mono: readonly ["JetBrains Mono", "monospace"];
|
|
8
|
+
};
|
|
9
|
+
export declare const fontSize: {
|
|
10
|
+
readonly xs: readonly ["0.75rem", {
|
|
11
|
+
readonly lineHeight: "1rem";
|
|
12
|
+
}];
|
|
13
|
+
readonly sm: readonly ["0.875rem", {
|
|
14
|
+
readonly lineHeight: "1.25rem";
|
|
15
|
+
}];
|
|
16
|
+
readonly base: readonly ["1rem", {
|
|
17
|
+
readonly lineHeight: "1.5rem";
|
|
18
|
+
}];
|
|
19
|
+
readonly lg: readonly ["1.125rem", {
|
|
20
|
+
readonly lineHeight: "1.75rem";
|
|
21
|
+
}];
|
|
22
|
+
readonly xl: readonly ["1.25rem", {
|
|
23
|
+
readonly lineHeight: "1.75rem";
|
|
24
|
+
}];
|
|
25
|
+
readonly '2xl': readonly ["1.5rem", {
|
|
26
|
+
readonly lineHeight: "2rem";
|
|
27
|
+
}];
|
|
28
|
+
readonly '3xl': readonly ["2rem", {
|
|
29
|
+
readonly lineHeight: "2.5rem";
|
|
30
|
+
}];
|
|
31
|
+
};
|
|
32
|
+
export declare const fontWeight: {
|
|
33
|
+
readonly normal: "400";
|
|
34
|
+
readonly medium: "500";
|
|
35
|
+
readonly semibold: "600";
|
|
36
|
+
readonly bold: "700";
|
|
37
|
+
};
|
|
38
|
+
export type FontFamily = typeof fontFamily;
|
|
39
|
+
export type FontSize = typeof fontSize;
|
|
40
|
+
export type FontWeight = typeof fontWeight;
|
|
41
|
+
//# sourceMappingURL=typography.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"typography.d.ts","sourceRoot":"","sources":["../../src/tailwind/typography.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,eAAO,MAAM,UAAU;;;CAGb,CAAC;AAEX,eAAO,MAAM,QAAQ;;;;;;;;;;;;;;;;;;;;;;CAQX,CAAC;AAEX,eAAO,MAAM,UAAU;;;;;CAKb,CAAC;AAEX,MAAM,MAAM,UAAU,GAAG,OAAO,UAAU,CAAC;AAC3C,MAAM,MAAM,QAAQ,GAAG,OAAO,QAAQ,CAAC;AACvC,MAAM,MAAM,UAAU,GAAG,OAAO,UAAU,CAAC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { type ClassValue } from 'clsx';
|
|
2
|
+
/**
|
|
3
|
+
* Utility function to merge Tailwind CSS classes.
|
|
4
|
+
* Combines clsx for conditional classes with tailwind-merge for deduplication.
|
|
5
|
+
*
|
|
6
|
+
* @example
|
|
7
|
+
* cn('px-4 py-2', 'px-6') // 'py-2 px-6'
|
|
8
|
+
* cn('text-red-500', isActive && 'text-blue-500')
|
|
9
|
+
* cn(baseStyles, variantStyles, className)
|
|
10
|
+
*/
|
|
11
|
+
export declare function cn(...inputs: ClassValue[]): string;
|
|
12
|
+
//# sourceMappingURL=cn.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cn.d.ts","sourceRoot":"","sources":["../../src/utils/cn.ts"],"names":[],"mappings":"AAAA,OAAO,EAAQ,KAAK,UAAU,EAAE,MAAM,MAAM,CAAC;AAG7C;;;;;;;;GAQG;AACH,wBAAgB,EAAE,CAAC,GAAG,MAAM,EAAE,UAAU,EAAE,GAAG,MAAM,CAElD"}
|