@invana/styling 0.0.19 → 0.0.21

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@invana/styling",
3
- "version": "0.0.19",
3
+ "version": "0.0.21",
4
4
  "description": "Invana TailwindCSS 4 Design System - Reusable styling configuration",
5
5
  "homepage": "https://github.com/invana/design-kit#readme",
6
6
  "type": "module",
@@ -71,6 +71,14 @@
71
71
  "./themes/presets-base.css": {
72
72
  "style": "./src/themes/presets-base.css",
73
73
  "default": "./src/themes/presets-base.css"
74
+ },
75
+ "./themes/data-palette": {
76
+ "style": "./src/themes/data-palette.css",
77
+ "default": "./src/themes/data-palette.css"
78
+ },
79
+ "./themes/data-palette.css": {
80
+ "style": "./src/themes/data-palette.css",
81
+ "default": "./src/themes/data-palette.css"
74
82
  }
75
83
  },
76
84
  "files": [
package/src/index.css CHANGED
@@ -49,6 +49,15 @@
49
49
  --color-destructive: hsl(0 70% 60%);
50
50
  --color-destructive-foreground: hsl(0 0% 100%);
51
51
 
52
+ /* Semantic status colors — agent/task state (activity markers, task dots,
53
+ votes). Distinct from destructive (which stays the action-danger color). */
54
+ --color-success: hsl(142 70% 38%);
55
+ --color-success-foreground: hsl(0 0% 100%);
56
+ --color-warning: hsl(38 92% 42%);
57
+ --color-warning-foreground: hsl(0 0% 100%);
58
+ --color-info: hsl(210 90% 45%);
59
+ --color-info-foreground: hsl(0 0% 100%);
60
+
52
61
  --color-muted: hsl(210 6% 90%);
53
62
  --color-muted-foreground: hsl(210 8% 45%);
54
63
 
@@ -63,12 +72,56 @@
63
72
  --color-card: hsl(0 0% 100%);
64
73
  --color-card-foreground: hsl(210 10% 20%);
65
74
 
66
- /* Border Radius */
67
- --radius: 0.5rem;
75
+ /* ------------------------------------------------------------------------
76
+ * Border radius — the design language, decided 01-09-2026.
77
+ *
78
+ * STRUCTURE is cut. 0 anything that CONTAINS
79
+ * CONTROLS are pressed. 2px anything you PRESS or TYPE INTO
80
+ * SHAPE is not radius. 999px only where round IS the object
81
+ *
82
+ * Structure: cards, panels, dialogs, popovers, menus, tables, ledger rows,
83
+ * chips, badges, tab panels, canvas surfaces, diagram nodes.
84
+ * Controls: buttons, inputs, selects, textareas, menu items, tab triggers,
85
+ * toggles — `rounded-control`, generated from `--radius-control` below.
86
+ * Shape: avatars, status dots, spinners, slider thumbs, switch capsules,
87
+ * scrollbar thumbs. These keep `rounded-full` because they are round
88
+ * objects, not rectangles with soft ends. A rectangle wearing round ends is
89
+ * a pill, and there are no pills.
90
+ *
91
+ * WHY 0 FOR STRUCTURE. The hairline grid is the house component: cells sit
92
+ * on a `bg-border` backdrop separated by `gap-px`, so the "border" is the
93
+ * backdrop showing through a one-pixel gap. Any radius on a cell lets that
94
+ * backdrop through at every corner as a grey notch — radii and hairline
95
+ * grids cannot both win. It also holds at application density: a radius
96
+ * that is invisible on a 44px button is loud on a 24px row, and nesting a
97
+ * chip in a row in a panel in a card stacks four of them into mush. Sharp
98
+ * nests at any size.
99
+ *
100
+ * WHY 2px FOR CONTROLS, not 0. At touch size a fully cut button reads as
101
+ * cut metal. 2px is invisible as decoration and legible as affordance: the
102
+ * difference between a surface and a thing you press is information, and in
103
+ * a dense application that does real work.
104
+ *
105
+ * The scale is deliberately flat. `rounded-sm` / `-md` / `-lg` / `-xl` /
106
+ * `-2xl` all resolve to 0, so the ~79 components already written against
107
+ * them need no edit, and a `rounded-lg` typed out of habit tomorrow cannot
108
+ * quietly reintroduce a radius.
109
+ * ---------------------------------------------------------------------- */
110
+ --radius: 0px;
111
+ --radius-sm: 0px;
112
+ --radius-md: 0px;
113
+ --radius-lg: 0px;
114
+ --radius-xl: 0px;
115
+ --radius-2xl: 0px;
116
+ --radius-3xl: 0px;
117
+
118
+ /* The only non-zero rectangle radius in the system. Generates
119
+ `rounded-control`, which every control component points at. */
120
+ --radius-control: 2px;
121
+
122
+ /* Retained: predates the decision, and is now the same value as
123
+ --radius-control. Prefer `rounded-control` — it says what it is for. */
68
124
  --radius-2px: 2px;
69
- --radius-lg: var(--radius);
70
- --radius-md: calc(var(--radius) - 2px);
71
- --radius-sm: calc(var(--radius) - 6px);
72
125
 
73
126
  /* Animations */
74
127
  --animate-accordion-down: accordion-down 0.2s ease-out;
@@ -102,6 +155,9 @@
102
155
  --destructive: 0 70% 60%;
103
156
  --background: 0 0% 97%;
104
157
  --accent: 210 6% 92%;
158
+ --success: 142 70% 38%;
159
+ --warning: 38 92% 42%;
160
+ --info: 210 90% 45%;
105
161
 
106
162
  --surface-alpha: 1; /* opaque → identical to current look */
107
163
  --glass-blur: none; /* no backdrop blur */
@@ -118,6 +174,53 @@
118
174
  -webkit-backdrop-filter: var(--glass-blur, none);
119
175
  }
120
176
 
177
+ /*
178
+ * Corner-bracket hover/focus affordance — drop `corner-hint` on a button,
179
+ * anchor, or list item directly (no wrapper element needed). Brackets float
180
+ * just outside the box and fade in on hover/focus, standing in for a solid
181
+ * highlight background.
182
+ */
183
+ @utility corner-hint {
184
+ position: relative;
185
+
186
+ &::before,
187
+ &::after {
188
+ content: "";
189
+ position: absolute;
190
+ inset: -6px;
191
+ pointer-events: none;
192
+ opacity: 0;
193
+ transform: scale(0.9);
194
+ transition: opacity 150ms ease-out, transform 150ms ease-out;
195
+ background-repeat: no-repeat;
196
+ background-image:
197
+ linear-gradient(hsl(var(--foreground) / 0.7), hsl(var(--foreground) / 0.7)),
198
+ linear-gradient(hsl(var(--foreground) / 0.7), hsl(var(--foreground) / 0.7)),
199
+ linear-gradient(hsl(var(--foreground) / 0.7), hsl(var(--foreground) / 0.7)),
200
+ linear-gradient(hsl(var(--foreground) / 0.7), hsl(var(--foreground) / 0.7));
201
+ }
202
+
203
+ &::before {
204
+ background-size: 10px 2px, 2px 10px, 10px 2px, 2px 10px;
205
+ background-position: top left, top left, top right, top right;
206
+ }
207
+
208
+ &::after {
209
+ background-size: 10px 2px, 2px 10px, 10px 2px, 2px 10px;
210
+ background-position: bottom left, bottom left, bottom right, bottom right;
211
+ }
212
+
213
+ &:hover::before,
214
+ &:hover::after,
215
+ &:focus-visible::before,
216
+ &:focus-visible::after,
217
+ &:focus-within::before,
218
+ &:focus-within::after {
219
+ opacity: 1;
220
+ transform: scale(1);
221
+ }
222
+ }
223
+
121
224
  @keyframes accordion-down {
122
225
  from {
123
226
  height: 0;
package/src/theme.css CHANGED
@@ -33,11 +33,18 @@
33
33
  --color-card: hsl(0 0% 100%);
34
34
  --color-card-foreground: hsl(222.2 84% 4.9%);
35
35
 
36
- /* Border Radius */
37
- --radius: 0.5rem;
38
- --radius-lg: var(--radius);
39
- --radius-md: calc(var(--radius) - 2px);
40
- --radius-sm: calc(var(--radius) - 4px);
36
+ /* Border Radius — see the full rationale in `index.css`.
37
+ Structure 0 · controls 2px (`rounded-control`) · round only where round
38
+ IS the object. The scale is flat on purpose so components already written
39
+ against rounded-sm/md/lg need no edit and cannot drift back. */
40
+ --radius: 0px;
41
+ --radius-sm: 0px;
42
+ --radius-md: 0px;
43
+ --radius-lg: 0px;
44
+ --radius-xl: 0px;
45
+ --radius-2xl: 0px;
46
+ --radius-3xl: 0px;
47
+ --radius-control: 2px;
41
48
 
42
49
  /* Animations */
43
50
  --animate-accordion-down: accordion-down 0.2s ease-out;
@@ -0,0 +1,72 @@
1
+ /*
2
+ * The categorical data palette.
3
+ *
4
+ * Node and edge types, chart series, legends and list dots all read this one
5
+ * scale, so a colour means the same thing wherever it appears — the dot beside
6
+ * `Observation` in a panel is the colour the canvas paints that node
7
+ * (design-kit-coverage.md D2).
8
+ *
9
+ * **Both modes are selected, not flipped.** The dark column is the same eight
10
+ * hues re-stepped for a dark surface. Validated with the dataviz validator
11
+ * against the kit's own card surfaces (`#fffdf7` light, `#1a1a1a` dark): the
12
+ * lightness band, chroma floor, adjacent-pair CVD separation and normal-vision
13
+ * floor all pass in both modes.
14
+ *
15
+ * Light mode carries a contrast WARN on aqua, yellow and magenta (below 3:1 on
16
+ * a near-white card). That is admissible **only** because every use in this
17
+ * system names the thing beside its swatch — a legend row has its type name, a
18
+ * chart series has a legend, a canvas node has its label. Colour is never the
19
+ * only carrier of identity here. Do not use these as a lone status colour, and
20
+ * do not put a value on a chart in series colour: text wears text tokens.
21
+ *
22
+ * Deliberately eight, in a fixed order. Slot 1 is the first series on every
23
+ * chart, not "whichever came back first from the query" — colour follows the
24
+ * entity, never its rank.
25
+ */
26
+
27
+ @theme {
28
+ /* Light — the default, matching the base tokens in index.css. */
29
+ --color-data-1: #2a78d6; /* blue */
30
+ --color-data-2: #eb6834; /* orange */
31
+ --color-data-3: #1baf7a; /* aqua */
32
+ --color-data-4: #eda100; /* yellow */
33
+ --color-data-5: #e87ba4; /* magenta */
34
+ --color-data-6: #008300; /* green */
35
+ --color-data-7: #4a3aa7; /* violet */
36
+ --color-data-8: #e34948; /* red */
37
+ }
38
+
39
+ /*
40
+ * Dark — every dark theme, whatever its brand accent. The data palette is not a
41
+ * brand palette: a chart series does not change hue because the shell went from
42
+ * Gold to Ocean, or the same data would look like different data.
43
+ */
44
+ [data-theme="default-dark"],
45
+ [data-theme="tailwind-dark"],
46
+ [data-theme="vite-dark"],
47
+ [data-theme="gold-dark"],
48
+ [data-theme="ocean-dark"],
49
+ [data-theme="forest-dark"],
50
+ [data-theme="rose-dark"],
51
+ [data-theme="minimal-dark"],
52
+ /* The generic hook every dark theme also stamps — this is what catches a theme
53
+ added after this file was written. The explicit ids above stay so the palette
54
+ works even where the class is not applied. */
55
+ .dark,
56
+ .theme-default-dark,
57
+ .theme-tailwind-dark,
58
+ .theme-vite-dark,
59
+ .theme-gold-dark,
60
+ .theme-ocean-dark,
61
+ .theme-forest-dark,
62
+ .theme-rose-dark,
63
+ .theme-minimal-dark {
64
+ --color-data-1: #3987e5;
65
+ --color-data-2: #d95926;
66
+ --color-data-3: #199e70;
67
+ --color-data-4: #c98500;
68
+ --color-data-5: #d55181;
69
+ --color-data-6: #008300;
70
+ --color-data-7: #9085e9;
71
+ --color-data-8: #e66767;
72
+ }
@@ -26,6 +26,12 @@
26
26
  --destructive: 0 70% 60%;
27
27
  --destructive-foreground: 0 0% 100%;
28
28
  --ring: 142 70% 43%;
29
+ --success: 142 70% 38%;
30
+ --success-foreground: 0 0% 100%;
31
+ --warning: 38 92% 42%;
32
+ --warning-foreground: 0 0% 100%;
33
+ --info: 210 90% 45%;
34
+ --info-foreground: 0 0% 100%;
29
35
 
30
36
  /* Full HSL colors for direct use */
31
37
  --color-background: hsl(0 0% 97%);
@@ -47,6 +53,12 @@
47
53
  --color-border: hsl(210 6% 85%);
48
54
  --color-input: hsl(210 6% 92%);
49
55
  --color-ring: hsl(142 70% 43%);
56
+ --color-success: hsl(142 70% 38%);
57
+ --color-success-foreground: hsl(0 0% 100%);
58
+ --color-warning: hsl(38 92% 42%);
59
+ --color-warning-foreground: hsl(0 0% 100%);
60
+ --color-info: hsl(210 90% 45%);
61
+ --color-info-foreground: hsl(0 0% 100%);
50
62
  }
51
63
 
52
64
  /* Dark mode - Default theme */
@@ -72,6 +84,12 @@
72
84
  --destructive: 0 60% 45%;
73
85
  --destructive-foreground: 0 0% 95%;
74
86
  --ring: 142 70% 60%;
87
+ --success: 142 65% 55%;
88
+ --success-foreground: 210 4% 13%;
89
+ --warning: 45 90% 60%;
90
+ --warning-foreground: 210 4% 13%;
91
+ --info: 210 90% 65%;
92
+ --info-foreground: 210 4% 13%;
75
93
 
76
94
  /* Full HSL colors for direct use */
77
95
  --color-background: hsl(210 4% 10%);
@@ -93,4 +111,10 @@
93
111
  --color-border: hsl(210 6% 22%);
94
112
  --color-input: hsl(210 6% 22%);
95
113
  --color-ring: hsl(142 70% 60%);
114
+ --color-success: hsl(142 65% 55%);
115
+ --color-success-foreground: hsl(210 4% 13%);
116
+ --color-warning: hsl(45 90% 60%);
117
+ --color-warning-foreground: hsl(210 4% 13%);
118
+ --color-info: hsl(210 90% 65%);
119
+ --color-info-foreground: hsl(210 4% 13%);
96
120
  }
@@ -34,6 +34,12 @@
34
34
  --destructive: 0 84% 60%;
35
35
  --destructive-foreground: 0 0% 100%;
36
36
  --ring: 199 89% 48%; /* sky-500 */
37
+ --success: 142 72% 36%;
38
+ --success-foreground: 0 0% 100%;
39
+ --warning: 32 95% 44%;
40
+ --warning-foreground: 0 0% 100%;
41
+ --info: 199 89% 48%;
42
+ --info-foreground: 0 0% 100%;
37
43
 
38
44
  /* Full HSL colors for direct use */
39
45
  --color-background: hsl(0 0% 100%);
@@ -55,6 +61,12 @@
55
61
  --color-border: hsl(214 32% 91%);
56
62
  --color-input: hsl(214 32% 91%);
57
63
  --color-ring: hsl(199 89% 48%);
64
+ --color-success: hsl(142 72% 36%);
65
+ --color-success-foreground: hsl(0 0% 100%);
66
+ --color-warning: hsl(32 95% 44%);
67
+ --color-warning-foreground: hsl(0 0% 100%);
68
+ --color-info: hsl(199 89% 48%);
69
+ --color-info-foreground: hsl(0 0% 100%);
58
70
  }
59
71
 
60
72
  /* Dark mode - Tailwind theme */
@@ -81,6 +93,12 @@
81
93
  --destructive: 0 63% 31%;
82
94
  --destructive-foreground: 210 40% 98%;
83
95
  --ring: 198 93% 60%; /* sky-400 */
96
+ --success: 142 69% 58%;
97
+ --success-foreground: 222 47% 11%;
98
+ --warning: 45 96% 56%;
99
+ --warning-foreground: 222 47% 11%;
100
+ --info: 199 93% 60%;
101
+ --info-foreground: 222 47% 11%;
84
102
 
85
103
  /* Full HSL colors for direct use */
86
104
  --color-background: hsl(222 47% 5%);
@@ -102,4 +120,10 @@
102
120
  --color-border: hsl(217 19% 27%);
103
121
  --color-input: hsl(217 19% 27%);
104
122
  --color-ring: hsl(198 93% 60%);
123
+ --color-success: hsl(142 69% 58%);
124
+ --color-success-foreground: hsl(222 47% 11%);
125
+ --color-warning: hsl(45 96% 56%);
126
+ --color-warning-foreground: hsl(222 47% 11%);
127
+ --color-info: hsl(199 93% 60%);
128
+ --color-info-foreground: hsl(222 47% 11%);
105
129
  }
@@ -36,6 +36,12 @@
36
36
  --destructive: 0 84% 60%;
37
37
  --destructive-foreground: 0 0% 100%;
38
38
  --ring: 235 85% 70%;
39
+ --success: 153 55% 40%;
40
+ --success-foreground: 0 0% 100%;
41
+ --warning: 38 92% 44%;
42
+ --warning-foreground: 0 0% 100%;
43
+ --info: 213 90% 52%;
44
+ --info-foreground: 0 0% 100%;
39
45
 
40
46
  /* Full HSL colors for direct use */
41
47
  --color-background: hsl(0 0% 100%);
@@ -57,6 +63,12 @@
57
63
  --color-border: hsl(240 6% 90%);
58
64
  --color-input: hsl(240 6% 90%);
59
65
  --color-ring: hsl(235 85% 70%);
66
+ --color-success: hsl(153 55% 40%);
67
+ --color-success-foreground: hsl(0 0% 100%);
68
+ --color-warning: hsl(38 92% 44%);
69
+ --color-warning-foreground: hsl(0 0% 100%);
70
+ --color-info: hsl(213 90% 52%);
71
+ --color-info-foreground: hsl(0 0% 100%);
60
72
  }
61
73
 
62
74
  /* Dark mode - Vite theme */
@@ -83,6 +95,12 @@
83
95
  --destructive: 0 63% 50%;
84
96
  --destructive-foreground: 0 0% 100%;
85
97
  --ring: 235 85% 70%;
98
+ --success: 153 55% 55%;
99
+ --success-foreground: 240 6% 12%;
100
+ --warning: 45 90% 60%;
101
+ --warning-foreground: 240 6% 12%;
102
+ --info: 213 90% 66%;
103
+ --info-foreground: 240 6% 12%;
86
104
 
87
105
  /* Full HSL colors for direct use */
88
106
  --color-background: hsl(0 0% 14%);
@@ -104,4 +122,10 @@
104
122
  --color-border: hsl(0 0% 20%);
105
123
  --color-input: hsl(0 0% 20%);
106
124
  --color-ring: hsl(235 85% 70%);
125
+ --color-success: hsl(153 55% 55%);
126
+ --color-success-foreground: hsl(240 6% 12%);
127
+ --color-warning: hsl(45 90% 60%);
128
+ --color-warning-foreground: hsl(240 6% 12%);
129
+ --color-info: hsl(213 90% 66%);
130
+ --color-info-foreground: hsl(240 6% 12%);
107
131
  }