orbital-ds 0.10.1 → 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 (69) hide show
  1. package/AGENTS.md +32 -4
  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/i18n.d.ts +17 -0
  7. package/dist/lib/i18n.js +54 -3
  8. package/dist/styles.css +111 -0
  9. package/dist/themes/fractalia.css +464 -0
  10. package/dist/themes/fractalia.fonts.css +3 -0
  11. package/dist/themes/fractalia.guide.md +77 -0
  12. package/dist/themes/fractalia.meta.json +96 -0
  13. package/dist/themes/fractalia.scoped.css +464 -0
  14. package/dist/themes/fractalia.tokens.json +39 -0
  15. package/dist/ui/accordion.js +1 -1
  16. package/dist/ui/attachment.js +1 -1
  17. package/dist/ui/badge.js +1 -1
  18. package/dist/ui/banner.js +2 -2
  19. package/dist/ui/button-group.js +1 -1
  20. package/dist/ui/button.js +7 -7
  21. package/dist/ui/calendar.js +2 -2
  22. package/dist/ui/chart.js +3 -3
  23. package/dist/ui/combobox.js +1 -1
  24. package/dist/ui/command.js +1 -1
  25. package/dist/ui/empty.js +1 -1
  26. package/dist/ui/field.js +2 -2
  27. package/dist/ui/gauge.d.ts +40 -0
  28. package/dist/ui/gauge.js +157 -0
  29. package/dist/ui/heatmap-grid.js +1 -1
  30. package/dist/ui/input-group.js +1 -1
  31. package/dist/ui/input.js +1 -1
  32. package/dist/ui/item.js +1 -1
  33. package/dist/ui/kbd.js +1 -1
  34. package/dist/ui/label.js +1 -1
  35. package/dist/ui/legend.d.ts +3 -1
  36. package/dist/ui/legend.js +15 -1
  37. package/dist/ui/level-meter.d.ts +16 -0
  38. package/dist/ui/level-meter.js +60 -0
  39. package/dist/ui/menubar.js +1 -1
  40. package/dist/ui/message.js +2 -2
  41. package/dist/ui/navigation-menu.js +1 -1
  42. package/dist/ui/password-strength.d.ts +14 -0
  43. package/dist/ui/password-strength.js +61 -0
  44. package/dist/ui/progress.js +1 -1
  45. package/dist/ui/proportion-bar.js +2 -2
  46. package/dist/ui/questionnaire.js +2 -2
  47. package/dist/ui/shield.d.ts +21 -0
  48. package/dist/ui/shield.js +141 -0
  49. package/dist/ui/sidebar.js +1 -1
  50. package/dist/ui/status-badge.d.ts +3 -2
  51. package/dist/ui/status-badge.js +4 -2
  52. package/dist/ui/status-hero.d.ts +12 -0
  53. package/dist/ui/status-hero.js +60 -0
  54. package/dist/ui/step-dots.d.ts +10 -0
  55. package/dist/ui/step-dots.js +40 -0
  56. package/dist/ui/step-ring.d.ts +12 -0
  57. package/dist/ui/step-ring.js +35 -0
  58. package/dist/ui/table.js +1 -1
  59. package/dist/ui/tabs.js +1 -1
  60. package/dist/ui/task-loader.d.ts +14 -0
  61. package/dist/ui/task-loader.js +50 -0
  62. package/dist/ui/task-progress.d.ts +18 -0
  63. package/dist/ui/task-progress.js +84 -0
  64. package/dist/ui/toggle.js +1 -1
  65. package/docs/adr/0002-sistemas-corporativos-al-modelo.md +176 -0
  66. package/package.json +1 -1
  67. package/scripts/brand-core.mjs +5 -3
  68. package/scripts/doctor.mjs +61 -3
  69. package/scripts/init.mjs +182 -26
package/contract.json CHANGED
@@ -148,6 +148,43 @@
148
148
  ]
149
149
  }
150
150
  },
151
+ "slotTokens": {
152
+ "descripcion": "Huecos públicos de una pieza: si la PERSONALIDAD de un tema pinta esa propiedad de esa pieza, debe hacerlo rellenando el hueco (en sus VARIABLES), no con una regla que lo rodee. Hoy aviso en todos (transición: ADR 0002, F1b); pasará a error en los temas «strict».",
153
+ "slots": {
154
+ "button": {
155
+ "border-radius": "--ds-radius-button"
156
+ },
157
+ "badge": {
158
+ "border-radius": "--ds-radius-badge"
159
+ },
160
+ "tabs-trigger": {
161
+ "border-radius": "--ds-radius-tab"
162
+ },
163
+ "tabs-list": {
164
+ "border-radius": "--ds-radius-tabs-list"
165
+ },
166
+ "input": {
167
+ "background": "--ds-field-bg",
168
+ "background-color": "--ds-field-bg"
169
+ },
170
+ "textarea": {
171
+ "background": "--ds-field-bg",
172
+ "background-color": "--ds-field-bg"
173
+ },
174
+ "select-trigger": {
175
+ "background": "--ds-field-bg",
176
+ "background-color": "--ds-field-bg"
177
+ },
178
+ "native-select": {
179
+ "background": "--ds-field-bg",
180
+ "background-color": "--ds-field-bg"
181
+ },
182
+ "input-group": {
183
+ "background": "--ds-field-bg",
184
+ "background-color": "--ds-field-bg"
185
+ }
186
+ }
187
+ },
151
188
  "brand": {
152
189
  "descripcion": "Grupo ESTABLE de variables que una app suele personalizar en su fichero de marca (brand.css). Renombrar o quitar una es versión MAYOR. Todas están también en `root` salvo las --ds-*.",
153
190
  "tokens": [
@@ -83,6 +83,23 @@ declare const DsMessagesContext: React.Context<{
83
83
  statusMeaning: string;
84
84
  statusCause: string;
85
85
  statusAction: string;
86
+ shieldLabel: string;
87
+ strengthLabel: string;
88
+ strengthWeak: string;
89
+ strengthMedium: string;
90
+ strengthStrong: string;
91
+ stepOf: string;
92
+ stepRingLabel: string;
93
+ progressNotStarted: string;
94
+ progressRunning: string;
95
+ progressDone: string;
96
+ progressError: string;
97
+ progressCounter: string;
98
+ toneSuccess: string;
99
+ toneWarning: string;
100
+ toneDanger: string;
101
+ toneInfo: string;
102
+ toneNeutral: string;
86
103
  }>;
87
104
  /** Textos de los componentes en el idioma activo. */
88
105
  declare function useDsMessages(): DsMessages;
@@ -82,6 +82,23 @@ declare const en: {
82
82
  statusMeaning: string;
83
83
  statusCause: string;
84
84
  statusAction: string;
85
+ shieldLabel: string;
86
+ strengthLabel: string;
87
+ strengthWeak: string;
88
+ strengthMedium: string;
89
+ strengthStrong: string;
90
+ stepOf: string;
91
+ stepRingLabel: string;
92
+ progressNotStarted: string;
93
+ progressRunning: string;
94
+ progressDone: string;
95
+ progressError: string;
96
+ progressCounter: string;
97
+ toneSuccess: string;
98
+ toneWarning: string;
99
+ toneDanger: string;
100
+ toneInfo: string;
101
+ toneNeutral: string;
85
102
  };
86
103
  type DsMessages = typeof en;
87
104
  type DsMessageKey = keyof DsMessages;
package/dist/lib/i18n.js CHANGED
@@ -80,7 +80,24 @@ const en = {
80
80
  notificationUnread: "Unread",
81
81
  statusMeaning: "What it means",
82
82
  statusCause: "Why",
83
- statusAction: "What to do"
83
+ statusAction: "What to do",
84
+ shieldLabel: "Protection level: {value}",
85
+ strengthLabel: "Strength:",
86
+ strengthWeak: "Weak",
87
+ strengthMedium: "Medium",
88
+ strengthStrong: "Strong",
89
+ stepOf: "Step {n} of {total}",
90
+ stepRingLabel: "{completed} of {total} steps completed",
91
+ progressNotStarted: "Not started",
92
+ progressRunning: "In progress",
93
+ progressDone: "Completed",
94
+ progressError: "Failed",
95
+ progressCounter: "{n} of {total}",
96
+ toneSuccess: "Correct",
97
+ toneWarning: "Warning",
98
+ toneDanger: "Error",
99
+ toneInfo: "Information",
100
+ toneNeutral: "Neutral"
84
101
  };
85
102
  const es = {
86
103
  close: "Cerrar",
@@ -162,7 +179,24 @@ const es = {
162
179
  notificationUnread: "Sin leer",
163
180
  statusMeaning: "Qu\xE9 significa",
164
181
  statusCause: "Por qu\xE9",
165
- statusAction: "Qu\xE9 hacer"
182
+ statusAction: "Qu\xE9 hacer",
183
+ shieldLabel: "Nivel de protecci\xF3n: {value}",
184
+ strengthLabel: "Nivel de fuerza:",
185
+ strengthWeak: "Baja",
186
+ strengthMedium: "Media",
187
+ strengthStrong: "Alta",
188
+ stepOf: "Paso {n} de {total}",
189
+ stepRingLabel: "{completed} de {total} pasos completados",
190
+ progressNotStarted: "No iniciado",
191
+ progressRunning: "En proceso",
192
+ progressDone: "Completado",
193
+ progressError: "Con errores",
194
+ progressCounter: "{n} de {total}",
195
+ toneSuccess: "Correcto",
196
+ toneWarning: "Alerta",
197
+ toneDanger: "Error",
198
+ toneInfo: "Informaci\xF3n",
199
+ toneNeutral: "Neutro"
166
200
  };
167
201
  const ptBR = {
168
202
  close: "Fechar",
@@ -244,7 +278,24 @@ const ptBR = {
244
278
  notificationUnread: "N\xE3o lida",
245
279
  statusMeaning: "O que significa",
246
280
  statusCause: "Por qu\xEA",
247
- statusAction: "O que fazer"
281
+ statusAction: "O que fazer",
282
+ shieldLabel: "N\xEDvel de prote\xE7\xE3o: {value}",
283
+ strengthLabel: "N\xEDvel de for\xE7a:",
284
+ strengthWeak: "Fraca",
285
+ strengthMedium: "M\xE9dia",
286
+ strengthStrong: "Forte",
287
+ stepOf: "Etapa {n} de {total}",
288
+ stepRingLabel: "{completed} de {total} etapas conclu\xEDdas",
289
+ progressNotStarted: "N\xE3o iniciado",
290
+ progressRunning: "Em andamento",
291
+ progressDone: "Conclu\xEDdo",
292
+ progressError: "Com erros",
293
+ progressCounter: "{n} de {total}",
294
+ toneSuccess: "Correto",
295
+ toneWarning: "Alerta",
296
+ toneDanger: "Erro",
297
+ toneInfo: "Informa\xE7\xE3o",
298
+ toneNeutral: "Neutro"
248
299
  };
249
300
  const dsCatalogs = { en, es, "pt-BR": ptBR };
250
301
  function resolveDsLocale(tag) {
package/dist/styles.css CHANGED
@@ -105,6 +105,7 @@
105
105
  --radius-code: var(--ds-radius-code);
106
106
  --radius-tooltip: var(--ds-radius-tooltip);
107
107
  --radius-tab: var(--ds-radius-tab);
108
+ --radius-tabs-list: var(--ds-radius-tabs-list);
108
109
  --radius-field-multiline: var(--ds-radius-field-multiline);
109
110
  --radius-inset: var(--ds-radius-inset);
110
111
  --radius-skeleton: var(--ds-radius-skeleton);
@@ -133,6 +134,7 @@
133
134
  --ds-radius-xs: 2px; /* marcas de leyenda y flecha del tooltip */
134
135
  --ds-radius-tooltip: var(--ds-radius-2xl);
135
136
  --ds-radius-tab: var(--ds-radius-xl);
137
+ --ds-radius-tabs-list: var(--ds-radius-control); /* contenedor de las pestañas */
136
138
  --ds-radius-field-multiline: var(--ds-radius-md); /* textarea y campos de varias líneas */
137
139
  --ds-radius-inset: var(--ds-radius-xl); /* contenido junto al lateral «inset» */
138
140
  --ds-radius-skeleton: var(--ds-radius-xl);
@@ -191,6 +193,7 @@
191
193
 
192
194
  /* Curvas de aceleración: un tema cambia aquí su «personalidad de movimiento». */
193
195
  --ds-ease-standard: cubic-bezier(0.22, 1, 0.36, 1); /* entrar y moverse */
196
+ --ds-ease-pulse: var(--ds-ease-standard); /* latidos en bucle (radar, carga indeterminada) */
194
197
  --ds-ease-emphasized: cubic-bezier(0.32, 0.72, 0, 1); /* paneles que llegan desde el borde */
195
198
  --ds-ease-enter: cubic-bezier(0.23, 1, 0.32, 1); /* aparecer */
196
199
  --ds-ease-exit: cubic-bezier(0.7, 0, 0.84, 0); /* desaparecer */
@@ -254,6 +257,7 @@
254
257
  --ds-title-leading: 1.25;
255
258
  --ds-label-tracking: 0.05em;
256
259
  --ds-strong-weight: 600;
260
+ --ds-medium-weight: 500; /* texto «medio» de los componentes (antes font-medium a mano) */
257
261
  --ds-nav-weight: 500;
258
262
  --ds-nav-active-weight: 500;
259
263
  --ds-tab-weight: 500;
@@ -271,6 +275,18 @@
271
275
  --ds-button-case: none;
272
276
  --ds-button-tracking: normal;
273
277
  --ds-button-outline-w: 1px;
278
+ /* Colores por variante del botón (0.11.0): por defecto, el aspecto de siempre */
279
+ --ds-button-primary-hover: color-mix(in oklab, var(--primary) 80%, transparent); /* fondo del primario al pasar */
280
+ --ds-button-primary-hover-fg: var(--primary-foreground);
281
+ --ds-button-outline-bg: var(--ds-field-bg); /* botón outline */
282
+ --ds-button-outline-fg: currentColor;
283
+ --ds-button-outline-border: var(--border);
284
+ --ds-button-secondary-border: transparent; /* borde del botón secundario */
285
+ --ds-badge-weight: var(--ds-label-weight); /* peso de la insignia */
286
+ --ds-button-disabled-opacity: var(--ds-disabled-opacity); /* botón desactivado: 1 si el tema lo pinta con color */
287
+ /* Desactivado CON COLOR (opcional): sin definir, cada variante conserva su color y se atenúa con la
288
+ * opacidad. Un tema que lo quiera define las tres y pone --ds-button-disabled-opacity: 1.
289
+ * --ds-button-disabled-bg · --ds-button-disabled-fg · --ds-button-disabled-border */
274
290
  --ds-shadow-button: 0 0 #0000;
275
291
  --ds-shadow-button-hover: 0 0 #0000;
276
292
  --ds-hover-lift: 0px;
@@ -437,6 +453,61 @@
437
453
  --ds-banner-px: 1rem; /* aviso de página (Banner) */
438
454
  --ds-banner-py: 0.625rem;
439
455
  --ds-tabs-gap: 0.25rem; /* separación entre pestañas cuando el tema las separa */
456
+ /* Piezas de estado y progreso (0.11.0): medidas y efectos propios, ajustables por tema y app */
457
+ --ds-track-bg: var(--muted); /* pista de barras, anillos y segmentos sin rellenar */
458
+ --ds-status-dot-sm: var(--ds-status-dot); /* StatusDot suelto: size="sm" (sin size, el punto en línea) */
459
+ --ds-status-dot-md: 0.75rem; /* size="md" */
460
+ --ds-status-dot-lg: 1rem; /* size="lg" */
461
+ --ds-gauge-size: 8.75rem; /* Gauge: lado del anillo (el arco ocupa la mitad de alto) */
462
+ --ds-gauge-stroke: 10px; /* grosor del trazo, en unidades del dibujo */
463
+ --ds-gauge-value-size: 2rem; /* cifra central */
464
+ --ds-gauge-suffix-size: 1.125rem; /* «/1.000» */
465
+ --ds-shield-w: 7.75rem; /* Shield md */
466
+ --ds-shield-h: 9.375rem;
467
+ --ds-shield-w-sm: 5.3125rem; /* Shield sm */
468
+ --ds-shield-h-sm: 6.4375rem;
469
+ --ds-shield-stroke: 10px; /* contorno del escudo */
470
+ --ds-shield-track: var(--border); /* contorno sin rellenar */
471
+ --ds-shield-fill: var(--card); /* interior */
472
+ --ds-shield-progress: var(--primary); /* contorno relleno */
473
+ --ds-shield-filter: drop-shadow(0 0 #0000); /* sombra del escudo (sin sombra por defecto) */
474
+ --ds-shield-value-size: 1.5rem;
475
+ --ds-shield-value-weight: var(--ds-heading-weight);
476
+ --ds-shield-badge: 2.5rem; /* insignia (estrella, icono) */
477
+ --ds-shield-radar-size: 15rem; /* ShieldRadar: marco */
478
+ --ds-shield-radar-circle: 11.375rem; /* círculo interior */
479
+ --ds-shield-radar-glow: 12px; /* brillo interior del círculo */
480
+ --ds-strength-segment-w: 1.5rem; /* PasswordStrength */
481
+ --ds-strength-segment-h: 0.3125rem;
482
+ --ds-strength-gap: 2px;
483
+ --ds-strength-radius: var(--ds-radius-track);
484
+ --ds-step-dot: 0.75rem; /* StepDots */
485
+ --ds-step-dot-active-w: 2rem;
486
+ --ds-step-dot-gap: 0.75rem;
487
+ --ds-step-dot-bg: var(--ds-track-bg); /* punto inactivo */
488
+ --ds-step-ring-size: 1.5rem; /* StepRing: círculo de sectores */
489
+ --ds-task-progress-h: var(--ds-track-h); /* TaskProgress */
490
+ --ds-level-value-size: 1.125rem; /* LevelMeter: porcentaje */
491
+ --ds-level-range-size: 1.625rem; /* LevelMeter: rango */
492
+ --ds-status-hero: 5.5rem; /* StatusHero: disco */
493
+ --ds-status-hero-p: 0.75rem;
494
+ --ds-status-hero-radius: var(--ds-radius-2xl);
495
+ --ds-status-hero-badge: 1.75rem;
496
+ --ds-status-halo-blur: 10px; /* halo alrededor del disco */
497
+ --ds-status-halo-inset: 3px; /* halo por dentro del disco */
498
+ --ds-status-halo-success: color-mix(in oklch, var(--success) 40%, transparent);
499
+ --ds-status-halo-warning: color-mix(in oklch, var(--warning) 40%, transparent);
500
+ --ds-status-halo-danger: color-mix(in oklch, var(--danger) 40%, transparent);
501
+ --ds-status-halo-info: color-mix(in oklch, var(--info) 40%, transparent);
502
+ --ds-status-halo-neutral: color-mix(in oklch, var(--neutral) 30%, transparent);
503
+ --ds-loader-size: 5.5rem; /* TaskLoader */
504
+ --ds-loader-p: 0.75rem;
505
+ --ds-loader-radius: var(--ds-radius-2xl);
506
+ --ds-loader-icon: 4rem;
507
+ --ds-loader-bar-h: 2px;
508
+ --ds-loader-bg: var(--muted);
509
+ --ds-loader-done-bg: var(--card);
510
+ --ds-loader-done-glow: 0 0 #0000; /* brillo al terminar (sin sombra por defecto) */
440
511
 
441
512
  /* ── MATERIALES ─────────────────────────────────────────────────────────
442
513
  * Cómo es la superficie, más allá del color. Cada valor es un
@@ -622,6 +693,46 @@
622
693
  height: var(--accordion-panel-height, auto);
623
694
  }
624
695
  }
696
+ /* Latido del radar (ShieldRadar) e indeterminado (TaskLoader): ritmo y curva del tema; quietos con
697
+ * movimiento reducido (motion-reduce:animate-none en cada pieza). */
698
+ @utility animate-ds-ring-inner {
699
+ animation: ds-ring-inner var(--ds-motion-pulse) var(--ds-ease-pulse) infinite alternate both;
700
+ }
701
+ @utility animate-ds-ring-outer {
702
+ animation: ds-ring-outer var(--ds-motion-pulse) var(--ds-ease-pulse) infinite alternate both;
703
+ }
704
+ @utility animate-ds-indeterminate {
705
+ animation: ds-indeterminate var(--ds-motion-pulse) var(--ds-ease-pulse) infinite;
706
+ }
707
+ @keyframes ds-ring-inner {
708
+ from {
709
+ transform: scale(0.813);
710
+ opacity: 0.5;
711
+ }
712
+ to {
713
+ transform: scale(1);
714
+ opacity: 0.3;
715
+ }
716
+ }
717
+ @keyframes ds-ring-outer {
718
+ from {
719
+ transform: scale(0.892);
720
+ opacity: 0.3;
721
+ }
722
+ to {
723
+ transform: scale(1);
724
+ opacity: 0.5;
725
+ }
726
+ }
727
+ @keyframes ds-indeterminate {
728
+ /* --ds-dir: 1 en LTR, -1 en RTL (lo pone la pista): recorre la pista desde el inicio */
729
+ from {
730
+ transform: translateX(calc(-100% * var(--ds-dir, 1)));
731
+ }
732
+ to {
733
+ transform: translateX(calc(250% * var(--ds-dir, 1)));
734
+ }
735
+ }
625
736
  @keyframes ds-accordion-close {
626
737
  from {
627
738
  height: var(--accordion-panel-height, auto);