@a4ui/core 0.10.0 → 0.10.2

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.
@@ -22,8 +22,8 @@ interface AppShellProps extends ParentProps {
22
22
  * an optional sidebar slot plus a content column (optional banner + topbar +
23
23
  * routed `<main>`). Slot-based and unopinionated about the sidebar — pass
24
24
  * your own component via `sidebar` and it manages its own width/collapse.
25
- * `<main>` is wrapped in `Suspense` + an `ErrorBoundary` (with a ~160ms page
26
- * cross-fade) so a route chunk failing or still loading never blanks the shell.
25
+ * `<main>` is wrapped in `Suspense` + an `ErrorBoundary` so a route chunk
26
+ * failing or still loading never blanks the shell.
27
27
  *
28
28
  * @example
29
29
  * ```tsx
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@a4ui/core",
3
- "version": "0.10.0",
3
+ "version": "0.10.2",
4
4
  "description": "A4ui — Spatial Glass design system & component library for SolidJS (Kobalte behavior + Tailwind glass tokens + motion).",
5
5
  "type": "module",
6
6
  "license": "MIT",
package/preset.js CHANGED
@@ -66,6 +66,31 @@ const glass = plugin(({ addComponents }) => {
66
66
  'radial-gradient(240px circle at var(--mx, 50%) var(--my, 50%), hsl(var(--primary) / 1), hsl(var(--accent) / 0.55) 42%, transparent 72%)',
67
67
  },
68
68
 
69
+ // ---- Field focus/error "bloom" ----
70
+ // Theme-aware glow for text fields: the colour comes from the theme's --ring
71
+ // (focus) or --destructive (invalid), so each theme blooms in its own hue.
72
+ // Applied via the `a4-field` class on inputs/triggers.
73
+ '.a4-field': {
74
+ transition: 'box-shadow .16s ease, border-color .16s ease',
75
+ },
76
+ '.a4-field:focus, .a4-field:focus-within': {
77
+ outline: 'none',
78
+ borderColor: 'hsl(var(--ring))',
79
+ boxShadow: '0 0 0 3px hsl(var(--ring) / 0.22), 0 0 16px -2px hsl(var(--ring) / 0.55)',
80
+ },
81
+ '.a4-field[aria-invalid="true"], .a4-field[data-invalid]': {
82
+ borderColor: 'hsl(var(--destructive))',
83
+ boxShadow: '0 0 0 2px hsl(var(--destructive) / 0.18)',
84
+ },
85
+ '.a4-field[aria-invalid="true"]:focus, .a4-field[data-invalid]:focus': {
86
+ outline: 'none',
87
+ boxShadow: '0 0 0 3px hsl(var(--destructive) / 0.3), 0 0 16px -2px hsl(var(--destructive) / 0.6)',
88
+ },
89
+ // Light backgrounds swallow soft glows — bloom a touch stronger there.
90
+ "[data-theme='light'] .a4-field:focus, [data-theme='light'] .a4-field:focus-within": {
91
+ boxShadow: '0 0 0 3px hsl(var(--ring) / 0.3), 0 0 18px -2px hsl(var(--ring) / 0.65)',
92
+ },
93
+
69
94
  // ---- Floating overlay glass (menus, modals, drawers, toasts) ----
70
95
  '.bg-glass': {
71
96
  background: 'hsl(var(--card) / 0.72)',