Skip to content

feat(gui-client): introduce "General" settings page#9381

Merged
thomaseizinger merged 12 commits into
mainfrom
feat/general-settings
Jun 4, 2025
Merged

feat(gui-client): introduce "General" settings page#9381
thomaseizinger merged 12 commits into
mainfrom
feat/general-settings

Conversation

@thomaseizinger

@thomaseizinger thomaseizinger commented Jun 3, 2025

Copy link
Copy Markdown
Member

This PR introduces "General" settings for the GUI client. The "Settings" menu item in the GUI is split into two sub-sections. The menu item is collapsible but open by default.

General Advanced

"Connect on start" and "Account slug" can both be MDM managed. The autostart functionality is implemented via the Windows Registry.

@thomaseizinger thomaseizinger requested review from Copilot and jamilbk June 3, 2025 14:24
@vercel

vercel Bot commented Jun 3, 2025

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
firezone ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 4, 2025 6:34am

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR refactors the settings UI in the GUI client by introducing a new "General" settings page and splitting the previous settings page into two distinct sections (General and Advanced). Key changes include:

  • Adding a new GeneralSettingsForm and related Tauri command to apply general settings.
  • Updating the settings model and view model in Rust and TypeScript to support the new general settings.
  • Adjusting the GUI navigation, sidebar, and controller logic to differentiate between advanced and general settings.

Reviewed Changes

Copilot reviewed 12 out of 12 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
rust/gui-client/src-tauri/src/view.rs Adds GeneralSettingsForm and a new Tauri command for general settings.
rust/gui-client/src-tauri/src/settings.rs Introduces new fields and view model for general settings.
rust/gui-client/src-tauri/src/gui/os_windows.rs Implements autostart functionality via Windows Registry.
rust/gui-client/src-tauri/src/gui.rs Updates GUI events and navigation to handle separate settings pages.
rust/gui-client/src-tauri/src/controller.rs Adds support for applying and persisting general settings.
rust/gui-client/src-frontend/main.tsx Updates sidebar navigation and route configuration for new settings pages.
rust/gui-client/src-frontend/components/ManagedInput.tsx Provides managed input wrappers for controlled UI components.
rust/gui-client/src-frontend/components/GeneralSettingsPage.tsx Implements the new UI for general settings.
rust/gui-client/src-frontend/components/AdvancedSettingsPage.tsx Adjusts the advanced settings page to integrate into the new structure.

Comment thread rust/gui-client/src-tauri/src/settings.rs Outdated

@jamilbk jamilbk left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Couple comments re: form ordering/styling, will take a deeper look again in a bit

Comment thread rust/gui-client/src-frontend/components/GeneralSettingsPage.tsx
Comment thread rust/gui-client/src-frontend/components/GeneralSettingsPage.tsx Outdated
@jamilbk

jamilbk commented Jun 4, 2025

Copy link
Copy Markdown
Member

Noooo I rebased to fix the CI and ended up with more problems 🙃

@jamilbk jamilbk force-pushed the feat/general-settings branch from 9d64050 to f738459 Compare June 4, 2025 03:30
@jamilbk

jamilbk commented Jun 4, 2025

Copy link
Copy Markdown
Member

@thomaseizinger I pushed a change blind 🙈 - spent a bit of time trying to get the frontend to load on macOS to no avail 😆. Open to syncing up to close this one out. The new UI looks really nice overall!

@jamilbk

jamilbk commented Jun 4, 2025

Copy link
Copy Markdown
Member
Screenshot 2025-06-03 at 10 54 47 PM

Comment thread rust/gui-client/src-frontend/components/GeneralSettingsPage.tsx Outdated
Comment thread rust/gui-client/src-tauri/src/view.rs Outdated
Comment thread rust/gui-client/src-tauri/src/view.rs Outdated
Comment thread rust/gui-client/src-tauri/src/view.rs Outdated
@thomaseizinger

Copy link
Copy Markdown
Member Author

I can fix up the Rust comments :)

@jamilbk

jamilbk commented Jun 4, 2025

Copy link
Copy Markdown
Member

I noticed the generated HTML uses a font URL as opposed to embedded font file. Any idea if that might not load if this window is opened without internet connectivity?

@thomaseizinger

Copy link
Copy Markdown
Member Author

I noticed the generated HTML uses a font URL as opposed to embedded font file. Any idea if that might not load if this window is opened without internet connectivity?

I would assume this to be cached but I never tested it.

@thomaseizinger thomaseizinger enabled auto-merge June 4, 2025 13:43
@thomaseizinger

Copy link
Copy Markdown
Member Author

Ready to go in from my PoV.

@thomaseizinger thomaseizinger requested a review from jamilbk June 4, 2025 13:44
@jamilbk

jamilbk commented Jun 4, 2025

Copy link
Copy Markdown
Member

I noticed the generated HTML uses a font URL as opposed to embedded font file. Any idea if that might not load if this window is opened without internet connectivity?

I would assume this to be cached but I never tested it.

See #9398

@thomaseizinger thomaseizinger added this pull request to the merge queue Jun 4, 2025
Merged via the queue into main with commit d6ecda5 Jun 4, 2025
111 checks passed
@thomaseizinger thomaseizinger deleted the feat/general-settings branch June 4, 2025 16:03
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.

3 participants