Redesign mobile project-page sidebar with chips + info-list (#1271)#1394
Merged
Conversation
The mobile project page rendered the sidebar's auto-fit 140px grid above the description, jamming unrelated metadata (date, links, leads, contributor count) into shared rows that read as jumbled, and pushing the description ~500px down. Replace that on mobile (<992px) with two inline blocks in the main column: - a compact status chip strip under the title (Active/Completed, date range, contributor count); - a labeled info-list below the description: Links as clickable chips, Team as a flat seniority-ordered lead list with a native <details> "+N more" disclosure, and Funding as a wrapping logo row (fixes the orphaned 4th logo). The desktop two-column sticky sidebar is unchanged: it's now hidden <992px and restored >=992px, so the mobile blocks don't duplicate it (same dual-render-by- breakpoint pattern Related Projects already uses). No JS changes. Details: - views/project.py: add active_leads_ordered (flat, de-duped, seniority-ordered leads with short inline role labels) for the mobile Team list. - new snippet display_project_team_member_mobile.html for compact lead rows. - design-tokens.css: add --color-status-active-* tokens (status chip green text is 6.9:1 on its fill - AA; avoids hardcoded hex per the tokens convention). - seed_demo_projects.py: seed sponsors/grants (from the WIP branch), make demo projects public, and give the Sidewalk-like demo real links so the full info-list is verifiable locally. - tests/test_project_page.py: regression tests for the chips, link chips, Team overflow <details>, funding, the Completed/empty case, and that the desktop sidebar still renders. - .pa11yci.json: add a 414px-viewport project scan so a11y CI exercises the mobile-only blocks. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #1271.
Problem
On mobile, the project page rendered the sidebar's auto-fit 140px grid above the description, jamming unrelated metadata (date, website, code link, lead avatars, contributor count) into shared rows that read as jumbled — and forcing the reader past ~500px of metadata before the description.
Approach
Additive and mobile-only — desktop is untouched. Below 992px the old sidebar grid is hidden and two inline blocks render in the main column instead (the same dual-render-by-breakpoint pattern Related Projects already uses). No
display:contents, no JS changes.Mobile reading order: title → status chips → description → info-list (Links · Team · Funding) → publications/videos/talks → related.
Active/Completed· date range · contributor count.· PI,· Co-PI,· Lead); the first 4 show and the rest collapse into a native<details>"+N more" disclosure (keyboard/AT-accessible, no JS).Desktop keeps the two-column sticky sidebar exactly as before (now hidden <992px, restored ≥992px so the mobile blocks don't duplicate it).
Files
views/project.py—active_leads_ordered(flat/de-duped/ordered leads w/ role labels).templates/website/project.html— the two.project-mobile-metablocks.templates/snippets/display_project_team_member_mobile.html— new compact lead row.static/website/css/project.css— mobile-meta styles; sidebar → desktop-only.static/website/css/design-tokens.css—--color-status-active-*tokens (chip green 6.9:1 on its fill — AA; no hardcoded hex).management/commands/seed_demo_projects.py— sponsor/grant seeding (from the WIP branch), demo projects made public, real links on the Sidewalk-like demo.tests/test_project_page.py— regression tests (chips, link chips, Team<details>overflow, funding, Completed/empty case, desktop sidebar still renders)..pa11yci.json— 414px-viewport project scan so a11y CI exercises the mobile blocks.Testing
<details>, alt all clean). Local axecolor-contrastflags are the known media-less false positives (they also hit the existing description heading/body). The one genuine marginal finding — green chip at 4.49:1 — was fixed to 6.9:1.Screenshots
🤖 Generated with Claude Code