Page management, step 1: every page in a registry, new pages, hidden and disabled
Migration 080 makes site_pages the list of every page: address, title, intro, Hidden, Disabled (out of menus, sitemap and search) and card order. site.json's pages and Navigation's page list move into it. Pages -> Page management (one editor in place of six) makes new pages of sections at any free address; the admin home opens Pages with a banner and a card per page. A catch-all route draws whatever page is at an address; the fixed pages take their words from the registry and can't be deleted. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
56acedf926
commit
1342691f49
36 changed files with 584 additions and 405 deletions
|
|
@ -148,7 +148,7 @@ type Group = { label?: string; choices: Choice[] }
|
|||
on the site rather than an anchor on one of them (Give, not
|
||||
Contact Us). */
|
||||
function mainPages(nav: ReturnType<typeof useSiteNav>): Choice[] {
|
||||
const pages = nav.pages.map((p) => ({ path: p.path, label: p.label }))
|
||||
const pages = nav.pageLinks.map((p) => ({ path: p.path, label: p.label }))
|
||||
const known = new Set(pages.map((p) => p.path))
|
||||
for (const action of nav.actions) {
|
||||
if (!action.path.startsWith('/') || action.path.includes('#') || known.has(action.path)) continue
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue