Skip to content

feat(themes): Apariencia › Temas, sidebar and dock selectors, faithful preview - #315

Merged
egdev6 merged 4 commits into
feat/saved-themesfrom
feat/saved-themes-ui
Nov 23, 2026
Merged

egdev6 merged 4 commits into
feat/saved-themesfrom
feat/saved-themes-ui

Conversation

@egdev6

@egdev6 egdev6 commented Nov 22, 2026

Copy link
Copy Markdown
Owner

Refs #313 · Phase 2 of saved themes → integration branch feat/saved-themes. Implements the chosen artboard design/saved-themes/03-detalle-con-vista-previa.html.

  • Apariencia › Temas: list (n/10), select to preview without activating, large preview rendered by the real overlay/goal/chat renderers with the selected theme's own look (read-only /api/themes/:id/preview), Activar / Duplicar / Renombrar / Borrar (disabled on the active theme with its reason), «Nuevo tema» from a theme or from «Color de cada plataforma», edit-active notice and switch feedback.
  • Sidebar footer active-theme selector with a quick switcher; dock header «Tema activo» + «Tema» tab (narrow and wide). Stream Deck /sd/tema/<id>. Live sync across surfaces.
  • Presets reduced to «Color de cada plataforma», the default look of new installs and of themes from default; existing installs keep their previous default look (migration).
  • Draft fence: theme-owned panel writes carry X-Antena-Theme; a mismatch → 409 «El tema activo cambió mientras editabas; tus cambios no se guardaron» with nothing written (mixed custom-overlay + themed writes atomic); stale drafts stay visible, Guardar blocked, Descartar clears; global writes and API/MCP writes without the header unchanged.

Verification (independent, Risk 1+3): every in-scope item met; existing v0/v1/v2 installs keep /theme.css and samples byte-identical; preview read-only with no leaks; fence covers themed writes only; differential vs feat/saved-themes identical except the preset list/defaults. New tests: saved-themes-ui, saved-themes-browser, theme-fence-preview, saved-themes-default-look (+ adjusted existing browser tests). Local: unit, browser, platform groups and typecheck green.

Not in this phase: data-tema marker + per-overlay CSS (phase 3), theme export/import (phase 4).

…l preview

Implements the chosen artboard design/saved-themes/03-detalle-con-vista-previa:
- Apariencia gets a «Temas» tab: saved themes (n/10), select to preview
  without activating, a large preview rendered by the real overlay, goal and
  chat renderers with the selected theme's own look (read-only projection),
  and Activar / Duplicar / Renombrar / Borrar (disabled on the active theme).
  «Nuevo tema» duplicates a theme or starts from «Color de cada plataforma».
- The panel sidebar footer shows the active theme with a quick switcher;
  the dock shows it in its header and adds a «Tema» tab (narrow and wide).
- Stream Deck action to activate a theme; all surfaces follow a switch live.
- Presets are reduced to «Color de cada plataforma», now the look of new
  installs and of themes created from the default; migrated installs keep
  their previous default look.
- Theme-owned panel writes carry the theme they were edited against: if the
  active theme changed meanwhile the server answers 409 and writes nothing
  (mixed overlay + themed writes are atomic); stale drafts stay visible,
  cannot be saved and can be discarded. API/MCP writes without the header
  keep writing the active theme.

Refs #313
Dark grid stage with a dashed safe area and compact height so the goal and
chat previews and the action row fit at 1440x900; each theme's dot shows its
accent or the multicolour platform dot; the selected theme shows «Vista
previa seleccionada».

Refs #313
Each saved theme can carry an avatar (theme metadata, outside the copied
look): an uploaded image cropped to a circle and/or a colour drawn as its
ring; without one, the theme's dot shows inside the same ring. It is set in
«Nuevo tema» and in «Editar» (formerly «Renombrar») and shown in every theme
list: Apariencia (list, detail header, «Nuevo tema» origins), the sidebar
switcher and the dock header and «Tema» tab. MCP renombrar_tema accepts
optional color and imagen.

Images must be PNG, JPG, WebP or GIF regular files in the media folder (SVG
and symlinks are refused); removing an avatar or deleting a theme never
deletes media. Duplicating a theme does not copy its avatar; activation
keeps both themes' avatars.

Refs #313
.d-btn, declared later with the same specificity, forced a column layout on
the theme choices; the artboard shows avatar, name and action in one row.

Refs #313
@egdev6
egdev6 merged commit d41b2c7 into feat/saved-themes Nov 23, 2026
5 checks passed
@egdev6
egdev6 deleted the feat/saved-themes-ui branch November 23, 2026 00:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant