2
10
Fork
You've already forked mathyml
2

feat: handle math.cancel and bare scripts/limits wrappers #2

Closed
DzmingLi wants to merge 1 commit from DzmingLi/mathyml:feat/cancel-scripts-limits into main
pull from: DzmingLi/mathyml:feat/cancel-scripts-limits
merge into: akida:main
akida:main
akida:pages
First-time contributor
Copy link

Add support for two element kinds that currently fall through to the unknown content element error.

  • math.cancel — maps to MathML <menclose> with a strike notation. inverted: true flips the slash direction; cross: true combines both diagonals.

  • bare scripts(x) / limits(x) — these wrappers only steer sub/superscript placement in the enclosing operator (handled in _has-limits). When they appear standalone without any attached scripts they're a no-op — unwrap and recurse into the body.

A note on <menclose>

MathML Core marks <menclose> as deprecated, but Chromium / Firefox / WebKit all still render it, and there's no Core replacement yet.

Add support for two element kinds that currently fall through to the `unknown content element` error. - **`math.cancel`** — maps to MathML `<menclose>` with a strike notation. `inverted: true` flips the slash direction; `cross: true` combines both diagonals. - **bare `scripts(x)` / `limits(x)`** — these wrappers only steer sub/superscript placement in the enclosing operator (handled in `_has-limits`). When they appear standalone without any attached scripts they're a no-op — unwrap and recurse into the body. ### A note on `<menclose>` MathML Core marks `<menclose>` as deprecated, but Chromium / Firefox / WebKit all still render it, and there's no Core replacement yet.
`math.cancel` maps to MathML `<menclose>` with a strike notation;
`inverted` flips the slash, `cross` combines both diagonals.
Bare `scripts(x)` / `limits(x)` without attached sub/superscripts only
steered limit placement in the enclosing operator (handled in
`_has-limits`), so when they appear standalone they're a no-op — unwrap
to the body instead of bailing out via the SVG fallback.
DzmingLi closed this pull request 2026年06月25日 04:25:00 +02:00

Pull request closed

Please reopen this pull request to perform a merge.
Sign in to join this conversation.
No reviewers
Labels
Clear labels
No items
No labels
Milestone
Clear milestone
No items
No milestone
Projects
Clear projects
No items
No project
Assignees
Clear assignees
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
akida/mathyml!2
Reference in a new issue
akida/mathyml
No description provided.
Delete branch "DzmingLi/mathyml:feat/cancel-scripts-limits"

Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?