Skip to content

docs: give the last step of the prevnext chain its way back - #457

Closed
lens0021 wants to merge 1 commit into
mainfrom
claude/docs-prevnext-translation-ssot-0lcxtd
Closed

docs: give the last step of the prevnext chain its way back#457
lens0021 wants to merge 1 commit into
mainfrom
claude/docs-prevnext-translation-ssot-0lcxtd

Conversation

@lens0021

Copy link
Copy Markdown
Collaborator

Closes the one gap left in #455's evidence. Most of what that issue reported was fixed hours earlier by #452, which wired Commands, Development and Writing an extension into the chain; the issue has been corrected to say so. What #452 could not reach is the end of the chain.

The gap

Writing an extension's next link points at Licenses, and Licenses carries no navigation at all. A reader who follows that link arrives at the last page of the documentation with no way back and nothing telling them they have reached the end.

It could not have one. The template read a single argument as the next step, so the two ends of the chain were not symmetrical:

before
first page `{{prevnext Installation}}`
last page nothing after it — not expressible

The change

The first argument is the previous step and the second is the next, each side left empty where the chain ends:

{{prevnext|previous step|next step}}
{{prevnext||next step}}
{{prevnext|previous step|}}

That drops the template's {{{2|{{{1}}}}}} fallback — the one that made a lone argument mean "next" — so both edges now read the same way, and the template is shorter than it was.

Rendering changes for exactly one page. index and Why wikitext move to the empty-first-argument form and come out byte-identical; Licenses gains the row it was missing.

What it looks like now

The chain walks the sidebar's 19 entries in the sidebar's order and stops where the sidebar does:

index → Why wikitext → Installation → Getting Started → Pages → Editing sidebar → Images
      → Skins → Extensions → JavaScript → Searching → Translating → Deploying
      → Troubleshooting → Configuration → Standalone binary → Commands → Development
      → Writing an extension → Licenses ∎

Every sidebar entry has a prevnext, every back-link points at the page that links forward to it, and index remains the head that the sidebar does not list.

Not in this change

The order is still written twice, once here and once as MediaWiki:Sidebar. This fixes the drift, not its cause — #455 holds the proposal for the cause, including the cheaper half of it: a check that the chain and the sidebar agree, which is what would have caught both this gap and the one #452 closed.


Generated by Claude Code

The bottom navigation covers the sidebar's 19 pages except the last one.
Licenses is a step in the chain -- Writing an extension's next link
points at it -- and it carries no navigation at all, so a reader who
follows that link arrives with no way back and nothing saying they have
reached the end.

It could not have one. The template read one argument as the next step,
so the first page of a chain could say it has nothing before it and the
last page had no way to say it has nothing after it. The two ends were
not symmetrical.

Make them so: the first argument is the previous step and the second is
the next, each side left empty where the chain ends. That drops the
template's "second argument, or else the first" fallback and reads the
two edges the same way. The two pages that used the one-argument form
(index, Why wikitext) now write the empty first argument and render
exactly as they did; Licenses gains the row it was missing.

The order is still written twice, here and in MediaWiki:Sidebar, which
is #455. What this fixes is the drift, not its cause: the chain now
matches the sidebar entry for entry, in order.
@lens0021

Copy link
Copy Markdown
Collaborator Author

Closed as a duplicate of #456, which was opened 34 seconds earlier and fixes the same gap: Licenses had no navigation because the template could not spell "a previous step and no next".

The two differ only in how they spell it, and #456's way is the safer one. It adds a named prev= and leaves the positional forms alone, so every existing call keeps its meaning. This one made the first argument always the previous step and the second always the next, which reads more uniformly and shortens the template, but it silently redefines {{prevnext|X}} from "next is X" to "previous is X" — fine for the 20 calls updated in the same commit, and a trap for the 21st written from memory or copied out of an older revision.

One thing from here worth keeping if it is not already covered: the chain and the sidebar were checked entry by entry, and with Licenses fixed they agree exactly — 19 sidebar entries, all with a prevnext, in the sidebar's order, every back-link pointing at the page that links forward to it, and index as the head the sidebar does not list. That agreement is what #455 is about keeping true.


Generated by Claude Code

@lens0021
lens0021 deleted the claude/docs-prevnext-translation-ssot-0lcxtd branch September 1, 2026 00:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants