Repository navigation
Hide Writing, Play and the feed until they have content - #25
Merged
Merged
Conversation
The home page showed "Nothing published yet." under Writing and Play,
two of the four nav links led to nothing, the footer linked an empty
feed, and the copy said the site already held writing.
- lib/essays.dart: publishedEssays, the one rule (kind: essay, not
draft or noindex, newest first) the essay lists, the Writing nav
link, the feed links and the Writing page's indexing all follow.
- EssayList takes heading and id: as a section it draws its own h2
and § link, or nothing until an essay is published. /writing keeps
the plain list and, flagged essayIndex: true, is noindex (so out of
the sitemap) until then.
- Play leaves the nav and the home page until its first piece; a
comment in j_layout.dart says how to bring it back.
- The home intro and description, and the About page, say what's
coming ("Next I'm learning ... and I'll write it up here").
- make verify fails if an indexable page shows "Nothing published
yet.", links to /writing or the feed before there is an essay, or
links to a home-page section that doesn't exist.
Co-Authored-By: Claude Opus 5.5 <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.
Problem
Before launch, the site showed its gaps:
/writing.Changes
site/lib/essays.dart(new):publishedEssaysis the one rule (kind: essay, notdraftornoindex, newest first). The essay lists, the Writing nav link, the feed links and the Writing page's indexing all follow it.EssayListtakesheadingandid. As a section (<EssayList limit="3" heading="Writing" id="writing"/>on the home page), it draws its ownh2and § link, or nothing until an essay is published./writingkeeps the plain list. FlaggedessayIndex: true, it isnoindex, and so out of the sitemap, until there's an essay._navinj_layout.dartsays how to bring it back.make verifyfails if a page search engines can index:/writingor the feed while no essay is published;/#play).site/DESIGN.md: a section shows only once it has something in it.Verification
dart analyze: no issues.make site-test: all 70 tests pass, including a new table test forpublishedEssays.make site dist verifypasses:/writingisnoindex, and the sitemap has 4 pages./writingwas indexed and in the sitemap (6 pages), andverifypassed. The test essay was then removed.dist/,verifycaught an empty section, a/writinglink with no essays, and a/#playlink with no Play section.🤖 Generated with Claude Code