feat(tahuantinsuyu): rueda 3D, hover-highlight, universo, themes papel

Segunda tanda de UX a partir de feedback de uso real:

- Zoom/pan reasignados: wheel = zoom puro (sin modifier). LMB drag
  fuera del anillo de signos = pan; sobre el anillo = jog-dial
  (rectificación). MMB sigue como pan secundario. Tecla `0`
  resetea zoom + pan.

- Planetas legibles: el "dot rellenado" se reduce a 3 px (solo
  marca el grado exacto). Encima va `planet_glyph` con disco-halo
  del bg_panel y border del color del planeta — el glyph unicode
  astronómico (☉☽☿♀♂♃♄♅♆♇) ahora se lee contra cualquier fondo.

- Aspectos hover-highlight: al hovear un planeta, sus líneas se
  mantienen al 100 % y el resto cae a 18 %. Resuelve el "¿quién
  contra quién?" sin desordenar la rueda.

- Ascensionales: cruz completa ASC-DESC + MC-IC (4 radios) con
  α=0.55. Labels ASC/MC/DESC/IC como pills con bg-halo y border
  `angle_highlight`, font 11 — antes eran texto chico que se
  fundía con el dial.

- Universo: el wheel pierde su bg de cuadrado (que cortaba contra
  el panel). El root del canvas pinta un starfield sutil ~130
  puntos deterministas (xorshift32 con seed fija, sin parpadeo
  entre frames). Solo activo en themes dark — sobre fondos claros
  generaría ruido.

- Estilo 3D anillos: `stroke_circle_3d` (highlight +luma + base +
  shadow -luma) reemplaza al stroke plano en sign_outer, sign_inner
  y el outer ring. Más `paint_dial_bevel` con 10 strokes finos en
  bell curve entre sign_inner y sign_outer — simula gradient radial
  que gpui canvas no soporta nativo.

- Theme `Print Color`: papel crema, paleta astro con luminancia
  0.26-0.34 y saturación alta, sin glow ni gradients.

- Theme `Print B&W`: monocromático sobre blanco puro. Aspectos
  diferenciados por dash pattern en lugar de color:
  conjunction/opposition sólidos, square dash medio, trine dash
  largo, sextile dotted, minors dotted finísimo. `paint_segment`
  con `dash: Option<(on,off)>` para implementar dashes (gpui
  canvas no tiene stroke dash nativo).

Todos los tests siguen verdes (6 shell + 5 yahweh-theme +
2 tahuantinsuyu-theme).

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
sergio
2026-05-18 15:45:48 +00:00
parent e09207b152
commit 1078e433f2
3 changed files with 615 additions and 142 deletions
@@ -147,6 +147,8 @@ impl Theme {
Self::flat_dark(),
Self::solarized_light(),
Self::high_contrast(),
Self::print_color(),
Self::print_bw(),
]
}
@@ -369,6 +371,71 @@ impl Theme {
}
}
/// **Print Color** — preview de impresión a color sobre papel.
/// Fondo crema cálido (#f7f4ea-ish), texto y ornamentos en
/// luminancias bajas para que sobrevivan ink-bleed. Sin gradientes
/// (los gradients no imprimen bien) y sin glow.
pub fn print_color() -> Self {
let bg_app: Background = hsla(42.0 / 360.0, 0.30, 0.94, 1.0).into();
let bg_panel: Background = hsla(40.0 / 360.0, 0.25, 0.97, 1.0).into();
let bg_panel_alt: Background = hsla(40.0 / 360.0, 0.20, 0.92, 1.0).into();
Self {
name: "Print Color",
is_dark: false,
bg_app,
bg_panel,
bg_panel_alt,
bg_row_hover: hsla(40.0 / 360.0, 0.30, 0.86, 0.70),
bg_row_active: hsla(35.0 / 360.0, 0.45, 0.78, 0.85),
fg_text: hsla(30.0 / 360.0, 0.15, 0.18, 1.0),
fg_muted: hsla(30.0 / 360.0, 0.12, 0.40, 1.0),
fg_disabled: hsla(30.0 / 360.0, 0.08, 0.62, 1.0),
accent: hsla(15.0 / 360.0, 0.70, 0.40, 1.0),
accent_strong: hsla(355.0 / 360.0, 0.78, 0.36, 1.0),
border: hsla(40.0 / 360.0, 0.22, 0.82, 1.0),
border_strong: hsla(30.0 / 360.0, 0.30, 0.55, 1.0),
marker_palette: vec![
hsla(15.0 / 360.0, 0.70, 0.35, 0.30),
hsla(210.0 / 360.0, 0.65, 0.35, 0.30),
hsla(140.0 / 360.0, 0.55, 0.30, 0.30),
hsla(285.0 / 360.0, 0.55, 0.38, 0.30),
hsla(40.0 / 360.0, 0.85, 0.40, 0.30),
],
}
}
/// **Print B&W** — preview de impresión monocromática. Fondo
/// blanco puro, todo en escala de grises. Cualquier slot que
/// dependa de "color" en widgets astrológicos se diferencia por
/// forma o por dash pattern, no por tinte.
pub fn print_bw() -> Self {
let bg_app: Background = hsla(0.0, 0.0, 1.00, 1.0).into();
let bg_panel: Background = hsla(0.0, 0.0, 0.99, 1.0).into();
let bg_panel_alt: Background = hsla(0.0, 0.0, 0.95, 1.0).into();
Self {
name: "Print B&W",
is_dark: false,
bg_app,
bg_panel,
bg_panel_alt,
bg_row_hover: hsla(0.0, 0.0, 0.88, 0.85),
bg_row_active: hsla(0.0, 0.0, 0.78, 0.95),
fg_text: hsla(0.0, 0.0, 0.10, 1.0),
fg_muted: hsla(0.0, 0.0, 0.40, 1.0),
fg_disabled: hsla(0.0, 0.0, 0.65, 1.0),
accent: hsla(0.0, 0.0, 0.20, 1.0),
accent_strong: hsla(0.0, 0.0, 0.05, 1.0),
border: hsla(0.0, 0.0, 0.80, 1.0),
border_strong: hsla(0.0, 0.0, 0.40, 1.0),
marker_palette: vec![
hsla(0.0, 0.0, 0.30, 0.35),
hsla(0.0, 0.0, 0.50, 0.35),
hsla(0.0, 0.0, 0.20, 0.35),
hsla(0.0, 0.0, 0.60, 0.35),
],
}
}
/// **High Contrast** — accesibilidad. Negro puro con texto blanco y
/// ornamentos amarillo/verde fuertes. Suficientemente diferente para
/// notar inmediatamente al usar el switcher.