3
0
Fork 0
mirror of https://github.com/tj-actions/changed-files synced 2025-03-07 09:27:23 +00:00

Added missing changes and modified dist assets.

This commit is contained in:
GitHub Action 2024-07-24 13:08:27 +00:00 committed by renovate[bot]
parent 28fd03b28d
commit 10471793b2
2 changed files with 25 additions and 16 deletions

39
dist/index.js generated vendored
View file

@ -62987,10 +62987,23 @@ function resolveCollection(CN, ctx, token, onError, tagName, tag) {
coll.tag = tagName; coll.tag = tagName;
return coll; return coll;
} }
function composeCollection(CN, ctx, token, tagToken, onError) { function composeCollection(CN, ctx, token, props, onError) {
const tagToken = props.tag;
const tagName = !tagToken const tagName = !tagToken
? null ? null
: ctx.directives.tagName(tagToken.source, msg => onError(tagToken, 'TAG_RESOLVE_FAILED', msg)); : ctx.directives.tagName(tagToken.source, msg => onError(tagToken, 'TAG_RESOLVE_FAILED', msg));
if (token.type === 'block-seq') {
const { anchor, newlineAfterProp: nl } = props;
const lastProp = anchor && tagToken
? anchor.offset > tagToken.offset
? anchor
: tagToken
: (anchor ?? tagToken);
if (lastProp && (!nl || nl.offset < lastProp.offset)) {
const message = 'Missing newline after block sequence props';
onError(lastProp, 'MISSING_CHAR', message);
}
}
const expType = token.type === 'block-map' const expType = token.type === 'block-map'
? 'map' ? 'map'
: token.type === 'block-seq' : token.type === 'block-seq'
@ -63004,8 +63017,7 @@ function composeCollection(CN, ctx, token, tagToken, onError) {
!tagName || !tagName ||
tagName === '!' || tagName === '!' ||
(tagName === YAMLMap.YAMLMap.tagName && expType === 'map') || (tagName === YAMLMap.YAMLMap.tagName && expType === 'map') ||
(tagName === YAMLSeq.YAMLSeq.tagName && expType === 'seq') || (tagName === YAMLSeq.YAMLSeq.tagName && expType === 'seq')) {
!expType) {
return resolveCollection(CN, ctx, token, onError, tagName); return resolveCollection(CN, ctx, token, onError, tagName);
} }
let tag = ctx.schema.tags.find(t => t.tag === tagName && t.collection === expType); let tag = ctx.schema.tags.find(t => t.tag === tagName && t.collection === expType);
@ -63128,7 +63140,7 @@ function composeNode(ctx, token, props, onError) {
case 'block-map': case 'block-map':
case 'block-seq': case 'block-seq':
case 'flow-collection': case 'flow-collection':
node = composeCollection.composeCollection(CN, ctx, token, tag, onError); node = composeCollection.composeCollection(CN, ctx, token, props, onError);
if (anchor) if (anchor)
node.anchor = anchor.source.substring(1); node.anchor = anchor.source.substring(1);
break; break;
@ -63566,7 +63578,7 @@ function resolveBlockMap({ composeNode, composeEmptyNode }, ctx, bm, onError, ta
} }
continue; continue;
} }
if (keyProps.hasNewlineAfterProp || utilContainsNewline.containsNewline(key)) { if (keyProps.newlineAfterProp || utilContainsNewline.containsNewline(key)) {
onError(key ?? start[start.length - 1], 'MULTILINE_IMPLICIT_KEY', 'Implicit keys need to be on a single line'); onError(key ?? start[start.length - 1], 'MULTILINE_IMPLICIT_KEY', 'Implicit keys need to be on a single line');
} }
} }
@ -64408,11 +64420,11 @@ function resolveProps(tokens, { flow, indicator, next, offset, onError, parentIn
let comment = ''; let comment = '';
let commentSep = ''; let commentSep = '';
let hasNewline = false; let hasNewline = false;
let hasNewlineAfterProp = false;
let reqSpace = false; let reqSpace = false;
let tab = null; let tab = null;
let anchor = null; let anchor = null;
let tag = null; let tag = null;
let newlineAfterProp = null;
let comma = null; let comma = null;
let found = null; let found = null;
let start = null; let start = null;
@ -64466,7 +64478,7 @@ function resolveProps(tokens, { flow, indicator, next, offset, onError, parentIn
atNewline = true; atNewline = true;
hasNewline = true; hasNewline = true;
if (anchor || tag) if (anchor || tag)
hasNewlineAfterProp = true; newlineAfterProp = token;
hasSpace = true; hasSpace = true;
break; break;
case 'anchor': case 'anchor':
@ -64540,9 +64552,9 @@ function resolveProps(tokens, { flow, indicator, next, offset, onError, parentIn
spaceBefore, spaceBefore,
comment, comment,
hasNewline, hasNewline,
hasNewlineAfterProp,
anchor, anchor,
tag, tag,
newlineAfterProp,
end, end,
start: start ?? end start: start ?? end
}; };
@ -65881,7 +65893,6 @@ class Collection extends Node.NodeBase {
} }
} }
} }
Collection.maxFlowStringSingleLineLength = 60;
exports.Collection = Collection; exports.Collection = Collection;
exports.collectionFromPath = collectionFromPath; exports.collectionFromPath = collectionFromPath;
@ -67342,15 +67353,11 @@ class Lexer {
if (!this.atEnd && !this.hasChars(4)) if (!this.atEnd && !this.hasChars(4))
return this.setNext('line-start'); return this.setNext('line-start');
const s = this.peek(3); const s = this.peek(3);
if (s === '---' && isEmpty(this.charAt(3))) { if ((s === '---' || s === '...') && isEmpty(this.charAt(3))) {
yield* this.pushCount(3); yield* this.pushCount(3);
this.indentValue = 0; this.indentValue = 0;
this.indentNext = 0; this.indentNext = 0;
return 'doc'; return s === '---' ? 'doc' : 'stream';
}
else if (s === '...' && isEmpty(this.charAt(3))) {
yield* this.pushCount(3);
return 'stream';
} }
} }
this.indentValue = yield* this.pushSpaces(false); this.indentValue = yield* this.pushSpaces(false);
@ -70095,6 +70102,8 @@ const FOLD_QUOTED = 'quoted';
function foldFlowLines(text, indent, mode = 'flow', { indentAtStart, lineWidth = 80, minContentWidth = 20, onFold, onOverflow } = {}) { function foldFlowLines(text, indent, mode = 'flow', { indentAtStart, lineWidth = 80, minContentWidth = 20, onFold, onOverflow } = {}) {
if (!lineWidth || lineWidth < 0) if (!lineWidth || lineWidth < 0)
return text; return text;
if (lineWidth < minContentWidth)
minContentWidth = 0;
const endStep = Math.max(1 + minContentWidth, 1 + lineWidth - indent.length); const endStep = Math.max(1 + minContentWidth, 1 + lineWidth - indent.length);
if (text.length <= endStep) if (text.length <= endStep)
return text; return text;

2
dist/index.js.map generated vendored

File diff suppressed because one or more lines are too long