Skip to content

Revamp Settings Providers tab & fix multiple bugs#220

Open
caezium wants to merge 6 commits intoJerryZLiu:mainfrom
caezium:settings-revamp-and-bugfixes
Open

Revamp Settings Providers tab & fix multiple bugs#220
caezium wants to merge 6 commits intoJerryZLiu:mainfrom
caezium:settings-revamp-and-bugfixes

Conversation

@caezium
Copy link

@caezium caezium commented Mar 1, 2026

Summary

Overhauls the Settings → Providers tab with a card-based UI and fixes several bugs related to window lifecycle, onboarding state, and macOS fullscreen behavior.

Changes

Settings Providers Tab Revamp

  • Card-based provider management — Replaced the multi-step onboarding-style UI with a clean card layout showing Primary Provider, Backup Provider, Connection Health, and Available Providers at a glance.
  • New ProviderCardView — Compact, reusable card component with provider icon, name, status badge, summary, and contextual action buttons (Configure / Set as Primary / Set as Backup / Remove).
  • New ProviderConfigEditor — Sheet-based form editor for each provider type (Gemini, Ollama, ChatGPT/Claude), replacing the wizard flow for configuration changes.
  • Inline model & prompt customization — Model Preference and Prompt Customization sections are now directly accessible within the Providers tab.

Bug Fixes

  • Stale settings on window reopen — Provider state now refreshes from UserDefaults/Keychain when the settings window regains focus, fixing incorrect defaults after soft-quit/reopen cycles. (SettingsView.swift, ProvidersSettingsViewModel.swift)
  • Premature onboarding persistence — Setup wizard no longer writes partial config to UserDefaults/Keychain during intermediate steps; only persists on final save. (LLMProviderSetupView.swift)
  • Timeline cards disappearing — Activities and review count now refresh when the app becomes active, fixing blank timeline after wake/reopen. (Layout.swift)
  • Menu bar popover not showing in fullscreen — Popover window now uses canJoinAllSpaces, moveToActiveSpace, and fullScreenAuxiliary collection behaviors so it appears over fullscreen apps. (StatusBarController.swift)
  • Dark mode color bleed in connection health card — Forced light color scheme on connection health test views to prevent .roundedBorder text fields from rendering with dark backgrounds. (SettingsProvidersTabView.swift)

Files Changed (8 files, +653 / -253)

File Change
ProviderCardView.swift New — Reusable provider card component
ProviderConfigEditor.swift New — Sheet-based provider configuration editor
SettingsProvidersTabView.swift Rewritten — Card-based layout replacing wizard flow
ProvidersSettingsViewModel.swift Modified — Added refresh, editing state, remove provider
SettingsView.swift Modified — Window focus triggers provider refresh
LLMProviderSetupView.swift Modified — Removed premature persistence in onboarding
Layout.swift Modified — Refresh timeline on app activation
StatusBarController.swift Modified — Fullscreen-compatible popover behavior

Testing

  • Built successfully with xcodebuild (Debug, no code signing)
  • Manual testing recommended for: provider card interactions, config editor sheet, window reopen state, fullscreen menu bar popover, timeline refresh after sleep/wake

caezium added 6 commits March 1, 2026 21:48
…tale defaults

Add refreshFromPersistence() to reload all provider config from UserDefaults/Keychain when the settings window becomes key. Fixes closing and reopening the window (without quitting) showing stale or default values.
… setup wizard

Remove early persistLocalSettings() and persistGeminiAPIKey() calls from intermediate setup steps. Config is now only saved on final saveConfiguration(), preventing the onboarding wizard from mutating provider state when users click through without completing setup.
Rewrite the Providers settings tab with a clearer card-based layout:
- ProviderCardView: compact card showing provider status with contextual actions
- ProviderConfigEditor: lightweight sheet for editing provider config without re-running the full onboarding wizard
- SettingsProvidersTabView: reorganized into Primary, Backup, Health, and Available Providers sections

Removes the confusing onboarding-style routing matrix. Forces light color scheme on the editor sheet to match the app's light-mode-only design.
…ctive

Trigger refreshActivitiesTrigger and updateCardsToReviewCount() in the existing didBecomeActiveNotification handler. Fixes timeline cards disappearing after the app is backgrounded and brought back without a full quit-and-relaunch.
Set popover window collection behavior to canJoinAllSpaces, moveToActiveSpace, and fullScreenAuxiliary. Also activate the app and make the popover window key so it appears above fullscreen windows.
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