Add settings page navigation to flow-launcher:// deep links
What
Extends the flow-launcher://settings deep link from #4565 so links can open a specific settings pane, jump to an installed plugin in the Plugins pane, or pre-fill the Plugin Store search.
Stacked on #4565 (feature/query-command-line-arg). Will retarget to dev once that merges; only the last 5 commits are new here.
| Link | Behavior |
|---|---|
flow-launcher://settings | unchanged, opens settings at General |
flow-launcher://settings/general / theme / hotkey / proxy / about | opens that pane |
flow-launcher://settings/plugins | opens the Plugins pane |
flow-launcher://settings/plugins?plugin=<id> | Plugins pane with the filter pre-set to that plugin's name; unknown id shows an error notification and still opens the pane unfiltered (id match is case-insensitive, same as plugin/install) |
flow-launcher://settings/store?q=<term> | Plugin Store pane with the search box pre-filled |
flow-launcher://settings/<anything else> | existing unrecognized-link error path |
How
DeepLink.cs: a publicSettingsPagesmap (verb to pane type) drives the handler registrations, so the documented links, the dispatch table, and the tests share one source of truth.settings/pluginsresolves the id via loaded plugins;settings/storepassesqthrough; whitespace-only params are treated as absent.SettingWindowViewModel: one-shot pending destination (pane type + optional filter text) with consume-once accessors, so a later manual visit never re-applies a stale destination or filter.SettingWindow: the frame-loaded handler consumes the pending page instead of always selecting General (resetting the stale page type first so navigation actually fires); an already open window is navigated viaNavigateToPendingPage, which re-navigates the frame directly when the target pane is already selected so a new filter still applies.SettingsPanePlugins/SettingsPanePluginStore: consume the pending filter inOnNavigatedToand assign it to their existingFilterText.- Two new strings in
en.xamlfor the unknown-plugin notification.
Tests
- Unit:
DeepLinkTestcovers every documented link mapping (including case-insensitivity and an unmapped subpage), plusplugin/qparameter extraction;SettingWindowViewModelTestcovers the consume-once semantics. - Manual (Windows) matrix in progress, draft until complete:
- Each pane link, cold and warm start
?plugin=<installed id>filters; unknown id shows the notification and opens unfiltered?q=clipboardpre-fills the store search- Warm same-pane link updates the filter
- Reopening settings manually shows no stale filter
- Close settings on the Plugins pane, then cold-start
flow-launcher://settings/plugins(regression check for the stale page type) - Plain
flow-launcher://settingsunchanged
Summary by cubic
Summary of changes
Adds navigation for flow-launcher://settings deep links so links can open a specific pane, jump to an installed plugin in Plugins, or pre-fill the Plugin Store search. Previously, flow-launcher://settings always opened General; now subpaths select panes, Plugins supports ?plugin=<id>, Store supports ?q=<term>, and unknown plugin ids show a notification while still opening Plugins.
- Changed behavior/logic:
- Deep link dispatch now derives settings handlers from a single
SettingsPagesmap; the same map drives tests and routing. settings/plugins?plugin=<id>looks up installed plugins case-insensitively; whitespace-only parameters are ignored.- Settings window resets a stale page type and re-navigates the current pane so new filters apply even when already open.
- Added user-facing strings for the unknown-plugin notification.
- Deep link dispatch now derives settings handlers from a single
- New behavior/logic:
- Added
OpenSettingsPageandHandleSettingsPlugins, plus a consume-once pending navigation state onSettingWindowViewModel. - Plugins and Store panes consume pending filter text in
OnNavigatedTo. - New
NavigateToPendingPageenables warm navigation to the target pane. - Tests cover link-to-pane mappings, parameter extraction, case-insensitivity, and consume-once semantics.
- Added
- Removed behavior/logic:
- Replaced the single “always open General” settings handler with per-pane handlers built from
SettingsPages. - Removed duplicated string literals for
settings/pluginsandsettings/store.
- Replaced the single “always open General” settings handler with per-pane handlers built from
- Memory impact:
- Negligible. Adds a small immutable
SettingsPagesmap and two short-lived fields for pending navigation on an existing singleton view model.
- Negligible. Adds a small immutable
- Security risks:
- Low. Parameters are normalized and only drive in-app navigation and filtering; no elevated actions are executed. Unknown plugin ids result in a local notification only.
- Unit tests:
DeepLinkTestvalidates all documented settings links and parameter parsing.SettingWindowViewModelTestverifies one-shot pending navigation and default behaviors.
Release Note
You can now open specific Settings pages via links (for example, Plugins or Store) and even pre-fill plugin filters or store search directly from a flow-launcher://settings/... link.