@ai-matrx/content-ir 0.19.11 → 0.19.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.19.13
4
+
5
+ Automatic changed-only republish (docs/metadata drift since the last tag — see
6
+ `git diff npm/content-ir-core/v0.19.12..npm/content-ir-core/v0.19.13 -- apps/shared/content-ir-core`).
7
+ No source changes intended and no consumer action required.
8
+
9
+ ## 0.19.12
10
+
11
+ Automatic changed-only republish (docs/metadata drift since the last tag — see
12
+ `git diff npm/content-ir-core/v0.19.11..npm/content-ir-core/v0.19.12 -- apps/shared/content-ir-core`).
13
+ No source changes intended and no consumer action required.
14
+
3
15
  ## 0.19.11
4
16
 
5
17
  Automatic changed-only republish (docs/metadata drift since the last tag — see
@@ -15,6 +27,7 @@ No source changes intended and no consumer action required.
15
27
  ## 0.19.9
16
28
  ### Unreleased
17
29
 
30
+ - `/source` **`isHtmlBlockTagName(name)`** (verify-RC-B4 round 9): the tag names CommonMark reads as an HTML BLOCK when they open a line (conditions 1 and 6: `div`, `details`, `section`, `script`, …; case-insensitive) — so a splitter can leave such a line to the markdown renderer, ending where GFM ends it, instead of opening a custom XML container that owns what follows.
18
31
  - `/source` **A table ends where GFM ends it (verify-RC-B4 round 9):** `continuesTable` / `findTableEnd` end a table at an HTML block start (all seven CommonMark 4.6 conditions — `<script`/`<pre`/`<style`/`<textarea`, `<!--`, `<?`, `<!X`, `<![CDATA[`, a block tag name, or any other complete tag alone on its line such as `</artifact>`) and at indented code: a line 4+ columns past the table's container. New `startsHtmlBlock`, `lineIndent`, `tableContainerIndent` (the content column of the list item a table sits in); `continuesTable(line, containerIndent = 0)`. A lone `|` is a row (one empty cell) — `rowCells("|")` is `[""]`, no longer `[]`. Since 0.19.4 an HTML line or an indented line after a table was read as a table row. Shared vectors gain `tableEnds` (30 cases, each judged against remark-gfm in matrx-frontend); the Python twin moved with them.
19
32
  - `/source` **A table never opens on a lazy continuation line (verify-RC-B4 round 9):** `opensTable` / `tableStartsAt` / `findTableStart` refuse a header that lazily continues a list item's or a block quote's paragraph (no blank line above, not indented to the item's content column, or missing the quote's `>`) — GFM reads it as paragraph text (`- item` then `| a | b |` is no table). Vectors gain `tableStarts` (15 cases, judged against remark-gfm).
20
33
  - `/source` **A table opens exactly where GFM opens one (verify-RC-B4 round 9):** `tableStartsAt` requires the delimiter row to match the header's width for pipe-led headers too (`| a | b |` over `|---|` is no table), refuses a "delimiter" that is a list item (`- | -`), and refuses a header indented 4+ columns past its container (indented code). `startsPipelessTable` accepts a header with one pipe (`| a`) or none (`Notes` over `|---|` is a one-column table), as GFM does. Vectors gain 8 opening cases.
package/dist/index.cjs CHANGED
@@ -7701,6 +7701,17 @@ var HTML_BLOCK_NAMES = "address|article|aside|base|basefont|blockquote|body|capt
7701
7701
  var HTML_BLOCK_TAG = new RegExp(`^</?(?:${HTML_BLOCK_NAMES})(?:[\\s>]|/>|$)`, "i");
7702
7702
  var ATTRIBUTE = `\\s+[A-Za-z_:][A-Za-z0-9_.:-]*(?:\\s*=\\s*(?:[^\\s"'=<>\`]+|'[^']*'|"[^"]*"))?`;
7703
7703
  var HTML_COMPLETE_TAG = new RegExp(`^(?:<[A-Za-z][A-Za-z0-9-]*(?:${ATTRIBUTE})*\\s*/?>|</[A-Za-z][A-Za-z0-9-]*\\s*>)\\s*$`);
7704
+ var HTML_BLOCK_NAME_SET = /* @__PURE__ */ new Set([
7705
+ // Condition 1 (raw text) and condition 6 (block) tag names — CommonMark 0.31.
7706
+ "script",
7707
+ "pre",
7708
+ "style",
7709
+ "textarea",
7710
+ ...HTML_BLOCK_NAMES.replace("h[1-6]", "h1|h2|h3|h4|h5|h6").split("|")
7711
+ ]);
7712
+ function isHtmlBlockTagName(name) {
7713
+ return HTML_BLOCK_NAME_SET.has(name.toLowerCase());
7714
+ }
7704
7715
  function startsHtmlBlock(trimmed) {
7705
7716
  if (!trimmed.startsWith("<")) return false;
7706
7717
  return HTML_RAW.test(trimmed) || HTML_COMMENT_ETC.test(trimmed) || HTML_BLOCK_TAG.test(trimmed) || HTML_COMPLETE_TAG.test(trimmed);
@@ -7909,6 +7920,7 @@ exports.isDuplicateBlockSlug = isDuplicateBlockSlug;
7909
7920
  exports.isEmptyResidue = isEmptyResidue;
7910
7921
  exports.isEscapedBracketMath = isEscapedBracketMath;
7911
7922
  exports.isGfmDelimiterRow = isGfmDelimiterRow;
7923
+ exports.isHtmlBlockTagName = isHtmlBlockTagName;
7912
7924
  exports.isIrEnvelopeCache = isIrEnvelopeCache;
7913
7925
  exports.isJsonAnyField = isJsonAnyField;
7914
7926
  exports.isKindDirective = isKindDirective;