Refine Primer website discovery, search, and responsive reading UX - #3297
IEvangelist wants to merge 1 commit into
Conversation
Prioritize learning, reuse branded artwork, align responsive frames and controls, scope and deduplicate search, compact reading headers, and resolve documentation images with shared helpers and regression coverage. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
🔵 Needs a closer look
Three unresolved moderate findings affect accessibility, search scan limits, and multi-image spacing.
Pull request overview
Refines the Awesome GitHub Copilot website’s discovery, search, responsive navigation, reading UX, catalogs, and image handling while preserving existing routes and identifiers.
Changes:
- Adds locale-aware search, deduplication, keyboard navigation, and catalog pagination.
- Introduces shared reading headers, progress behavior, focus handling, and responsive visual refinements.
- Adds safe markdown image provenance, sanitization, and regression coverage.
Review findings:
ReadingHeader.tsx— Moderate (1 vote): compact and expanded titles may both be exposed to assistive technology.pagefindSearch.ts— Moderate (1 vote): locale misses or deduplication can cause the full matching result set to be inspected.sanitize-html.ts— Moderate (1 vote): multi-image non-Pcontainers may receive standalone-image margins.
File summaries
| File | Reviewed change |
|---|---|
website/src/styles/base.css |
Shared image spacing and heading textures |
website/src/pages/plugin/[id].astro |
Skips README loading for external plugins |
website/src/pages/extensions.astro |
Updates Extensions catalog metadata |
website/src/pages/extension/[id].astro |
Adds repository image provenance |
website/src/lib/sanitize-html.ts |
Sanitizes and classifies markdown images |
website/src/lib/markdown-images.ts |
Resolves safe image and srcset URLs |
website/src/lib/detail-page.ts |
Passes image provenance to markdown rendering |
website/src/integrations/pagefind-resources.ts |
Builds canonical localized search records |
website/src/components/brand/useCatalogPageFocus.ts |
Shares catalog pagination focus behavior |
website/src/components/brand/useAgentDetailScroll.ts |
Shares reading pinning, progress, and scroll-spy logic |
website/src/components/brand/TopNavSearch.tsx |
Improves grouped localized keyboard search |
website/src/components/brand/TopNav.tsx |
Adds navigation icons and external arrows |
website/src/components/brand/styles/TopNavSearch.module.css |
Styles grouped scrollable search results |
website/src/components/brand/styles/TopNav.module.css |
Adjusts responsive menu sizing and alignment |
website/src/components/brand/styles/styles.module.css |
Refines homepage cards, CTA animation, and frames |
website/src/components/brand/styles/skills.module.css |
Applies shared pagination styling |
website/src/components/brand/styles/reading-header.module.css |
Defines compact reading header layout |
website/src/components/brand/styles/plugins.module.css |
Applies shared pagination styling |
website/src/components/brand/styles/learning-hub-copilot-app.module.css |
Updates article layout and progress visuals |
website/src/components/brand/styles/instructions.module.css |
Applies shared pagination styling |
website/src/components/brand/styles/github-copilot-app.module.css |
Updates article reading layout and progress |
website/src/components/brand/styles/footer.module.css |
Adds the GitHub footer mark |
website/src/components/brand/styles/extensions.module.css |
Applies shared pagination styling |
website/src/components/brand/styles/dotnet-upgrade.module.css |
Updates detail reading layout and progress |
website/src/components/brand/styles/catalog-pagination.module.css |
Aligns pagination controls |
website/src/components/brand/styles/agents.module.css |
Applies shared pagination styling |
website/src/components/brand/SkillsIcon.tsx |
Makes SVG clipping IDs instance-safe |
website/src/components/brand/SkillsCatalog.tsx |
Adds focus handling and heading texture |
website/src/components/brand/SkillDetail.tsx |
Adds compact install actions and image provenance |
website/src/components/brand/searchIndex.ts |
Adds canonical identity and locale filtering |
website/src/components/brand/ReadingHeader.tsx |
Adds the shared compact reading header |
website/src/components/brand/PluginsCatalog.tsx |
Shares catalog focus handling and texture |
website/src/components/brand/PluginDetail.tsx |
Adds compact install actions |
website/src/components/brand/PageShell.tsx |
Integrates responsive navigation positioning |
website/src/components/brand/pagefindSearch.ts |
Adapts localized Pagefind results |
website/src/components/brand/navigation.ts |
Adds navigation metadata and icons |
website/src/components/brand/LearningHubIndex.tsx |
Adds catalog focus handling and texture |
website/src/components/brand/LearningHubIcon.tsx |
Makes SVG clipping IDs instance-safe |
website/src/components/brand/LearningArticleLayout.tsx |
Integrates shared reading behavior |
website/src/components/brand/LargeFooter.tsx |
Applies footer mark styling |
website/src/components/brand/InstructionsIcon.tsx |
Extracts reusable instruction artwork |
website/src/components/brand/InstructionsCatalog.tsx |
Reuses artwork and pagination focus |
website/src/components/brand/InstructionDetail.tsx |
Adds compact install actions |
website/src/components/brand/HomePage.tsx |
Prioritizes Learning Hub and reuses artwork |
website/src/components/brand/ExtensionsCatalog.tsx |
Updates extension labeling and pagination focus |
website/src/components/brand/ExtensionDetail.tsx |
Adds compact install actions |
website/src/components/brand/DetailChassis.tsx |
Integrates shared reading headers and progress |
website/src/components/brand/Custom.tsx |
Anchors responsive navigation panels |
website/src/components/brand/CookbookRecipe.tsx |
Resolves images in file previews |
website/src/components/brand/AgentsIcon.tsx |
Extracts reusable agent artwork |
website/src/components/brand/AgentsCatalog.tsx |
Reuses artwork and pagination focus |
website/src/components/brand/AgentDetail.tsx |
Adds compact install actions |
website/src/assets/github-mark.svg |
Bundles the official GitHub mark |
website/scripts/site-refinement-regression.mjs |
Adds homepage and visual regression checks |
website/scripts/search.test.mjs |
Tests search indexing and locale behavior |
website/scripts/search-browser.test.mjs |
Tests production search interactions |
website/scripts/resource-card-layout-regression.mjs |
Tests responsive card layouts |
website/scripts/reading-header-regression.mjs |
Tests reading header behavior |
website/scripts/reading-catalog-regression.mjs |
Tests reading and catalog interactions |
website/scripts/mobile-nav-regression.mjs |
Tests responsive navigation |
website/scripts/markdown-images.test.mjs |
Tests image resolution and sanitization |
website/README.md |
Documents website conventions and checks |
Review details
Suppressed comments (3)
website/src/components/brand/ReadingHeader.tsx:21
- When the handoff makes this slot visible,
useAgentDetailHeroPinchanges itsaria-hiddentofalse, but the expanded hero's<h1>remains in the accessibility tree. Screen readers therefore encounter the same title twice (the compactdivfollowed by the original heading), even though the compact copy is only a visual reading header. Keep one title exposed to assistive technology—e.g. synchronize the compact header as a visual duplicate and preserve the expanded heading as the sole accessible heading, while keeping the compact install action accessible.
<div className={styles.slot} data-reading-header inert aria-hidden="true">
<div className={clsx(styles.surface, className)}>
<div className={styles.row}>
<div className={styles.title} title={title}>{title}</div>
website/src/components/brand/pagefindSearch.ts:120
- The
limitonly bounds the returned items, not the Pagefind records inspected: when the current locale has no matching hits (or many results collapse during dedupe), this loop callsdata()for every result in the response. A common query on a translated/fallback page can therefore load the entire index's matching records and defeat theMAX_PAGEFIND_HITSbound. Add a separate maximum scan budget (or use a provider-side language filter) and stop once that budget is exhausted, while retaining the result limit.
website/src/lib/sanitize-html.ts:40 - For non-
Pcontainers the image-count check is skipped, so a raw HTML badge/gallery row such as<div><img ...><img ...></div>has no text nodes and marks every image as a block. The global rule then adds 24px margins between inline images, contrary to the image-only-block behavior; apply the same single-image/standalone-container check to these supported parent types or explicitly exclude multi-image rows.
- Files reviewed: 61/62 changed files
- Comments generated: 0
- Review effort level: Lite (auto)
Note
Copilot is running an experiment and ran this review at Lite.
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Live design-team previewhttps://ievangelist.github.io/awesome-copilot/ The reviewed branch is deployed on the author's fork so the design team can explore the changes without running the site locally.
This is a public design preview, not the production site. Search-engine crawling is discouraged with robots.txt. |
Description
Refine the Awesome GitHub Copilot website while preserving Primer Brand, existing resource artwork, and the green reading-progress animation. This follows an iterative desktop/mobile review of discovery, navigation, search, reading layouts, and embedded documentation.
Findings and fixes
#catalog.srcsetfrom explicit source document paths/revisions before sanitization. Apply 24px spacing to standalone documentation images only; preserve inline icons, badge rows, and component-owned galleries.Investigated and intentionally preserved
/plugin/pr-artifact-explorer/is the plugin's short installation README;/extension/pr-artifact-explorer/contains complete extension documentation and previews. Content was not missing; the existing “What's included” link connects them. They remain distinct pages and search results.Self-review and cleanup
Shared reading-header/progress behavior, pagination alignment/focus, branded SVGs, and Markdown image handling replace repeated page-specific logic. Browser regression scripts share
SITE_BASE_URLwith Astro's default port rather than session-specific settings. The full-diff review identified and fixed offscreen keyboard search selection. No new dependencies or screenshot binaries are committed.Validation
npm run website:buildsucceeds, including README/marketplace/data generation; 1155 Astro pages and a Pagefind index of 1194 canonical pages from 6934 generated HTML files. Rebuilt successfully after the self-review fix.bash eng/fix-line-endings.shandgit diff --checkpass.One initial production search run timed out on a Learning Hub result; the complete suite passed on rerun and again after the review fix, without weakening assertions. Existing external-plugin warnings about unpinned sources and non-SPDX license names remain outside scope.
Screenshot attachment status
Seven screenshots were captured from the production preview: desktop homepage in light/dark, mobile homepage, mobile resource menu, grouped search, compact .NET reading header, and embedded extension documentation image.
Attachment upload is blocked: GitHub's user-attachment upload endpoint returned HTTP 404 with both the active OAuth credential and the verified keyring credential. No broken image URLs are included here. The captured PNGs are retained in the originating session's
files/screenshots/directory for upload through GitHub's PR editor. Screenshots still need to be attached.Type of Contribution
No new instructions, prompts, agents, plugins, skills, workflows, or extension packages are introduced.
Pull Request Checklist
maindirectly ingithub/awesome-copilot.By submitting this pull request, I confirm that my contribution abides by the Code of Conduct and will be licensed under the MIT License.