@synthex-engineers/refined-tech 0.0.0-stage → 1.0.1

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 (45) hide show
  1. package/README.md +187 -2
  2. package/dist/angular/index.cjs +1476 -0
  3. package/dist/angular/index.cjs.map +1 -0
  4. package/dist/angular/index.d.cts +237 -0
  5. package/dist/angular/index.d.ts +237 -0
  6. package/dist/angular/index.js +1463 -0
  7. package/dist/angular/index.js.map +1 -0
  8. package/dist/astro/components/ButtonOutline.astro +36 -0
  9. package/dist/astro/components/ButtonPrimary.astro +36 -0
  10. package/dist/astro/components/ButtonSecondary.astro +36 -0
  11. package/dist/astro/components/ClientTrustCard.astro +79 -0
  12. package/dist/astro/components/HelpTooltip.astro +119 -0
  13. package/dist/astro/components/LanguageSelectorPill.astro +35 -0
  14. package/dist/astro/components/ProcessStepCard.astro +68 -0
  15. package/dist/astro/components/SolutionBentoCard.astro +90 -0
  16. package/dist/astro/components/WavyUnderlineHeading.astro +90 -0
  17. package/dist/astro/index.d.ts +9 -0
  18. package/dist/astro/index.js +9 -0
  19. package/dist/chunk-EUXUH3YW.js +14 -0
  20. package/dist/chunk-EUXUH3YW.js.map +1 -0
  21. package/dist/chunk-PAHBEY3T.js +73 -0
  22. package/dist/chunk-PAHBEY3T.js.map +1 -0
  23. package/dist/index.cjs +910 -0
  24. package/dist/index.cjs.map +1 -0
  25. package/dist/index.d.cts +82 -0
  26. package/dist/index.d.ts +82 -0
  27. package/dist/index.js +833 -0
  28. package/dist/index.js.map +1 -0
  29. package/dist/react/index.cjs +1171 -0
  30. package/dist/react/index.cjs.map +1 -0
  31. package/dist/react/index.d.cts +239 -0
  32. package/dist/react/index.d.ts +239 -0
  33. package/dist/react/index.js +1138 -0
  34. package/dist/react/index.js.map +1 -0
  35. package/dist/registry/components.json +791 -0
  36. package/dist/tokens/index.cjs +85 -0
  37. package/dist/tokens/index.cjs.map +1 -0
  38. package/dist/tokens/index.d.cts +133 -0
  39. package/dist/tokens/index.d.ts +133 -0
  40. package/dist/tokens/index.js +4 -0
  41. package/dist/tokens/index.js.map +1 -0
  42. package/dist/tokens/refined-tech.css +73 -0
  43. package/dist/tokens/tailwind-preset.d.ts +46 -0
  44. package/dist/tokens/tailwind-preset.js +74 -0
  45. package/package.json +100 -4
package/README.md CHANGED
@@ -1,3 +1,188 @@
1
- # Temporary Holding Version
1
+ # @synthex/refined-tech
2
2
 
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
3
+ Librería canónica oficial de diseño, tokens y componentes UI multi-framework (Angular 19+, React 19+, HTML/Tailwind) con catálogo interactivo y sincronización automática para el ecosistema **Synthex**.
4
+
5
+ ---
6
+
7
+ ## 1. Instalación y Consumo en Proyectos
8
+
9
+ Gracias a la configuración de **npm workspaces** en la raíz del monorepo (`synthex/package.json`), el paquete está enlazado simbólicamente de forma automática en todos los proyectos (`brand/landing`, `synthex-gym-erp/web`, `synthex-ledger/web`).
10
+
11
+ Para añadirlo explícitamente en el `package.json` de cualquier proyecto del monorepo:
12
+
13
+ ```json
14
+ {
15
+ "dependencies": {
16
+ "@synthex/refined-tech": "file:../../brand/synthex-refined-tech"
17
+ }
18
+ }
19
+ ```
20
+
21
+ Al utilizar enlaces simbólicos nativos (`symlink`), **cualquier cambio realizado en los componentes o tokens de Synthex Refined Tech se actualiza automáticamente en tus proyectos en tiempo real**, sin necesidad de compilaciones manuales intermedias ni publicaciones a npm.
22
+
23
+ ---
24
+
25
+ ## 2. Puntos de Entrada y Uso
26
+
27
+ ### A. Componentes Angular 19+ (Standalone)
28
+
29
+ ```typescript
30
+ import {
31
+ ButtonPrimaryComponent,
32
+ ButtonSecondaryComponent,
33
+ ButtonOutlineComponent,
34
+ CommandKTriggerComponent,
35
+ TimerWidgetComponent,
36
+ MetricCardComponent,
37
+ BentoCardComponent,
38
+ BadgeStatusComponent,
39
+ InputTextComponent,
40
+ ToggleSwitchComponent,
41
+ ManifestoIconBoxComponent,
42
+ WorkspaceSwitcherComponent,
43
+ TableLedgerRowComponent,
44
+ MagicLinkCardComponent,
45
+ PreloaderComponent,
46
+ FooterBounceComponent,
47
+ MagneticButtonComponent,
48
+ } from '@synthex/refined-tech/angular';
49
+
50
+ @Component({
51
+ imports: [ButtonPrimaryComponent, CommandKTriggerComponent],
52
+ template: `
53
+ <st-button-primary (onClick)="handleSubmit()">Confirmar Acción</st-button-primary>
54
+ <st-command-k-trigger (onOpen)="openCommandPalette()"></st-command-k-trigger>
55
+ `
56
+ })
57
+ export class MiComponente {}
58
+ ```
59
+
60
+ ### B. Componentes React 19+ (TypeScript)
61
+
62
+ ```tsx
63
+ import {
64
+ ButtonPrimary,
65
+ ButtonSecondary,
66
+ ButtonOutline,
67
+ CommandKTrigger,
68
+ TimerWidget,
69
+ MetricCard,
70
+ BentoGridCard,
71
+ BadgeStatus,
72
+ InputText,
73
+ ToggleSwitch,
74
+ ManifestoIconBox,
75
+ WorkspaceSwitcher,
76
+ TableLedgerRow,
77
+ MagicLinkCard,
78
+ Preloader,
79
+ FooterBounce,
80
+ MagneticButton,
81
+ } from '@synthex/refined-tech/react';
82
+
83
+ export function MiPanel() {
84
+ return (
85
+ <div className="flex gap-4">
86
+ <ButtonPrimary onClick={() => console.log('Confirmado')}>
87
+ Confirmar Acción
88
+ </ButtonPrimary>
89
+ <CommandKTrigger onOpen={() => console.log('Paleta')} />
90
+ </div>
91
+ );
92
+ }
93
+ ```
94
+
95
+ ### C. Tokens Canónicos de Diseño
96
+
97
+ ```typescript
98
+ import { colors, fonts, radii, shadows, borders, tokens } from '@synthex/refined-tech/tokens';
99
+
100
+ console.log(colors.pistachio); // #E0F9B5
101
+ console.log(colors.charcoal); // #111111
102
+ console.log(colors.slateSurface); // #1E1E1E
103
+ console.log(fonts.display); // 'Outfit', ...
104
+ ```
105
+
106
+ ### D. Tokens CSS (:root)
107
+
108
+ ```css
109
+ @import '@synthex/refined-tech/css';
110
+ ```
111
+
112
+ ### E. Preset Oficial de Tailwind CSS
113
+
114
+ En tu archivo `tailwind.config.mjs`:
115
+
116
+ ```javascript
117
+ import refinedTechPreset from '@synthex/refined-tech/tailwind-preset';
118
+
119
+ export default {
120
+ presets: [refinedTechPreset],
121
+ content: ['./src/**/*.{html,ts,tsx,astro}'],
122
+ // ...
123
+ };
124
+ ```
125
+
126
+ ---
127
+
128
+ ## 3. Motor de Sincronización Automática
129
+
130
+ El script `scripts/sync-components.js` gestiona la arquitectura *"1 Componente = 1 ID Canónico + 1 Carpeta por Tecnología"*:
131
+
132
+ 1. **Inspección Dinámica:** Escanea recursivamente `src/components/library/`.
133
+ 2. **Generación de Barriles:** Regenera de forma atómica:
134
+ - `src/components/library/angular/index.ts`
135
+ - `src/components/library/react/index.ts`
136
+ 3. **Registro Maestro:** Actualiza `registry/components.json` y los archivos `meta.json` de cada componente.
137
+ 4. **Ganchos Automáticos (Hooks):**
138
+ - Se ejecuta automáticamente antes de `npm run dev`, `npm run build` y `npm test` (`predev`, `prebuild`, `pretest`).
139
+ - El modo `npm run dev` incorpora un vigilante de archivos (`fs.watch`) para resincronizar en caliente cualquier componente que crees o modifiques al instante.
140
+
141
+ ---
142
+
143
+ ## 4. Comandos de Flujo de Trabajo
144
+
145
+ - **Iniciar servidor de desarrollo y catálogo interactivo:**
146
+ ```bash
147
+ npm run dev
148
+ ```
149
+ - **Sincronizar manualmente componentes y barriles:**
150
+ ```bash
151
+ npm run sync
152
+ ```
153
+ - **Ejecutar suite completa de tests TDD (Vitest):**
154
+ ```bash
155
+ npm test
156
+ ```
157
+ - **Comprobar tipado estricto Astro / TypeScript:**
158
+ ```bash
159
+ npm run check
160
+ ```
161
+ - **Compilar para producción:**
162
+ ```bash
163
+ npm run build
164
+ ```
165
+
166
+ ---
167
+
168
+ ## 5. Catálogo de los 17 Componentes Canónicos
169
+
170
+ | ID Canónico | Slug | Nombre | Angular | React | HTML | Animación |
171
+ | :--- | :--- | :--- | :---: | :---: | :---: | :---: |
172
+ | `SRT-BTN-01` | `button-primary` | Botón Primario Pistacho | ✓ | ✓ | ✓ | — |
173
+ | `SRT-BTN-02` | `button-secondary` | Botón Secundario Pizarra | ✓ | ✓ | ✓ | — |
174
+ | `SRT-BTN-03` | `button-outline` | Botón Contorno Técnico | ✓ | ✓ | ✓ | — |
175
+ | `SRT-TMR-01` | `timer-widget` | Widget de Cronómetro Monospace | ✓ | ✓ | ✓ | — |
176
+ | `SRT-CMD-01` | `command-k-trigger` | Disparador Command K | ✓ | ✓ | ✓ | — |
177
+ | `SRT-CRD-01` | `metric-card` | Tarjeta Métrica Bento | ✓ | ✓ | ✓ | — |
178
+ | `SRT-CRD-02` | `bento-grid-card` | Tarjeta Bento de Ingeniería | ✓ | ✓ | ✓ | — |
179
+ | `SRT-BDG-01` | `badge-status` | Badge de Estado Técnico | ✓ | ✓ | ✓ | — |
180
+ | `SRT-INP-01` | `input-text` | Campo de Entrada Micro-Borde | ✓ | ✓ | ✓ | — |
181
+ | `SRT-TGL-01` | `toggle-switch` | Interruptor Toggle Booleano | ✓ | ✓ | ✓ | — |
182
+ | `SRT-ICN-01` | `manifesto-icon-box` | Caja Isotipo Squircle | ✓ | ✓ | ✓ | — |
183
+ | `SRT-SWT-01` | `workspace-switcher` | Selector de Workspace Multi-Empresa | ✓ | ✓ | ✓ | — |
184
+ | `SRT-TBL-01` | `table-ledger-row` | Fila de Ledger Criptográfico | ✓ | ✓ | ✓ | — |
185
+ | `SRT-MLC-01` | `magic-link-card` | Tarjeta Acceso Magic Link | ✓ | ✓ | ✓ | — |
186
+ | `SRT-GSAP-PRE01` | `gsap-preloader` | Preload Metamorfosis Geométrica | ✓ | ✓ | ✓ | GSAP MorphSVG |
187
+ | `SRT-GSAP-FBT01` | `gsap-footer-bounce` | Rebote Elástico de Footer | ✓ | ✓ | ✓ | GSAP Elastic Curve |
188
+ | `SRT-GSAP-MAG01` | `gsap-magnetic-button` | Botón con Atracción Magnética | ✓ | ✓ | ✓ | GSAP quickTo |