From f0919f24a558ed1c7e45b1b966db11a16c903e7b Mon Sep 17 00:00:00 2001 From: Chili Palmer Date: Sat, 30 May 2026 14:21:28 +0200 Subject: [PATCH] B1-4: distill Style as its own :style singleton tab in editor_settings spec --- SPECGAPS.md | 4 ++-- specs/editor_settings.allium | 17 ++++++++++++++--- 2 files changed, 16 insertions(+), 5 deletions(-) diff --git a/SPECGAPS.md b/SPECGAPS.md index 1b10758..c99c7a5 100644 --- a/SPECGAPS.md +++ b/SPECGAPS.md @@ -63,7 +63,7 @@ Gap categories: **SC** = spec correct, fix code | **CS** = code correct, update | ~~B1-1~~ | ~~Chat inline surfaces (9 types: card, chart, form, list, metric, mindmap, table, tabs, text/json)~~ | `tool_surfaces.ex` | **Resolved:** added InlineSurface value type with all 9 discriminators, supporting value types (SurfaceAction, ChartSeries, MindmapNode, FormField, FieldOption, TabPanel), inline_surfaces on ChatMessage, InlineSurfaceRendering guarantee, and surface_form_debounce_ms config to editor_chat.allium; updated StructuredRenderTools invariant in ai.allium to list all 9 types | | ~~B1-2~~ | ~~Auto-translation system (AutoTranslation.maybe_schedule, media cascade, batch fill)~~ | `lib/bds/posts/auto_translation.ex` | **Resolved:** distilled into translation.allium — added `AutoTranslationControlSurface` (PostSavedForAutoTranslation reactive + FillMissingTranslationsRequested batch triggers), three rules (`ScheduleAutoTranslation` draft-per-missing-language + media cascade, `AutoTranslatePost` upsert/auto-publish primitive, `AutoTranslateMediaCascade` linked-media per-language tasks, `FillMissingTranslations` published-only batch emitting `ProgressReported` + `FillMissingTranslationsCompleted`), three invariants (`AutoTranslationGatedByEndpoint`, `AutoTranslationSkipsDoNotTranslate`, `AutoTranslationOnlyMissingLanguages`), and `auto_translation_task_group_name` config; `allium check` passes | | ~~B1-3~~ | ~~3 extra settings sections (Technology, MCP, Data Maintenance)~~ | `lib/bds/desktop/shell_live/settings_editor/` | **Resolved:** distilled into editor_settings.allium — added `SettingsTechnologySection` (semantic_similarity toggle + read-only scripting-runtime note, saved with project metadata), `SettingsDataSection` (rebuild_targets), and `technology_section`/`data_section` on `SettingsView`; reconciled `SettingsMCPSection`/`MCPAgentRow` to code (dropped non-existent status badge; added `is_supported`/`config_path`; only Claude Code + GitHub Copilot supported); updated TechnologySection/MCPSection/DataMaintenanceSection guarantees (7 rebuild buttons incl. Rebuild Embedding Index) and SettingsRebuild rule entity_type (+embedding); `allium check` passes | -| B1-4 | Style/Theme as separate tab (`:style`), not settings section | `lib/bds/ui/style_editor.ex` | Distill into spec | +| ~~B1-4~~ | ~~Style/Theme as separate tab (`:style`), not settings section~~ | `lib/bds/desktop/shell_live/settings_editor/style_editor.ex` | **Resolved:** editor_settings.allium Style view section now frames it as its own `style` singleton tab (cross-ref tabs.allium), explicitly NOT a SettingsView collapsible section; added `SeparateTab` guarantee (requires active project), documented 20 named Pico themes and the theme display-name transform ("-"→" ", capitalise); `allium check` passes | | B1-5 | `published_*` snapshot fields on Post for diffing | `lib/bds/posts/post.ex:61-65` | Add to post.allium entity | | B1-6 | Full rendering subsystem (Liquex, Filters, Labels, LinksAndLanguages, PostRendering) | `lib/bds/rendering/` | Distill into spec | | B1-7 | 404.html generation | `lib/bds/generation/outputs.ex:344-345` | Add to generation.allium | @@ -193,7 +193,7 @@ All reconciled to follow code. Specs must be self-consistent and match code. 1c. ~~**A1-17**~~ — blogmark deep-link handler resolved: `BDS.Desktop.DeepLink` receives OS `bds2://` URL events and `BDS.Blogmark` parses them, runs the transform pipeline, and creates+opens a draft post (macOS `Info.plist` scheme registration documented, pending an app-bundle pipeline) 2. **D1-1 through D1-18** — untested invariants/guarantees 3. **C-1 through C-3** — internal spec inconsistencies (reconcile to code) -4. **B1-1 through B1-6** — major code behaviors missing from spec (B1-1, B1-2, B1-3 resolved) +4. **B1-1 through B1-6** — major code behaviors missing from spec (B1-1, B1-2, B1-3, B1-4 resolved) 5. **A2-1 through A2-17** — spec drift (code is normative, update spec) 6. **D2-1 through D2-17** — untested rules 7. **D3-1 through D3-11** — partial test coverage diff --git a/specs/editor_settings.allium b/specs/editor_settings.allium index c025ac9..0dddd18 100644 --- a/specs/editor_settings.allium +++ b/specs/editor_settings.allium @@ -235,10 +235,16 @@ rule SettingsRebuild { -- ─── Style view ─────────────────────────────────────────────── +-- The Style view is its OWN singleton tab (tab type `style`, see tabs.allium), +-- NOT one of the SettingsView collapsible sections. It is opened from the +-- Style menu/tab entry and renders the Pico CSS theme editor, distinct from +-- the `settings` tab. Shares the settings_editor code group only because both +-- persist into project metadata. + value StyleView { - themes: List - selected_theme: String? - applied_theme: String? + themes: List -- 20 named Pico themes (see metadata.supported_pico_themes) + selected_theme: String? -- local selection, defaults to applied_theme + applied_theme: String? -- persisted picoTheme (default when none set) preview_mode: String -- auto | light | dark } @@ -268,9 +274,14 @@ surface StyleViewSurface { when style.selected_theme != style.applied_theme StylePreviewModeChanged(mode) + @guarantee SeparateTab + -- Rendered in its own `style` singleton tab (tabs.allium), never inline + -- in the settings view. Requires an active project; no project => no view. + @guarantee ThemePicker -- Grid of theme buttons (one per Pico CSS theme). -- Each button: swatch with 3 colour tones (accent, light bg, dark bg) + theme name. + -- Theme name shown via display transform: "-" -> " ", first letter capitalised. -- Selected theme highlighted with aria-pressed. @guarantee ControlsRow