@ai-matrx/content-ir 0.19.18 → 0.19.19
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 +5 -0
- package/dist/index.cjs +7 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +7 -1
- package/dist/index.js.map +1 -1
- package/dist/source.cjs +7 -0
- package/dist/source.cjs.map +1 -1
- package/dist/source.d.cts +6 -1
- package/dist/source.d.ts +6 -1
- package/dist/source.js +7 -1
- package/dist/source.js.map +1 -1
- package/package.json +1 -1
package/dist/source.cjs
CHANGED
|
@@ -1035,6 +1035,11 @@ var HTML_BLOCK_NAMES = "address|article|aside|base|basefont|blockquote|body|capt
|
|
|
1035
1035
|
var HTML_BLOCK_TAG = new RegExp(`^</?(?:${HTML_BLOCK_NAMES})(?:[\\s>]|/>|$)`, "i");
|
|
1036
1036
|
var ATTRIBUTE = `\\s+[A-Za-z_:][A-Za-z0-9_.:-]*(?:\\s*=\\s*(?:[^\\s"'=<>\`]+|'[^']*'|"[^"]*"))?`;
|
|
1037
1037
|
var HTML_COMPLETE_TAG = new RegExp(`^(?:<[A-Za-z][A-Za-z0-9-]*(?:${ATTRIBUTE})*\\s*/?>|</[A-Za-z][A-Za-z0-9-]*\\s*>)\\s*$`);
|
|
1038
|
+
var STRIPPED_HTML_BLOCK_NAMES = "address|article|aside|base|basefont|body|center|dialog|dir|fieldset|footer|form|frame|frameset|head|header|html|iframe|legend|link|main|menu|menuitem|nav|noframes|optgroup|option|param|search|title|track";
|
|
1039
|
+
var STRIPPED_HTML_BLOCK_TAG = new RegExp(`^</?(?:${STRIPPED_HTML_BLOCK_NAMES})(?:[\\s>]|/>|$)`, "i");
|
|
1040
|
+
function opensStrippedHtmlBlock(trimmed) {
|
|
1041
|
+
return STRIPPED_HTML_BLOCK_TAG.test(trimmed);
|
|
1042
|
+
}
|
|
1038
1043
|
var HTML_BLOCK_NAME_SET = /* @__PURE__ */ new Set([
|
|
1039
1044
|
// Condition 1 (raw text) and condition 6 (block) tag names — CommonMark 0.31.
|
|
1040
1045
|
"script",
|
|
@@ -1152,6 +1157,7 @@ function insideHtmlBlock(lines, index) {
|
|
|
1152
1157
|
continue;
|
|
1153
1158
|
}
|
|
1154
1159
|
paragraph = false;
|
|
1160
|
+
if (opensStrippedHtmlBlock(trimmed)) continue;
|
|
1155
1161
|
open = end && end.test(trimmed.slice(2)) ? void 0 : end;
|
|
1156
1162
|
}
|
|
1157
1163
|
return open !== void 0;
|
|
@@ -2911,6 +2917,7 @@ exports.mapInlineCodeSpans = mapInlineCodeSpans;
|
|
|
2911
2917
|
exports.mapPosition = mapPosition;
|
|
2912
2918
|
exports.mapRange = mapRange;
|
|
2913
2919
|
exports.normalizeLinkLabel = normalizeLinkLabel;
|
|
2920
|
+
exports.opensStrippedHtmlBlock = opensStrippedHtmlBlock;
|
|
2914
2921
|
exports.opensTable = opensTable;
|
|
2915
2922
|
exports.pairDisplayMath = pairDisplayMath;
|
|
2916
2923
|
exports.parseFenceOpener = parseFenceOpener;
|