3
0
mirror of https://github.com/larvit/adf-codec.git synced 2026-11-19 06:35:44 +01:00

Say the card refusal holds only in a block written as an element

This commit is contained in:
2026-11-04 19:52:37 +01:00
parent be5d177a62
commit c06d5a3e99
3 changed files with 10 additions and 8 deletions
+4 -3
View File
@@ -526,7 +526,7 @@ content. No stylesheet ships. The complete dialect:
| `rule` | `<hr>` |
| `text` marked `code`, `em`, `strong` | `<code>`, `<em>`, `<strong>`, the first mark outermost |
| an attribute its type holds that its element does not write, such as `localId`, on a paragraph, heading, quote, list, list item, code block, rule, emoji, mention, status, date or card | `data-*` named as HTML's `dataset` names it: `<p data-local-id="a1f3">` |
| any other node, or a node holding what its element cannot, except an inline card a link marks, which is refused | `<div class="adf-carry" data-adf="{…}"><p>its content</p></div>`, a `<span>` inline |
| any other node, or a node holding what its element cannot, except an inline card a link marks in a block written as an element, which is refused | `<div class="adf-carry" data-adf="{…}"><p>its content</p></div>`, a `<span>` inline |
- Every URL is written as the ADF holds it, `javascript:` included: a link's, an image's, a
card's, and a carried link's in the carry element. Sanitize the HTML before showing a document from
@@ -646,8 +646,9 @@ Every call can raise these:
twice, a block or a non-text inline node holding `text`, or a leaf block or a non-text inline node
holding `content`. Keep the ADF and show the document read-only; where you built the ADF, fix
what the message names.
- **Writing, in `adfToHtml`**: an inline card marked by a link: Atlassian's schema gives a card no
link mark, and HTML nests no link in a link. Keep the ADF and show the document read-only; where
- **Writing, in `adfToHtml`**: an inline card marked by a link, in a block written as an element
(in a carried block it rides the carry): Atlassian's schema gives a card no link mark, and HTML
nests no link in a link. Keep the ADF and show the document read-only; where
you built the ADF, remove the link mark from the card the error's `path` names.
- **Writing, in `adfToPortableMarkdown`**: a line or task list the portable writer cannot spell.
This is a bug in this library: report it.