@ai-matrx/content-ir 0.24.6 → 0.24.7

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/dist/index.js CHANGED
@@ -5514,7 +5514,7 @@ function fenceParts(raw) {
5514
5514
  const closed = rest.length > 0 && new FenceReader(opener, { nesting: false }).feed(rest[rest.length - 1]);
5515
5515
  if (!closed) return { opener, body: rest.join("\n"), closed };
5516
5516
  const last = rest[rest.length - 1];
5517
- const before = trimFenceLine(last).startsWith("```") ? "" : last.slice(0, last.indexOf("```"));
5517
+ const before = opener.char === "~" || trimFenceLine(last).startsWith("```") ? "" : last.slice(0, last.indexOf("```"));
5518
5518
  return { opener, body: [...rest.slice(0, -1), ...before.trim() ? [before] : []].join("\n"), closed };
5519
5519
  }
5520
5520
  function fenceLineKinds(text) {