Clarify morfo translation contract

active-uix
dev 5 months ago
parent 475ac77505
commit 35958a4902

@ -41,6 +41,8 @@ Actualizacion 2026-05-14:
- `src/arts/prefs/README.md` reescrito al modelo actual schema-based. Se - `src/arts/prefs/README.md` reescrito al modelo actual schema-based. Se
elimina la arquitectura historica de capabilities como guia principal y se elimina la arquitectura historica de capabilities como guia principal y se
marca `themeDimension`/`densityDimension` como legacy/custom fuera de UIX. marca `themeDimension`/`densityDimension` como legacy/custom fuera de UIX.
- `src/uix/morfo/README.md` actualizado: fija `translations`, `commonRef`,
registro via `registerMorfo` y `soma.runtime(...)` como contrato vigente.
- Commits nuevos empujados: - Commits nuevos empujados:
- `694eb5c5` — `Clarify prefs projection contract` - `694eb5c5` — `Clarify prefs projection contract`
- `223cdf9e` — `Align sema docs with channel ownership` - `223cdf9e` — `Align sema docs with channel ownership`
@ -54,6 +56,8 @@ Actualizacion 2026-05-14:
- `8ad04714` — `Refresh UIX architecture docs` - `8ad04714` — `Refresh UIX architecture docs`
- `e2ba371b` — `Add UIX architecture regression guards` - `e2ba371b` — `Add UIX architecture regression guards`
- `71e05765` — `Align langs diagnostic wording` - `71e05765` — `Align langs diagnostic wording`
- `607dfdbb` — `Clarify direct UIX service contracts`
- `475ac775` — `Refresh prefs architecture docs`
- Validado de nuevo: - Validado de nuevo:
- `npx vitest run src/uix/contracts.test.ts src/arts/prefs/test/dom-projection.test.ts src/uix/active-uix/active-uix.svelte.test.ts src/uix/eidos/active-eidos.test.ts src/uix/soma/runtime.svelte.test.ts` -> 79 tests OK. - `npx vitest run src/uix/contracts.test.ts src/arts/prefs/test/dom-projection.test.ts src/uix/active-uix/active-uix.svelte.test.ts src/uix/eidos/active-eidos.test.ts src/uix/soma/runtime.svelte.test.ts` -> 79 tests OK.
- `npx vitest run src/uix/sema/engine.test.ts src/uix/soma/runtime.svelte.test.ts` -> 48 tests OK. - `npx vitest run src/uix/sema/engine.test.ts src/uix/soma/runtime.svelte.test.ts` -> 48 tests OK.

@ -6,21 +6,22 @@ Morfo is the single source of truth for a component's parts, data-attrs, ARIA co
**One file per component**, at `src/uix/morfo/components/{kebab}.ts`. No prose — that's the component's README. No props — those live in `types.ts` with JSDoc. Component-owned translations may live in `translations` when they are part of ARIA labels, live-region text, or internal functional labels. Everything else is the machine-readable contract. **One file per component**, at `src/uix/morfo/components/{kebab}.ts`. No prose — that's the component's README. No props — those live in `types.ts` with JSDoc. Component-owned translations may live in `translations` when they are part of ARIA labels, live-region text, or internal functional labels. Everything else is the machine-readable contract.
## Handoff 2026-05-13 ## Handoff 2026-05-14
Morfo debe seguir siendo declarativo: no instancia servicios y no conoce Morfo debe seguir siendo declarativo: no instancia servicios y no conoce
`ActiveUix`. La frontera pendiente es fijar que campos de morfo son contrato `ActiveUix`. Sus campos solo entran en el contrato cuando son superficie
cross-layer real y cuales pertenecen a cada capa. cross-layer real; si un dato pertenece a una sola capa, vive en esa capa.
Puntos a cerrar antes de seguir: Decisiones cerradas:
- `translations` solo para traducciones owned por el componente; - `translations` solo contiene texto owned por el componente.
- textos comunes por referencia al catalogo comun, no duplicados en cada - Textos comunes usan `v.commonRef(...)` o un idlangref absoluto; no se
morfo; duplican en cada morfo.
- registro de traducciones durante el registro del morfo o en un paso previo - `registerMorfo(morfo)` registra el contrato `data-*` y publica
claramente definido; `morfo.translations` en los `ActiveLangs` conectados.
- si Sema/Eidos necesitan un dato compartido, debe pasar por morfo o por un - Si Soma, Sema y Eidos necesitan un dato compartido, pasa por morfo o por un
contrato publico, no por imports laterales entre capas. contrato publico; no por imports laterales entre capas.
- La regla 2-de-3 sigue vigente para extender morfo.
--- ---
@ -619,7 +620,7 @@ const attrs = createAttrs(dialogMorfo);
``` ```
Runtime-based providers call `createSomaRuntime(morfo, sources)` or Runtime-based providers call `createSomaRuntime(morfo, sources)` or
`uix.runtime(morfo, sources)`. That path calls `registerMorfo(morfo)` for `soma.runtime(morfo, sources)`. That path calls `registerMorfo(morfo)` for
you, which compiles the morfo, registers the data contract, and publishes you, which compiles the morfo, registers the data contract, and publishes
`morfo.translations` to any connected `ActiveLangs`. `morfo.translations` to any connected `ActiveLangs`.

Loading…
Cancel
Save

Powered by TurnKey Linux.