[FEATURE] Support selecting an alternate template per document - #1364
Conversation
Add the generic ':template:' field-list metadata: TemplateNode, TemplateFieldListItemRule to parse it, TemplateMetadataNodeRenderer to render it as nothing (it's a marker, not visible content), and DocumentNode::getTemplate() to expose the selected template name. Split out of #1358 per review feedback -- the genindex work on that branch is the first consumer (`:template: genindex`), but the mechanism itself is generic and reviewable on its own. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01PP4LkejR5PSubbhNmF4RkT
e2a33b5 to
072e9da
Compare
jaapio
left a comment
There was a problem hiding this comment.
Could you also include an integration test for this new feature?
|
No integration test here: at this point The unit tests cover what's actually testable at this layer: An integration/fixture test showing the template actually affecting output belongs with the consumer — the genindex work on the follow-up branch, which reads |
Add the generic
:template:field-list metadata: TemplateNode,TemplateFieldListItemRule to parse it, TemplateMetadataNodeRenderer to
render it as nothing (it's a marker, not visible content), and
DocumentNode::getTemplate() to expose the selected template name.
Split out of #1358 per review feedback -- the genindex work on that
branch is the first consumer (
:template: genindex), but themechanism itself is generic and reviewable on its own.
Signed-off-by: lina.wolf lwolf@w-commerce.de
Assisted by claude-code:claude-opus-5 — Session