@kolkrabbi/kol-theme 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +26 -0
- package/kol-base-tokens.css +74 -0
- package/kol-color.css +280 -0
- package/kol-components-atoms.css +709 -0
- package/kol-components-molecules.css +255 -0
- package/kol-components-organisms.css +220 -0
- package/kol-opacity.css +369 -0
- package/kol-opaque.css +203 -0
- package/kol-theme.css +110 -0
- package/kol-type-mono-classes.css +115 -0
- package/kol-typography-mono.css +64 -0
- package/kol-typography.css +1090 -0
- package/kol-utilities.css +92 -0
- package/package.json +34 -0
package/kol-theme.css
ADDED
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Kolkrabbi Design System — Unified Theme entry point.
|
|
3
|
+
*
|
|
4
|
+
* Cascade order matters — later imports override earlier ones at equal
|
|
5
|
+
* specificity. Color/opacity primitives load first; typography consumes them;
|
|
6
|
+
* utilities provide generic helpers; components close the cascade with the
|
|
7
|
+
* highest-level chrome.
|
|
8
|
+
*
|
|
9
|
+
* 1. kol-color — surface tokens, ramps, brand/accent/status, semantic aliases
|
|
10
|
+
* 2. kol-opacity — fg-opacity scale (14 stops × {bg,text,border} × {standard,inverse}
|
|
11
|
+
* × {base,hover}) + 5 text-role tokens/classes
|
|
12
|
+
* 2b. kol-opaque — oq solid-neutral scale: the opaque mirror of kol-opacity
|
|
13
|
+
* (color-mix onto surface, not transparent). Same 14 stops.
|
|
14
|
+
* 3. kol-typography — @font-face, type scale tokens, .kol-prose
|
|
15
|
+
* 4. kol-utilities — flex-center, absolute-center, text-balance,
|
|
16
|
+
* breakpoint-padding, sr-only, fullbleed
|
|
17
|
+
* 5. kol-components — DS chrome: buttons, toggles, table, etc.
|
|
18
|
+
*
|
|
19
|
+
* Phase 5 rename map (from prior file names):
|
|
20
|
+
* theme.css → kol-theme.css (this file)
|
|
21
|
+
* kol-color-simple.css → kol-color.css (post-Phase-4a, hex-opacity family removed)
|
|
22
|
+
* kol-typography-mono.css → kol-typography.css (post-Phase-4a, type tokens added)
|
|
23
|
+
* components.css → kol-components.css (Table CSS absorbed from kol-client)
|
|
24
|
+
* (NEW) → kol-opacity.css (ported from kol-client Phase 4a)
|
|
25
|
+
* (NEW) → kol-utilities.css (curated slice of _new-css/utilities.css)
|
|
26
|
+
*/
|
|
27
|
+
|
|
28
|
+
@import "./kol-base-tokens.css";
|
|
29
|
+
@import "./kol-color.css";
|
|
30
|
+
@import "./kol-opacity.css";
|
|
31
|
+
@import "./kol-opaque.css";
|
|
32
|
+
@import "./kol-typography.css";
|
|
33
|
+
@import "./kol-typography-mono.css";
|
|
34
|
+
@import "./kol-type-mono-classes.css";
|
|
35
|
+
@import "./kol-utilities.css";
|
|
36
|
+
@import "./kol-components-atoms.css";
|
|
37
|
+
@import "./kol-components-molecules.css";
|
|
38
|
+
@import "./kol-components-organisms.css";
|
|
39
|
+
|
|
40
|
+
/* Theme-level design tokens */
|
|
41
|
+
:root {
|
|
42
|
+
/* Spacing scale (4px base) */
|
|
43
|
+
--kol-spacing-1: 0.25rem; /* 4px */
|
|
44
|
+
--kol-spacing-2: 0.5rem; /* 8px */
|
|
45
|
+
--kol-spacing-3: 0.75rem; /* 12px */
|
|
46
|
+
--kol-spacing-4: 1rem; /* 16px */
|
|
47
|
+
--kol-spacing-5: 1.25rem; /* 20px */
|
|
48
|
+
--kol-spacing-6: 1.5rem; /* 24px */
|
|
49
|
+
--kol-spacing-8: 2rem; /* 32px */
|
|
50
|
+
--kol-spacing-10: 2.5rem; /* 40px */
|
|
51
|
+
--kol-spacing-12: 3rem; /* 48px */
|
|
52
|
+
--kol-spacing-16: 4rem; /* 64px */
|
|
53
|
+
--kol-spacing-20: 5rem; /* 80px */
|
|
54
|
+
--kol-spacing-24: 6rem; /* 96px */
|
|
55
|
+
|
|
56
|
+
/* Semantic spacing aliases */
|
|
57
|
+
--kol-spacing-section: var(--kol-spacing-20);
|
|
58
|
+
--kol-spacing-container: var(--kol-spacing-10);
|
|
59
|
+
--kol-spacing-gap-sm: var(--kol-spacing-2);
|
|
60
|
+
--kol-spacing-gap-md: var(--kol-spacing-4);
|
|
61
|
+
--kol-spacing-gap-lg: var(--kol-spacing-6);
|
|
62
|
+
|
|
63
|
+
/* Border radius (4px increments) */
|
|
64
|
+
--kol-radius-none: 0;
|
|
65
|
+
--kol-radius-sm: 4px;
|
|
66
|
+
--kol-radius-md: 8px;
|
|
67
|
+
--kol-radius-lg: 12px;
|
|
68
|
+
--kol-radius-xl: 16px;
|
|
69
|
+
--kol-radius-2xl: 20px;
|
|
70
|
+
--kol-radius-full: 9999px;
|
|
71
|
+
|
|
72
|
+
/* Shadows (subtle elevation) */
|
|
73
|
+
--kol-shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
|
|
74
|
+
--kol-shadow-md: 0 4px 6px rgba(0, 0, 0, 0.07);
|
|
75
|
+
--kol-shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);
|
|
76
|
+
--kol-shadow-xl: 0 20px 25px rgba(0, 0, 0, 0.15);
|
|
77
|
+
--kol-shadow-inner: inset 0 2px 4px rgba(0, 0, 0, 0.06);
|
|
78
|
+
|
|
79
|
+
/* Transitions (consistent timing) */
|
|
80
|
+
--kol-transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
|
|
81
|
+
--kol-transition-base: 200ms cubic-bezier(0.4, 0, 0.2, 1);
|
|
82
|
+
--kol-transition-slow: 300ms cubic-bezier(0.4, 0, 0.2, 1);
|
|
83
|
+
--kol-transition-spring: 500ms cubic-bezier(0.34, 1.56, 0.64, 1);
|
|
84
|
+
|
|
85
|
+
/* Z-index scale */
|
|
86
|
+
--kol-z-base: 1;
|
|
87
|
+
--kol-z-dropdown: 10;
|
|
88
|
+
--kol-z-sticky: 20;
|
|
89
|
+
--kol-z-overlay: 50;
|
|
90
|
+
--kol-z-modal: 100;
|
|
91
|
+
--kol-z-toast: 200;
|
|
92
|
+
--kol-z-tooltip: 300;
|
|
93
|
+
--kol-z-nav: 1000;
|
|
94
|
+
|
|
95
|
+
/* Opacity values */
|
|
96
|
+
--kol-opacity-hover: 0.8;
|
|
97
|
+
--kol-opacity-disabled: 0.5;
|
|
98
|
+
--kol-opacity-subtle: 0.6;
|
|
99
|
+
--kol-opacity-loading: 0.7;
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
/* Dark mode shadow adjustments */
|
|
103
|
+
[data-theme="dark"],
|
|
104
|
+
.dark {
|
|
105
|
+
--kol-shadow-sm: 0 1px 2px rgba(255, 255, 255, 0.03);
|
|
106
|
+
--kol-shadow-md: 0 4px 6px rgba(255, 255, 255, 0.05);
|
|
107
|
+
--kol-shadow-lg: 0 10px 15px rgba(255, 255, 255, 0.08);
|
|
108
|
+
--kol-shadow-xl: 0 20px 25px rgba(255, 255, 255, 0.1);
|
|
109
|
+
--kol-shadow-inner: inset 0 2px 4px rgba(255, 255, 255, 0.04);
|
|
110
|
+
}
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* kol-type-mono-classes.css — Mono typography CLASSES (class-only).
|
|
3
|
+
*
|
|
4
|
+
* Split out of kol-typography-mono.css so a consumer can adopt the mono type
|
|
5
|
+
* SCALE (.kol-mono-N / .kol-helper-N) WITHOUT inheriting the JetBrains Mono
|
|
6
|
+
* @font-face / :root token / @theme contract. Each consumer's own
|
|
7
|
+
* --kol-font-family-mono supplies the actual font — fonts are per-app:
|
|
8
|
+
* apps/brand = JetBrains Mono, apps/web = RightGroteskMono.
|
|
9
|
+
*
|
|
10
|
+
* Classes reference --kol-font-family-mono + literal px values only; nothing
|
|
11
|
+
* else from the canonical typography files.
|
|
12
|
+
*
|
|
13
|
+
* Architecture: docs/kol-migration/locked/typography-system.md
|
|
14
|
+
*/
|
|
15
|
+
|
|
16
|
+
/* =============================================================================
|
|
17
|
+
* BASE SCALE — multi-line mono body / values. Weight 400 (regular), with leading.
|
|
18
|
+
* ============================================================================= */
|
|
19
|
+
|
|
20
|
+
.kol-mono-8 {
|
|
21
|
+
font-family: var(--kol-font-family-mono);
|
|
22
|
+
font-size: 8px;
|
|
23
|
+
line-height: 12px;
|
|
24
|
+
font-weight: 400;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
.kol-mono-10 {
|
|
28
|
+
font-family: var(--kol-font-family-mono);
|
|
29
|
+
font-size: 10px;
|
|
30
|
+
line-height: 14px;
|
|
31
|
+
font-weight: 400;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.kol-mono-12 {
|
|
35
|
+
font-family: var(--kol-font-family-mono);
|
|
36
|
+
font-size: 12px;
|
|
37
|
+
line-height: 16px;
|
|
38
|
+
font-weight: 400;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
.kol-mono-14 {
|
|
42
|
+
font-family: var(--kol-font-family-mono);
|
|
43
|
+
font-size: 14px;
|
|
44
|
+
line-height: 18px;
|
|
45
|
+
font-weight: 400;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
.kol-mono-16 {
|
|
49
|
+
font-family: var(--kol-font-family-mono);
|
|
50
|
+
font-size: 16px;
|
|
51
|
+
line-height: 22px;
|
|
52
|
+
font-weight: 400;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
.kol-mono-20 {
|
|
56
|
+
font-family: var(--kol-font-family-mono);
|
|
57
|
+
font-size: 20px;
|
|
58
|
+
line-height: 26px;
|
|
59
|
+
font-weight: 400;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
/* =============================================================================
|
|
63
|
+
* LABEL SCALE — single-line labels. Weight 500 (medium), no leading,
|
|
64
|
+
* letter-spaced. For label/value pairs at the same size where the label needs
|
|
65
|
+
* visual prominence (heavier weight) without size-jumping. Wider letter-spacing
|
|
66
|
+
* on the smallest two stops for sub-12px readability.
|
|
67
|
+
* ============================================================================= */
|
|
68
|
+
|
|
69
|
+
.kol-helper-8 {
|
|
70
|
+
font-family: var(--kol-font-family-mono);
|
|
71
|
+
font-size: 8px;
|
|
72
|
+
line-height: 1;
|
|
73
|
+
font-weight: 500;
|
|
74
|
+
letter-spacing: 0.10em;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
.kol-helper-10 {
|
|
78
|
+
font-family: var(--kol-font-family-mono);
|
|
79
|
+
font-size: 10px;
|
|
80
|
+
line-height: 1;
|
|
81
|
+
font-weight: 500;
|
|
82
|
+
letter-spacing: 0.10em;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
.kol-helper-12 {
|
|
86
|
+
font-family: var(--kol-font-family-mono);
|
|
87
|
+
font-size: 12px;
|
|
88
|
+
line-height: 1;
|
|
89
|
+
font-weight: 500;
|
|
90
|
+
letter-spacing: 0.06em;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
.kol-helper-14 {
|
|
94
|
+
font-family: var(--kol-font-family-mono);
|
|
95
|
+
font-size: 14px;
|
|
96
|
+
line-height: 1;
|
|
97
|
+
font-weight: 500;
|
|
98
|
+
letter-spacing: 0.06em;
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
.kol-helper-16 {
|
|
102
|
+
font-family: var(--kol-font-family-mono);
|
|
103
|
+
font-size: 16px;
|
|
104
|
+
line-height: 1;
|
|
105
|
+
font-weight: 500;
|
|
106
|
+
letter-spacing: 0.06em;
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
.kol-helper-20 {
|
|
110
|
+
font-family: var(--kol-font-family-mono);
|
|
111
|
+
font-size: 20px;
|
|
112
|
+
line-height: 1;
|
|
113
|
+
font-weight: 500;
|
|
114
|
+
letter-spacing: 0.06em;
|
|
115
|
+
}
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* kol-typography-mono.css — Mono typography FONTS + TOKENS (JetBrains Mono).
|
|
3
|
+
*
|
|
4
|
+
* @font-face cuts + the --kol-font-family-mono token + the Tailwind font-mono
|
|
5
|
+
* contract. The .kol-mono-N / .kol-helper-N CLASS rules moved to
|
|
6
|
+
* kol-type-mono-classes.css (class-only, font-agnostic) so a consumer can adopt
|
|
7
|
+
* the scale with its own mono font — fonts are per-app (brand = JetBrains Mono,
|
|
8
|
+
* web = RightGroteskMono). The umbrella kol-theme.css imports both files.
|
|
9
|
+
*
|
|
10
|
+
* Italic note: only 500i is bundled (Medium Italic). 400i (Regular Italic)
|
|
11
|
+
* deferred until a consumer requires it.
|
|
12
|
+
*
|
|
13
|
+
* Architecture: docs/kol-migration/locked/typography-system.md
|
|
14
|
+
*/
|
|
15
|
+
|
|
16
|
+
/* =============================================================================
|
|
17
|
+
* FONT-FACE — JetBrains Mono (4 weights: 400, 500, 500i, 600)
|
|
18
|
+
* ============================================================================= */
|
|
19
|
+
|
|
20
|
+
@font-face {
|
|
21
|
+
font-family: 'JetBrains Mono';
|
|
22
|
+
src: url('/fonts/jetbrains-mono/JetBrainsMono-Regular.woff2') format('woff2');
|
|
23
|
+
font-weight: 400;
|
|
24
|
+
font-style: normal;
|
|
25
|
+
font-display: swap;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
@font-face {
|
|
29
|
+
font-family: 'JetBrains Mono';
|
|
30
|
+
src: url('/fonts/jetbrains-mono/JetBrainsMono-Medium.woff2') format('woff2');
|
|
31
|
+
font-weight: 500;
|
|
32
|
+
font-style: normal;
|
|
33
|
+
font-display: swap;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
@font-face {
|
|
37
|
+
font-family: 'JetBrains Mono';
|
|
38
|
+
src: url('/fonts/jetbrains-mono/JetBrainsMono-MediumItalic.woff2') format('woff2');
|
|
39
|
+
font-weight: 500;
|
|
40
|
+
font-style: italic;
|
|
41
|
+
font-display: swap;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
@font-face {
|
|
45
|
+
font-family: 'JetBrains Mono';
|
|
46
|
+
src: url('/fonts/jetbrains-mono/JetBrainsMono-SemiBold.woff2') format('woff2');
|
|
47
|
+
font-weight: 600;
|
|
48
|
+
font-style: normal;
|
|
49
|
+
font-display: swap;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
/* =============================================================================
|
|
53
|
+
* FAMILY TOKEN + TAILWIND CONTRACT
|
|
54
|
+
*
|
|
55
|
+
* .kol-mono-N / .kol-helper-N class rules live in kol-type-mono-classes.css.
|
|
56
|
+
* ============================================================================= */
|
|
57
|
+
|
|
58
|
+
:root {
|
|
59
|
+
--kol-font-family-mono: 'JetBrains Mono', monospace;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
@theme {
|
|
63
|
+
--font-mono: 'JetBrains Mono', monospace;
|
|
64
|
+
}
|