Template:Category/Review record
Render template for Category:Review record subobjects.
Called by the SemanticSchemas dispatcher when a category's Review record
field declaration designates this template as its renderer (via
has_subobject_display_template=Category/Review record on
Category:Review record).
Gated on Has review interval being set on the host page.
If the page has no interval, this template renders nothing — the
document isn't enrolled in review tracking, so we don't show a status
sidebox or emit derived annotations even if Review record subobjects
happen to exist on the page (legacy data, mistakenly added records,
etc.).
When the interval IS set, delegates to
Template:Category/Review record/State which both emits the
page-level annotations (Has last reviewed date,
Has next review due) and renders the right-floating Review
status sidebox — including a collapsed Review history section at the
bottom of the sidebox.
The import-annotation=true parameter on the inner
#ask is essential — without it the inner #set
calls in the State subtemplate don't attach to the host page.
Empty-state fallback via default= in the inner #ask is a
defensive measure; in practice this dispatcher only fires when at
least one Review record subobject exists.
The <templatestyles> include is emitted HERE (in the
dispatcher), not in the State / Empty subtemplates that actually use
the .wiki-status-sidebox* classes. Rationale: when a
<templatestyles> tag is expanded from a template
invoked via #ask|format=template, the resulting
<style> element gets HTML-escaped on its way back
through the #ask result substitution on some MW/SMW versions
(observed on miniscope.org, not on aharoni-lab), and the page renders
the CSS as visible text. Emitting it at the dispatcher level —
outside the #ask round-trip — sidesteps that and produces the same
deduplicated <style> element either way. Gated
inside the Has review interval #if so we don't emit
styles when the sidebox won't render.
Parameters:
category— "Review record" (informational)page— the parent page. Falls back to
Template:Category/Review record if the dispatcher doesn't pass it.