3
0
mirror of https://github.com/larvit/adf-codec.git synced 2026-11-18 22:25:44 +01:00

Refuse an inline card a link marks in adfToHtml as unsupported-node-shape

This commit is contained in:
2026-11-04 19:37:08 +01:00
parent 81d741d3b6
commit 2e7caeb6ae
7 changed files with 32 additions and 20 deletions
+3 -1
View File
@@ -94,7 +94,7 @@ later release writes it as its own element.
- A hard break is `<br>`, and so is a line feed in text outside a `<div>`'s code block.
- Text a link marks is `<a href="…" title="…">` around it, or the text alone where HTML cannot
hold the link's `href` or `title`; a `title` that is no string is left out. A card is a link to
the target of a link marking it, else to its URL.
its URL; inside a carry element, to the target of a link marking it.
- An external image with no link to another target is a link to its URL. An image marked by a
link to another target shows as portable markdown writes it inline. First comes the link,
around the image's `alt`, else the link's target, else the image's URL. Then comes ` (image)`,
@@ -155,6 +155,8 @@ that node in either spelling: an edit there would be lost, so it is `unmappable-
is not the day its `data-timestamp` names, a card without `data-data` whose `href` and text are
not one URL, and a card with `data-data` whose `href` is not the URL its `data` holds or whose
text is not its name, else that URL, are `unmappable-html`.
- `adfToHtml` refuses an inline card a link marks, which Atlassian's schema gives no link mark, as
`unsupported-node-shape`.
- A `data-*` attribute that its element does not take, such as `data-level` on `<h1>`, or that holds
a value outside its attribute's kind or not written as compact JSON, is `unsupported-node-shape`.
- A carry element's `data-adf` holding invalid JSON is `unmappable-html`. JSON that is no ADF node,