Sort by recency on landing page + project detail redesign #51

Closed
opened 2026-02-27 18:53:56 +00:00 by forgejo_admin · 0 comments

Plan

plan-2026-02-27-browse-ux-enhancements — Phase 1

Repo

pal-e-docs — the repo where the code change happens

User Story

As a visitor browsing pal-e-docs
I need the landing page to surface recently updated content first, and project pages to tell a story (overview → repos → notes)
So that the site feels like a well-organized documentation hub, not a flat alphabetical dump

Acceptance Criteria

When I visit the landing page
Then doc sections (SOPs, conventions, etc.) are sorted by most recently updated first
And projects are sorted by most recently created first

When I visit a project detail page that has a page_note_id
Then the project page note content renders at the top (through the sanitize → autolink → wrap_tables pipeline)
And the project's repos are shown below the page note
And the remaining notes feed follows (excluding the page note to avoid duplication)

Additional Information

  • Landing page doc sections currently use order_by(Note.title) — change to order_by(Note.updated_at.desc())
  • Project query currently uses order_by(Project.name) — change to order_by(Project.created_at.desc()) (no updated_at on Project model)
  • Repo query — check if Repo model has timestamp fields. If not, keep alphabetical.
  • Project detail page: page_note_id FK already exists on projects table (PR #29). Use it to fetch and render the page note.
  • Rendering pipeline for page note content: sanitize_html() → autolink_slugs() → wrap_tables()
  • Key files: src/pal_e_docs/routes/frontend.py, src/pal_e_docs/templates/project_notes.html

Checklist

  • PR opened with related notes
  • Tests cover the acceptance criteria
  • Docs updated if needed
  • project-pal-e-docs — parent project
  • issue-pal-e-docs-recency-project-detail — pal-e-docs tracking note
### Plan `plan-2026-02-27-browse-ux-enhancements` — Phase 1 ### Repo `pal-e-docs` — the repo where the code change happens ### User Story As a visitor browsing pal-e-docs I need the landing page to surface recently updated content first, and project pages to tell a story (overview → repos → notes) So that the site feels like a well-organized documentation hub, not a flat alphabetical dump ### Acceptance Criteria When I visit the landing page Then doc sections (SOPs, conventions, etc.) are sorted by most recently updated first And projects are sorted by most recently created first When I visit a project detail page that has a `page_note_id` Then the project page note content renders at the top (through the sanitize → autolink → wrap_tables pipeline) And the project's repos are shown below the page note And the remaining notes feed follows (excluding the page note to avoid duplication) ### Additional Information - Landing page doc sections currently use `order_by(Note.title)` — change to `order_by(Note.updated_at.desc())` - Project query currently uses `order_by(Project.name)` — change to `order_by(Project.created_at.desc())` (no `updated_at` on Project model) - Repo query — check if Repo model has timestamp fields. If not, keep alphabetical. - Project detail page: `page_note_id` FK already exists on projects table (PR #29). Use it to fetch and render the page note. - Rendering pipeline for page note content: `sanitize_html() → autolink_slugs() → wrap_tables()` - Key files: `src/pal_e_docs/routes/frontend.py`, `src/pal_e_docs/templates/project_notes.html` ### Checklist - [ ] PR opened with related notes - [ ] Tests cover the acceptance criteria - [ ] Docs updated if needed ### Related - `project-pal-e-docs` — parent project - `issue-pal-e-docs-recency-project-detail` — pal-e-docs tracking note
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
forgejo_admin/pal-e-api#51
No description provided.