Template:Category/Guide/workflow nav

From Miniscope
Jump to: navigation, search

Text-list workflow navigation block for Template:Category/Guide.

Rendered alongside the mermaid workflow graph on workflow-node pages as an accessible, screen-reader-friendly, and mobile-friendly fallback. The visual graph stays the primary navigation affordance; this block adds explicit "Prerequisites" and "Next steps" lists so a reader can navigate without relying on the SVG. Not rendered on the workflow container page — there the whole graph is the navigation.

Parameters:

  • page — the guide page being rendered. Defaults to Template:Category/Guide/workflow nav.

Prerequisites are read from the page's own Has prerequisite guide values via #show + #arraymap (so each prereq becomes its own bullet rather than one bullet with comma-joined values). SMW joins multi-values with ", "; #arraymap accepts that as a multi-char delimiter directly — do not wrap the #show output in #replace. ParserFunctions like #replace evaluate after #arraymap splits the value, so a nested #replace stays as literal text and the literal template markers get split on the comma inside them.

Next steps are derived via the forward SMW query {{{page}}} — every guide that names this page in its own Has prerequisite guide. No separate "next step" property is maintained. Note: SMW's inverse-query syntax PAGE would return PAGE's own prereqs (the opposite direction from what we want here) — when the stored property is itself a backward-pointing edge, the FORWARD query gives the successor view.