Skip to content

Update the CanvasNet Pandoc filter to version 16 (gallery verified current) - #51

Merged
Malcolmnixon merged 2 commits into
mainfrom
gallery-and-filter-refresh
Nov 15, 2026
Merged

Malcolmnixon merged 2 commits into
mainfrom
gallery-and-filter-refresh

Conversation

@Malcolmnixon

@Malcolmnixon Malcolmnixon commented Nov 15, 2026 •

Copy link
Copy Markdown
Member

Description

Updates docs/filters/canvasnet.lua to CanvasNet's Pandoc filter version 16, copied verbatim from CanvasNet main (demaconsulting/CanvasNet#144), and pins the demaconsulting.canvasnet.tool to 0.2.0-beta.10, the release that ships filter 16.

Filter 16 (over the previous version 6 here) adds native Mermaid rendering, SVG flattening of composite pictures, and opt-in file access (CANVASNET_FILE_ACCESS / CANVASNET_ROOTS, default any as in Pandoc); version 16 passes --file-access roots explicitly when only CANVASNET_ROOTS is set, stops a restrictive build on file-access-denied, and hashes a chart cycle once.

Version split (intentional): the documentation tool is 0.2.0-beta.10 (needed for filter 16 / document builds), while the runtime DemaConsulting.CanvasNet* package references stay at 0.2.0-beta.9 in this PR; the runtime packages will move to beta.10 in a separate dependency update, keeping this PR documentation-tooling only.

Also corrects docs/design/ots/pandoc.md, which said mermaid-filter draws the Mermaid diagrams. The gallery was regenerated with ./gallery.ps1 (58/58) and found current: the apparent SVG differences were CRLF/LF line endings only, so no gallery files change. mermaid-filter is still listed in package.json and passed in build.yaml; it is now redundant and can be removed in a later cleanup.

Validation

  • Documents build with Pandoc using filter 16 and the beta.10 tool (no filter errors, no "Could not fetch" / "Failed to load image").
  • CI: build, tests, lint and documents pass.

Copy docs/filters/canvasnet.lua verbatim from CanvasNet (FILTER_VERSION 15):
SVG flatten support, native Mermaid diagrams, and the opt-in file-access
mode (CANVASNET_FILE_ACCESS / CANVASNET_ROOTS). Requires canvasnet tool
0.2.0-beta.9, which is already pinned.

Update the Pandoc OTS design note: Mermaid diagrams are now drawn by the
CanvasNet filter, and mermaid-filter only sees types CanvasNet does not draw.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI lite review requested due to automatic review settings November 15, 2026 02:06

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

Two active issues remain: chart cycles can recurse until MAX_DEPTH, and file-access-denied diagnostics may be ignored, allowing a partial render to be published.

2 open issues
What changed in this PR

Updates the CanvasNet Pandoc filter to version 15 with native Mermaid rendering, SVG flattening, expanded dependency tracking, and configurable file-access restrictions. The Pandoc integration documentation now reflects CanvasNet's diagram-filtering responsibilities.

Changes:

  • Replaces the CanvasNet filter with version 15, including Mermaid support, SVG flattening, dependency hashing, and file-access controls.
  • Updates the Pandoc documentation to describe CanvasNet as the primary Mermaid renderer and clarify the remaining mermaid-filter stage.
  • Gallery outputs remain unchanged after regeneration.
File Description
docs/​filters/​canvasnet.lua Replaces the CanvasNet filter with version 15, adding Mermaid rendering, SVG flattening, dependency tracking, cache invalidation, and configurable file-access controls.
docs/​design/​ots/​pandoc.md Updates the Pandoc integration documentation to identify CanvasNet as the primary Mermaid diagram filter and clarify mermaid-filter's remaining role.

Review effort: Lite

Comment thread docs/filters/canvasnet.lua Resolved
Comment thread docs/filters/canvasnet.lua Resolved
…ol to 0.2.0-beta.10

Filter 16 (demaconsulting/CanvasNet#144) addresses the review findings on version 15.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI lite review requested due to automatic review settings November 15, 2026 16:10
@Malcolmnixon Malcolmnixon changed the title Update the CanvasNet Pandoc filter to version 15 (gallery verified current) Update the CanvasNet Pandoc filter to version 16 (gallery verified current) Nov 15, 2026

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

The CanvasNet tool manifest is upgraded to beta.10 while the runtime package and OTS documentation remain on beta.9, leaving the intended version relationship and reproducibility requirements ambiguous.

1 open issue
2 resolved since last review

Review effort: Lite

Comment thread .config/dotnet-tools.json Resolved
@Malcolmnixon
Malcolmnixon merged commit b074efa into main Nov 15, 2026
7 checks passed
@Malcolmnixon
Malcolmnixon deleted the gallery-and-filter-refresh branch November 15, 2026 16:33
Malcolmnixon added a commit that referenced this pull request Nov 17, 2026
…eta.11 shim (#63)

* Sync agents, skills and standards from Agents main

Copy .github/agents, skills and standards (excluding cpp-*) from Agents
origin/main and apply the LintMark/Node.js AGENTS.md wording from #48.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* Switch to LintMark, remove Node.js, update CanvasNet tool

- Replace markdownlint-cli2 with demaconsulting.lintmark 0.1.0-beta.2 in
  lint.ps1/fix.ps1, add .lintmark.yaml carrying over the repo ignores, and
  delete .markdownlint-cli2.yaml (template #49, Agents #48)
- Remove Node.js: package.json, CI setup-node steps, node/npm VersionMark
  captures and the .gitignore Node section; capture lintmark
- Drop the stale package-lock.json textlint ignore
- Name LintMark instead of markdownlint in CONTRIBUTING.md, the VersionMark
  OTS design and the gallery index comments
- Pin demaconsulting.canvasnet.tool 0.2.0-beta.11 (template #51)

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* Replace canvasnet.lua with the CanvasNet 0.2.0-beta.11 shim

Written by 'dotnet canvasnet pandoc-filter --write-shim docs/filters/canvasnet.lua'
(template #51).

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* Apply LintMark --fix formatting

Formatting-only changes from 'dotnet lintmark --fix': emphasis delimiters,
compact tables, trailing whitespace and paragraph rewrapping at 120 columns.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* Add lintmark to the TextLint word list

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* Rejoin the two-waypoint compound split by an old line wrap

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

---------

Co-authored-by: Malcolm Nixon <Malcolm.Nixon@hiarc.inc>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
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