orbital-ds 0.10.0 → 0.12.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.
Files changed (74) hide show
  1. package/AGENTS.md +37 -6
  2. package/README.md +7 -1
  3. package/components.manifest.json +1854 -1713
  4. package/contract.json +37 -0
  5. package/dist/hooks/use-ds-messages.d.ts +17 -0
  6. package/dist/lib/echarts-server.js +2 -2
  7. package/dist/lib/echarts-setup.d.ts +5 -1
  8. package/dist/lib/echarts-setup.js +36 -28
  9. package/dist/lib/i18n.d.ts +17 -0
  10. package/dist/lib/i18n.js +54 -3
  11. package/dist/styles.css +111 -0
  12. package/dist/themes/fractalia.css +464 -0
  13. package/dist/themes/fractalia.fonts.css +3 -0
  14. package/dist/themes/fractalia.guide.md +77 -0
  15. package/dist/themes/fractalia.meta.json +96 -0
  16. package/dist/themes/fractalia.scoped.css +464 -0
  17. package/dist/themes/fractalia.tokens.json +39 -0
  18. package/dist/ui/accordion.js +1 -1
  19. package/dist/ui/attachment.js +1 -1
  20. package/dist/ui/badge.js +1 -1
  21. package/dist/ui/banner.js +2 -2
  22. package/dist/ui/button-group.js +1 -1
  23. package/dist/ui/button.js +7 -7
  24. package/dist/ui/calendar.js +2 -2
  25. package/dist/ui/chart.js +3 -3
  26. package/dist/ui/combobox.js +1 -1
  27. package/dist/ui/command.js +1 -1
  28. package/dist/ui/echart.js +2 -2
  29. package/dist/ui/empty.js +1 -1
  30. package/dist/ui/field.js +2 -2
  31. package/dist/ui/gauge.d.ts +40 -0
  32. package/dist/ui/gauge.js +157 -0
  33. package/dist/ui/heatmap-grid.js +1 -1
  34. package/dist/ui/input-group.js +1 -1
  35. package/dist/ui/input.js +1 -1
  36. package/dist/ui/item.js +1 -1
  37. package/dist/ui/kbd.js +1 -1
  38. package/dist/ui/label.js +1 -1
  39. package/dist/ui/legend.d.ts +3 -1
  40. package/dist/ui/legend.js +15 -1
  41. package/dist/ui/level-meter.d.ts +16 -0
  42. package/dist/ui/level-meter.js +60 -0
  43. package/dist/ui/menubar.js +1 -1
  44. package/dist/ui/message.js +2 -2
  45. package/dist/ui/navigation-menu.js +1 -1
  46. package/dist/ui/password-strength.d.ts +14 -0
  47. package/dist/ui/password-strength.js +61 -0
  48. package/dist/ui/progress.js +1 -1
  49. package/dist/ui/proportion-bar.js +2 -2
  50. package/dist/ui/questionnaire.js +2 -2
  51. package/dist/ui/shield.d.ts +21 -0
  52. package/dist/ui/shield.js +141 -0
  53. package/dist/ui/sidebar.js +1 -1
  54. package/dist/ui/status-badge.d.ts +3 -2
  55. package/dist/ui/status-badge.js +4 -2
  56. package/dist/ui/status-hero.d.ts +12 -0
  57. package/dist/ui/status-hero.js +60 -0
  58. package/dist/ui/step-dots.d.ts +10 -0
  59. package/dist/ui/step-dots.js +40 -0
  60. package/dist/ui/step-ring.d.ts +12 -0
  61. package/dist/ui/step-ring.js +35 -0
  62. package/dist/ui/table.js +1 -1
  63. package/dist/ui/tabs.js +1 -1
  64. package/dist/ui/task-loader.d.ts +14 -0
  65. package/dist/ui/task-loader.js +50 -0
  66. package/dist/ui/task-progress.d.ts +18 -0
  67. package/dist/ui/task-progress.js +84 -0
  68. package/dist/ui/toggle.js +1 -1
  69. package/docs/adr/0002-sistemas-corporativos-al-modelo.md +176 -0
  70. package/package.json +173 -171
  71. package/scripts/brand-core.mjs +5 -3
  72. package/scripts/doctor.mjs +61 -3
  73. package/scripts/i18n.mjs +0 -0
  74. package/scripts/init.mjs +182 -26
@@ -0,0 +1,464 @@
1
+ /*
2
+ * TEMA fractalia — «Plataforma Fractalia: navy institucional, claridad y cero adornos».
3
+ *
4
+ * Fuente: FractaliaDS (repositorio GitLab design-system → fractalia-ds/tokens.css),
5
+ * reflejo de las Variables de Figma y de las fichas de Supernova (DS 821888).
6
+ * Ningún valor de la piel clara está inventado: cada hex lleva al lado su token.
7
+ *
8
+ * Gestos del sistema que este tema traslada:
9
+ * - Botones en píldora (Radius Label 32px), Roboto Bold en MAYÚSCULAS por CSS.
10
+ * - Hover del primario = azul `primary-hover` + sombra `drop-shadow`; sin elevación.
11
+ * - Campos rellenos (neutral-bg) con borde fino neutral-black y esquina de 4px.
12
+ * - Pestañas en píldora: la activa, rellena de navy con texto blanco.
13
+ * - Montserrat Bold solo en encabezados; Roboto para todo lo demás.
14
+ * - Cero degradados. Solo las 4 sombras oficiales (Effect Styles).
15
+ *
16
+ * Importar DESPUÉS de la estructura. Variables `--zf-*`: privadas de este tema.
17
+ * Fuentes: `fractalia.fonts.css` (Montserrat + Roboto), lo primero del CSS de la app.
18
+ */
19
+
20
+ /* ── VARIABLES · PIEL CLARA (publicada en el DS) ─────────────────────────── */
21
+ :root:where([data-theme='fractalia']) {
22
+ --radius: 8px; /* Radius Notifications */
23
+
24
+ --ds-font-sans: 'Roboto', system-ui, -apple-system, 'Segoe UI', sans-serif;
25
+ --ds-font-display: 'Montserrat', system-ui, sans-serif;
26
+ --ds-font-mono: ui-monospace, 'SF Mono', Menlo, monospace;
27
+
28
+ /* Lateral: iconos newcore a 24px, filas de 44px (item-menu desktop) */
29
+ --ds-sidebar-icon: 1.5rem;
30
+ --ds-sidebar-icon-stroke: 2;
31
+ --ds-sidebar-rail-w: 4.5rem;
32
+ --ds-sidebar-rail-item: 2.75rem;
33
+ --ds-sidebar-logo: 2.25rem;
34
+ --ds-sidebar-sep-inset: 0rem;
35
+ --ds-heading-tracking: normal; /* letter-spacing 0 en todos los estilos */
36
+
37
+ /* Color: lienzo neutral-bg, tinta neutral-black, primario navy, acento azul */
38
+ --background: #ecf1f8; /* neutral-100 · neutral-bg */
39
+ --foreground: #34383f; /* neutral-900 · neutral-black */
40
+
41
+ --card: #ffffff; /* neutral-0 */
42
+ --card-foreground: #34383f;
43
+ --popover: #ffffff;
44
+ --popover-foreground: #34383f;
45
+
46
+ --primary: #242b5a; /* primary-default */
47
+ --primary-foreground: #ffffff;
48
+ --secondary: #ecf1f8; /* botón Secondary: neutral-bg + texto navy */
49
+ --secondary-foreground: #242b5a;
50
+ --muted: #ecf1f8;
51
+ --muted-foreground: #666a73; /* neutral-700 · grey-medium (4.78:1 sobre muted) */
52
+ --accent: #ecf1f8; /* fila seleccionada de item-menu */
53
+ --accent-foreground: #34383f;
54
+ --destructive: #d60000; /* danger-500 · botón Delete */
55
+ --destructive-foreground: #ffffff;
56
+
57
+ --border: #e3e8f3; /* neutral-200 · grey (separadores) */
58
+ --input: #34383f; /* borde de inputs y dropdown: neutral-black */
59
+ --ring: #0349fe; /* accent-default (convención de foco) */
60
+
61
+ /* Series de gráficas (paleta de grafica-grafc + navy) */
62
+ --chart-1: #0349fe; /* accent */
63
+ --chart-2: #242b5a; /* primary */
64
+ --chart-3: #007922; /* success-700 */
65
+ --chart-4: #c25400; /* warning-900 */
66
+ --chart-5: #d60000; /* danger-500 */
67
+
68
+ --sidebar: #ffffff;
69
+ --sidebar-foreground: #34383f;
70
+ --sidebar-primary: #242b5a;
71
+ --sidebar-primary-foreground: #ffffff;
72
+ --sidebar-accent: #ecf1f8; /* item-menu selected */
73
+ --sidebar-accent-foreground: #34383f;
74
+ --sidebar-border: #e3e8f3;
75
+ --sidebar-ring: #0349fe;
76
+
77
+ --danger: #d60000; /* danger-500 */
78
+ --danger-soft: #ffd9d9; /* danger-0 · danger-light */
79
+ --warning: #c25400; /* warning-900 · warning-dark */
80
+ --warning-soft: #fff5d6; /* warning-0 · warning-light */
81
+ --success: #007922; /* success-700 */
82
+ --success-soft: #d7fae1; /* success-0 */
83
+ --info: #0349fe; /* info-500 */
84
+ --info-soft: #d3dffe; /* info-0 */
85
+ --neutral: #666a73; /* neutral-700 */
86
+ --neutral-soft: #e3e8f3; /* neutral-200 */
87
+
88
+ --link: #0349fe; /* accent-default */
89
+ --link-hover: #012b98; /* accent-hover */
90
+ --inset: #ecf1f8;
91
+ --inset-foreground: #34383f;
92
+ --brand: #242b5a;
93
+ --brand-bright: #2a8bb8; /* primary-hover */
94
+
95
+ /* Formas: rampa primitives/radius (4 · 8 · 12 · 16 · 24) */
96
+ --ds-radius-sm: 4px; /* radius-xxs · Radius Imputs */
97
+ --ds-radius-md: 8px; /* radius-xs · Radius Notifications */
98
+ --ds-radius-lg: 12px; /* radius-s */
99
+ --ds-radius-xl: 16px; /* radius-sm */
100
+ --ds-radius-2xl: 24px; /* radius-md · Radius Circle M */
101
+ --ds-radius-control: 4px; /* inputs, dropdown, textarea */
102
+ --ds-radius-overlay: 16px; /* radius-sm (pendiente de confirmar en modales) */
103
+
104
+ /* Sombras: SOLO los 4 Effect Styles oficiales */
105
+ --ds-shadow-card: 0 1px 3px 0 rgba(52, 56, 63, 0.08), 0 4px 8px 1px rgba(52, 56, 63, 0.04); /* elevation-test */
106
+ --ds-shadow-card-hover: 0 4px 4px 0 rgba(188, 196, 212, 0.75); /* drop-shadow */
107
+ --ds-shadow-control: 0 0 #0000;
108
+ --ds-shadow-raised: 0 1px 3px 0 rgba(52, 56, 63, 0.08), 0 4px 8px 1px rgba(52, 56, 63, 0.04); /* elevation-test */
109
+ --ds-shadow-overlay: 0 4px 4px 0 rgba(188, 196, 212, 0.75); /* drop-shadow */
110
+ --ds-shadow-popover: 0 3px 5px 0 rgba(0, 0, 0, 0.1); /* menu-shadow */
111
+
112
+ /* Medidas: botón 12+16+12 = 40px; inputs y filas de menú 44px */
113
+ --ds-control-h-sm: 2rem;
114
+ --ds-control-h-md: 2.5rem;
115
+ --ds-control-h-lg: 2.75rem;
116
+ --ds-button-px-sm: 1rem; /* spacing-sm 16 */
117
+ --ds-button-px-md: 2rem; /* spacing-l 32 */
118
+ --ds-button-px-lg: 2.5rem; /* spacing-xl 40 */
119
+ --ds-field-px: 0.75rem; /* spacing-s 12 */
120
+ --ds-card-spacing: 1rem; /* spacing-sm 16 */
121
+ --ds-card-spacing-sm: 0.75rem; /* spacing-s 12 */
122
+
123
+ /* Sin cristal: material plano */
124
+ --ds-card-backdrop: none;
125
+ --ds-overlay-backdrop: none;
126
+ --ds-field-backdrop: none;
127
+ --ds-sidebar-backdrop: none;
128
+ --ds-page-backdrop: none;
129
+
130
+ /* Sidebar blanca a ras de borde sobre el lienzo neutral-bg */
131
+ --ds-sidebar-pad: 0px;
132
+ --ds-sidebar-radius: 0px;
133
+ --ds-sidebar-shadow: 0 0 #0000;
134
+ --ds-sidebar-ring: 0px;
135
+ --ds-sidebar-edge: 1px solid var(--sidebar-border);
136
+ --ds-sidebar-item-radius: 8px; /* item-menu selected */
137
+ --ds-sidebar-item-h: 2.75rem; /* 44px */
138
+
139
+ /* Traducción de las fichas del DS a los huecos del núcleo (ADR 0002) */
140
+ --ds-radius-button: 32px; /* Radius Label: botones en píldora */
141
+ --ds-radius-badge: 32px; /* tag */
142
+ --ds-radius-tab: 32px; /* button-tab-rounded */
143
+ --ds-radius-tabs-list: 32px; /* tab-box-rounded */
144
+ --ds-radius-track: 4px; /* progress-bar: radio 4 */
145
+ --ds-track-h: 12px; /* progress-bar: alto 12 */
146
+ --ds-field-bg: #ecf1f8; /* inputs y dropdown: relleno neutral-bg */
147
+ --ds-field-bg-hover: #ecf1f8; /* el DS no cambia el relleno al pasar */
148
+ --ds-switch-track-off: #c8cdd8; /* switch OFF · grey-light */
149
+ --ds-button-primary-hover: #2a8bb8; /* primary-hover */
150
+ --ds-button-primary-hover-fg: #ffffff;
151
+ --ds-button-outline-bg: #ffffff; /* botón White */
152
+ --ds-button-outline-fg: var(--primary);
153
+ --ds-button-outline-border: var(--primary);
154
+ --ds-button-secondary-border: var(--primary); /* botón Secondary: borde navy */
155
+ --ds-ring-width: 2px; /* foco: 2px */
156
+ --ds-step-size: 34px; /* empresa-item-step (desktop) */
157
+ --ds-status-dot-sm: 12px; /* status-ball: sm 12 · md 16 · lg 24 */
158
+ --ds-status-dot-md: 16px;
159
+ --ds-status-dot-lg: 24px;
160
+ --ds-legend-swatch: 8px; /* bolita de leyenda de las gráficas */
161
+ --ds-badge-px: 8px; /* tag: padding 2/8 */
162
+ --ds-badge-py: 2px;
163
+ /* Pesos: el tema carga Roboto 400/700 y Montserrat 700; ningún peso intermedio */
164
+ --ds-button-weight: 700;
165
+ --ds-title-weight: 700;
166
+ --ds-overlay-title-weight: 700;
167
+ --ds-heading-weight: 700;
168
+ --ds-strong-weight: 700;
169
+ --ds-stat-value-weight: 700;
170
+ --ds-nav-weight: 700; /* item-menu: Roboto Bold */
171
+ --ds-tab-weight: 400;
172
+ --ds-tab-active-weight: 700;
173
+ --ds-table-head-weight: 700;
174
+ --ds-badge-weight: 400; /* tag: Roboto Regular 12 */
175
+ --ds-medium-weight: 400; /* Roboto no carga 500: el «medio» es Regular */
176
+ /* Botón desactivado con color, sin opacidad (button.md · Disabled) */
177
+ --ds-button-disabled-bg: #c8cdd8; /* secondary-disabled */
178
+ --ds-button-disabled-fg: #666a73; /* grey-medium */
179
+ --ds-button-disabled-border: transparent;
180
+ --ds-button-disabled-opacity: 1;
181
+
182
+ /* Piezas de estado y progreso: valores de fractalia.components (fichas 01–03 del DS) */
183
+ --ds-track-bg: #c8cdd8; /* neutrals-grey-light: pistas e inactivos */
184
+ --ds-gauge-size: 140px; /* grafica-grafc: marco 140 */
185
+ --ds-gauge-stroke: 12px; /* PROPUESTA: la ficha no da grosor */
186
+ --ds-gauge-value-size: 32px; /* desktop-h4-l */
187
+ --ds-gauge-suffix-size: 18px;
188
+ --ds-shield-w: 124px; /* shield S/M/S2/S3 */
189
+ --ds-shield-h: 150px;
190
+ --ds-shield-w-sm: 85px; /* corporate */
191
+ --ds-shield-h-sm: 103px;
192
+ --ds-shield-stroke: 10px;
193
+ --ds-shield-filter: drop-shadow(0 4px 4px rgba(0, 0, 0, 0.25)); /* sombra de Figma */
194
+ --ds-shield-value-size: 24px;
195
+ --ds-shield-value-weight: 700; /* Figma: ExtraBold 800, no cargado (decisión pendiente) */
196
+ --ds-shield-badge: 40px;
197
+ --ds-shield-radar-size: 240px;
198
+ --ds-shield-radar-circle: 182px;
199
+ --ds-shield-radar-glow: 12px; /* aproximado sobre el render */
200
+ --ds-strength-segment-w: 24px;
201
+ --ds-strength-segment-h: 5px;
202
+ --ds-strength-gap: 2px;
203
+ --ds-strength-radius: 8px;
204
+ --ds-step-dot: 12px;
205
+ --ds-step-dot-active-w: 32px;
206
+ --ds-step-dot-gap: 12px;
207
+ --ds-step-dot-bg: var(--muted); /* neutral-bg (el DS: no se ve sobre el lienzo, solo sobre blanco) */
208
+ --ds-step-ring-size: 24px;
209
+ --ds-level-value-size: 18px; /* desktop-h4 */
210
+ --ds-level-range-size: 26px; /* desktop-h4-m */
211
+ --ds-status-hero: 88px; /* alerta-estado: 12 + 64 + 12 */
212
+ --ds-status-hero-p: 12px;
213
+ --ds-status-hero-radius: 24px; /* Radius Circle M */
214
+ --ds-status-hero-badge: 28px;
215
+ --ds-status-halo-blur: 10px;
216
+ --ds-status-halo-inset: 3px; /* ficha: inset de 3px */
217
+ --ds-status-halo-success: rgba(138, 197, 142, 0.5);
218
+ --ds-status-halo-warning: rgba(255, 230, 148, 0.5);
219
+ --ds-status-halo-danger: rgba(255, 110, 110, 0.75);
220
+ --ds-loader-size: 88px; /* loader-analisis */
221
+ --ds-loader-p: 12px;
222
+ --ds-loader-radius: 24px;
223
+ --ds-loader-icon: 64px;
224
+ --ds-loader-bar-h: 2px;
225
+ --ds-loader-done-glow: 0 0 16px rgba(3, 73, 254, 0.25); /* PROPUESTA: glow «celeste» */
226
+
227
+ /* Privadas de fractalia (solo lo que ningún hueco público cubre) */
228
+ --zf-fill-hover: rgba(52, 56, 63, 0.08); /* state layer hover 0.08 */
229
+ --zf-fill-press: rgba(52, 56, 63, 0.12); /* state layer pressed 0.12 */
230
+ --zf-border-thick: 2px; /* checkbox y foco */
231
+ --zf-focus-offset: 2px;
232
+ }
233
+
234
+ /* ── VARIABLES · PIEL OSCURA (DERIVADA — no publicada en el DS) ────────────
235
+ * Fractalia no tiene tema oscuro en Figma ni en Supernova. Se parte de la capa
236
+ * oscura derivada de fractalia-ds/tokens.css. No llevar a Figma sin validar con diseño.
237
+ */
238
+ :where(:root[data-theme='fractalia']).dark {
239
+ --background: #10122a;
240
+ --foreground: #e4e9f6;
241
+
242
+ --card: #151833;
243
+ --card-foreground: #e4e9f6;
244
+ --popover: #1e2246;
245
+ --popover-foreground: #e4e9f6;
246
+
247
+ --primary: #c6d2f5; /* = text-heading oscuro; navy ilegible sobre fondo oscuro */
248
+ --primary-foreground: #242b5a;
249
+ --secondary: #1e2246;
250
+ --secondary-foreground: #e4e9f6;
251
+ --muted: #1e2246;
252
+ --muted-foreground: #9aa3bc;
253
+ --accent: #1e2246;
254
+ --accent-foreground: #e4e9f6;
255
+ --destructive: #ff7a7a; /* danger-300 */
256
+ --destructive-foreground: #10122a;
257
+
258
+ --border: #2c3157;
259
+ --input: #9aa3bc;
260
+ --ring: #7497fb; /* info-300 */
261
+
262
+ --chart-1: #7497fb; /* info-300 */
263
+ --chart-2: #c6d2f5;
264
+ --chart-3: #51ca6f; /* success-400 */
265
+ --chart-4: #ffb313; /* warning-400 */
266
+ --chart-5: #ff7a7a; /* danger-300 */
267
+
268
+ --sidebar: #151833;
269
+ --sidebar-foreground: #e4e9f6;
270
+ --sidebar-primary: #c6d2f5;
271
+ --sidebar-primary-foreground: #242b5a;
272
+ --sidebar-accent: #1e2246;
273
+ --sidebar-accent-foreground: #e4e9f6;
274
+ --sidebar-border: #2c3157;
275
+ --sidebar-ring: #7497fb;
276
+
277
+ --danger: #ff7a7a;
278
+ --danger-soft: rgba(214, 0, 0, 0.2);
279
+ --warning: #ffb313;
280
+ --warning-soft: rgba(255, 179, 19, 0.16);
281
+ --success: #51ca6f;
282
+ --success-soft: rgba(45, 177, 79, 0.18);
283
+ --info: #7497fb;
284
+ --info-soft: rgba(3, 73, 254, 0.22);
285
+ --neutral: #9aa3bc;
286
+ --neutral-soft: rgba(255, 255, 255, 0.08);
287
+
288
+ --link: #7497fb; /* info-300 */
289
+ --link-hover: #98b4fc; /* info-200 */
290
+ --inset: #1e2246;
291
+ --inset-foreground: #e4e9f6;
292
+ --brand: #c6d2f5;
293
+ --brand-bright: #7497fb;
294
+
295
+ --ds-shadow-card: 0 1px 3px 0 rgba(0, 0, 0, 0.32), 0 4px 8px 1px rgba(0, 0, 0, 0.2);
296
+ --ds-shadow-card-hover: 0 4px 4px 0 rgba(0, 0, 0, 0.45);
297
+ --ds-shadow-raised: 0 1px 3px 0 rgba(0, 0, 0, 0.32), 0 4px 8px 1px rgba(0, 0, 0, 0.2);
298
+ --ds-shadow-overlay: 0 4px 4px 0 rgba(0, 0, 0, 0.5);
299
+ --ds-shadow-popover: 0 3px 5px 0 rgba(0, 0, 0, 0.4);
300
+
301
+ --ds-button-primary-hover: #98b4fc;
302
+ --ds-button-primary-hover-fg: #242b5a;
303
+ --ds-button-outline-bg: transparent;
304
+ --ds-button-disabled-bg: #2c3157;
305
+ --ds-track-bg: #3c4270;
306
+ --ds-shield-filter: drop-shadow(0 4px 4px rgba(0, 0, 0, 0.5));
307
+ --ds-status-halo-success: rgba(81, 202, 111, 0.35);
308
+ --ds-status-halo-warning: rgba(255, 179, 19, 0.35);
309
+ --ds-status-halo-danger: rgba(255, 122, 122, 0.45);
310
+ --ds-loader-done-glow: 0 0 16px rgba(116, 151, 251, 0.35);
311
+ --ds-button-disabled-fg: #9aa3bc;
312
+ --ds-field-bg: #1e2246;
313
+ --ds-field-bg-hover: #1e2246;
314
+ --ds-switch-track-off: #3c4270;
315
+ --zf-fill-hover: rgba(255, 255, 255, 0.08);
316
+ --zf-fill-press: rgba(255, 255, 255, 0.12);
317
+ }
318
+
319
+ /* ── VARIABLES DE LA PERSONALIDAD ────────────────────────────────────────────
320
+ * Lo que las reglas de abajo piden: cámbialo aquí (o en el brand.css de la app),
321
+ * nunca en las reglas. Movimiento: tokens de 00-foundations/tokens-motion.md.
322
+ */
323
+ :root:where([data-theme='fractalia']) {
324
+ /* Movimiento: sobrio y funcional, sin rebote */
325
+ --ds-motion-fast: 120ms; /* duration-hover */
326
+ --ds-motion-base: 220ms; /* duration-transition */
327
+ --ds-motion-slow: 360ms; /* duration-overlay */
328
+ --ds-ease-standard: cubic-bezier(0.2, 0, 0, 1); /* easing-default */
329
+ --ds-ease-enter: cubic-bezier(0, 0, 0, 1); /* easing-enter (decelerate) */
330
+ --ds-ease-exit: cubic-bezier(0.3, 0, 1, 1); /* easing-exit (accelerate) */
331
+ --ds-motion-distance: 8px; /* spacing-xs — diseñado, no publicado */
332
+ --ds-motion-scale: 0.98; /* diseñado, no publicado */
333
+ --ds-motion-blur: 0px;
334
+ --ds-spring-bounce: 0;
335
+ --ds-motion-stagger: 0ms;
336
+ --ds-motion-press-scale: 1; /* el DS no encoge al pulsar */
337
+ --ds-motion-pulse: 1500ms; /* motion-duration.pulse (radar, latidos) */
338
+ --ds-ease-pulse: cubic-bezier(0.4, 0, 0.6, 1); /* easing-pulse */
339
+ --ds-key-weight: 700; /* Roboto Bold en botones */
340
+ --ds-button-case: uppercase;
341
+ --ds-button-tracking: 0;
342
+ --ds-button-outline-w: 1px; /* sin decimales: solo 0/1/2/4/6 */
343
+ --ds-shadow-button: 0 0 #0000;
344
+ --ds-shadow-button-hover: 0 4px 4px 0 rgba(188, 196, 212, 0.75); /* drop-shadow */
345
+ --ds-hover-lift: 0px;
346
+ --ds-label-tracking: 0;
347
+ --ds-label-weight: 700;
348
+ --ds-nav-active-weight: 700;
349
+ }
350
+
351
+ :where(:root[data-theme='fractalia']).dark {
352
+ --ds-shadow-button-hover: 0 4px 4px 0 rgba(0, 0, 0, 0.45);
353
+ }
354
+
355
+ @media (prefers-reduced-motion: reduce) {
356
+ :root {
357
+ --ds-motion-fast: 0ms; /* a11y.reduced-motion-duration */
358
+ --ds-motion-base: 0ms;
359
+ --ds-motion-slow: 0ms;
360
+ --ds-motion-distance: 0px;
361
+ --ds-motion-scale: 1;
362
+ }
363
+ }
364
+
365
+ /* ── PERSONALIDAD ────────────────────────────────────────────────────────────
366
+ * Sin capa: gana a las utilidades de los componentes. Solo variables
367
+ * (`conformance: strict`). Familias completas.
368
+ */
369
+ :root:where([data-theme='fractalia']) {
370
+ /* Botones: píldora de 32px, Roboto Bold en MAYÚSCULAS, sin elevación */
371
+ [data-slot='button'] {
372
+ text-transform: var(--ds-button-case);
373
+ letter-spacing: var(--ds-button-tracking);
374
+ font-family: var(--ds-font-sans);
375
+ font-weight: var(--ds-key-weight);
376
+ transition:
377
+ background-color var(--ds-motion-fast) var(--ds-ease-standard),
378
+ box-shadow var(--ds-motion-fast) var(--ds-ease-standard);
379
+ }
380
+ [data-slot='button'][data-variant='link'] {
381
+ text-transform: none;
382
+ letter-spacing: normal;
383
+ }
384
+ /* Primary: hover azul primary-hover + drop-shadow */
385
+ [data-slot='button'][data-variant='default'] {
386
+ box-shadow: var(--ds-shadow-button);
387
+ }
388
+ [data-slot='button'][data-variant='default']:hover:not(:disabled) {
389
+ box-shadow: var(--ds-shadow-button-hover);
390
+ }
391
+ /* Focus: mantiene el fondo, anillo primary-hover a 2px + drop-shadow.
392
+ Con outline (no box-shadow) para que la sombra no anule el foco. */
393
+ [data-slot='button']:focus-visible {
394
+ outline: var(--ds-ring-width) solid var(--ds-button-primary-hover);
395
+ outline-offset: var(--zf-focus-offset);
396
+ box-shadow: var(--ds-shadow-button-hover);
397
+ }
398
+ /* Secondary y outline: texto navy también en oscuro (secondary-foreground es otro tono) */
399
+ [data-slot='button'][data-variant='secondary']:not(:disabled) {
400
+ color: var(--primary);
401
+ }
402
+ [data-slot='button'][data-variant='secondary']:hover:not(:disabled),
403
+ [data-slot='button'][data-variant='outline']:hover:not(:disabled),
404
+ [data-slot='button'][data-variant='ghost']:hover:not(:disabled) {
405
+ background: var(--zf-fill-hover);
406
+ }
407
+ [data-slot='button'][data-variant='secondary']:active:not(:disabled),
408
+ [data-slot='button'][data-variant='outline']:active:not(:disabled),
409
+ [data-slot='button'][data-variant='ghost']:active:not(:disabled) {
410
+ background: var(--zf-fill-press);
411
+ }
412
+
413
+ /* Tarjetas: blancas sobre neutral-bg, sin borde, sombra elevation-test */
414
+ [data-slot='card'],
415
+ [data-slot='panel'][data-variant='default'],
416
+ [data-slot='stat'][data-variant='card'] {
417
+ border-color: transparent;
418
+ }
419
+ /* Checkbox y radio (familia «choice»): borde de 2px neutral-black; marcado, navy */
420
+ [data-slot='checkbox'],
421
+ [data-slot='radio-group-item'] {
422
+ border-width: var(--zf-border-thick);
423
+ border-color: var(--input);
424
+ }
425
+
426
+ /* Tags: píldora de 32px, Roboto Regular 12, sin borde; la secundaria es info */
427
+ [data-slot='badge'][data-variant='secondary'] {
428
+ background: var(--info-soft);
429
+ color: var(--foreground);
430
+ }
431
+
432
+ /* Tablas: cabecera en Roboto Bold, sin mayúsculas; separadores grey */
433
+ [data-slot='table-head'] {
434
+ font-weight: var(--ds-label-weight);
435
+ letter-spacing: var(--ds-label-tracking);
436
+ color: var(--foreground);
437
+ }
438
+
439
+ /* Sidebar (item-menu): fila activa neutral-bg, Roboto Bold */
440
+ [data-sidebar='menu-button'] {
441
+ font-weight: var(--ds-nav-active-weight);
442
+ }
443
+ [data-sidebar='menu-button']:hover:not([data-active='true']) {
444
+ background: var(--zf-fill-hover);
445
+ }
446
+
447
+ /* Pestañas y toggles (button-tab-rounded / tab-box-rounded):
448
+ contenedor y pestaña en píldora; la activa, rellena de navy con texto blanco */
449
+ [data-slot='tabs-trigger'],
450
+ [data-slot='toggle'],
451
+ [data-slot='toggle-group-item'] {
452
+ border-radius: var(--ds-radius-tab);
453
+ color: var(--primary);
454
+ }
455
+ [data-slot='tabs-trigger'][data-active],
456
+ [data-slot='tabs-trigger'][data-state='active'],
457
+ [data-slot='toggle'][aria-pressed='true'],
458
+ [data-slot='toggle-group-item'][aria-pressed='true'] {
459
+ background: var(--primary);
460
+ color: var(--primary-foreground);
461
+ font-weight: var(--ds-key-weight);
462
+ box-shadow: var(--ds-shadow-control);
463
+ }
464
+ }
@@ -0,0 +1,39 @@
1
+ {
2
+ "name": "fractalia",
3
+ "light": {
4
+ "palette": [
5
+ "#0349fe",
6
+ "#242b5a",
7
+ "#007922",
8
+ "#c25400",
9
+ "#d60000"
10
+ ],
11
+ "foreground": "#34383f",
12
+ "muted": "#666a73",
13
+ "border": "#e3e8f3",
14
+ "surface": "#ffffff",
15
+ "surfaceForeground": "#34383f",
16
+ "fontSans": "'Roboto', system-ui, -apple-system, 'Segoe UI', sans-serif",
17
+ "fontDisplay": "'Montserrat', system-ui, sans-serif",
18
+ "motionBaseMs": 200,
19
+ "motionSlowMs": 300
20
+ },
21
+ "dark": {
22
+ "palette": [
23
+ "#7497fb",
24
+ "#c6d2f5",
25
+ "#51ca6f",
26
+ "#ffb313",
27
+ "#ff7a7a"
28
+ ],
29
+ "foreground": "#e4e9f6",
30
+ "muted": "#9aa3bc",
31
+ "border": "#2c3157",
32
+ "surface": "#1e2246",
33
+ "surfaceForeground": "#e4e9f6",
34
+ "fontSans": "'Roboto', system-ui, -apple-system, 'Segoe UI', sans-serif",
35
+ "fontDisplay": "'Montserrat', system-ui, sans-serif",
36
+ "motionBaseMs": 200,
37
+ "motionSlowMs": 300
38
+ }
39
+ }
@@ -35,7 +35,7 @@ function AccordionTrigger({
35
35
  {
36
36
  "data-slot": "accordion-trigger",
37
37
  className: cn(
38
- "group/accordion-trigger relative flex flex-1 items-start justify-between gap-6 border border-transparent p-4 text-left text-sm font-medium transition-all duration-(--ds-motion-snap) outline-none hover:underline aria-disabled:pointer-events-none aria-disabled:opacity-(--ds-disabled-opacity) **:data-[slot=accordion-trigger-icon]:ml-auto **:data-[slot=accordion-trigger-icon]:size-4 **:data-[slot=accordion-trigger-icon]:text-muted-foreground",
38
+ "group/accordion-trigger relative flex flex-1 items-start justify-between gap-6 border border-transparent p-4 text-left text-sm font-(--ds-medium-weight) transition-all duration-(--ds-motion-snap) outline-none hover:underline aria-disabled:pointer-events-none aria-disabled:opacity-(--ds-disabled-opacity) **:data-[slot=accordion-trigger-icon]:ml-auto **:data-[slot=accordion-trigger-icon]:size-4 **:data-[slot=accordion-trigger-icon]:text-muted-foreground",
39
39
  className
40
40
  ),
41
41
  ...props,
@@ -93,7 +93,7 @@ function AttachmentTitle({
93
93
  {
94
94
  "data-slot": "attachment-title",
95
95
  className: cn(
96
- "block max-w-full min-w-0 truncate font-medium group-data-[state=processing]/attachment:shimmer group-data-[state=uploading]/attachment:shimmer",
96
+ "block max-w-full min-w-0 truncate font-(--ds-medium-weight) group-data-[state=processing]/attachment:shimmer group-data-[state=uploading]/attachment:shimmer",
97
97
  className
98
98
  ),
99
99
  ...props
package/dist/ui/badge.js CHANGED
@@ -3,7 +3,7 @@ import { useRender } from "@base-ui/react/use-render";
3
3
  import { cva } from "class-variance-authority";
4
4
  import { cn } from "../lib/utils";
5
5
  const badgeVariants = cva(
6
- "group/badge inline-flex w-fit shrink-0 items-center justify-center gap-1 overflow-hidden rounded-badge border border-transparent px-(--ds-badge-px) py-(--ds-badge-py) text-xs font-(--ds-label-weight) whitespace-nowrap transition-all duration-(--ds-motion-snap) focus-visible:border-ring focus-visible:ring-(length:--ds-ring-width) focus-visible:ring-(--ds-ring-color) has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 aria-invalid:border-(--ds-invalid-border) aria-invalid:ring-(--ds-invalid-ring) [&>svg]:pointer-events-none [&>svg]:size-3!",
6
+ "group/badge inline-flex w-fit shrink-0 items-center justify-center gap-1 overflow-hidden rounded-badge border border-transparent px-(--ds-badge-px) py-(--ds-badge-py) text-xs font-(--ds-badge-weight) whitespace-nowrap transition-all duration-(--ds-motion-snap) focus-visible:border-ring focus-visible:ring-(length:--ds-ring-width) focus-visible:ring-(--ds-ring-color) has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 aria-invalid:border-(--ds-invalid-border) aria-invalid:ring-(--ds-invalid-ring) [&>svg]:pointer-events-none [&>svg]:size-3!",
7
7
  {
8
8
  variants: {
9
9
  variant: {
package/dist/ui/banner.js CHANGED
@@ -41,7 +41,7 @@ function BannerContent({ className, ...props }) {
41
41
  {
42
42
  "data-slot": "banner-content",
43
43
  className: cn(
44
- "flex min-w-0 flex-1 flex-wrap items-baseline gap-x-2 gap-y-1 [&_a]:font-medium [&_a]:underline [&_a]:underline-offset-3",
44
+ "flex min-w-0 flex-1 flex-wrap items-baseline gap-x-2 gap-y-1 [&_a]:font-(--ds-medium-weight) [&_a]:underline [&_a]:underline-offset-3",
45
45
  className
46
46
  ),
47
47
  ...props
@@ -53,7 +53,7 @@ function BannerTitle({ className, ...props }) {
53
53
  "strong",
54
54
  {
55
55
  "data-slot": "banner-title",
56
- className: cn("font-semibold", className),
56
+ className: cn("font-(--ds-strong-weight)", className),
57
57
  ...props
58
58
  }
59
59
  );
@@ -44,7 +44,7 @@ function ButtonGroupText({
44
44
  props: mergeProps(
45
45
  {
46
46
  className: cn(
47
- "flex items-center gap-2 rounded-button border bg-muted px-2.5 text-sm font-medium [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4",
47
+ "flex items-center gap-2 rounded-button border bg-muted px-2.5 text-sm font-(--ds-medium-weight) [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4",
48
48
  className
49
49
  )
50
50
  },
package/dist/ui/button.js CHANGED
@@ -3,16 +3,16 @@ import { useRender } from "@base-ui/react/use-render";
3
3
  import { cva } from "class-variance-authority";
4
4
  import { cn } from "../lib/utils";
5
5
  const buttonVariants = cva(
6
- "group/button inline-flex shrink-0 items-center justify-center rounded-button border border-transparent bg-clip-padding text-sm font-(--ds-button-weight) whitespace-nowrap transition-all duration-(--ds-motion-snap) outline-none select-none focus-visible:border-ring focus-visible:ring-(length:--ds-ring-width) focus-visible:ring-(--ds-ring-color) active:not-aria-[haspopup]:translate-y-px disabled:pointer-events-none disabled:opacity-(--ds-disabled-opacity) aria-invalid:border-(--ds-invalid-border) aria-invalid:ring-(length:--ds-ring-width) aria-invalid:ring-(--ds-invalid-ring) [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
6
+ "group/button inline-flex shrink-0 items-center justify-center rounded-button border border-transparent bg-clip-padding text-sm font-(--ds-button-weight) whitespace-nowrap transition-all duration-(--ds-motion-snap) outline-none select-none focus-visible:border-ring focus-visible:ring-(length:--ds-ring-width) focus-visible:ring-(--ds-ring-color) active:not-aria-[haspopup]:translate-y-px disabled:pointer-events-none disabled:opacity-(--ds-button-disabled-opacity) aria-invalid:border-(--ds-invalid-border) aria-invalid:ring-(length:--ds-ring-width) aria-invalid:ring-(--ds-invalid-ring) [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
7
7
  {
8
8
  variants: {
9
9
  variant: {
10
- default: "bg-primary text-primary-foreground hover:bg-primary/80",
11
- outline: "border-border bg-(--ds-field-bg) hover:bg-(--ds-field-bg-hover) hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground",
12
- secondary: "bg-secondary text-secondary-foreground hover:bg-[color-mix(in_oklch,var(--secondary),var(--foreground)_5%)] aria-expanded:bg-secondary aria-expanded:text-secondary-foreground",
13
- ghost: "hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:hover:bg-muted/50",
14
- destructive: "bg-destructive/10 text-destructive hover:bg-destructive/20 focus-visible:border-destructive/40 focus-visible:ring-destructive/20 dark:bg-destructive/20 dark:hover:bg-destructive/30 dark:focus-visible:ring-destructive/40",
15
- link: "text-primary underline-offset-4 hover:underline"
10
+ default: "bg-primary text-primary-foreground hover:bg-(--ds-button-primary-hover) hover:text-(--ds-button-primary-hover-fg) disabled:bg-[color:var(--ds-button-disabled-bg,var(--primary))] disabled:text-[color:var(--ds-button-disabled-fg,var(--primary-foreground))]",
11
+ outline: "border-(--ds-button-outline-border) bg-(--ds-button-outline-bg) text-(--ds-button-outline-fg) hover:bg-(--ds-field-bg-hover) hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground disabled:bg-[color:var(--ds-button-disabled-bg,var(--ds-button-outline-bg))] disabled:text-[color:var(--ds-button-disabled-fg,var(--ds-button-outline-fg))] disabled:border-[color:var(--ds-button-disabled-border,var(--ds-button-outline-border))]",
12
+ secondary: "border-(--ds-button-secondary-border) bg-secondary text-secondary-foreground hover:bg-[color-mix(in_oklch,var(--secondary),var(--foreground)_5%)] aria-expanded:bg-secondary aria-expanded:text-secondary-foreground disabled:bg-[color:var(--ds-button-disabled-bg,var(--secondary))] disabled:text-[color:var(--ds-button-disabled-fg,var(--secondary-foreground))] disabled:border-[color:var(--ds-button-disabled-border,var(--ds-button-secondary-border))]",
13
+ ghost: "hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:hover:bg-muted/50 disabled:bg-[color:var(--ds-button-disabled-bg,transparent)] disabled:text-[color:var(--ds-button-disabled-fg,currentColor)]",
14
+ destructive: "bg-destructive/10 text-destructive hover:bg-destructive/20 focus-visible:border-destructive/40 focus-visible:ring-destructive/20 dark:bg-destructive/20 dark:hover:bg-destructive/30 dark:focus-visible:ring-destructive/40 disabled:bg-[color:var(--ds-button-disabled-bg,color-mix(in_oklab,var(--destructive)_10%,transparent))] disabled:text-[color:var(--ds-button-disabled-fg,var(--destructive))] dark:disabled:bg-[color:var(--ds-button-disabled-bg,color-mix(in_oklab,var(--destructive)_20%,transparent))]",
15
+ link: "text-primary underline-offset-4 hover:underline disabled:bg-[color:var(--ds-button-disabled-bg,transparent)] disabled:text-[color:var(--ds-button-disabled-fg,var(--primary))]"
16
16
  },
17
17
  size: {
18
18
  default: "h-(--ds-control-h-md) gap-1.5 px-(--ds-button-px-md) has-data-[icon=inline-end]:pr-2.5 has-data-[icon=inline-start]:pl-2.5",
@@ -65,7 +65,7 @@ function Calendar({
65
65
  defaultClassNames.month_caption
66
66
  ),
67
67
  dropdowns: cn(
68
- "flex h-(--cell-size) w-full items-center justify-center gap-1.5 text-sm font-medium",
68
+ "flex h-(--cell-size) w-full items-center justify-center gap-1.5 text-sm font-(--ds-medium-weight)",
69
69
  defaultClassNames.dropdowns
70
70
  ),
71
71
  dropdown_root: cn(
@@ -77,7 +77,7 @@ function Calendar({
77
77
  defaultClassNames.dropdown
78
78
  ),
79
79
  caption_label: cn(
80
- "font-medium select-none",
80
+ "font-(--ds-medium-weight) select-none",
81
81
  captionLayout === "label" ? "text-sm" : "flex items-center gap-1 rounded-(--cell-radius) text-sm [&>svg]:size-3.5 [&>svg]:text-muted-foreground",
82
82
  defaultClassNames.caption_label
83
83
  ),
package/dist/ui/chart.js CHANGED
@@ -96,12 +96,12 @@ function ChartTooltipContent({
96
96
  const itemConfig = getPayloadConfigFromPayload(config, item, key);
97
97
  const value = !labelKey && typeof label === "string" ? config[label]?.label ?? label : itemConfig?.label;
98
98
  if (labelFormatter) {
99
- return /* @__PURE__ */ jsx("div", { className: cn("font-medium", labelClassName), children: labelFormatter(value, payload) });
99
+ return /* @__PURE__ */ jsx("div", { className: cn("font-(--ds-medium-weight)", labelClassName), children: labelFormatter(value, payload) });
100
100
  }
101
101
  if (!value) {
102
102
  return null;
103
103
  }
104
- return /* @__PURE__ */ jsx("div", { className: cn("font-medium", labelClassName), children: value });
104
+ return /* @__PURE__ */ jsx("div", { className: cn("font-(--ds-medium-weight)", labelClassName), children: value });
105
105
  }, [
106
106
  label,
107
107
  labelFormatter,
@@ -168,7 +168,7 @@ function ChartTooltipContent({
168
168
  nestLabel ? tooltipLabel : null,
169
169
  /* @__PURE__ */ jsx("span", { className: "text-muted-foreground", children: itemConfig?.label ?? item.name })
170
170
  ] }),
171
- item.value != null && /* @__PURE__ */ jsx("span", { className: "font-mono font-medium text-foreground tabular-nums", children: typeof item.value === "number" ? item.value.toLocaleString() : String(item.value) })
171
+ item.value != null && /* @__PURE__ */ jsx("span", { className: "font-mono font-(--ds-medium-weight) text-foreground tabular-nums", children: typeof item.value === "number" ? item.value.toLocaleString() : String(item.value) })
172
172
  ]
173
173
  }
174
174
  )
@@ -226,7 +226,7 @@ function ComboboxChip({
226
226
  {
227
227
  "data-slot": "combobox-chip",
228
228
  className: cn(
229
- "flex h-(--ds-chip-h) w-fit items-center justify-center gap-1 rounded-control bg-muted-foreground/10 px-2 text-xs font-medium whitespace-nowrap text-foreground has-disabled:pointer-events-none has-disabled:cursor-not-allowed has-disabled:opacity-(--ds-disabled-opacity) has-data-[slot=combobox-chip-remove]:pr-0",
229
+ "flex h-(--ds-chip-h) w-fit items-center justify-center gap-1 rounded-control bg-muted-foreground/10 px-2 text-xs font-(--ds-medium-weight) whitespace-nowrap text-foreground has-disabled:pointer-events-none has-disabled:cursor-not-allowed has-disabled:opacity-(--ds-disabled-opacity) has-data-[slot=combobox-chip-remove]:pr-0",
230
230
  className
231
231
  ),
232
232
  ...props,
@@ -115,7 +115,7 @@ function CommandGroup({
115
115
  {
116
116
  "data-slot": "command-group",
117
117
  className: cn(
118
- "overflow-hidden p-(--ds-menu-p) text-foreground **:[[cmdk-group-heading]]:px-(--ds-menu-item-px) **:[[cmdk-group-heading]]:py-(--ds-menu-item-py) **:[[cmdk-group-heading]]:text-xs **:[[cmdk-group-heading]]:font-medium **:[[cmdk-group-heading]]:text-muted-foreground",
118
+ "overflow-hidden p-(--ds-menu-p) text-foreground **:[[cmdk-group-heading]]:px-(--ds-menu-item-px) **:[[cmdk-group-heading]]:py-(--ds-menu-item-py) **:[[cmdk-group-heading]]:text-xs **:[[cmdk-group-heading]]:font-(--ds-medium-weight) **:[[cmdk-group-heading]]:text-muted-foreground",
119
119
  className
120
120
  ),
121
121
  ...props