Skip to content

feat(web): add settings sidebar search - #4682

Merged
maria-rcks merged 15 commits into
pingdotgg:mainfrom
shivamhwp:agent/settings-sidebar-search
Jul 31, 2026
Merged

feat(web): add settings sidebar search#4682
maria-rcks merged 15 commits into
pingdotgg:mainfrom
shivamhwp:agent/settings-sidebar-search

Conversation

@shivamhwp

@shivamhwp shivamhwp commented Jul 27, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • add a Settings sidebar search that replaces section navigation with settings whose visible titles contain the query
  • navigate mouse and keyboard selections to stable route anchors, scroll them into view, focus them, and visibly highlight the destination
  • support Arrow Up/Down, Enter, Escape, an accessible empty state, async settings panels, reduced motion, and mobile sidebar closing
  • use router-controlled destination state so highlighting and remount scrolling work with Electron hash history and asynchronously replaced settings content
  • index stable settings and route conditional options to their always-available parent setting

Why

Settings are split across several routed panels. Finding a specific option currently requires knowing which section contains it. This adds a lightweight, dependency-free title index directly in the sidebar while keeping the main Settings layout unchanged.

Screenshots

Search results

Settings sidebar showing a title-only search result for Word wrap

Selected setting

Appearance settings after navigating to Word wrap from search

Validation

  • vp test run src/components/settings/settingsSearch.test.ts src/components/settings/settingsLayout.test.tsx --project unit from apps/web — 9 tests passed
  • targeted vp lint and vp fmt for changed files
  • vp run --filter @t3tools/web typecheck
  • computer-use smoke pass covering search results, click navigation, keyboard selection, empty state, and Escape clearing
  • Opus cleanup review completed and incorporated

Review notes

The initial search pass also showed that hidden descriptions and keywords produced surprising matches. The implementation now matches only visible setting titles, uses a persistent scoped destination highlight, and indexes only the stable Remote environments target. Final hands-on visual review is intentionally left to the reviewer.

Note

Add search to the settings sidebar with hash-based anchor navigation

  • Adds a search input to SettingsSidebarNav, activated with /, that filters settings by title and lets users jump directly to a setting via keyboard or mouse.
  • Introduces a settingsSearch.ts catalog mapping setting ids, titles, and routes, plus a searchableSetting(id) helper that attaches stable anchor ids to panels and rows.
  • Navigation pushes a URL hash; settingsLayout.tsx reads the hash on mount, scrolls and focuses the target element with a pulse animation, then clears the hash.
  • Spreads searchableSetting(...) across all major settings panels (Appearance, General, Providers, Keybindings, Connections, Source Control, Beta) to register them as searchable targets.
  • On mobile, the sidebar closes automatically after navigating to a result.

Macroscope summarized 56c2d87.


Note

Low Risk
UI-only navigation and labeling changes with unit tests; no auth, data, or server behavior changes.

Overview
Adds settings search in the settings sidebar: a title-only index backed by a central settingsSearch catalog, with / to focus the field and arrow/Enter/Escape keyboard navigation.

While searching, section links swap for matching results (setting title plus parent section). Choosing a result navigates to the right settings route with a URL hash anchor; SettingsPageContainer and searchableSetting keep row/section ids and titles aligned with the catalog so panels and search cannot drift.

Scroll, focus, and highlight land on the target row or section header (section headers scroll when the anchor is a SettingsSection), with a short pulse animation unless reduced motion is enabled; the hash is cleared after handling. Conditional settings can point at a stable parent via targetId (e.g. environment identification → Appearance).

Settings panels across General, Appearance, Beta, Connections, and related areas now spread searchableSetting(...) instead of hard-coded titles. Minor sidebar chrome cleanup removes an extra separator.

Reviewed by Cursor Bugbot for commit 56c2d87. Bugbot is set up for automated code reviews on this repo. Configure here.

@coderabbitai

coderabbitai Bot commented Jul 27, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 9c69da8c-292e-47c0-9f4e-d2fd6fa614ea

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions github-actions Bot added vouch:trusted PR author is trusted by repo permissions or the VOUCHED list. size:XL 500-999 changed lines (additions + deletions). labels Jul 27, 2026
Comment thread apps/web/src/components/settings/settingsLayout.tsx Outdated
@github-actions github-actions Bot added size:L 100-499 changed lines (additions + deletions). and removed size:XL 500-999 changed lines (additions + deletions). labels Jul 27, 2026
@shivamhwp
shivamhwp marked this pull request as ready for review July 27, 2026 23:09
Comment thread apps/web/src/index.css
Comment thread apps/web/src/components/settings/SettingsSidebarNav.tsx Outdated
Comment thread apps/web/src/components/settings/settingsLayout.tsx
@macroscopeapp

macroscopeapp Bot commented Jul 27, 2026

Copy link
Copy Markdown
Contributor

Approvability

Verdict: Needs human review

This PR introduces a new settings sidebar search feature with keyboard navigation, search results UI, and scroll-to-target animations. New user-facing features with new components and behaviors warrant human review.

You can customize Macroscope's approvability policy. Learn more.

Comment thread apps/web/src/components/settings/settingsLayout.tsx
@github-actions github-actions Bot added size:XL 500-999 changed lines (additions + deletions). and removed size:L 100-499 changed lines (additions + deletions). labels Jul 28, 2026
Comment thread apps/web/src/index.css
@shivamhwp
shivamhwp force-pushed the agent/settings-sidebar-search branch from 5525708 to 18af1be Compare July 30, 2026 02:49
@shivamhwp shivamhwp changed the title Add settings sidebar search feat(web): add settings sidebar search Jul 30, 2026
Comment thread apps/web/src/index.css
Comment thread apps/web/src/components/settings/SettingsSidebarNav.tsx Outdated
Comment thread apps/web/src/components/settings/SourceControlSettings.tsx Outdated
shivamhwp and others added 4 commits July 31, 2026 00:34
…rgets

Disable TanStack Router's built-in hashScrollIntoView on settings search
navigations so it can't fight the custom centered scroll/focus/pulse, and
keep search target ids off loading placeholders (source control skeleton,
archive loading state) so the hash survives until real content mounts.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
… titles

Panels now spread id/title from searchableSetting() instead of restating
them, and the sidebar nav derives its entries from the shared section
labels, so a retitle (or a future translation pass) happens in one module.
Also fixes the Project Grouping/Project grouping drift the split had
already caused.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…/settings-sidebar-search

# Conflicts:
#	apps/web/src/components/settings/SettingsSidebarNav.tsx
Focusing the destination drew the browser focus ring on top of the pulse
animation. Suppress the outline while the pulse class is present; under
reduced motion the class is never added, so the ring remains the sole
destination indicator there.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Comment thread apps/web/src/components/settings/settingsLayout.tsx
shivamhwp and others added 2 commits August 1, 2026 02:41
Pressing "/" anywhere on a settings page (outside an editable field)
focuses and selects the sidebar search, matching the keybindings panel
mod+F pattern. The nav only mounts on settings routes, so the listener
is scoped automatically.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Same Kbd chip the main sidebar uses for its command palette shortcut; it
yields its slot to the clear button while a query is active.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Comment thread apps/web/src/components/settings/SettingsSidebarNav.tsx Outdated
shivamhwp and others added 2 commits August 1, 2026 03:01
- Remove the pulse class when the destination loses focus, so stale
  targets regain their normal focus outline instead of keeping the
  suppression for the rest of the session.
- Open the sidebar (mobile sheet or collapsed desktop rail) before the
  "/" shortcut focuses the search input, so it never focuses off-screen.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Comment thread apps/web/src/components/settings/SettingsSidebarNav.tsx
Bail when the keypress originates inside a dialog or popup so the
shortcut cannot pull focus out of a modal focus trap.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

@cursor cursor Bot 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.

Cursor Bugbot has reviewed your changes using high effort and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 56c2d87. Configure here.

Comment thread apps/web/src/components/settings/SettingsSidebarNav.tsx
@maria-rcks
maria-rcks merged commit e5c7547 into pingdotgg:main Jul 31, 2026
17 checks passed
github-actions Bot added a commit to omarcresp/t3code-flake that referenced this pull request Aug 1, 2026
## What's Changed
* feat(web): add settings sidebar search by @shivamhwp in pingdotgg/t3code#4682
* fix: threads with open PRs no longer auto-settle by @t3dotgg in pingdotgg/t3code#5151
* fix(server): bound thread catch-up replay and stop full-DB snapshot hydration by @t3dotgg in pingdotgg/t3code#5147


**Full Changelog**: pingdotgg/t3code@v0.0.32-nightly.20260731.968...v0.0.32-nightly.20260801.969

Upstream release: https://github.com/pingdotgg/t3code/releases/tag/v0.0.32-nightly.20260801.969
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:XL 500-999 changed lines (additions + deletions). vouch:trusted PR author is trusted by repo permissions or the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants