Skip to content

Redesign cluster search as collapsible sidebar#650

Merged
LukasWallrich merged 3 commits intocopilot/make-cluster-page-searchablefrom
copilot/sub-pr-616
Feb 18, 2026
Merged

Redesign cluster search as collapsible sidebar#650
LukasWallrich merged 3 commits intocopilot/make-cluster-page-searchablefrom
copilot/sub-pr-616

Conversation

Copy link
Contributor

Copilot AI commented Feb 18, 2026

The previous inline search results box blocked the main content, preventing users from navigating to cluster tabs. Search results displayed in a sticky container that grew large enough to hide all cluster content below.

Changes

Replaced inline search with collapsible left sidebar:

  • Toggle button fixed to left edge (200px from top, z-index 1000)
  • 350px sidebar slides in/out with CSS transitions (left: -350px → 0)
  • Sidebar contains search input, results summary, and scrollable result cards
  • Full viewport height with independent scroll

Result display:

  • Compact cards: tab name + badge, cluster name, highlighted snippet
  • Active state uses inset box-shadow (prevents layout shift)
  • Click navigates to cluster tab, sidebar remains open
  • Auto-focuses search input on open

Interaction:

  • Toggle button, close button (X), ESC key all control sidebar
  • Enter key triggers search
  • Clear button shown only when results exist

Responsive:

  • Desktop: 350px sidebar
  • Mobile (<768px): 100% width sidebar

Example Structure

// Before: sticky container inserted after intro section
const searchContainer = document.createElement('div');
searchContainer.className = 'cluster-search-container';
introSection.parentNode.insertBefore(searchContainer, introSection.nextSibling);

// After: fixed sidebar at body start
const sidebar = document.createElement('div');
sidebar.innerHTML = `
  <button class="cluster-search-toggle">...</button>
  <div class="cluster-search-panel">
    <div class="cluster-search-header">...</div>
    <div class="cluster-search-body">...</div>
  </div>
`;
document.body.insertBefore(sidebar, document.body.firstChild);

CSS handles visibility via panel.classList.toggle('open') which transitions left property.


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Copilot AI and others added 2 commits February 18, 2026 16:25
Co-authored-by: LukasWallrich <60155545+LukasWallrich@users.noreply.github.com>
…ayout shift

Co-authored-by: LukasWallrich <60155545+LukasWallrich@users.noreply.github.com>
Copilot AI changed the title [WIP] Implement search functionality for cluster page Redesign cluster search as collapsible sidebar Feb 18, 2026
Copilot AI requested a review from LukasWallrich February 18, 2026 16:32
@LukasWallrich LukasWallrich marked this pull request as ready for review February 18, 2026 16:35
@LukasWallrich LukasWallrich requested a review from a team as a code owner February 18, 2026 16:35
@github-actions
Copy link
Contributor

✅ Spell Check Passed

No spelling issues found in this PR! 🎉

@github-actions
Copy link
Contributor

👍 All image files/references (if any) are in webp format, in line with our policy.

@LukasWallrich LukasWallrich merged commit 1066ec6 into copilot/make-cluster-page-searchable Feb 18, 2026
2 checks passed
@LukasWallrich LukasWallrich deleted the copilot/sub-pr-616 branch February 18, 2026 16:49
richarddushime added a commit that referenced this pull request Mar 22, 2026
* Initial plan

* Add search functionality to clusters page for searching within tabs

Co-authored-by: LukasWallrich <60155545+LukasWallrich@users.noreply.github.com>

* Fix code review issues: improve regex handling and DOM manipulation

Co-authored-by: LukasWallrich <60155545+LukasWallrich@users.noreply.github.com>

* Redesign cluster search as collapsible sidebar (#650)

* Initial plan

* Redesign cluster search as collapsible left sidebar

Co-authored-by: LukasWallrich <60155545+LukasWallrich@users.noreply.github.com>

* Fix code review feedback: use alert-info for no results and prevent layout shift

Co-authored-by: LukasWallrich <60155545+LukasWallrich@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: LukasWallrich <60155545+LukasWallrich@users.noreply.github.com>

* [WIP] Fix search function layout on cluster page (#654)

* Initial plan

* Fix search panel visibility and scroll behavior

Co-authored-by: LukasWallrich <60155545+LukasWallrich@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: LukasWallrich <60155545+LukasWallrich@users.noreply.github.com>
Co-authored-by: Lukas Wallrich <lukas.wallrich@gmail.com>

* fix: improve clusters search panel UX

- Auto-hide panel when clicking search result
- Position panel below navbar to avoid hiding logo
- Reduce panel width to 70% on mobile devices
- Show only search icon on mobile toggle button

* Improve cluster search: searchable titles and scroll to match

- Make cluster titles and tab labels searchable (e.g., searching "QRP"
  now finds the "QRPs" tab)
- Search section description text outside of tabs
- Scroll to the first highlighted match within a tab pane instead of
  the cluster section top
- Handle section-level results (description/title matches)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* Per-paragraph results, live search, fix cluster title display

- Show one result per matching paragraph/reference instead of per tab
- Filter out nested blocks (p inside li) to avoid duplicate results
- Fix cluster name: use h1 (actual title) not h3 ("Description")
- Live search as user types with 300ms debounce
- Make tab labels searchable (e.g. "QRP" finds "QRPs" tab)
- Scroll to the specific matched element, not the section top

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* Extend cluster search to include titles and descriptions

The search previously only searched within tab panes. Now also searches
cluster titles and description content outside tabs.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: Richard Dushime <45734838+richarddushime@users.noreply.github.com>
Co-authored-by: richarddushime <mudaherarich@gmail.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
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.

2 participants