@readme/markdown 6.48.1 → 6.48.2
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/main.js +6 -6
- package/dist/main.node.js +6 -6
- package/package.json +1 -1
package/dist/main.js
CHANGED
|
@@ -29309,12 +29309,8 @@ module.exports.sanitize = function (sanitizeSchema) {
|
|
|
29309
29309
|
/* @note: copied from https://github.com/rehypejs/rehype-minify/blob/main/packages/hast-util-to-string/index.js
|
|
29310
29310
|
*/
|
|
29311
29311
|
function toString(node) {
|
|
29312
|
-
|
|
29313
|
-
|
|
29314
|
-
return all(node);
|
|
29315
|
-
}
|
|
29316
|
-
|
|
29317
|
-
return 'value' in node ? node.value : ' ';
|
|
29312
|
+
// eslint-disable-next-line no-use-before-define
|
|
29313
|
+
return 'children' in node ? all(node) : one(node);
|
|
29318
29314
|
}
|
|
29319
29315
|
|
|
29320
29316
|
function one(node) {
|
|
@@ -29326,6 +29322,10 @@ function one(node) {
|
|
|
29326
29322
|
|
|
29327
29323
|
if (node.type === 'text') {
|
|
29328
29324
|
return node.value;
|
|
29325
|
+
}
|
|
29326
|
+
|
|
29327
|
+
if ('value' in node) {
|
|
29328
|
+
return node.value;
|
|
29329
29329
|
} // eslint-disable-next-line no-use-before-define
|
|
29330
29330
|
|
|
29331
29331
|
|
package/dist/main.node.js
CHANGED
|
@@ -12131,12 +12131,8 @@ module.exports.sanitize = function (sanitizeSchema) {
|
|
|
12131
12131
|
/* @note: copied from https://github.com/rehypejs/rehype-minify/blob/main/packages/hast-util-to-string/index.js
|
|
12132
12132
|
*/
|
|
12133
12133
|
function toString(node) {
|
|
12134
|
-
|
|
12135
|
-
|
|
12136
|
-
return all(node);
|
|
12137
|
-
}
|
|
12138
|
-
|
|
12139
|
-
return 'value' in node ? node.value : ' ';
|
|
12134
|
+
// eslint-disable-next-line no-use-before-define
|
|
12135
|
+
return 'children' in node ? all(node) : one(node);
|
|
12140
12136
|
}
|
|
12141
12137
|
|
|
12142
12138
|
function one(node) {
|
|
@@ -12148,6 +12144,10 @@ function one(node) {
|
|
|
12148
12144
|
|
|
12149
12145
|
if (node.type === 'text') {
|
|
12150
12146
|
return node.value;
|
|
12147
|
+
}
|
|
12148
|
+
|
|
12149
|
+
if ('value' in node) {
|
|
12150
|
+
return node.value;
|
|
12151
12151
|
} // eslint-disable-next-line no-use-before-define
|
|
12152
12152
|
|
|
12153
12153
|
|
package/package.json
CHANGED