Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions wiki/concepts/menu-bar-popover.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

> **Kind:** concept
> **Sources:** Bubo/Composition/App/App.swift, Bubo/Presentation/Views/MenuBar/MenuBarView.swift, Bubo/Presentation/Views/MenuBar/MenuBarView+AutoDefer.swift, Bubo/Presentation/Views/MenuBar/MenuBarView+RollForward.swift, Bubo/Presentation/Views/MenuBar/MenuBarView+Pomodoro.swift, Bubo/Presentation/Views/MenuBar/MenuBarView+Timeline.swift, Bubo/Presentation/Views/MenuBar/MenuBarView+BacklogDrop.swift, Bubo/Presentation/Views/MenuBar/MenuBarView+Strings.swift, Bubo/Presentation/Views/MenuBar/MenuBarView+EventActions.swift, Bubo/Presentation/Views/MenuBar/MenuBarView+Permissions.swift, Bubo/Presentation/Views/MenuBar/MenuBarView+Focus.swift, Bubo/Presentation/Views/MenuBar/MenuBarView+NavigationRoutes.swift, Bubo/Presentation/Views/MenuBar/MenuBarView+MainContent.swift, Bubo/Presentation/Views/MenuBar/MenuBarView+Lifecycle.swift, Bubo/Presentation/Views/MenuBar/MenuBarView+EventRow.swift, Bubo/Presentation/Views/MenuBar/MenuBarView+DayGroup.swift, Bubo/Presentation/Views/Components/, Bubo/Application/Reminders/ReminderService.swift
> **Last ingest:** 2026-05-12 (PR #506)
> **Last ingest:** 2026-05-14 (PR #535)
> **Related:** [`../modules/app.md`](../modules/app.md), [`../modules/views.md`](../modules/views.md), [`../architecture/event-pipeline.md`](../architecture/event-pipeline.md)

## What
Expand All @@ -14,7 +14,7 @@ The menu-bar popover is Bubo's primary surface — one click on the owl icon ope
- `BuboApp` (`Bubo/Composition/App/App.swift:17`) declares a `MenuBarExtra` scene (`:315`) with a Core-Graphics owl glyph (`:44`) plus a density bar (calendar-load indicator).
- The scene's content is `MenuBarView` (`Bubo/Presentation/Views/MenuBar/MenuBarView.swift`).
- `MenuBarView` reads `ReminderService.upcomingEvents` and `BacklogService.tasks` directly via `@Observable`.
- Sub-views: `DaySectionView`, `EventRowView`, `GhostEventRow` (optimizer ghost previews), `FreeSlotRow`, `NowNextLine`, `SmartActionsBar`.
- Sub-views: `DaySectionView`, `EventRowView`, `GhostEventRow` (optimizer ghost previews), `FreeSlotRow`, `SmartActionsBar`. Status surface is the `inlineStatusRow` (`MenuBarView+MainContent.swift`) — a single `StatusBanner` showing the highest-priority issue (no internet / cached data / sync error); hidden when all systems are healthy.

## Density bar (J2)

Expand Down
6 changes: 6 additions & 0 deletions wiki/log.md
Original file line number Diff line number Diff line change
Expand Up @@ -882,3 +882,9 @@ Append-only chronological record of wiki operations. Newest at the bottom. See `
- **Trigger:** PR #528 (fe4136d95fa7)
- **Touched:** none
- **Notes:** PR #528's own commit (ef4f813) already updated all 13 wiki pages; automated routine verified all Sources: citations exist on disk, no stale Sources/BuboDomain/, Sources/BuboOptimizer/, or Tests/BuboTests/ directory references remain in non-log pages, and import-name accuracy preserved (SwiftPM target names BuboDomain/BuboOptimizer unchanged). Bubo/ trigger-path changes are comment-only; docs/refactor/ deleted files cited only in log.md. No further wiki edits required.

## [2026-05-14] ingest | PR #535 — Simplify UI by removing optimizer and end-of-day features

- **Trigger:** PR #535 (d3008bdb)
- **Touched:** wiki/modules/views.md, wiki/concepts/menu-bar-popover.md
- **Notes:** Biggest correction: removed stale entries for 11 deleted component files (EndOfDayBanner, EnergyCheckInBanner, RollForwardBanner, NowNextLine, PermissionBanners, BacklogScrollOffsetKey, and five others added in PR #531 that were never reflected in the wiki). Updated BacklogFullscreenView line count 952→765 (urgency-filter and optimizer-preset features removed). Corrected all fourteen MenuBarView extension line counts; updated +AutoDefer description (EOD banner removed), +Permissions (permissionBannerSpecs removed), +MainContent (inlineStatusRow added). Replaced multi-banner sub-view list in menu-bar-popover.md with single inlineStatusRow surface.
22 changes: 8 additions & 14 deletions wiki/modules/views.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

> **Kind:** module
> **Sources:** Bubo/Presentation/Views/
> **Last ingest:** 2026-05-12 (PR #506)
> **Last ingest:** 2026-05-14 (PR #535)
> **Related:** [`../concepts/menu-bar-popover.md`](../concepts/menu-bar-popover.md), [`../concepts/full-screen-alerts.md`](../concepts/full-screen-alerts.md), [`../concepts/design-principles.md`](../concepts/design-principles.md), [`skins.md`](skins.md)

## Layout
Expand All @@ -26,7 +26,7 @@ Presentation/Views/

| File | Type+line | Lines | Role |
|---|---|---:|---|
| `MenuBar/MenuBarView.swift` | `struct MenuBarView` (`:3`) | 222 | Popover root — composition only. `var body` is ~50 L: background + `navigationDestination()` + command palette + toast + keyboard shortcuts, plus the modifier chain. Fourteen logic/view clusters live in sibling extension files: prior nine (`+AutoDefer`, `+RollForward`, `+Pomodoro`, `+Timeline`, `+BacklogDrop`, `+Strings`, `+EventActions`, `+Permissions`, `+Focus`) plus five from the 2026-05-12 body decomposition (`+NavigationRoutes`, `+MainContent`, `+Lifecycle`, `+EventRow`, `+DayGroup`). Nested types extracted to file scope: `MenuBarNavigation`, `MenuBarPaletteContext`, `MenuBarDayListItem`, `MenuBarTimelineDay`. Permission banners + settings button live in `Presentation/Views/Components/`; preference keys in `Presentation/Views/MenuBar/MenuBarPreferenceKeys.swift` |
| `MenuBar/MenuBarView.swift` | `struct MenuBarView` (`:3`) | 211 | Popover root — composition only. `var body` is ~50 L: background + `navigationDestination()` + command palette + toast + keyboard shortcuts, plus the modifier chain. Fourteen logic/view clusters live in sibling extension files: prior nine (`+AutoDefer`, `+RollForward`, `+Pomodoro`, `+Timeline`, `+BacklogDrop`, `+Strings`, `+EventActions`, `+Permissions`, `+Focus`) plus five from the 2026-05-12 body decomposition (`+NavigationRoutes`, `+MainContent`, `+Lifecycle`, `+EventRow`, `+DayGroup`). Nested types extracted to file scope: `MenuBarNavigation`, `MenuBarPaletteContext`, `MenuBarDayListItem`, `MenuBarTimelineDay`. Settings button lives in `Presentation/Views/Components/`; preference keys in `Presentation/Views/MenuBar/MenuBarPreferenceKeys.swift` |
| `MenuBarNavigation.swift` | `enum MenuBarNavigation: Equatable` (`:9`) | 43 | 8-state navigation machine for the popover. Equality compares by event/task id |
| `MenuBarPaletteContext.swift` | `struct MenuBarPaletteContext: Equatable` (`:9`) | 21 | Seed-data carrier for the command palette overlay; nil on `MenuBarView.paletteContext` = hidden |
| `MenuBarDayListItem.swift` | `enum MenuBarDayListItem: Identifiable` (`:9`) | 30 | Row kind for the day list: event / free-slot / ghost / nowMarker |
Expand All @@ -39,8 +39,7 @@ Presentation/Views/
| `FullScreenAlert/FullScreenAlertView.swift` | `struct FullScreenAlertView` (`:3`) | 358 | Pre-meeting takeover. Live countdown, Join/Dismiss, optional next-event hint, snooze menu, skin-tinted overlay |
| `Event/JoinRibbonView.swift` | `struct JoinRibbonView` (`:16`) | 92 | Post-join ribbon. Live countdown to start, meeting name, Re-alert action. Auto-dismisses at `startDate` |
| `Timer/TimerScreenView.swift` | `struct TimerScreenView` (`:3`) | 694 | Pomodoro/event timer. Live countdown ring. **Scrub gesture** adjusts `endDate`. **Pause gesture** shifts start+end. Wallpaper support. Pinned state |
| `Backlog/BacklogFullscreenView.swift` | `struct BacklogFullscreenView` (`:36`) | 952 | Full-popover task list. Inline editing, drag-reorder, urgency filter, smart-sort, hotkeys 1–9 for completion, optimizer presets, schedule/deadline actions. Three logic clusters in sibling files: `+BulkActions`, `+Reorder`, `+Actions`. `BacklogScrollOffsetKey: PreferenceKey` lives in its own file |
| `BacklogScrollOffsetKey.swift` | `struct BacklogScrollOffsetKey: PreferenceKey` (`:14`) | 18 | Publishes the task list's scroll offset to its parent for sticky-collapse of the filter band |
| `Backlog/BacklogFullscreenView.swift` | `struct BacklogFullscreenView` (`:38`) | 765 | Full-popover task list. Inline editing, drag-reorder, smart-sort, hotkeys 1–9 for completion, schedule/deadline actions. Three logic clusters in sibling files: `+BulkActions`, `+Reorder`, `+Actions` |
| `CommandPalette/CommandPalette.swift` | `struct CommandPalette` (`:14`) | 784 | Smart suggestion palette. AI intent composition, event/task search, optimization presets, **dry-run preview**, "power mode" for advanced users. Three clusters in sibling files: `+PowerMode`, `+Status`, `+Actions`. Moved 2026-05-12 from `Views/Common/` to its own folder |
| `DesignSystem/DesignSystem.swift` + 6 siblings | `enum DS` (`:20`) | 530 + 722 | The 1228-line catalog was split across `DS+Layout` (Spacing, Density, Hero, Popover, Grid, SettingsWindow, EmptyState), `DS+Typography`, `DS+Sizes` (Component sizes, Border, Opacity), `DS+Visual` (Shadows, Elevation, Physics, Animation), `DS+Colors` (Semantic, Materials, EventColorTag, Urgency, Countdown), `DS+Formatting` (SnoozeOption, Ordinal, Time, Shared formatters). `DesignSystem.swift` itself now keeps only the `enum DS` namespace + the `Haptics` enum + the View / Text / EnvironmentValues extensions that depend on DS tokens. Call sites unchanged (`DS.Spacing.sm`, `DS.Colors.surfacePrimary`, …). |
| `BuboSkin.swift` (relocated) | `struct SkinBackgroundLayer` (`:5`) | 286 | Now at `Presentation/Views/Skins/BuboSkin.swift` — see [`skins.md`](skins.md) |
Expand All @@ -62,7 +61,7 @@ Presentation/Views/

## Components (`Presentation/Views/Components/`)

66 SwiftUI components across `Components/{Background,Backlog,Banner,Common,Event,Picker,Slot}/`. Grouped by role; line numbers cite the main type declaration.
78 Swift files across `Components/{Background,Backlog,Banner,Common,Event,Picker,Slot}/`. Grouped by role; line numbers cite the main type declaration.

### Layout (4)
- `FlowLayout` (`FlowLayout.swift:7`) — `struct FlowLayout: Layout`
Expand Down Expand Up @@ -102,13 +101,9 @@ Presentation/Views/
- `SmartActions` (`:30`) — chip row absorbing four legacy optimizer entry points; forecasts capacity + ranks actions
- `SmartActionsBar` (`:13`)

### Status / feedback (6)
- `StatusBannerView` — `StatusBanner` (`:3`), color-driven, used for network status
### Status / feedback (2)
- `StatusBannerView` — `StatusBanner` (`:3`), color-driven; consumed by `inlineStatusRow` in `MenuBarView+MainContent.swift` for network / cache / sync-error state
- `ToastView` — `ToastMessage` (`:4`), `ToastOverlay: View` (`:69`)
- `EndOfDayBanner` (`:17`) — quiet end-of-day prompt with one-tap carry-to-tomorrow
- `EnergyCheckInBanner` (`:9`) — one-tap rating (1–5), feeds the personal energy curve
- `RollForwardBanner` (`:13`) — end-of-workday nudge with unified undo
- `NowNextLine` (`:16`) — single-line status with current and next event + overdue chip

### Utility (9)
- `Chip` — `enum ChipVariant` (`:22`) defines visual roles (prominent / quiet / selected / unselected / status)
Expand All @@ -123,7 +118,6 @@ Presentation/Views/

Additional components extracted from `MenuBarView`:
- `OpenSettingsButton` (`Components/OpenSettingsButton.swift`) — gear button that closes the popover and opens the Settings window.
- `PermissionBannerSpec`, `PermissionBannerLabel`, `PermissionBannersCarousel`, `PermissionBannerPageDots` (`Components/PermissionBanners.swift`) — single-pill or paged-carousel permission banner under the popover header.
- `EventColorTag.color` SwiftUI mapping (`Components/EventColorTag+Color.swift`) — kept out of the domain model so `Domain/CalendarEvent.swift` doesn't need `import SwiftUI`.
- `LoadMoreDaysButton` (`Components/LoadMoreDaysButton.swift`) — quiet full-width footer below the timeline that fires the host's «extend horizon by one week» closure.

Expand All @@ -135,8 +129,8 @@ Top SwiftUI files by line count.

| File | Lines | Top-level structure (verified by `grep -n '^struct\|^private struct'`) |
|---|---:|---|
| `MenuBar/MenuBarView.swift` | 222 | State surface + ~50 L body (composition only). Body = `AppBackgroundLayer` → `Group { navigationDestination() }` → `commandPaletteOverlay()` → `ToastOverlay` → `keyboardShortcutsLayer()`, plus modifier chain calling out to `handleAppear` / `handleDisappear` / per-notification handlers. Fourteen sibling extensions: **prior nine** — `+AutoDefer` (162, midnight rollover + EOD banner), `+RollForward` (180, J-Recover + focus-slot fill + overdue reschedule), `+Pomodoro` (206, convertEventToPomodoro + clone-as-draft + ripple-shift + slot Pomodoro), `+Timeline` (163, `filteredEventsByDay`/`timelineEventsByDay`/`visibleEventCount`/`timelineDays`/`interleave`/`startOf`/`ghostForDay`), `+BacklogDrop` (230, `handleTaskDrop`+`scheduleBacklogTask`+`scheduleSlotPickerBatch`), `+Strings` (133, pure-compute strings), `+EventActions` (76, `resolveEdit`/`handleDelete`/`notifyScheduleChange`/`runQuickAction`), `+Permissions` (71, `permissionBannerSpecs`/`refreshPermissionSnapshots`/`showSyncingState`), `+Focus` (83, day-nav cluster state); **five from 2026-05-12 body decomposition** — `+NavigationRoutes` (406, one `@ViewBuilder` per `MenuBarNavigation` case + `navigationDestination()` dispatcher), `+MainContent` (446, `mainContent`/`eventList`/`syncingState`/`parallaxOffset`/`nowMarkerRow`/`nowMarkerLabel`/`dayNavCluster`), `+Lifecycle` (239, `commandPaletteOverlay`/`keyboardShortcutsLayer`/`handleAppear`/`handleDisappear` + per-notification handlers), `+EventRow` (205, `eventRow(_:)` with 15+ row callbacks), `+DayGroup` (190, `dayGroupHeader`/`dayGroupSection`/`freeSlotRow`/`collapsedEventsHeader`). State surface (~30 `@State` fields), notable: `navigation: MenuBarNavigation`, `dayRolloverTimer`, `everyMinuteTimer` (only thing still `private` — only used in body), `initialSyncTimeoutFired` + `initialSyncDataArrived`, `extraDaysShown` capped at `extraDaysCap = 84`. The 2026-05-12 split also relaxed `paletteContext`, `listScrollY`, `showingQuickCapture`, `dismissedBannerIds`, `optimizerBottomY`, `initialSyncTimeoutFired`, `openSettings`, `reduceMotion`, `skin`, `activeSkin`, `extraDaysCap` from `private` to internal for cross-file access. |
| `Backlog/BacklogFullscreenView.swift` | 952 | Body + computed properties + subview helpers + filter chrome. Three logic clusters split out 2026-05-12: `+BulkActions.swift` (131, multi-select schedule/defer/freeze/delete + tombstone undo), `+Reorder.swift` (132, up/down/edge moves + drag-reorder drop), `+Actions.swift` (147, per-task CRUD + inline-add). All `@State`/`@FocusState`/`@Environment` wrappers are internal so siblings can read/write. |
| `MenuBar/MenuBarView.swift` | 211 | State surface + ~50 L body (composition only). Body = `AppBackgroundLayer` → `Group { navigationDestination() }` → `commandPaletteOverlay()` → `ToastOverlay` → `keyboardShortcutsLayer()`, plus modifier chain calling out to `handleAppear` / `handleDisappear` / per-notification handlers. Fourteen sibling extensions: **prior nine** — `+AutoDefer` (66, midnight rollover), `+RollForward` (125, focus-slot fill + overdue reschedule), `+Pomodoro` (175, convertEventToPomodoro + clone-as-draft + ripple-shift + slot Pomodoro), `+Timeline` (163, `filteredEventsByDay`/`timelineEventsByDay`/`visibleEventCount`/`timelineDays`/`interleave`/`startOf`/`ghostForDay`), `+BacklogDrop` (230, `handleTaskDrop`+`scheduleBacklogTask`+`scheduleSlotPickerBatch`), `+Strings` (133, pure-compute strings), `+EventActions` (77, `resolveEdit`/`handleDelete`/`notifyScheduleChange`/`runQuickAction`), `+Permissions` (49, `refreshPermissionSnapshots`/`showSyncingState`), `+Focus` (65, day-nav cluster state); **five from 2026-05-12 body decomposition** — `+NavigationRoutes` (375, one `@ViewBuilder` per `MenuBarNavigation` case + `navigationDestination()` dispatcher), `+MainContent` (331, `mainContent`/`eventList`/`inlineStatusRow`/`syncingState`/`parallaxOffset`/`nowMarkerRow`/`nowMarkerLabel`/`dayNavCluster`), `+Lifecycle` (239, `commandPaletteOverlay`/`keyboardShortcutsLayer`/`handleAppear`/`handleDisappear` + per-notification handlers), `+EventRow` (160, `eventRow(_:)` with 15+ row callbacks), `+DayGroup` (194, `dayGroupHeader`/`dayGroupSection`/`freeSlotRow`/`collapsedEventsHeader`). State surface (~30 `@State` fields), notable: `navigation: MenuBarNavigation`, `dayRolloverTimer`, `everyMinuteTimer` (only thing still `private` — only used in body), `initialSyncTimeoutFired` + `initialSyncDataArrived`, `extraDaysShown` capped at `extraDaysCap = 84`. The 2026-05-12 split also relaxed `paletteContext`, `listScrollY`, `showingQuickCapture`, `dismissedBannerIds`, `optimizerBottomY`, `initialSyncTimeoutFired`, `openSettings`, `reduceMotion`, `skin`, `activeSkin`, `extraDaysCap` from `private` to internal for cross-file access. |
| `Backlog/BacklogFullscreenView.swift` | 765 | Body + computed properties + subview helpers. Three logic clusters split out 2026-05-12: `+BulkActions.swift` (131, multi-select schedule/defer/freeze/delete + tombstone undo), `+Reorder.swift` (132, up/down/edge moves + drag-reorder drop), `+Actions.swift` (147, per-task CRUD + inline-add). All `@State`/`@FocusState`/`@Environment` wrappers are internal so siblings can read/write. |
| `CommandPalette/CommandPalette.swift` | 784 | NL intent / quick action search. Three clusters split out 2026-05-12: `+PowerMode.swift` (216, progressive-disclosure composer for OptimizationRequest), `+Status.swift` (133, status/applied/failed result surfaces), `+Actions.swift` (172, handleSubmit/runRequest + keyboard shortcuts). |
| `Components/Backlog/BacklogTaskRow.swift` | 730 | Single-row component. `BacklogTaskRow+Subviews.swift` (601) holds drag payload + checkbox/content/controls/background/focus-ring/scheduled-chip helpers; `OverduePulseDot.swift` (25) lifted to its own file. |
| `Components/Event/EventRowView.swift` | 721 | Single-row component. Three clusters split out 2026-05-12: `+Title.swift` (102, inline rename gate + commit/cancel), `+DragReschedule.swift` (134, vertical drag with minute snapping + preview badge), `+HoverActions.swift` (169, snooze/complete/disintegration-delete/reminder menu). |
Expand Down