node_modules: upgrade

This commit is contained in:
Dawid Dziurla
2024-01-17 10:08:10 +01:00
parent 9ff0bc8d99
commit 00765f79cf
320 changed files with 31840 additions and 1039 deletions

View File

@@ -1,5 +1,5 @@
import { Collection } from '../nodes/Collection.js';
import { isNode, isPair } from '../nodes/Node.js';
import { isNode, isPair } from '../nodes/identity.js';
import { stringify } from './stringify.js';
import { lineComment, indentComment } from './stringifyComment.js';
@@ -60,7 +60,7 @@ function stringifyBlockCollection({ comment, items }, ctx, { blockItemPrefix, fl
return str;
}
function stringifyFlowCollection({ comment, items }, ctx, { flowChars, itemIndent, onComment }) {
const { indent, indentStep, options: { commentString } } = ctx;
const { indent, indentStep, flowCollectionPadding: fcPadding, options: { commentString } } = ctx;
itemIndent += indentStep;
const itemCtx = Object.assign({}, ctx, {
indent: itemIndent,
@@ -96,7 +96,7 @@ function stringifyFlowCollection({ comment, items }, ctx, { flowChars, itemInden
if (iv.commentBefore)
reqNewline = true;
}
else if (item.value == null && ik && ik.comment) {
else if (item.value == null && ik?.comment) {
comment = ik.comment;
}
}
@@ -129,11 +129,11 @@ function stringifyFlowCollection({ comment, items }, ctx, { flowChars, itemInden
str += `\n${indent}${end}`;
}
else {
str = `${start} ${lines.join(' ')} ${end}`;
str = `${start}${fcPadding}${lines.join(' ')}${fcPadding}${end}`;
}
}
if (comment) {
str += lineComment(str, commentString(comment), indent);
str += lineComment(str, indent, commentString(comment));
if (onComment)
onComment();
}