@utsu-ri/cli 0.3.4 → 0.3.6
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/README.md +17 -11
- package/dist/build-manifest.json +99 -99
- package/dist/sbom.spdx.json +19 -19
- package/dist/third-party-licenses.json +7 -7
- package/dist/utsuri.mjs +621 -214
- package/package.json +6 -6
package/dist/utsuri.mjs
CHANGED
|
@@ -203560,9 +203560,9 @@ var require_png = __commonJS2({
|
|
|
203560
203560
|
}
|
|
203561
203561
|
});
|
|
203562
203562
|
|
|
203563
|
-
// node_modules/.bun/yaml@2.9.
|
|
203563
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/nodes/identity.js
|
|
203564
203564
|
var require_identity = __commonJS2({
|
|
203565
|
-
"node_modules/.bun/yaml@2.9.
|
|
203565
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/nodes/identity.js"(exports2) {
|
|
203566
203566
|
"use strict";
|
|
203567
203567
|
var ALIAS = /* @__PURE__ */ Symbol.for("yaml.alias");
|
|
203568
203568
|
var DOC = /* @__PURE__ */ Symbol.for("yaml.document");
|
|
@@ -203617,9 +203617,9 @@ var require_identity = __commonJS2({
|
|
|
203617
203617
|
}
|
|
203618
203618
|
});
|
|
203619
203619
|
|
|
203620
|
-
// node_modules/.bun/yaml@2.9.
|
|
203620
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/visit.js
|
|
203621
203621
|
var require_visit = __commonJS2({
|
|
203622
|
-
"node_modules/.bun/yaml@2.9.
|
|
203622
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/visit.js"(exports2) {
|
|
203623
203623
|
"use strict";
|
|
203624
203624
|
var identity = require_identity();
|
|
203625
203625
|
var BREAK = /* @__PURE__ */ Symbol("break visit");
|
|
@@ -203775,9 +203775,9 @@ var require_visit = __commonJS2({
|
|
|
203775
203775
|
}
|
|
203776
203776
|
});
|
|
203777
203777
|
|
|
203778
|
-
// node_modules/.bun/yaml@2.9.
|
|
203778
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/doc/directives.js
|
|
203779
203779
|
var require_directives = __commonJS2({
|
|
203780
|
-
"node_modules/.bun/yaml@2.9.
|
|
203780
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/doc/directives.js"(exports2) {
|
|
203781
203781
|
"use strict";
|
|
203782
203782
|
var identity = require_identity();
|
|
203783
203783
|
var visit = require_visit();
|
|
@@ -203946,9 +203946,9 @@ var require_directives = __commonJS2({
|
|
|
203946
203946
|
}
|
|
203947
203947
|
});
|
|
203948
203948
|
|
|
203949
|
-
// node_modules/.bun/yaml@2.9.
|
|
203949
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/doc/anchors.js
|
|
203950
203950
|
var require_anchors = __commonJS2({
|
|
203951
|
-
"node_modules/.bun/yaml@2.9.
|
|
203951
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/doc/anchors.js"(exports2) {
|
|
203952
203952
|
"use strict";
|
|
203953
203953
|
var identity = require_identity();
|
|
203954
203954
|
var visit = require_visit();
|
|
@@ -204016,9 +204016,9 @@ var require_anchors = __commonJS2({
|
|
|
204016
204016
|
}
|
|
204017
204017
|
});
|
|
204018
204018
|
|
|
204019
|
-
// node_modules/.bun/yaml@2.9.
|
|
204019
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/doc/applyReviver.js
|
|
204020
204020
|
var require_applyReviver = __commonJS2({
|
|
204021
|
-
"node_modules/.bun/yaml@2.9.
|
|
204021
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/doc/applyReviver.js"(exports2) {
|
|
204022
204022
|
"use strict";
|
|
204023
204023
|
function applyReviver(reviver, obj, key, val) {
|
|
204024
204024
|
if (val && typeof val === "object") {
|
|
@@ -204066,9 +204066,9 @@ var require_applyReviver = __commonJS2({
|
|
|
204066
204066
|
}
|
|
204067
204067
|
});
|
|
204068
204068
|
|
|
204069
|
-
// node_modules/.bun/yaml@2.9.
|
|
204069
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/nodes/toJS.js
|
|
204070
204070
|
var require_toJS = __commonJS2({
|
|
204071
|
-
"node_modules/.bun/yaml@2.9.
|
|
204071
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/nodes/toJS.js"(exports2) {
|
|
204072
204072
|
"use strict";
|
|
204073
204073
|
var identity = require_identity();
|
|
204074
204074
|
function toJS(value2, arg, ctx) {
|
|
@@ -204096,9 +204096,9 @@ var require_toJS = __commonJS2({
|
|
|
204096
204096
|
}
|
|
204097
204097
|
});
|
|
204098
204098
|
|
|
204099
|
-
// node_modules/.bun/yaml@2.9.
|
|
204099
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/nodes/Node.js
|
|
204100
204100
|
var require_Node = __commonJS2({
|
|
204101
|
-
"node_modules/.bun/yaml@2.9.
|
|
204101
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/nodes/Node.js"(exports2) {
|
|
204102
204102
|
"use strict";
|
|
204103
204103
|
var applyReviver = require_applyReviver();
|
|
204104
204104
|
var identity = require_identity();
|
|
@@ -204137,9 +204137,9 @@ var require_Node = __commonJS2({
|
|
|
204137
204137
|
}
|
|
204138
204138
|
});
|
|
204139
204139
|
|
|
204140
|
-
// node_modules/.bun/yaml@2.9.
|
|
204140
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/nodes/Alias.js
|
|
204141
204141
|
var require_Alias = __commonJS2({
|
|
204142
|
-
"node_modules/.bun/yaml@2.9.
|
|
204142
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/nodes/Alias.js"(exports2) {
|
|
204143
204143
|
"use strict";
|
|
204144
204144
|
var anchors = require_anchors();
|
|
204145
204145
|
var visit = require_visit();
|
|
@@ -204184,36 +204184,38 @@ var require_Alias = __commonJS2({
|
|
|
204184
204184
|
if (node.anchor === this.source)
|
|
204185
204185
|
found = node;
|
|
204186
204186
|
}
|
|
204187
|
+
if (found && ctx) {
|
|
204188
|
+
const { anchors: anchors2, doc: doc2, maxAliasCount } = ctx;
|
|
204189
|
+
let data = anchors2.get(found);
|
|
204190
|
+
if (!data) {
|
|
204191
|
+
toJS.toJS(found, null, ctx);
|
|
204192
|
+
data = anchors2.get(found);
|
|
204193
|
+
}
|
|
204194
|
+
if (data?.res === void 0) {
|
|
204195
|
+
const msg = "This should not happen: Alias anchor was not resolved?";
|
|
204196
|
+
throw new ReferenceError(msg);
|
|
204197
|
+
}
|
|
204198
|
+
if (maxAliasCount >= 0) {
|
|
204199
|
+
data.count += 1;
|
|
204200
|
+
if (data.aliasCount === 0)
|
|
204201
|
+
data.aliasCount = getAliasCount(doc2, found, anchors2);
|
|
204202
|
+
if (data.count * data.aliasCount > maxAliasCount) {
|
|
204203
|
+
const msg = "Excessive alias count indicates a resource exhaustion attack";
|
|
204204
|
+
throw new ReferenceError(msg);
|
|
204205
|
+
}
|
|
204206
|
+
}
|
|
204207
|
+
}
|
|
204187
204208
|
return found;
|
|
204188
204209
|
}
|
|
204189
204210
|
toJSON(_arg, ctx) {
|
|
204190
204211
|
if (!ctx)
|
|
204191
204212
|
return { source: this.source };
|
|
204192
|
-
const
|
|
204193
|
-
const source12 = this.resolve(doc, ctx);
|
|
204213
|
+
const source12 = this.resolve(ctx.doc, ctx);
|
|
204194
204214
|
if (!source12) {
|
|
204195
204215
|
const msg = `Unresolved alias (the anchor must be set before the alias): ${this.source}`;
|
|
204196
204216
|
throw new ReferenceError(msg);
|
|
204197
204217
|
}
|
|
204198
|
-
|
|
204199
|
-
if (!data) {
|
|
204200
|
-
toJS.toJS(source12, null, ctx);
|
|
204201
|
-
data = anchors2.get(source12);
|
|
204202
|
-
}
|
|
204203
|
-
if (data?.res === void 0) {
|
|
204204
|
-
const msg = "This should not happen: Alias anchor was not resolved?";
|
|
204205
|
-
throw new ReferenceError(msg);
|
|
204206
|
-
}
|
|
204207
|
-
if (maxAliasCount >= 0) {
|
|
204208
|
-
data.count += 1;
|
|
204209
|
-
if (data.aliasCount === 0)
|
|
204210
|
-
data.aliasCount = getAliasCount(doc, source12, anchors2);
|
|
204211
|
-
if (data.count * data.aliasCount > maxAliasCount) {
|
|
204212
|
-
const msg = "Excessive alias count indicates a resource exhaustion attack";
|
|
204213
|
-
throw new ReferenceError(msg);
|
|
204214
|
-
}
|
|
204215
|
-
}
|
|
204216
|
-
return data.res;
|
|
204218
|
+
return ctx.anchors.get(source12).res;
|
|
204217
204219
|
}
|
|
204218
204220
|
toString(ctx, _onComment, _onChompKeep) {
|
|
204219
204221
|
const src = `*${this.source}`;
|
|
@@ -204253,9 +204255,9 @@ var require_Alias = __commonJS2({
|
|
|
204253
204255
|
}
|
|
204254
204256
|
});
|
|
204255
204257
|
|
|
204256
|
-
// node_modules/.bun/yaml@2.9.
|
|
204258
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/nodes/Scalar.js
|
|
204257
204259
|
var require_Scalar = __commonJS2({
|
|
204258
|
-
"node_modules/.bun/yaml@2.9.
|
|
204260
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/nodes/Scalar.js"(exports2) {
|
|
204259
204261
|
"use strict";
|
|
204260
204262
|
var identity = require_identity();
|
|
204261
204263
|
var Node2 = require_Node();
|
|
@@ -204283,9 +204285,9 @@ var require_Scalar = __commonJS2({
|
|
|
204283
204285
|
}
|
|
204284
204286
|
});
|
|
204285
204287
|
|
|
204286
|
-
// node_modules/.bun/yaml@2.9.
|
|
204288
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/doc/createNode.js
|
|
204287
204289
|
var require_createNode = __commonJS2({
|
|
204288
|
-
"node_modules/.bun/yaml@2.9.
|
|
204290
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/doc/createNode.js"(exports2) {
|
|
204289
204291
|
"use strict";
|
|
204290
204292
|
var Alias = require_Alias();
|
|
204291
204293
|
var identity = require_identity();
|
|
@@ -204358,9 +204360,9 @@ var require_createNode = __commonJS2({
|
|
|
204358
204360
|
}
|
|
204359
204361
|
});
|
|
204360
204362
|
|
|
204361
|
-
// node_modules/.bun/yaml@2.9.
|
|
204363
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/nodes/Collection.js
|
|
204362
204364
|
var require_Collection = __commonJS2({
|
|
204363
|
-
"node_modules/.bun/yaml@2.9.
|
|
204365
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/nodes/Collection.js"(exports2) {
|
|
204364
204366
|
"use strict";
|
|
204365
204367
|
var createNode = require_createNode();
|
|
204366
204368
|
var identity = require_identity();
|
|
@@ -204501,9 +204503,9 @@ var require_Collection = __commonJS2({
|
|
|
204501
204503
|
}
|
|
204502
204504
|
});
|
|
204503
204505
|
|
|
204504
|
-
// node_modules/.bun/yaml@2.9.
|
|
204506
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/stringify/stringifyComment.js
|
|
204505
204507
|
var require_stringifyComment = __commonJS2({
|
|
204506
|
-
"node_modules/.bun/yaml@2.9.
|
|
204508
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/stringify/stringifyComment.js"(exports2) {
|
|
204507
204509
|
"use strict";
|
|
204508
204510
|
var stringifyComment = (str) => str.replace(/^(?!$)(?: $)?/gm, "#");
|
|
204509
204511
|
function indentComment(comment, indent2) {
|
|
@@ -204518,9 +204520,9 @@ var require_stringifyComment = __commonJS2({
|
|
|
204518
204520
|
}
|
|
204519
204521
|
});
|
|
204520
204522
|
|
|
204521
|
-
// node_modules/.bun/yaml@2.9.
|
|
204523
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/stringify/foldFlowLines.js
|
|
204522
204524
|
var require_foldFlowLines = __commonJS2({
|
|
204523
|
-
"node_modules/.bun/yaml@2.9.
|
|
204525
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/stringify/foldFlowLines.js"(exports2) {
|
|
204524
204526
|
"use strict";
|
|
204525
204527
|
var FOLD_FLOW = "flow";
|
|
204526
204528
|
var FOLD_BLOCK = "block";
|
|
@@ -204654,9 +204656,9 @@ ${indent2}${text2.slice(fold + 1, end2)}`;
|
|
|
204654
204656
|
}
|
|
204655
204657
|
});
|
|
204656
204658
|
|
|
204657
|
-
// node_modules/.bun/yaml@2.9.
|
|
204659
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/stringify/stringifyString.js
|
|
204658
204660
|
var require_stringifyString = __commonJS2({
|
|
204659
|
-
"node_modules/.bun/yaml@2.9.
|
|
204661
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/stringify/stringifyString.js"(exports2) {
|
|
204660
204662
|
"use strict";
|
|
204661
204663
|
var Scalar = require_Scalar();
|
|
204662
204664
|
var foldFlowLines = require_foldFlowLines();
|
|
@@ -204937,9 +204939,9 @@ ${indent2}`);
|
|
|
204937
204939
|
}
|
|
204938
204940
|
});
|
|
204939
204941
|
|
|
204940
|
-
// node_modules/.bun/yaml@2.9.
|
|
204942
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/stringify/stringify.js
|
|
204941
204943
|
var require_stringify = __commonJS2({
|
|
204942
|
-
"node_modules/.bun/yaml@2.9.
|
|
204944
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/stringify/stringify.js"(exports2) {
|
|
204943
204945
|
"use strict";
|
|
204944
204946
|
var anchors = require_anchors();
|
|
204945
204947
|
var identity = require_identity();
|
|
@@ -205061,9 +205063,9 @@ ${ctx.indent}${str}`;
|
|
|
205061
205063
|
}
|
|
205062
205064
|
});
|
|
205063
205065
|
|
|
205064
|
-
// node_modules/.bun/yaml@2.9.
|
|
205066
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/stringify/stringifyPair.js
|
|
205065
205067
|
var require_stringifyPair = __commonJS2({
|
|
205066
|
-
"node_modules/.bun/yaml@2.9.
|
|
205068
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/stringify/stringifyPair.js"(exports2) {
|
|
205067
205069
|
"use strict";
|
|
205068
205070
|
var identity = require_identity();
|
|
205069
205071
|
var Scalar = require_Scalar();
|
|
@@ -205194,9 +205196,9 @@ ${ctx.indent}`;
|
|
|
205194
205196
|
}
|
|
205195
205197
|
});
|
|
205196
205198
|
|
|
205197
|
-
// node_modules/.bun/yaml@2.9.
|
|
205199
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/log.js
|
|
205198
205200
|
var require_log = __commonJS2({
|
|
205199
|
-
"node_modules/.bun/yaml@2.9.
|
|
205201
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/log.js"(exports2) {
|
|
205200
205202
|
"use strict";
|
|
205201
205203
|
var node_process = __require("process");
|
|
205202
205204
|
function debug17(logLevel, ...messages) {
|
|
@@ -205216,9 +205218,9 @@ var require_log = __commonJS2({
|
|
|
205216
205218
|
}
|
|
205217
205219
|
});
|
|
205218
205220
|
|
|
205219
|
-
// node_modules/.bun/yaml@2.9.
|
|
205221
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/yaml-1.1/merge.js
|
|
205220
205222
|
var require_merge = __commonJS2({
|
|
205221
|
-
"node_modules/.bun/yaml@2.9.
|
|
205223
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/yaml-1.1/merge.js"(exports2) {
|
|
205222
205224
|
"use strict";
|
|
205223
205225
|
var identity = require_identity();
|
|
205224
205226
|
var Scalar = require_Scalar();
|
|
@@ -205276,9 +205278,9 @@ var require_merge = __commonJS2({
|
|
|
205276
205278
|
}
|
|
205277
205279
|
});
|
|
205278
205280
|
|
|
205279
|
-
// node_modules/.bun/yaml@2.9.
|
|
205281
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/nodes/addPairToJSMap.js
|
|
205280
205282
|
var require_addPairToJSMap = __commonJS2({
|
|
205281
|
-
"node_modules/.bun/yaml@2.9.
|
|
205283
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/nodes/addPairToJSMap.js"(exports2) {
|
|
205282
205284
|
"use strict";
|
|
205283
205285
|
var log2 = require_log();
|
|
205284
205286
|
var merge2 = require_merge();
|
|
@@ -205340,9 +205342,9 @@ var require_addPairToJSMap = __commonJS2({
|
|
|
205340
205342
|
}
|
|
205341
205343
|
});
|
|
205342
205344
|
|
|
205343
|
-
// node_modules/.bun/yaml@2.9.
|
|
205345
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/nodes/Pair.js
|
|
205344
205346
|
var require_Pair = __commonJS2({
|
|
205345
|
-
"node_modules/.bun/yaml@2.9.
|
|
205347
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/nodes/Pair.js"(exports2) {
|
|
205346
205348
|
"use strict";
|
|
205347
205349
|
var createNode = require_createNode();
|
|
205348
205350
|
var stringifyPair = require_stringifyPair();
|
|
@@ -205380,9 +205382,9 @@ var require_Pair = __commonJS2({
|
|
|
205380
205382
|
}
|
|
205381
205383
|
});
|
|
205382
205384
|
|
|
205383
|
-
// node_modules/.bun/yaml@2.9.
|
|
205385
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/stringify/stringifyCollection.js
|
|
205384
205386
|
var require_stringifyCollection = __commonJS2({
|
|
205385
|
-
"node_modules/.bun/yaml@2.9.
|
|
205387
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/stringify/stringifyCollection.js"(exports2) {
|
|
205386
205388
|
"use strict";
|
|
205387
205389
|
var identity = require_identity();
|
|
205388
205390
|
var stringify2 = require_stringify();
|
|
@@ -205531,9 +205533,9 @@ ${indent2}${end}`;
|
|
|
205531
205533
|
}
|
|
205532
205534
|
});
|
|
205533
205535
|
|
|
205534
|
-
// node_modules/.bun/yaml@2.9.
|
|
205536
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/nodes/YAMLMap.js
|
|
205535
205537
|
var require_YAMLMap = __commonJS2({
|
|
205536
|
-
"node_modules/.bun/yaml@2.9.
|
|
205538
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/nodes/YAMLMap.js"(exports2) {
|
|
205537
205539
|
"use strict";
|
|
205538
205540
|
var stringifyCollection = require_stringifyCollection();
|
|
205539
205541
|
var addPairToJSMap = require_addPairToJSMap();
|
|
@@ -205675,9 +205677,9 @@ var require_YAMLMap = __commonJS2({
|
|
|
205675
205677
|
}
|
|
205676
205678
|
});
|
|
205677
205679
|
|
|
205678
|
-
// node_modules/.bun/yaml@2.9.
|
|
205680
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/common/map.js
|
|
205679
205681
|
var require_map = __commonJS2({
|
|
205680
|
-
"node_modules/.bun/yaml@2.9.
|
|
205682
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/common/map.js"(exports2) {
|
|
205681
205683
|
"use strict";
|
|
205682
205684
|
var identity = require_identity();
|
|
205683
205685
|
var YAMLMap = require_YAMLMap();
|
|
@@ -205697,9 +205699,9 @@ var require_map = __commonJS2({
|
|
|
205697
205699
|
}
|
|
205698
205700
|
});
|
|
205699
205701
|
|
|
205700
|
-
// node_modules/.bun/yaml@2.9.
|
|
205702
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/nodes/YAMLSeq.js
|
|
205701
205703
|
var require_YAMLSeq = __commonJS2({
|
|
205702
|
-
"node_modules/.bun/yaml@2.9.
|
|
205704
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/nodes/YAMLSeq.js"(exports2) {
|
|
205703
205705
|
"use strict";
|
|
205704
205706
|
var createNode = require_createNode();
|
|
205705
205707
|
var stringifyCollection = require_stringifyCollection();
|
|
@@ -205813,9 +205815,9 @@ var require_YAMLSeq = __commonJS2({
|
|
|
205813
205815
|
}
|
|
205814
205816
|
});
|
|
205815
205817
|
|
|
205816
|
-
// node_modules/.bun/yaml@2.9.
|
|
205818
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/common/seq.js
|
|
205817
205819
|
var require_seq = __commonJS2({
|
|
205818
|
-
"node_modules/.bun/yaml@2.9.
|
|
205820
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/common/seq.js"(exports2) {
|
|
205819
205821
|
"use strict";
|
|
205820
205822
|
var identity = require_identity();
|
|
205821
205823
|
var YAMLSeq = require_YAMLSeq();
|
|
@@ -205835,9 +205837,9 @@ var require_seq = __commonJS2({
|
|
|
205835
205837
|
}
|
|
205836
205838
|
});
|
|
205837
205839
|
|
|
205838
|
-
// node_modules/.bun/yaml@2.9.
|
|
205840
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/common/string.js
|
|
205839
205841
|
var require_string = __commonJS2({
|
|
205840
|
-
"node_modules/.bun/yaml@2.9.
|
|
205842
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/common/string.js"(exports2) {
|
|
205841
205843
|
"use strict";
|
|
205842
205844
|
var stringifyString = require_stringifyString();
|
|
205843
205845
|
var string = {
|
|
@@ -205854,9 +205856,9 @@ var require_string = __commonJS2({
|
|
|
205854
205856
|
}
|
|
205855
205857
|
});
|
|
205856
205858
|
|
|
205857
|
-
// node_modules/.bun/yaml@2.9.
|
|
205859
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/common/null.js
|
|
205858
205860
|
var require_null = __commonJS2({
|
|
205859
|
-
"node_modules/.bun/yaml@2.9.
|
|
205861
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/common/null.js"(exports2) {
|
|
205860
205862
|
"use strict";
|
|
205861
205863
|
var Scalar = require_Scalar();
|
|
205862
205864
|
var nullTag = {
|
|
@@ -205872,9 +205874,9 @@ var require_null = __commonJS2({
|
|
|
205872
205874
|
}
|
|
205873
205875
|
});
|
|
205874
205876
|
|
|
205875
|
-
// node_modules/.bun/yaml@2.9.
|
|
205877
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/core/bool.js
|
|
205876
205878
|
var require_bool = __commonJS2({
|
|
205877
|
-
"node_modules/.bun/yaml@2.9.
|
|
205879
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/core/bool.js"(exports2) {
|
|
205878
205880
|
"use strict";
|
|
205879
205881
|
var Scalar = require_Scalar();
|
|
205880
205882
|
var boolTag = {
|
|
@@ -205896,9 +205898,9 @@ var require_bool = __commonJS2({
|
|
|
205896
205898
|
}
|
|
205897
205899
|
});
|
|
205898
205900
|
|
|
205899
|
-
// node_modules/.bun/yaml@2.9.
|
|
205901
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/stringify/stringifyNumber.js
|
|
205900
205902
|
var require_stringifyNumber = __commonJS2({
|
|
205901
|
-
"node_modules/.bun/yaml@2.9.
|
|
205903
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/stringify/stringifyNumber.js"(exports2) {
|
|
205902
205904
|
"use strict";
|
|
205903
205905
|
function stringifyNumber({ format, minFractionDigits, tag, value: value2 }) {
|
|
205904
205906
|
if (typeof value2 === "bigint")
|
|
@@ -205923,9 +205925,9 @@ var require_stringifyNumber = __commonJS2({
|
|
|
205923
205925
|
}
|
|
205924
205926
|
});
|
|
205925
205927
|
|
|
205926
|
-
// node_modules/.bun/yaml@2.9.
|
|
205928
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/core/float.js
|
|
205927
205929
|
var require_float = __commonJS2({
|
|
205928
|
-
"node_modules/.bun/yaml@2.9.
|
|
205930
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/core/float.js"(exports2) {
|
|
205929
205931
|
"use strict";
|
|
205930
205932
|
var Scalar = require_Scalar();
|
|
205931
205933
|
var stringifyNumber = require_stringifyNumber();
|
|
@@ -205969,9 +205971,9 @@ var require_float = __commonJS2({
|
|
|
205969
205971
|
}
|
|
205970
205972
|
});
|
|
205971
205973
|
|
|
205972
|
-
// node_modules/.bun/yaml@2.9.
|
|
205974
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/core/int.js
|
|
205973
205975
|
var require_int = __commonJS2({
|
|
205974
|
-
"node_modules/.bun/yaml@2.9.
|
|
205976
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/core/int.js"(exports2) {
|
|
205975
205977
|
"use strict";
|
|
205976
205978
|
var stringifyNumber = require_stringifyNumber();
|
|
205977
205979
|
var intIdentify = (value2) => typeof value2 === "bigint" || Number.isInteger(value2);
|
|
@@ -206014,9 +206016,9 @@ var require_int = __commonJS2({
|
|
|
206014
206016
|
}
|
|
206015
206017
|
});
|
|
206016
206018
|
|
|
206017
|
-
// node_modules/.bun/yaml@2.9.
|
|
206019
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/core/schema.js
|
|
206018
206020
|
var require_schema = __commonJS2({
|
|
206019
|
-
"node_modules/.bun/yaml@2.9.
|
|
206021
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/core/schema.js"(exports2) {
|
|
206020
206022
|
"use strict";
|
|
206021
206023
|
var map = require_map();
|
|
206022
206024
|
var _null = require_null();
|
|
@@ -206042,9 +206044,9 @@ var require_schema = __commonJS2({
|
|
|
206042
206044
|
}
|
|
206043
206045
|
});
|
|
206044
206046
|
|
|
206045
|
-
// node_modules/.bun/yaml@2.9.
|
|
206047
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/json/schema.js
|
|
206046
206048
|
var require_schema2 = __commonJS2({
|
|
206047
|
-
"node_modules/.bun/yaml@2.9.
|
|
206049
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/json/schema.js"(exports2) {
|
|
206048
206050
|
"use strict";
|
|
206049
206051
|
var Scalar = require_Scalar();
|
|
206050
206052
|
var map = require_map();
|
|
@@ -206109,9 +206111,9 @@ var require_schema2 = __commonJS2({
|
|
|
206109
206111
|
}
|
|
206110
206112
|
});
|
|
206111
206113
|
|
|
206112
|
-
// node_modules/.bun/yaml@2.9.
|
|
206114
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/yaml-1.1/binary.js
|
|
206113
206115
|
var require_binary = __commonJS2({
|
|
206114
|
-
"node_modules/.bun/yaml@2.9.
|
|
206116
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/yaml-1.1/binary.js"(exports2) {
|
|
206115
206117
|
"use strict";
|
|
206116
206118
|
var node_buffer = __require("buffer");
|
|
206117
206119
|
var Scalar = require_Scalar();
|
|
@@ -206175,9 +206177,9 @@ var require_binary = __commonJS2({
|
|
|
206175
206177
|
}
|
|
206176
206178
|
});
|
|
206177
206179
|
|
|
206178
|
-
// node_modules/.bun/yaml@2.9.
|
|
206180
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/yaml-1.1/pairs.js
|
|
206179
206181
|
var require_pairs = __commonJS2({
|
|
206180
|
-
"node_modules/.bun/yaml@2.9.
|
|
206182
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/yaml-1.1/pairs.js"(exports2) {
|
|
206181
206183
|
"use strict";
|
|
206182
206184
|
var identity = require_identity();
|
|
206183
206185
|
var Pair = require_Pair();
|
|
@@ -206253,9 +206255,9 @@ ${cn.comment}` : item.comment;
|
|
|
206253
206255
|
}
|
|
206254
206256
|
});
|
|
206255
206257
|
|
|
206256
|
-
// node_modules/.bun/yaml@2.9.
|
|
206258
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/yaml-1.1/omap.js
|
|
206257
206259
|
var require_omap = __commonJS2({
|
|
206258
|
-
"node_modules/.bun/yaml@2.9.
|
|
206260
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/yaml-1.1/omap.js"(exports2) {
|
|
206259
206261
|
"use strict";
|
|
206260
206262
|
var identity = require_identity();
|
|
206261
206263
|
var toJS = require_toJS();
|
|
@@ -206331,9 +206333,9 @@ var require_omap = __commonJS2({
|
|
|
206331
206333
|
}
|
|
206332
206334
|
});
|
|
206333
206335
|
|
|
206334
|
-
// node_modules/.bun/yaml@2.9.
|
|
206336
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/yaml-1.1/bool.js
|
|
206335
206337
|
var require_bool2 = __commonJS2({
|
|
206336
|
-
"node_modules/.bun/yaml@2.9.
|
|
206338
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/yaml-1.1/bool.js"(exports2) {
|
|
206337
206339
|
"use strict";
|
|
206338
206340
|
var Scalar = require_Scalar();
|
|
206339
206341
|
function boolStringify({ value: value2, source: source12 }, ctx) {
|
|
@@ -206363,9 +206365,9 @@ var require_bool2 = __commonJS2({
|
|
|
206363
206365
|
}
|
|
206364
206366
|
});
|
|
206365
206367
|
|
|
206366
|
-
// node_modules/.bun/yaml@2.9.
|
|
206368
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/yaml-1.1/float.js
|
|
206367
206369
|
var require_float2 = __commonJS2({
|
|
206368
|
-
"node_modules/.bun/yaml@2.9.
|
|
206370
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/yaml-1.1/float.js"(exports2) {
|
|
206369
206371
|
"use strict";
|
|
206370
206372
|
var Scalar = require_Scalar();
|
|
206371
206373
|
var stringifyNumber = require_stringifyNumber();
|
|
@@ -206412,9 +206414,9 @@ var require_float2 = __commonJS2({
|
|
|
206412
206414
|
}
|
|
206413
206415
|
});
|
|
206414
206416
|
|
|
206415
|
-
// node_modules/.bun/yaml@2.9.
|
|
206417
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/yaml-1.1/int.js
|
|
206416
206418
|
var require_int2 = __commonJS2({
|
|
206417
|
-
"node_modules/.bun/yaml@2.9.
|
|
206419
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/yaml-1.1/int.js"(exports2) {
|
|
206418
206420
|
"use strict";
|
|
206419
206421
|
var stringifyNumber = require_stringifyNumber();
|
|
206420
206422
|
var intIdentify = (value2) => typeof value2 === "bigint" || Number.isInteger(value2);
|
|
@@ -206491,9 +206493,9 @@ var require_int2 = __commonJS2({
|
|
|
206491
206493
|
}
|
|
206492
206494
|
});
|
|
206493
206495
|
|
|
206494
|
-
// node_modules/.bun/yaml@2.9.
|
|
206496
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/yaml-1.1/set.js
|
|
206495
206497
|
var require_set = __commonJS2({
|
|
206496
|
-
"node_modules/.bun/yaml@2.9.
|
|
206498
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/yaml-1.1/set.js"(exports2) {
|
|
206497
206499
|
"use strict";
|
|
206498
206500
|
var identity = require_identity();
|
|
206499
206501
|
var Pair = require_Pair();
|
|
@@ -206580,9 +206582,9 @@ var require_set = __commonJS2({
|
|
|
206580
206582
|
}
|
|
206581
206583
|
});
|
|
206582
206584
|
|
|
206583
|
-
// node_modules/.bun/yaml@2.9.
|
|
206585
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/yaml-1.1/timestamp.js
|
|
206584
206586
|
var require_timestamp = __commonJS2({
|
|
206585
|
-
"node_modules/.bun/yaml@2.9.
|
|
206587
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/yaml-1.1/timestamp.js"(exports2) {
|
|
206586
206588
|
"use strict";
|
|
206587
206589
|
var stringifyNumber = require_stringifyNumber();
|
|
206588
206590
|
function parseSexagesimal(str, asBigInt) {
|
|
@@ -206668,9 +206670,9 @@ var require_timestamp = __commonJS2({
|
|
|
206668
206670
|
}
|
|
206669
206671
|
});
|
|
206670
206672
|
|
|
206671
|
-
// node_modules/.bun/yaml@2.9.
|
|
206673
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/yaml-1.1/schema.js
|
|
206672
206674
|
var require_schema3 = __commonJS2({
|
|
206673
|
-
"node_modules/.bun/yaml@2.9.
|
|
206675
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/yaml-1.1/schema.js"(exports2) {
|
|
206674
206676
|
"use strict";
|
|
206675
206677
|
var map = require_map();
|
|
206676
206678
|
var _null = require_null();
|
|
@@ -206712,9 +206714,9 @@ var require_schema3 = __commonJS2({
|
|
|
206712
206714
|
}
|
|
206713
206715
|
});
|
|
206714
206716
|
|
|
206715
|
-
// node_modules/.bun/yaml@2.9.
|
|
206717
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/tags.js
|
|
206716
206718
|
var require_tags = __commonJS2({
|
|
206717
|
-
"node_modules/.bun/yaml@2.9.
|
|
206719
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/tags.js"(exports2) {
|
|
206718
206720
|
"use strict";
|
|
206719
206721
|
var map = require_map();
|
|
206720
206722
|
var _null = require_null();
|
|
@@ -206806,9 +206808,9 @@ var require_tags = __commonJS2({
|
|
|
206806
206808
|
}
|
|
206807
206809
|
});
|
|
206808
206810
|
|
|
206809
|
-
// node_modules/.bun/yaml@2.9.
|
|
206811
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/Schema.js
|
|
206810
206812
|
var require_Schema = __commonJS2({
|
|
206811
|
-
"node_modules/.bun/yaml@2.9.
|
|
206813
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/schema/Schema.js"(exports2) {
|
|
206812
206814
|
"use strict";
|
|
206813
206815
|
var identity = require_identity();
|
|
206814
206816
|
var map = require_map();
|
|
@@ -206838,9 +206840,9 @@ var require_Schema = __commonJS2({
|
|
|
206838
206840
|
}
|
|
206839
206841
|
});
|
|
206840
206842
|
|
|
206841
|
-
// node_modules/.bun/yaml@2.9.
|
|
206843
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/stringify/stringifyDocument.js
|
|
206842
206844
|
var require_stringifyDocument = __commonJS2({
|
|
206843
|
-
"node_modules/.bun/yaml@2.9.
|
|
206845
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/stringify/stringifyDocument.js"(exports2) {
|
|
206844
206846
|
"use strict";
|
|
206845
206847
|
var identity = require_identity();
|
|
206846
206848
|
var stringify2 = require_stringify();
|
|
@@ -206918,9 +206920,9 @@ var require_stringifyDocument = __commonJS2({
|
|
|
206918
206920
|
}
|
|
206919
206921
|
});
|
|
206920
206922
|
|
|
206921
|
-
// node_modules/.bun/yaml@2.9.
|
|
206923
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/doc/Document.js
|
|
206922
206924
|
var require_Document = __commonJS2({
|
|
206923
|
-
"node_modules/.bun/yaml@2.9.
|
|
206925
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/doc/Document.js"(exports2) {
|
|
206924
206926
|
"use strict";
|
|
206925
206927
|
var Alias = require_Alias();
|
|
206926
206928
|
var Collection = require_Collection();
|
|
@@ -207227,9 +207229,9 @@ var require_Document = __commonJS2({
|
|
|
207227
207229
|
}
|
|
207228
207230
|
});
|
|
207229
207231
|
|
|
207230
|
-
// node_modules/.bun/yaml@2.9.
|
|
207232
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/errors.js
|
|
207231
207233
|
var require_errors2 = __commonJS2({
|
|
207232
|
-
"node_modules/.bun/yaml@2.9.
|
|
207234
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/errors.js"(exports2) {
|
|
207233
207235
|
"use strict";
|
|
207234
207236
|
var YAMLError = class extends Error {
|
|
207235
207237
|
constructor(name, pos, code, message) {
|
|
@@ -207292,9 +207294,9 @@ ${pointer}
|
|
|
207292
207294
|
}
|
|
207293
207295
|
});
|
|
207294
207296
|
|
|
207295
|
-
// node_modules/.bun/yaml@2.9.
|
|
207297
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/resolve-props.js
|
|
207296
207298
|
var require_resolve_props = __commonJS2({
|
|
207297
|
-
"node_modules/.bun/yaml@2.9.
|
|
207299
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/resolve-props.js"(exports2) {
|
|
207298
207300
|
"use strict";
|
|
207299
207301
|
function resolveProps(tokens, { flow, indicator, next, offset, onError, parentIndent, startOnNewline }) {
|
|
207300
207302
|
let spaceBefore = false;
|
|
@@ -207426,9 +207428,9 @@ var require_resolve_props = __commonJS2({
|
|
|
207426
207428
|
}
|
|
207427
207429
|
});
|
|
207428
207430
|
|
|
207429
|
-
// node_modules/.bun/yaml@2.9.
|
|
207431
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/util-contains-newline.js
|
|
207430
207432
|
var require_util_contains_newline = __commonJS2({
|
|
207431
|
-
"node_modules/.bun/yaml@2.9.
|
|
207433
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/util-contains-newline.js"(exports2) {
|
|
207432
207434
|
"use strict";
|
|
207433
207435
|
function containsNewline(key) {
|
|
207434
207436
|
if (!key)
|
|
@@ -207468,9 +207470,9 @@ var require_util_contains_newline = __commonJS2({
|
|
|
207468
207470
|
}
|
|
207469
207471
|
});
|
|
207470
207472
|
|
|
207471
|
-
// node_modules/.bun/yaml@2.9.
|
|
207473
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/util-flow-indent-check.js
|
|
207472
207474
|
var require_util_flow_indent_check = __commonJS2({
|
|
207473
|
-
"node_modules/.bun/yaml@2.9.
|
|
207475
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/util-flow-indent-check.js"(exports2) {
|
|
207474
207476
|
"use strict";
|
|
207475
207477
|
var utilContainsNewline = require_util_contains_newline();
|
|
207476
207478
|
function flowIndentCheck(indent2, fc, onError) {
|
|
@@ -207486,9 +207488,9 @@ var require_util_flow_indent_check = __commonJS2({
|
|
|
207486
207488
|
}
|
|
207487
207489
|
});
|
|
207488
207490
|
|
|
207489
|
-
// node_modules/.bun/yaml@2.9.
|
|
207491
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/util-map-includes.js
|
|
207490
207492
|
var require_util_map_includes = __commonJS2({
|
|
207491
|
-
"node_modules/.bun/yaml@2.9.
|
|
207493
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/util-map-includes.js"(exports2) {
|
|
207492
207494
|
"use strict";
|
|
207493
207495
|
var identity = require_identity();
|
|
207494
207496
|
function mapIncludes(ctx, items, search) {
|
|
@@ -207502,9 +207504,9 @@ var require_util_map_includes = __commonJS2({
|
|
|
207502
207504
|
}
|
|
207503
207505
|
});
|
|
207504
207506
|
|
|
207505
|
-
// node_modules/.bun/yaml@2.9.
|
|
207507
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/resolve-block-map.js
|
|
207506
207508
|
var require_resolve_block_map = __commonJS2({
|
|
207507
|
-
"node_modules/.bun/yaml@2.9.
|
|
207509
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/resolve-block-map.js"(exports2) {
|
|
207508
207510
|
"use strict";
|
|
207509
207511
|
var Pair = require_Pair();
|
|
207510
207512
|
var YAMLMap = require_YAMLMap();
|
|
@@ -207610,9 +207612,9 @@ var require_resolve_block_map = __commonJS2({
|
|
|
207610
207612
|
}
|
|
207611
207613
|
});
|
|
207612
207614
|
|
|
207613
|
-
// node_modules/.bun/yaml@2.9.
|
|
207615
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/resolve-block-seq.js
|
|
207614
207616
|
var require_resolve_block_seq = __commonJS2({
|
|
207615
|
-
"node_modules/.bun/yaml@2.9.
|
|
207617
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/resolve-block-seq.js"(exports2) {
|
|
207616
207618
|
"use strict";
|
|
207617
207619
|
var YAMLSeq = require_YAMLSeq();
|
|
207618
207620
|
var resolveProps = require_resolve_props();
|
|
@@ -207661,9 +207663,9 @@ var require_resolve_block_seq = __commonJS2({
|
|
|
207661
207663
|
}
|
|
207662
207664
|
});
|
|
207663
207665
|
|
|
207664
|
-
// node_modules/.bun/yaml@2.9.
|
|
207666
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/resolve-end.js
|
|
207665
207667
|
var require_resolve_end = __commonJS2({
|
|
207666
|
-
"node_modules/.bun/yaml@2.9.
|
|
207668
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/resolve-end.js"(exports2) {
|
|
207667
207669
|
"use strict";
|
|
207668
207670
|
function resolveEnd(end, offset, reqSpace, onError) {
|
|
207669
207671
|
let comment = "";
|
|
@@ -207704,9 +207706,9 @@ var require_resolve_end = __commonJS2({
|
|
|
207704
207706
|
}
|
|
207705
207707
|
});
|
|
207706
207708
|
|
|
207707
|
-
// node_modules/.bun/yaml@2.9.
|
|
207709
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/resolve-flow-collection.js
|
|
207708
207710
|
var require_resolve_flow_collection = __commonJS2({
|
|
207709
|
-
"node_modules/.bun/yaml@2.9.
|
|
207711
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/resolve-flow-collection.js"(exports2) {
|
|
207710
207712
|
"use strict";
|
|
207711
207713
|
var identity = require_identity();
|
|
207712
207714
|
var Pair = require_Pair();
|
|
@@ -207898,9 +207900,9 @@ var require_resolve_flow_collection = __commonJS2({
|
|
|
207898
207900
|
}
|
|
207899
207901
|
});
|
|
207900
207902
|
|
|
207901
|
-
// node_modules/.bun/yaml@2.9.
|
|
207903
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/compose-collection.js
|
|
207902
207904
|
var require_compose_collection = __commonJS2({
|
|
207903
|
-
"node_modules/.bun/yaml@2.9.
|
|
207905
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/compose-collection.js"(exports2) {
|
|
207904
207906
|
"use strict";
|
|
207905
207907
|
var identity = require_identity();
|
|
207906
207908
|
var Scalar = require_Scalar();
|
|
@@ -207963,9 +207965,9 @@ var require_compose_collection = __commonJS2({
|
|
|
207963
207965
|
}
|
|
207964
207966
|
});
|
|
207965
207967
|
|
|
207966
|
-
// node_modules/.bun/yaml@2.9.
|
|
207968
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/resolve-block-scalar.js
|
|
207967
207969
|
var require_resolve_block_scalar = __commonJS2({
|
|
207968
|
-
"node_modules/.bun/yaml@2.9.
|
|
207970
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/resolve-block-scalar.js"(exports2) {
|
|
207969
207971
|
"use strict";
|
|
207970
207972
|
var Scalar = require_Scalar();
|
|
207971
207973
|
function resolveBlockScalar(ctx, scalar, onError) {
|
|
@@ -208146,9 +208148,9 @@ var require_resolve_block_scalar = __commonJS2({
|
|
|
208146
208148
|
}
|
|
208147
208149
|
});
|
|
208148
208150
|
|
|
208149
|
-
// node_modules/.bun/yaml@2.9.
|
|
208151
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/resolve-flow-scalar.js
|
|
208150
208152
|
var require_resolve_flow_scalar = __commonJS2({
|
|
208151
|
-
"node_modules/.bun/yaml@2.9.
|
|
208153
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/resolve-flow-scalar.js"(exports2) {
|
|
208152
208154
|
"use strict";
|
|
208153
208155
|
var Scalar = require_Scalar();
|
|
208154
208156
|
var resolveEnd = require_resolve_end();
|
|
@@ -208215,37 +208217,38 @@ var require_resolve_flow_scalar = __commonJS2({
|
|
|
208215
208217
|
}
|
|
208216
208218
|
if (badChar)
|
|
208217
208219
|
onError(0, "BAD_SCALAR_START", `Plain value cannot start with ${badChar}`);
|
|
208218
|
-
return
|
|
208220
|
+
return unfoldLines(source12);
|
|
208219
208221
|
}
|
|
208220
208222
|
function singleQuotedValue(source12, onError) {
|
|
208221
208223
|
if (source12[source12.length - 1] !== "'" || source12.length === 1)
|
|
208222
208224
|
onError(source12.length, "MISSING_CHAR", "Missing closing 'quote");
|
|
208223
|
-
return
|
|
208225
|
+
return unfoldLines(source12.slice(1, -1)).replace(/''/g, "'");
|
|
208224
208226
|
}
|
|
208225
|
-
function
|
|
208226
|
-
|
|
208227
|
+
function unfoldLines(source12) {
|
|
208228
|
+
const line = /(.*?)\r?\n/sy;
|
|
208229
|
+
let match = line.exec(source12);
|
|
208230
|
+
if (!match)
|
|
208231
|
+
return source12;
|
|
208232
|
+
let trimEnd, trimBoth;
|
|
208227
208233
|
try {
|
|
208228
|
-
|
|
208229
|
-
|
|
208234
|
+
trimEnd = new RegExp("(?<![ ])[ ]+$");
|
|
208235
|
+
trimBoth = new RegExp("^[ ]+|(?<![ ])[ ]+$", "g");
|
|
208230
208236
|
} catch {
|
|
208231
|
-
|
|
208232
|
-
|
|
208237
|
+
trimEnd = /[ \t]+$/;
|
|
208238
|
+
trimBoth = /^[ \t]+|[ \t]+$/g;
|
|
208233
208239
|
}
|
|
208234
|
-
let
|
|
208235
|
-
if (!match)
|
|
208236
|
-
return source12;
|
|
208237
|
-
let res = match[1];
|
|
208240
|
+
let res = match[1].replace(trimEnd, "");
|
|
208238
208241
|
let sep = " ";
|
|
208239
|
-
let pos =
|
|
208240
|
-
line.lastIndex = pos;
|
|
208242
|
+
let pos = line.lastIndex;
|
|
208241
208243
|
while (match = line.exec(source12)) {
|
|
208242
|
-
|
|
208244
|
+
const lm = match[1].replace(trimBoth, "");
|
|
208245
|
+
if (lm === "") {
|
|
208243
208246
|
if (sep === "\n")
|
|
208244
208247
|
res += sep;
|
|
208245
208248
|
else
|
|
208246
208249
|
sep = "\n";
|
|
208247
208250
|
} else {
|
|
208248
|
-
res += sep +
|
|
208251
|
+
res += sep + lm;
|
|
208249
208252
|
sep = " ";
|
|
208250
208253
|
}
|
|
208251
208254
|
pos = line.lastIndex;
|
|
@@ -208366,9 +208369,9 @@ var require_resolve_flow_scalar = __commonJS2({
|
|
|
208366
208369
|
}
|
|
208367
208370
|
});
|
|
208368
208371
|
|
|
208369
|
-
// node_modules/.bun/yaml@2.9.
|
|
208372
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/compose-scalar.js
|
|
208370
208373
|
var require_compose_scalar = __commonJS2({
|
|
208371
|
-
"node_modules/.bun/yaml@2.9.
|
|
208374
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/compose-scalar.js"(exports2) {
|
|
208372
208375
|
"use strict";
|
|
208373
208376
|
var identity = require_identity();
|
|
208374
208377
|
var Scalar = require_Scalar();
|
|
@@ -208447,9 +208450,9 @@ var require_compose_scalar = __commonJS2({
|
|
|
208447
208450
|
}
|
|
208448
208451
|
});
|
|
208449
208452
|
|
|
208450
|
-
// node_modules/.bun/yaml@2.9.
|
|
208453
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/util-empty-scalar-position.js
|
|
208451
208454
|
var require_util_empty_scalar_position = __commonJS2({
|
|
208452
|
-
"node_modules/.bun/yaml@2.9.
|
|
208455
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/util-empty-scalar-position.js"(exports2) {
|
|
208453
208456
|
"use strict";
|
|
208454
208457
|
function emptyScalarPosition(offset, before, pos) {
|
|
208455
208458
|
if (before) {
|
|
@@ -208477,9 +208480,9 @@ var require_util_empty_scalar_position = __commonJS2({
|
|
|
208477
208480
|
}
|
|
208478
208481
|
});
|
|
208479
208482
|
|
|
208480
|
-
// node_modules/.bun/yaml@2.9.
|
|
208483
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/compose-node.js
|
|
208481
208484
|
var require_compose_node = __commonJS2({
|
|
208482
|
-
"node_modules/.bun/yaml@2.9.
|
|
208485
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/compose-node.js"(exports2) {
|
|
208483
208486
|
"use strict";
|
|
208484
208487
|
var Alias = require_Alias();
|
|
208485
208488
|
var identity = require_identity();
|
|
@@ -208583,9 +208586,9 @@ var require_compose_node = __commonJS2({
|
|
|
208583
208586
|
}
|
|
208584
208587
|
});
|
|
208585
208588
|
|
|
208586
|
-
// node_modules/.bun/yaml@2.9.
|
|
208589
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/compose-doc.js
|
|
208587
208590
|
var require_compose_doc = __commonJS2({
|
|
208588
|
-
"node_modules/.bun/yaml@2.9.
|
|
208591
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/compose-doc.js"(exports2) {
|
|
208589
208592
|
"use strict";
|
|
208590
208593
|
var Document = require_Document();
|
|
208591
208594
|
var composeNode = require_compose_node();
|
|
@@ -208626,9 +208629,9 @@ var require_compose_doc = __commonJS2({
|
|
|
208626
208629
|
}
|
|
208627
208630
|
});
|
|
208628
208631
|
|
|
208629
|
-
// node_modules/.bun/yaml@2.9.
|
|
208632
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/composer.js
|
|
208630
208633
|
var require_composer = __commonJS2({
|
|
208631
|
-
"node_modules/.bun/yaml@2.9.
|
|
208634
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/compose/composer.js"(exports2) {
|
|
208632
208635
|
"use strict";
|
|
208633
208636
|
var node_process = __require("process");
|
|
208634
208637
|
var directives = require_directives();
|
|
@@ -208834,9 +208837,9 @@ ${end.comment}` : end.comment;
|
|
|
208834
208837
|
}
|
|
208835
208838
|
});
|
|
208836
208839
|
|
|
208837
|
-
// node_modules/.bun/yaml@2.9.
|
|
208840
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/parse/cst-scalar.js
|
|
208838
208841
|
var require_cst_scalar = __commonJS2({
|
|
208839
|
-
"node_modules/.bun/yaml@2.9.
|
|
208842
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/parse/cst-scalar.js"(exports2) {
|
|
208840
208843
|
"use strict";
|
|
208841
208844
|
var resolveBlockScalar = require_resolve_block_scalar();
|
|
208842
208845
|
var resolveFlowScalar = require_resolve_flow_scalar();
|
|
@@ -209019,9 +209022,9 @@ var require_cst_scalar = __commonJS2({
|
|
|
209019
209022
|
}
|
|
209020
209023
|
});
|
|
209021
209024
|
|
|
209022
|
-
// node_modules/.bun/yaml@2.9.
|
|
209025
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/parse/cst-stringify.js
|
|
209023
209026
|
var require_cst_stringify = __commonJS2({
|
|
209024
|
-
"node_modules/.bun/yaml@2.9.
|
|
209027
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/parse/cst-stringify.js"(exports2) {
|
|
209025
209028
|
"use strict";
|
|
209026
209029
|
var stringify2 = (cst) => "type" in cst ? stringifyToken(cst) : stringifyItem(cst);
|
|
209027
209030
|
function stringifyToken(token) {
|
|
@@ -209080,9 +209083,9 @@ var require_cst_stringify = __commonJS2({
|
|
|
209080
209083
|
}
|
|
209081
209084
|
});
|
|
209082
209085
|
|
|
209083
|
-
// node_modules/.bun/yaml@2.9.
|
|
209086
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/parse/cst-visit.js
|
|
209084
209087
|
var require_cst_visit = __commonJS2({
|
|
209085
|
-
"node_modules/.bun/yaml@2.9.
|
|
209088
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/parse/cst-visit.js"(exports2) {
|
|
209086
209089
|
"use strict";
|
|
209087
209090
|
var BREAK = /* @__PURE__ */ Symbol("break visit");
|
|
209088
209091
|
var SKIP = /* @__PURE__ */ Symbol("skip children");
|
|
@@ -209142,9 +209145,9 @@ var require_cst_visit = __commonJS2({
|
|
|
209142
209145
|
}
|
|
209143
209146
|
});
|
|
209144
209147
|
|
|
209145
|
-
// node_modules/.bun/yaml@2.9.
|
|
209148
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/parse/cst.js
|
|
209146
209149
|
var require_cst = __commonJS2({
|
|
209147
|
-
"node_modules/.bun/yaml@2.9.
|
|
209150
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/parse/cst.js"(exports2) {
|
|
209148
209151
|
"use strict";
|
|
209149
209152
|
var cstScalar = require_cst_scalar();
|
|
209150
209153
|
var cstStringify = require_cst_stringify();
|
|
@@ -209244,9 +209247,9 @@ var require_cst = __commonJS2({
|
|
|
209244
209247
|
}
|
|
209245
209248
|
});
|
|
209246
209249
|
|
|
209247
|
-
// node_modules/.bun/yaml@2.9.
|
|
209250
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/parse/lexer.js
|
|
209248
209251
|
var require_lexer = __commonJS2({
|
|
209249
|
-
"node_modules/.bun/yaml@2.9.
|
|
209252
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/parse/lexer.js"(exports2) {
|
|
209250
209253
|
"use strict";
|
|
209251
209254
|
var cst = require_cst();
|
|
209252
209255
|
function isEmpty(ch) {
|
|
@@ -209833,9 +209836,9 @@ var require_lexer = __commonJS2({
|
|
|
209833
209836
|
}
|
|
209834
209837
|
});
|
|
209835
209838
|
|
|
209836
|
-
// node_modules/.bun/yaml@2.9.
|
|
209839
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/parse/line-counter.js
|
|
209837
209840
|
var require_line_counter = __commonJS2({
|
|
209838
|
-
"node_modules/.bun/yaml@2.9.
|
|
209841
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/parse/line-counter.js"(exports2) {
|
|
209839
209842
|
"use strict";
|
|
209840
209843
|
var LineCounter = class {
|
|
209841
209844
|
constructor() {
|
|
@@ -209864,9 +209867,9 @@ var require_line_counter = __commonJS2({
|
|
|
209864
209867
|
}
|
|
209865
209868
|
});
|
|
209866
209869
|
|
|
209867
|
-
// node_modules/.bun/yaml@2.9.
|
|
209870
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/parse/parser.js
|
|
209868
209871
|
var require_parser2 = __commonJS2({
|
|
209869
|
-
"node_modules/.bun/yaml@2.9.
|
|
209872
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/parse/parser.js"(exports2) {
|
|
209870
209873
|
"use strict";
|
|
209871
209874
|
var node_process = __require("process");
|
|
209872
209875
|
var cst = require_cst();
|
|
@@ -210738,9 +210741,9 @@ var require_parser2 = __commonJS2({
|
|
|
210738
210741
|
}
|
|
210739
210742
|
});
|
|
210740
210743
|
|
|
210741
|
-
// node_modules/.bun/yaml@2.9.
|
|
210744
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/public-api.js
|
|
210742
210745
|
var require_public_api = __commonJS2({
|
|
210743
|
-
"node_modules/.bun/yaml@2.9.
|
|
210746
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/public-api.js"(exports2) {
|
|
210744
210747
|
"use strict";
|
|
210745
210748
|
var composer = require_composer();
|
|
210746
210749
|
var Document = require_Document();
|
|
@@ -210835,9 +210838,9 @@ var require_public_api = __commonJS2({
|
|
|
210835
210838
|
}
|
|
210836
210839
|
});
|
|
210837
210840
|
|
|
210838
|
-
// node_modules/.bun/yaml@2.9.
|
|
210841
|
+
// node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/index.js
|
|
210839
210842
|
var require_dist2 = __commonJS2({
|
|
210840
|
-
"node_modules/.bun/yaml@2.9.
|
|
210843
|
+
"node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/index.js"(exports2) {
|
|
210841
210844
|
"use strict";
|
|
210842
210845
|
var composer = require_composer();
|
|
210843
210846
|
var Document = require_Document();
|
|
@@ -211330,10 +211333,104 @@ var annotations_schema_default = {
|
|
|
211330
211333
|
maxLength: 35,
|
|
211331
211334
|
pattern: "^[A-Za-z]{2,8}(?:-[A-Za-z0-9]{1,8})*$"
|
|
211332
211335
|
},
|
|
211336
|
+
verificationResults: {
|
|
211337
|
+
type: "array",
|
|
211338
|
+
maxItems: 100,
|
|
211339
|
+
items: {
|
|
211340
|
+
$ref: "#/$defs/verificationResult"
|
|
211341
|
+
}
|
|
211342
|
+
},
|
|
211333
211343
|
overview: { type: "string", minLength: 1, maxLength: 2e3 },
|
|
211334
211344
|
changes: { type: "array", items: { $ref: "#/$defs/semanticChange" } }
|
|
211335
211345
|
},
|
|
211336
211346
|
$defs: {
|
|
211347
|
+
verificationResult: {
|
|
211348
|
+
type: "object",
|
|
211349
|
+
additionalProperties: false,
|
|
211350
|
+
required: [
|
|
211351
|
+
"id",
|
|
211352
|
+
"kind",
|
|
211353
|
+
"environment",
|
|
211354
|
+
"command",
|
|
211355
|
+
"subjectSha",
|
|
211356
|
+
"exitCode",
|
|
211357
|
+
"passedCount",
|
|
211358
|
+
"warnings",
|
|
211359
|
+
"changeRefs",
|
|
211360
|
+
"completedAt"
|
|
211361
|
+
],
|
|
211362
|
+
properties: {
|
|
211363
|
+
id: {
|
|
211364
|
+
type: "string",
|
|
211365
|
+
pattern: "^verification[-:][A-Za-z0-9._:-]+$",
|
|
211366
|
+
maxLength: 128
|
|
211367
|
+
},
|
|
211368
|
+
kind: {
|
|
211369
|
+
enum: ["unit-tests", "typecheck", "lint", "build", "app-e2e", "external-service"]
|
|
211370
|
+
},
|
|
211371
|
+
environment: {
|
|
211372
|
+
type: "string",
|
|
211373
|
+
minLength: 1,
|
|
211374
|
+
maxLength: 500
|
|
211375
|
+
},
|
|
211376
|
+
command: {
|
|
211377
|
+
type: "array",
|
|
211378
|
+
minItems: 1,
|
|
211379
|
+
maxItems: 100,
|
|
211380
|
+
items: {
|
|
211381
|
+
type: "string",
|
|
211382
|
+
maxLength: 2048
|
|
211383
|
+
}
|
|
211384
|
+
},
|
|
211385
|
+
subjectSha: {
|
|
211386
|
+
type: ["string", "null"],
|
|
211387
|
+
pattern: "^(?:[a-f0-9]{40}|[a-f0-9]{64})$"
|
|
211388
|
+
},
|
|
211389
|
+
exitCode: {
|
|
211390
|
+
type: ["integer", "null"],
|
|
211391
|
+
minimum: 0,
|
|
211392
|
+
maximum: 255
|
|
211393
|
+
},
|
|
211394
|
+
passedCount: {
|
|
211395
|
+
type: ["integer", "null"],
|
|
211396
|
+
minimum: 0
|
|
211397
|
+
},
|
|
211398
|
+
warnings: {
|
|
211399
|
+
type: "array",
|
|
211400
|
+
maxItems: 100,
|
|
211401
|
+
items: {
|
|
211402
|
+
type: "string",
|
|
211403
|
+
maxLength: 2e3
|
|
211404
|
+
}
|
|
211405
|
+
},
|
|
211406
|
+
changeRefs: {
|
|
211407
|
+
type: "array",
|
|
211408
|
+
maxItems: 1e3,
|
|
211409
|
+
uniqueItems: true,
|
|
211410
|
+
items: {
|
|
211411
|
+
type: "string",
|
|
211412
|
+
pattern: "^change[-:]"
|
|
211413
|
+
}
|
|
211414
|
+
},
|
|
211415
|
+
completedAt: {
|
|
211416
|
+
type: ["string", "null"],
|
|
211417
|
+
format: "date-time"
|
|
211418
|
+
},
|
|
211419
|
+
logRef: {
|
|
211420
|
+
type: "string",
|
|
211421
|
+
pattern: "^verification/[A-Za-z0-9][A-Za-z0-9._/-]*\\.(?:txt|log|ndjson)$",
|
|
211422
|
+
maxLength: 500
|
|
211423
|
+
},
|
|
211424
|
+
logSha256: {
|
|
211425
|
+
type: "string",
|
|
211426
|
+
pattern: "^[a-f0-9]{64}$"
|
|
211427
|
+
}
|
|
211428
|
+
},
|
|
211429
|
+
dependencies: {
|
|
211430
|
+
logRef: ["logSha256"],
|
|
211431
|
+
logSha256: ["logRef"]
|
|
211432
|
+
}
|
|
211433
|
+
},
|
|
211337
211434
|
semanticChange: {
|
|
211338
211435
|
type: "object",
|
|
211339
211436
|
additionalProperties: false,
|
|
@@ -212695,6 +212792,17 @@ var report_schema_default = {
|
|
|
212695
212792
|
maxLength: 256
|
|
212696
212793
|
},
|
|
212697
212794
|
status: { enum: ["PASS", "CHANGED", "REGRESSION", "INCOMPLETE", "UNCOVERED", "SKIPPED"] },
|
|
212795
|
+
verificationResults: {
|
|
212796
|
+
type: "array",
|
|
212797
|
+
maxItems: 100,
|
|
212798
|
+
items: {
|
|
212799
|
+
$ref: "#/$defs/verificationResult"
|
|
212800
|
+
}
|
|
212801
|
+
},
|
|
212802
|
+
verificationSubjectSha: {
|
|
212803
|
+
type: ["string", "null"],
|
|
212804
|
+
pattern: "^(?:[a-f0-9]{40}|[a-f0-9]{64})$"
|
|
212805
|
+
},
|
|
212698
212806
|
summary: {
|
|
212699
212807
|
type: "object",
|
|
212700
212808
|
additionalProperties: false,
|
|
@@ -212747,6 +212855,101 @@ var report_schema_default = {
|
|
|
212747
212855
|
}
|
|
212748
212856
|
},
|
|
212749
212857
|
$defs: {
|
|
212858
|
+
verificationResult: {
|
|
212859
|
+
type: "object",
|
|
212860
|
+
additionalProperties: false,
|
|
212861
|
+
required: [
|
|
212862
|
+
"id",
|
|
212863
|
+
"kind",
|
|
212864
|
+
"environment",
|
|
212865
|
+
"command",
|
|
212866
|
+
"subjectSha",
|
|
212867
|
+
"exitCode",
|
|
212868
|
+
"passedCount",
|
|
212869
|
+
"warnings",
|
|
212870
|
+
"changeRefs",
|
|
212871
|
+
"completedAt",
|
|
212872
|
+
"provenance",
|
|
212873
|
+
"shaMatch"
|
|
212874
|
+
],
|
|
212875
|
+
properties: {
|
|
212876
|
+
id: {
|
|
212877
|
+
type: "string",
|
|
212878
|
+
pattern: "^verification[-:][A-Za-z0-9._:-]+$",
|
|
212879
|
+
maxLength: 128
|
|
212880
|
+
},
|
|
212881
|
+
kind: {
|
|
212882
|
+
enum: ["unit-tests", "typecheck", "lint", "build", "app-e2e", "external-service"]
|
|
212883
|
+
},
|
|
212884
|
+
environment: {
|
|
212885
|
+
type: "string",
|
|
212886
|
+
minLength: 1,
|
|
212887
|
+
maxLength: 500
|
|
212888
|
+
},
|
|
212889
|
+
command: {
|
|
212890
|
+
type: "array",
|
|
212891
|
+
minItems: 1,
|
|
212892
|
+
maxItems: 100,
|
|
212893
|
+
items: {
|
|
212894
|
+
type: "string",
|
|
212895
|
+
maxLength: 2048
|
|
212896
|
+
}
|
|
212897
|
+
},
|
|
212898
|
+
subjectSha: {
|
|
212899
|
+
type: ["string", "null"],
|
|
212900
|
+
pattern: "^(?:[a-f0-9]{40}|[a-f0-9]{64})$"
|
|
212901
|
+
},
|
|
212902
|
+
exitCode: {
|
|
212903
|
+
type: ["integer", "null"],
|
|
212904
|
+
minimum: 0,
|
|
212905
|
+
maximum: 255
|
|
212906
|
+
},
|
|
212907
|
+
passedCount: {
|
|
212908
|
+
type: ["integer", "null"],
|
|
212909
|
+
minimum: 0
|
|
212910
|
+
},
|
|
212911
|
+
warnings: {
|
|
212912
|
+
type: "array",
|
|
212913
|
+
maxItems: 100,
|
|
212914
|
+
items: {
|
|
212915
|
+
type: "string",
|
|
212916
|
+
maxLength: 2e3
|
|
212917
|
+
}
|
|
212918
|
+
},
|
|
212919
|
+
changeRefs: {
|
|
212920
|
+
type: "array",
|
|
212921
|
+
maxItems: 1e3,
|
|
212922
|
+
uniqueItems: true,
|
|
212923
|
+
items: {
|
|
212924
|
+
type: "string",
|
|
212925
|
+
pattern: "^change[-:]"
|
|
212926
|
+
}
|
|
212927
|
+
},
|
|
212928
|
+
completedAt: {
|
|
212929
|
+
type: ["string", "null"],
|
|
212930
|
+
format: "date-time"
|
|
212931
|
+
},
|
|
212932
|
+
logRef: {
|
|
212933
|
+
type: "string",
|
|
212934
|
+
pattern: "^verification/[A-Za-z0-9][A-Za-z0-9._/-]*\\.(?:txt|log|ndjson)$",
|
|
212935
|
+
maxLength: 500
|
|
212936
|
+
},
|
|
212937
|
+
logSha256: {
|
|
212938
|
+
type: "string",
|
|
212939
|
+
pattern: "^[a-f0-9]{64}$"
|
|
212940
|
+
},
|
|
212941
|
+
provenance: {
|
|
212942
|
+
enum: ["reported", "log-attached"]
|
|
212943
|
+
},
|
|
212944
|
+
shaMatch: {
|
|
212945
|
+
enum: ["match", "mismatch", "unknown"]
|
|
212946
|
+
}
|
|
212947
|
+
},
|
|
212948
|
+
dependencies: {
|
|
212949
|
+
logRef: ["logSha256"],
|
|
212950
|
+
logSha256: ["logRef"]
|
|
212951
|
+
}
|
|
212952
|
+
},
|
|
212750
212953
|
file: {
|
|
212751
212954
|
type: "object",
|
|
212752
212955
|
additionalProperties: false,
|
|
@@ -213374,7 +213577,8 @@ var review_event_schema_default = {
|
|
|
213374
213577
|
"feedback-batch.stored",
|
|
213375
213578
|
"feedback-batch.claimed",
|
|
213376
213579
|
"feedback-batch.released",
|
|
213377
|
-
"feedback-batch.answered"
|
|
213580
|
+
"feedback-batch.answered",
|
|
213581
|
+
"answer-read.changed"
|
|
213378
213582
|
]
|
|
213379
213583
|
},
|
|
213380
213584
|
createdAt: { type: "string", format: "date-time" },
|
|
@@ -213429,6 +213633,7 @@ var review_event_schema_default = {
|
|
|
213429
213633
|
},
|
|
213430
213634
|
itemCount: { type: "integer", minimum: 1, maximum: 20 },
|
|
213431
213635
|
deliveryMode: { enum: ["direct-same-session", "return-to-session", "export-only"] },
|
|
213636
|
+
answerUnread: { type: "boolean" },
|
|
213432
213637
|
originSessionMatched: { type: "boolean" }
|
|
213433
213638
|
},
|
|
213434
213639
|
allOf: [
|
|
@@ -213475,6 +213680,18 @@ var review_event_schema_default = {
|
|
|
213475
213680
|
{
|
|
213476
213681
|
if: { properties: { type: { const: "feedback-batch.answered" } } },
|
|
213477
213682
|
then: { required: ["batchId", "itemIds"] }
|
|
213683
|
+
},
|
|
213684
|
+
{
|
|
213685
|
+
if: {
|
|
213686
|
+
properties: {
|
|
213687
|
+
type: {
|
|
213688
|
+
const: "answer-read.changed"
|
|
213689
|
+
}
|
|
213690
|
+
}
|
|
213691
|
+
},
|
|
213692
|
+
then: {
|
|
213693
|
+
required: ["batchId", "itemIds", "answerUnread"]
|
|
213694
|
+
}
|
|
213478
213695
|
}
|
|
213479
213696
|
],
|
|
213480
213697
|
$defs: {
|
|
@@ -214255,7 +214472,7 @@ var nativeHelperTargets = [
|
|
|
214255
214472
|
"linux-arm64",
|
|
214256
214473
|
"linux-x64"
|
|
214257
214474
|
];
|
|
214258
|
-
var nativeHelperPackageVersion = "0.3.
|
|
214475
|
+
var nativeHelperPackageVersion = "0.3.6";
|
|
214259
214476
|
function currentTarget() {
|
|
214260
214477
|
const value2 = `${process.platform}-${process.arch}`;
|
|
214261
214478
|
return nativeHelperTargets.find((target) => target === value2) ?? null;
|
|
@@ -214656,6 +214873,12 @@ function assertPngBytes(input, options2 = {}) {
|
|
|
214656
214873
|
}
|
|
214657
214874
|
return { width, height };
|
|
214658
214875
|
}
|
|
214876
|
+
function assertVerificationLogReference(reference) {
|
|
214877
|
+
if (!/^verification\/[A-Za-z0-9][A-Za-z0-9._/-]*\.(?:txt|log|ndjson)$/u.test(reference) || reference.split("/").some((segment) => !segment || segment === "." || segment === "..")) {
|
|
214878
|
+
throw new Error(`Verification log reference is unsafe: ${reference}`);
|
|
214879
|
+
}
|
|
214880
|
+
return reference;
|
|
214881
|
+
}
|
|
214659
214882
|
|
|
214660
214883
|
// packages/security/src/index.ts
|
|
214661
214884
|
var shellExecutables = /* @__PURE__ */ new Set(["bash", "cmd", "fish", "powershell", "pwsh", "sh", "zsh"]);
|
|
@@ -220028,8 +220251,8 @@ import { access as access4, lstat as lstat7, mkdir as mkdir5, open as open6, rea
|
|
|
220028
220251
|
import path18 from "node:path";
|
|
220029
220252
|
|
|
220030
220253
|
// packages/report-builder/src/generated-ui-assets.ts
|
|
220031
|
-
var reportUiJavaScript = 'typeof window<"u"&&((window.__svelte??={}).v??=new Set).add("5");let Ts=!1,fc=!1;function mc(){Ts=!0}mc();const vc=1,gc=2,$l=4,yc=8,_c=16,wc=1,bc=2,xt=Symbol("uninitialized"),Pc="http://www.w3.org/1999/xhtml",ql=!1;var yn=Array.isArray,kc=Array.prototype.indexOf,un=Array.prototype.includes,_n=Array.from,Rl=Object.defineProperty,Rs=Object.getOwnPropertyDescriptor,Sl=Object.getOwnPropertyDescriptors,xc=Object.prototype,Ac=Array.prototype,yi=Object.getPrototypeOf,al=Object.isExtensible;const Ic=()=>{};function $c(r){return r()}function si(r){for(var a=0;a<r.length;a++)r[a]()}function El(){var r,a,s=new Promise((d,u)=>{r=d,a=u});return{promise:s,resolve:r,reject:a}}const jt=2,Qa=4,zs=8,Nl=1<<24,Or=16,qr=32,da=64,ni=128,_i=256,Ir=512,gt=1024,yt=2048,$r=4096,Gt=8192,wr=16384,as=32768,pn=1<<25,Xa=65536,cn=1<<17,qc=1<<18,ss=1<<19,Cl=1<<20,Zr=1<<25,Ta=65536,hn=1<<21,Ya=1<<22,_a=1<<23,wa=Symbol("$state"),Ll=Symbol("component"),Rc=Symbol(""),jl=Symbol("attributes"),ii=Symbol("class"),oi=Symbol("style"),li=Symbol("text"),sn=Symbol("form reset"),Ms=new class extends Error{name="StaleReactionError";message="The reaction that called `getAbortSignal()` was re-run or destroyed"};function Sc(){console.warn("https://svelte.dev/e/derived_inert")}function Ec(){console.warn("https://svelte.dev/e/select_multiple_invalid_value")}function Nc(){console.warn("https://svelte.dev/e/svelte_boundary_reset_noop")}function Ol(r){return r===this.v}function Cc(r,a){return r!=r?a==a:r!==a||r!==null&&typeof r=="object"||typeof r=="function"}function Tl(r){return!Cc(r,this.v)}function zl(r){throw new Error("https://svelte.dev/e/lifecycle_outside_component")}function Lc(){throw new Error("https://svelte.dev/e/async_derived_orphan")}function jc(r,a,s){throw new Error("https://svelte.dev/e/each_key_duplicate")}function Oc(r){throw new Error("https://svelte.dev/e/effect_in_teardown")}function Tc(){throw new Error("https://svelte.dev/e/effect_in_unowned_derived")}function zc(r){throw new Error("https://svelte.dev/e/effect_orphan")}function Mc(){throw new Error("https://svelte.dev/e/effect_update_depth_exceeded")}function Vc(){throw new Error("https://svelte.dev/e/state_descriptors_fixed")}function Dc(){throw new Error("https://svelte.dev/e/state_prototype_fixed")}function Fc(){throw new Error("https://svelte.dev/e/state_unsafe_mutation")}function Bc(){throw new Error("https://svelte.dev/e/svelte_boundary_reset_onerror")}let De=null;function es(r){De=r}function Ml(r,a=!1,s){De={p:De,i:!1,c:null,e:null,s:r,x:null,r:de,l:Ts&&!a?{s:null,u:null,$:[]}:null}}function Vl(r){var a=De,s=a.e;if(s!==null){a.e=null;for(var d of s)sd(d)}return a.i=!0,De=a.p,wi(r)}function wi(r={}){return Rl(r,Ll,{value:!0}),r}function Vs(){return!Ts||De!==null&&De.l===null}let Ca=[];function Dl(){var r=Ca;Ca=[],si(r)}function oa(r){if(Ca.length===0&&!Ss){var a=Ca;queueMicrotask(()=>{a===Ca&&Dl()})}Ca.push(r)}function Hc(){for(;Ca.length>0;)Dl()}const Wc=-7169;function Xe(r,a){r.f=r.f&Wc|a}function bi(r){(r.f&Ir)!==0||r.deps===null?Xe(r,gt):Xe(r,$r)}function Fl(r){if(r!==null)for(const a of r)(a.f&jt)===0||(a.f&Ta)===0||(a.f^=Ta,Fl(a.deps))}function Bl(r,a,s){(r.f&yt)!==0?a.add(r):(r.f&$r)!==0&&s.add(r),Fl(r.deps),Xe(r,gt)}let sl=!1;function Zc(){sl||(sl=!0,document.addEventListener("reset",r=>{Promise.resolve().then(()=>{if(!r.defaultPrevented)for(const a of r.target.elements)a[sn]?.()})},{capture:!0}))}function ns(r){var a=ue,s=de;Rr(null),Sr(null);try{return r()}finally{Rr(a),Sr(s)}}function Pi(r,a,s,d=s){r.addEventListener(a,()=>ns(s));const u=r[sn];u?r[sn]=()=>{u(),d(!0)}:r[sn]=()=>d(!0),Zc()}function Uc(r,a,s,d){const u=Vs()?wn:ya;var e=r.filter(w=>!w.settled),n=a.map(u);if(s.length===0&&e.length===0){d(n);return}var l=de,i=Kc(),o=e.length===1?e[0].promise:e.length>1?Promise.all(e.map(w=>w.promise)):null;function h(w){if((l.f&wr)===0){i();try{d([...n,...w])}catch(q){Hr(q,l)}fn()}}var c=Hl();if(s.length===0){o.then(()=>h([])).finally(c);return}function f(){Promise.all(s.map(w=>Jc(w))).then(h).catch(w=>Hr(w,l)).finally(c)}o?o.then(()=>{i(),f(),fn()}):f()}function Kc(){var r=de,a=ue,s=De,d=ie;return function(e=!0){Sr(r),Rr(a),es(s),e&&(r.f&wr)===0&&(d?.activate(),d?.apply())}}function fn(r=!0){Sr(null),Rr(null),es(null),r&&ie?.deactivate()}function Hl(){var r=de,a=r.b,s=ie,d=!!a?.is_rendered();return a?.update_pending_count(1,s),s.increment(d,r),()=>{a?.update_pending_count(-1,s),s.decrement(d,r)}}function wn(r){var a=jt|yt;return de!==null&&(de.f|=ss),{ctx:De,deps:null,effects:null,equals:Ol,f:a,fn:r,reactions:null,rv:0,v:xt,wv:0,parent:de,ac:null}}const xs=Symbol("obsolete");function Jc(r,a,s){let d=de;d===null&&Lc();var u=void 0,e=za(xt),n=!ue,l=new Set;return ph(()=>{var i=de,o=El();u=o.promise;try{Promise.resolve(r()).then(o.resolve,w=>{w!==Ms&&o.reject(w)}).finally(fn)}catch(w){o.reject(w),fn()}var h=ie;if(n){if((i.f&as)!==0)var c=Hl();if(d.b?.is_rendered())h.async_deriveds.get(i)?.reject(xs);else for(const w of l.values())w.reject(xs);l.add(o),h.async_deriveds.set(i,o)}const f=(w,q=void 0)=>{c?.(),l.delete(o),q!==xs&&(h.activate(),q?(e.f|=_a,ts(e,q)):((e.f&_a)!==0&&(e.f^=_a),ts(e,w)),h.deactivate())};o.promise.then(f,w=>f(null,w||"unknown"))}),$i(()=>{for(const i of l)i.reject(xs)}),new Promise(i=>{function o(h){function c(){h===u?i(e):o(u)}h.then(c,c)}o(u)})}function Yc(r){const a=wn(r);return ud(a),a}function ya(r){const a=wn(r);return a.equals=Tl,a}function Gc(r){var a=r.effects;if(a!==null){r.effects=null;for(var s=0;s<a.length;s+=1)pr(a[s])}}function ki(r){var a,s=de,d=r.parent;if(!ka&&d!==null&&r.v!==xt&&(d.f&(wr|Gt))!==0)return Sc(),r.v;Sr(d);try{r.f&=~Ta,Gc(r),a=fd(r)}finally{Sr(s)}return a}function Wl(r){var a=ki(r);if(!r.equals(a)&&(r.wv=cd(),(!ie?.is_fork||r.deps===null)&&(ie!==null?(ie.capture(r,a,!0),di?.capture(r,a,!0)):r.v=a,r.deps===null))){Xe(r,gt);return}ka||(Tr!==null?(Ii()||ie?.is_fork)&&Tr.set(r,a):bi(r))}function Qc(r){if(r.effects!==null)for(const a of r.effects)(a.teardown||a.ac)&&(a.teardown?.(),a.ac!==null&&ns(()=>{a.ac.abort(Ms),a.ac=null}),a.fn!==null&&(a.teardown=Ic),Ls(a,0),Ri(a))}function Zl(r){if(r.effects!==null)for(const a of r.effects)a.teardown&&a.fn!==null&&Ma(a)}let Fn=null,Za=null,ie=null,di=null,Tr=null,ui=null,Ss=!1,Bn=!1,Ja=null,nn=null;var nl=0;let Xc=1;class Pa{id=Xc++;#t=!1;linked=!0;#i=null;#e=null;async_deriveds=new Map;current=new Map;previous=new Map;#l=new Set;#a=new Set;#n=0;#r=new Map;#o=null;#s=[];#m=[];#d=new Set;#u=new Set;#c=new Map;#v=new Set;is_fork=!1;#p=!1;constructor(){Za===null?Fn=Za=this:(Za.#e=this,this.#i=Za),Za=this}#_(){if(this.is_fork)return!0;for(const d of this.#r.keys()){for(var a=d,s=!1;a.parent!==null;){if(this.#c.has(a)){s=!0;break}a=a.parent}if(!s)return!0}return!1}skip_effect(a){this.#c.has(a)||this.#c.set(a,{d:[],m:[]}),this.#v.delete(a)}unskip_effect(a,s=d=>this.schedule(d)){var d=this.#c.get(a);if(d){this.#c.delete(a);for(var u of d.d)Xe(u,yt),s(u);for(u of d.m)Xe(u,$r),s(u)}this.#v.add(a)}#g(){this.#t=!0,nl++>1e3&&(this.#f(),th());for(const i of this.#d)this.#u.delete(i),Xe(i,yt),this.schedule(i);for(const i of this.#u)Xe(i,$r),this.schedule(i);const a=this.#s;this.#s=[],this.apply();var s=Ja=[],d=[],u=nn=[];for(const i of a)try{this.#b(i,s,d)}catch(o){throw Jl(i),this.#_()||this.discard(),o}if(ie=null,u.length>0){var e=Pa.ensure();for(const i of u)e.schedule(i)}if(Ja=null,nn=null,this.#_()){this.#h(d),this.#h(s);for(const[i,o]of this.#c)Kl(i,o);u.length>0&&ie.#g();return}const n=this.#w();if(n){this.#h(d),this.#h(s),n.#P(this);return}this.#d.clear(),this.#u.clear();for(const i of this.#l)i(this);this.#l.clear(),di=this,il(d),il(s),di=null,this.#o?.resolve();var l=ie;if(this.#n===0&&(this.#s.length===0||l!==null)&&this.#f(),this.#s.length>0)if(l!==null){const i=l;i.#s.push(...this.#s.filter(o=>!i.#s.includes(o)))}else l=this;l!==null&&(Ur.clear(),l.#g())}#b(a,s,d){a.f^=gt;for(var u=a.first;u!==null;){var e=u.f,n=(e&(qr|da))!==0,l=n&&(e>)!==0,i=l||(e&Gt)!==0||this.#c.has(u);if(!i&&u.fn!==null){n?u.f^=gt:(e&Qa)!==0?s.push(u):os(u)&&((e&Or)!==0&&this.#u.add(u),Ma(u));var o=u.first;if(o!==null){u=o;continue}}for(;u!==null;){var h=u.next;if(h!==null){u=h;break}u=u.parent}}}#w(){for(var a=this.#i;a!==null;){if(!a.is_fork){for(const[s,[,d]]of this.current)if(a.current.has(s)&&!d)return a}a=a.#i}return null}#P(a){for(const[d,u]of a.current)!this.previous.has(d)&&a.previous.has(d)&&this.previous.set(d,a.previous.get(d)),this.current.set(d,u);for(const[d,u]of a.async_deriveds){const e=this.async_deriveds.get(d);e&&u.promise.then(e.resolve).catch(e.reject)}a.async_deriveds.clear(),this.transfer_effects(a.#d,a.#u);const s=d=>{var u=d.reactions;if(u!==null&&!((d.f&jt)!==0&&(d.f&(yt|$r))===0))for(const l of u){var e=l.f;if((e&jt)!==0)s(l);else{var n=l;e&(Ya|Or)&&!this.async_deriveds.has(n)&&(this.#u.delete(n),Xe(n,yt),this.schedule(n))}}};for(const d of this.current.keys())s(d);this.oncommit(()=>a.discard()),a.#f(),ie=this,this.#g()}#h(a){for(var s=0;s<a.length;s+=1)Bl(a[s],this.#d,this.#u)}capture(a,s,d=!1){a.v!==xt&&!this.previous.has(a)&&this.previous.set(a,a.v),(a.f&_a)===0&&(this.current.set(a,[s,d]),Tr?.set(a,s)),this.is_fork||(a.v=s)}activate(){ie=this}deactivate(){ie=null,Tr=null}flush(){try{Bn=!0,ie=this,this.#g()}finally{nl=0,ui=null,Ja=null,nn=null,Bn=!1,ie=null,Tr=null,Ur.clear()}}discard(){for(const a of this.#a)a(this);this.#a.clear();for(const a of this.async_deriveds.values())a.reject(xs);this.#f(),this.#o?.resolve()}register_created_effect(a){this.#m.push(a)}#y(){for(let c=Fn;c!==null;c=c.#e){var a=c.id<this.id,s=[];for(const[f,[w,q]]of this.current){if(c.current.has(f)){var d=c.current.get(f)[0];if(a&&w!==d)c.current.set(f,[w,q]);else continue}s.push(f)}if(a)for(const[f,w]of this.async_deriveds){const q=c.async_deriveds.get(f);q&&w.promise.then(q.resolve).catch(q.reject)}var u=[...c.current.keys()].filter(f=>!c.current.get(f)[1]);if(!(!c.#t||u.length===0)){var e=u.filter(f=>!this.current.has(f));if(e.length===0)a&&c.discard();else if(s.length>0){if(a)for(const f of this.#v)c.unskip_effect(f,w=>{(w.f&(Or|Ya))!==0?c.schedule(w):c.#h([w])});c.activate();var n=new Set,l=new Map;for(var i of s)Ul(i,e,n,l);l=new Map;var o=[...c.current].filter(([f,w])=>{const q=this.current.get(f);return q?q[0]!==w[0]||q[1]!==w[1]:!0}).map(([f])=>f);if(o.length>0)for(const f of this.#m)(f.f&(wr|Gt|cn))===0&&xi(f,o,l)&&((f.f&(Ya|Or))!==0?(Xe(f,yt),c.schedule(f)):c.#d.add(f));if(c.#s.length>0&&!c.#p){c.apply();for(var h of c.#s)c.#b(h,[],[]);c.#s=[]}c.deactivate()}}}}increment(a,s){if(this.#n+=1,a){let d=this.#r.get(s)??0;this.#r.set(s,d+1)}}decrement(a,s){if(this.#n-=1,a){let d=this.#r.get(s)??0;d===1?this.#r.delete(s):this.#r.set(s,d-1)}this.#p||(this.#p=!0,oa(()=>{this.#p=!1,this.linked&&this.flush()}))}transfer_effects(a,s){for(const d of a)this.#d.add(d);for(const d of s)this.#u.add(d);a.clear(),s.clear()}oncommit(a){this.#l.add(a)}ondiscard(a){this.#a.add(a)}settled(){return(this.#o??=El()).promise}static ensure(){if(ie===null){const a=ie=new Pa;!Bn&&!Ss&&oa(()=>{a.#t||a.flush()})}return ie}apply(){{Tr=null;return}}schedule(a){if(ui=a,a.b?.is_pending&&(a.f&(Qa|zs|Nl))!==0&&(a.f&as)===0){a.b.defer_effect(a);return}for(var s=a;s.parent!==null;){s=s.parent;var d=s.f;if(Ja!==null&&s===de&&(ue===null||(ue.f&jt)===0))return;if((d&(da|qr))!==0){if((d>)===0)return;s.f^=gt}}this.#s.push(s)}#f(){if(this.linked){var a=this.#i,s=this.#e;a===null?Fn=s:a.#e=s,s===null?Za=a:s.#i=a,this.linked=!1}}}function eh(r){var a=Ss;Ss=!0;try{for(var s;;){if(Hc(),ie===null)return s;ie.flush()}}finally{Ss=a}}function th(){try{Mc()}catch(r){Hr(r,ui)}}let ia=null;function il(r){var a=r.length;if(a!==0){for(var s=0;s<a;){var d=r[s++];if((d.f&(wr|Gt))===0&&os(d)&&(ia=new Set,Ma(d),d.deps===null&&d.first===null&&d.nodes===null&&d.teardown===null&&d.ac===null&&od(d),ia?.size>0)){Ur.clear();for(const u of ia){if((u.f&(wr|Gt))!==0)continue;const e=[u];let n=u.parent;for(;n!==null;)ia.has(n)&&(ia.delete(n),e.push(n)),n=n.parent;for(let l=e.length-1;l>=0;l--){const i=e[l];(i.f&(wr|Gt))===0&&Ma(i)}}ia.clear()}}ia=null}}function Ul(r,a,s,d){if(!s.has(r)&&(s.add(r),r.reactions!==null))for(const u of r.reactions){const e=u.f;(e&jt)!==0?Ul(u,a,s,d):(e&(Ya|Or))!==0&&(e&yt)===0&&xi(u,a,d)&&(Xe(u,yt),Ai(u))}}function xi(r,a,s){const d=s.get(r);if(d!==void 0)return d;if(r.deps!==null)for(const u of r.deps){if(un.call(a,u))return!0;if((u.f&jt)!==0&&xi(u,a,s))return s.set(u,!0),!0}return s.set(r,!1),!1}function Ai(r){ie.schedule(r)}function Kl(r,a){if(!((r.f&qr)!==0&&(r.f>)!==0)){(r.f&yt)!==0?a.d.push(r):(r.f&$r)!==0&&a.m.push(r),Xe(r,gt);for(var s=r.first;s!==null;)Kl(s,a),s=s.next}}function Jl(r){Xe(r,gt);for(var a=r.first;a!==null;)Jl(a),a=a.next}let mn=new Set;const Ur=new Map;let Yl=!1;function za(r,a){var s={f:0,v:r,reactions:null,equals:Ol,rv:0,wv:0};return s}function va(r,a){const s=za(r);return ud(s),s}function Y(r,a=!1,s=!0){const d=za(r);return a||(d.equals=Tl),Ts&&s&&De!==null&&De.l!==null&&(De.l.s??=[]).push(d),d}function ol(r,a){return A(r,p(()=>t(r))),a}function A(r,a,s=!1){ue!==null&&(!zr||(ue.f&cn)!==0)&&Vs()&&(ue.f&(jt|Or|Ya|cn))!==0&&(Kr===null||!Kr.has(r))&&Fc();let d=s?As(a):a;return ts(r,d,nn)}function ts(r,a,s=null){if(!r.equals(a)){ka?Ur.set(r,a):Ur.has(r)||Ur.set(r,r.v);var d=Pa.ensure();if(d.capture(r,a),(r.f&jt)!==0){const u=r;(r.f&yt)!==0&&ki(u),Tr===null&&bi(u)}r.wv=cd(),Gl(r,yt,s),Vs()&&de!==null&&(de.f>)!==0&&(de.f&(qr|da))===0&&(xr===null?fh([r]):xr.push(r)),!d.is_fork&&mn.size>0&&!Yl&&rh()}return a}function rh(){Yl=!1;for(const r of mn){(r.f>)!==0&&Xe(r,$r);let a;try{a=os(r)}catch{a=!0}a&&Ma(r)}mn.clear()}function Es(r){A(r,r.v+1)}function Gl(r,a,s){var d=r.reactions;if(d!==null)for(var u=Vs(),e=d.length,n=0;n<e;n++){var l=d[n],i=l.f;if(!(!u&&l===de)){var o=(i&yt)===0;if(o&&Xe(l,a),(i&cn)!==0)mn.add(l);else if((i&jt)!==0){var h=l;Tr?.delete(h),(i&Ta)===0&&(i&Ir&&(de===null||(de.f&hn)===0)&&(l.f|=Ta),Gl(h,$r,s))}else if(o){var c=l;(i&Or)!==0&&ia!==null&&ia.add(c),s!==null?s.push(c):Ai(c)}}}}function As(r){if(typeof r!="object"||r===null||wa in r||Ll in r)return r;const a=yi(r);if(a!==xc&&a!==Ac)return r;var s=new Map,d=yn(r),u=va(0),e=Oa,n=l=>{if(Oa===e)return l();var i=ue,o=Oa;Rr(null),pl(e);var h=l();return Rr(i),pl(o),h};return d&&s.set("length",va(r.length)),new Proxy(r,{defineProperty(l,i,o){(!("value"in o)||o.configurable===!1||o.enumerable===!1||o.writable===!1)&&Vc();var h=s.get(i);return h===void 0?n(()=>{var c=va(o.value);return s.set(i,c),c}):A(h,o.value,!0),!0},deleteProperty(l,i){var o=s.get(i);if(o===void 0){if(i in l){const h=n(()=>va(xt));s.set(i,h),Es(u)}}else A(o,xt),Es(u);return!0},get(l,i,o){if(i===wa)return r;var h=s.get(i),c=i in l;if(h===void 0&&(!c||Rs(l,i)?.writable)&&(h=n(()=>{var w=As(c?l[i]:xt),q=va(w);return q}),s.set(i,h)),h!==void 0){var f=t(h);return f===xt?void 0:f}return Reflect.get(l,i,o)},getOwnPropertyDescriptor(l,i){var o=Reflect.getOwnPropertyDescriptor(l,i);if(o&&"value"in o){var h=s.get(i);h&&(o.value=t(h))}else if(o===void 0){var c=s.get(i),f=c?.v;if(c!==void 0&&f!==xt)return{enumerable:!0,configurable:!0,value:f,writable:!0}}return o},has(l,i){if(i===wa)return!0;var o=s.get(i),h=o!==void 0&&o.v!==xt||Reflect.has(l,i);if(o!==void 0||de!==null&&(!h||Rs(l,i)?.writable)){o===void 0&&(o=n(()=>{var f=h?As(l[i]):xt,w=va(f);return w}),s.set(i,o));var c=t(o);if(c===xt)return!1}return h},set(l,i,o,h){var c=s.get(i),f=i in l;if(d&&i==="length")for(var w=o;w<c.v;w+=1){var q=s.get(w+"");q!==void 0?A(q,xt):w in l&&(q=n(()=>va(xt)),s.set(w+"",q))}if(c===void 0)(!f||Rs(l,i)?.writable)&&(c=n(()=>va(void 0)),A(c,As(o)),s.set(i,c));else{f=c.v!==xt;var H=n(()=>As(o));A(c,H)}var R=Reflect.getOwnPropertyDescriptor(l,i);if(R?.set&&R.set.call(h,o),!f){if(d&&typeof i=="string"){var W=s.get("length"),re=Number(i);Number.isInteger(re)&&re>=W.v&&A(W,re+1)}Es(u)}return!0},ownKeys(l){t(u);var i=Reflect.ownKeys(l).filter(c=>{var f=s.get(c);return f===void 0||f.v!==xt});for(var[o,h]of s)h.v!==xt&&!(o in l)&&i.push(o);return i},setPrototypeOf(){Dc()}})}function ll(r){try{if(r!==null&&typeof r=="object"&&wa in r)return r[wa]}catch{}return r}function Ql(r,a){return Object.is(ll(r),ll(a))}var dl,Xl,ed,td;function ah(){if(dl===void 0){dl=window,Xl=/Firefox/.test(navigator.userAgent);var r=Element.prototype,a=Node.prototype,s=Text.prototype;ed=Rs(a,"firstChild").get,td=Rs(a,"nextSibling").get,al(r)&&(r[ii]=void 0,r[jl]=null,r[oi]=void 0,r.__e=void 0),al(s)&&(s[li]=void 0)}}function ba(r=""){return document.createTextNode(r)}function Cs(r){return ed.call(r)}function Ds(r){return td.call(r)}function P(r,a){return Cs(r)}function jr(r,a=!1){{var s=Cs(r);return s instanceof Comment&&s.data===""?Ds(s):s}}function _(r,a=!1){return Cs(r)}function v(r,a=1,s=!1){let d=r;for(;a--;)d=Ds(d);return d}function sh(r){r.textContent=""}function rd(){return!1}function nh(r,a,s){return s?document.createElement(r,{is:s}):document.createElement(r)}function ih(r){var a=de;if(a===null)return ue.f|=_a,r;if((a.f&as)===0&&(a.f&Qa)===0)throw r;Hr(r,a)}function Hr(r,a){if(!(a!==null&&(a.f&wr)!==0)){for(;a!==null;){if((a.f&ni)!==0&&(a.f&(wr|pn))===0){if((a.f&as)===0)throw r;try{a.b.error(r);return}catch(s){r=s}}a=a.parent}throw r}}function ad(r){de===null&&(ue===null&&zc(),Tc()),ka&&Oc()}function oh(r,a){var s=a.last;s===null?a.last=a.first=r:(s.next=r,r.prev=s,a.last=r)}function Jr(r,a){var s=de;s!==null&&(s.f&Gt)!==0&&(r|=Gt);var d={ctx:De,deps:null,nodes:null,f:r|yt|Ir,first:null,fn:a,last:null,next:null,parent:s,b:s&&s.b,prev:null,teardown:null,wv:0,ac:null};ie?.register_created_effect(d);var u=d;if((r&Qa)!==0)Ja!==null?Ja.push(d):Pa.ensure().schedule(d);else if(a!==null){try{Ma(d)}catch(n){throw pr(d),n}u.deps===null&&u.teardown===null&&u.nodes===null&&u.first===u.last&&(u.f&ss)===0&&(u=u.first,(r&Or)!==0&&(r&Xa)!==0&&u!==null&&(u.f|=Xa))}if(u!==null&&(u.parent=s,s!==null&&oh(u,s),ue!==null&&(ue.f&jt)!==0&&(r&da)===0)){var e=ue;(e.effects??=[]).push(u)}return d}function Ii(){return ue!==null&&!zr}function $i(r){const a=Jr(zs,null);return Xe(a,gt),a.teardown=r,a}function pi(r){ad();var a=de.f,s=!ue&&(a&qr)!==0&&De!==null&&!De.i;if(s){var d=De;(d.e??=[]).push(r)}else return sd(r)}function sd(r){return Jr(Qa|Cl,r)}function lh(r){return ad(),Jr(zs|Cl,r)}function dh(r){Pa.ensure();const a=Jr(da|ss,r);return(s={})=>new Promise(d=>{s.outro?ja(a,()=>{pr(a),d(void 0)}):(pr(a),d(void 0))})}function nd(r){return Jr(Qa,r)}function Kt(r,a){var s=De,d={effect:null,ran:!1,deps:r};s.l.$.push(d),d.effect=is(()=>{if(r(),!d.ran){d.ran=!0;var u=de;try{Sr(u.parent),p(a)}finally{Sr(u)}}})}function uh(){var r=De;is(()=>{for(var a of r.l.$){a.deps();var s=a.effect;(s.f>)!==0&&s.deps!==null&&Xe(s,$r),os(s)&&Ma(s),a.ran=!1}})}function ph(r){return Jr(Ya|ss,r)}function is(r,a=0){return Jr(zs|a,r)}function S(r,a=[],s=[],d=[]){Uc(d,a,s,u=>{Jr(zs,()=>{r(...u.map(t))})})}function qi(r,a=0){var s=Jr(Or|a,r);return s}function Ar(r){return Jr(qr|ss,r)}function id(r){var a=r.teardown;if(a!==null){const s=ka,d=ue;ul(!0),Rr(null);try{a.call(null)}catch(u){Hr(u,r.parent)}finally{ul(s),Rr(d)}}}function Ri(r,a=!1){var s=r.first;for(r.first=r.last=null;s!==null;){const u=s.ac;u!==null&&ns(()=>{u.abort(Ms)});var d=s.next;(s.f&da)!==0?s.parent=null:pr(s,a),s=d}}function ch(r){for(var a=r.first;a!==null;){var s=a.next;(a.f&qr)===0&&pr(a),a=s}}function pr(r,a=!0){var s=!1;(a||(r.f&qc)!==0)&&r.nodes!==null&&r.nodes.end!==null&&(hh(r.nodes.start,r.nodes.end),s=!0),r.f|=pn,Ri(r,a&&!s),Ls(r,0);var d=r.nodes&&r.nodes.t;if(d!==null)for(const e of d)e.stop();id(r),r.f^=pn,r.f|=wr;var u=r.parent;u!==null&&u.first!==null&&od(r),r.next=r.prev=r.teardown=r.ctx=r.deps=r.fn=r.nodes=r.ac=r.b=null}function hh(r,a){for(;r!==null;){var s=r===a?null:Ds(r);r.remove(),r=s}}function od(r){var a=r.parent,s=r.prev,d=r.next;s!==null&&(s.next=d),d!==null&&(d.prev=s),a!==null&&(a.first===r&&(a.first=d),a.last===r&&(a.last=s))}function ja(r,a,s=!0){var d=[];r.f|=_i,ld(r,d,!0);var u=()=>{s&&pr(r),a&&a()},e=d.length;if(e>0){var n=()=>--e||u();for(var l of d)l.out(n)}else u()}function ld(r,a,s){if((r.f&Gt)===0){r.f^=Gt;var d=r.nodes&&r.nodes.t;if(d!==null)for(const l of d)(l.is_global||s)&&a.push(l);for(var u=r.first;u!==null;){var e=u.next;if((u.f&da)===0){var n=(u.f&Xa)!==0||(u.f&qr)!==0&&(r.f&Or)!==0;ld(u,a,n?s:!1)}u=e}}}function vn(r){r.f&=~_i,dd(r,!0)}function dd(r,a){if((r.f&_i)===0&&(r.f&Gt)!==0){r.f^=Gt,(r.f>)===0&&(Xe(r,yt),Pa.ensure().schedule(r));for(var s=r.first;s!==null;){var d=s.next,u=(s.f&Xa)!==0||(s.f&qr)!==0;dd(s,u?a:!1),s=d}var e=r.nodes&&r.nodes.t;if(e!==null)for(const n of e)(n.is_global||a)&&n.in()}}function Si(r,a){if(r.nodes)for(var s=r.nodes.start,d=r.nodes.end;s!==null;){var u=s===d?null:Ds(s);a.append(s),s=u}}let on=!1,ka=!1;function ul(r){ka=r}let ue=null,zr=!1;function Rr(r){ue=r}let de=null;function Sr(r){de=r}let Kr=null;function ud(r){ue!==null&&(Kr??=new Set).add(r)}let ur=null,_r=0,xr=null;function fh(r){xr=r}let pd=1,La=0,Oa=La;function pl(r){Oa=r}function cd(){return++pd}function os(r){var a=r.f;if((a&yt)!==0)return!0;if(a&jt&&(r.f&=~Ta),(a&$r)!==0){for(var s=r.deps,d=s.length,u=0;u<d;u++){var e=s[u];if(os(e)&&Wl(e),e.wv>r.wv)return!0}(a&Ir)!==0&&Tr===null&&Xe(r,gt)}return!1}function hd(r,a,s=!0){var d=r.reactions;if(d!==null&&!(Kr!==null&&Kr.has(r)))for(var u=0;u<d.length;u++){var e=d[u];(e.f&jt)!==0?hd(e,a,!1):a===e&&(s?Xe(e,yt):(e.f>)!==0&&Xe(e,$r),Ai(e))}}function fd(r){var a=ur,s=_r,d=xr,u=ue,e=Kr,n=De,l=zr,i=Oa,o=r.f;ur=null,_r=0,xr=null,ue=(o&(qr|da))===0?r:null,Kr=null,es(r.ctx),zr=!1,Oa=++La,r.ac!==null&&(ns(()=>{r.ac.abort(Ms)}),r.ac=null);try{r.f|=hn;var h=r.fn,c=h();r.f|=as;var f=cl(r);if(Vs()&&xr!==null&&!zr&&f!==null&&(r.f&(jt|$r|yt))===0)for(var w=0;w<xr.length;w++)hd(xr[w],r);if(u!==null&&u!==r){if(La++,u.deps!==null)for(let q=0;q<s;q+=1)u.deps[q].rv=La;if(a!==null)for(const q of a)q.rv=La;xr!==null&&(d===null?d=xr:d.push(...xr))}return(r.f&_a)!==0&&(r.f^=_a),c}catch(q){return cl(r),ih(q)}finally{r.f^=hn,ur=a,_r=s,xr=d,ue=u,Kr=e,es(n),zr=l,Oa=i}}function cl(r){var a=r.deps,s=ie?.is_fork;if(ur!==null){var d;if(s||Ls(r,_r),a!==null&&_r>0)for(a.length=_r+ur.length,d=0;d<ur.length;d++)a[_r+d]=ur[d];else r.deps=a=ur;if(Ii()&&(r.f&Ir)!==0)for(d=_r;d<a.length;d++)(a[d].reactions??=[]).push(r)}else!s&&a!==null&&_r<a.length&&(Ls(r,_r),a.length=_r);return a}function mh(r,a){let s=a.reactions;if(s!==null){var d=kc.call(s,r);if(d!==-1){var u=s.length-1;u===0?s=a.reactions=null:(s[d]=s[u],s.pop())}}if(s===null&&(a.f&jt)!==0&&(ur===null||!un.call(ur,a))){var e=a;(e.f&Ir)!==0&&(e.f^=Ir,e.f&=~Ta),e.v!==xt&&bi(e),e.ac!==null&&ns(()=>{e.ac.abort(Ms),e.ac=null,Xe(e,yt)}),Qc(e),Ls(e,0)}}function Ls(r,a){var s=r.deps;if(s!==null)for(var d=a;d<s.length;d++)mh(r,s[d])}function Ma(r){var a=r.f;if((a&wr)===0){Xe(r,gt);var s=de,d=on;de=r,on=(a&(qr|da))===0;try{(a&(Or|Nl))!==0?ch(r):Ri(r),id(r);var u=fd(r);r.teardown=typeof u=="function"?u:null,r.wv=pd;var e;ql&&fc&&(r.f&yt)!==0&&r.deps}finally{on=d,de=s}}}async function ln(){await Promise.resolve(),eh()}function t(r){var a=r.f,s=(a&jt)!==0;if(ue!==null&&!zr){var d=de!==null&&(de.f&wr)!==0;if(!d&&(Kr===null||!Kr.has(r))){var u=ue.deps;if((ue.f&hn)!==0)r.rv<La&&(r.rv=La,ur===null&&u!==null&&u[_r]===r?_r++:ur===null?ur=[r]:ur.push(r));else{ue.deps??=[],un.call(ue.deps,r)||ue.deps.push(r);var e=r.reactions;e===null?r.reactions=[ue]:un.call(e,ue)||e.push(ue)}}}if(ka&&Ur.has(r))return Ur.get(r);if(s){var n=r;if(ka){var l=n.v;return((n.f>)===0&&n.reactions!==null||vd(n))&&(l=ki(n)),Ur.set(n,l),l}var i=(n.f&Ir)===0&&!zr&&ue!==null&&(on||(ue.f&Ir)!==0),o=(n.f&as)===0;os(n)&&(i&&(n.f|=Ir),Wl(n)),i&&!o&&(Zl(n),md(n))}if(Tr?.has(r))return Tr.get(r);if((r.f&_a)!==0)throw r.v;return r.v}function md(r){if(r.f|=Ir,r.deps!==null)for(const a of r.deps)(a.reactions??=[]).push(r),(a.f&jt)!==0&&(a.f&Ir)===0&&(Zl(a),md(a))}function vd(r){if(r.v===xt)return!0;if(r.deps===null)return!1;for(const a of r.deps)if(Ur.has(a)||(a.f&jt)!==0&&vd(a))return!0;return!1}function p(r){var a=zr;try{return zr=!0,r()}finally{zr=a}}function Ze(r){if(!(typeof r!="object"||!r||r instanceof EventTarget)){if(wa in r)ci(r);else if(!Array.isArray(r))for(let a in r){const s=r[a];typeof s=="object"&&s&&wa in s&&ci(s)}}}function ci(r,a=new Set){if(typeof r=="object"&&r!==null&&!(r instanceof EventTarget)&&!a.has(r)){a.add(r),r instanceof Date&&r.getTime();for(let d in r)try{ci(r[d],a)}catch{}const s=yi(r);if(s!==Object.prototype&&s!==Array.prototype&&s!==Map.prototype&&s!==Set.prototype&&s!==Date.prototype){const d=Sl(s);for(let u in d){const e=d[u].get;if(e)try{e.call(r)}catch{}}}}}const Is=Symbol("events"),gd=new Set,hi=new Set;function vh(r,a,s,d={}){function u(e){if(d.capture||fi.call(a,e),!e.cancelBubble)return ns(()=>s?.call(this,e))}return r.startsWith("pointer")||r.startsWith("touch")||r==="wheel"?oa(()=>{a.addEventListener(r,u,d)}):a.addEventListener(r,u,d),u}function Hn(r,a,s,d,u){var e={capture:d,passive:u},n=vh(r,a,s,e);(a===document.body||a===window||a===document||a instanceof HTMLMediaElement)&&$i(()=>{a.removeEventListener(r,n,e)})}function G(r,a,s){(a[Is]??={})[r]=s}function gh(r){for(var a=0;a<r.length;a++)gd.add(r[a]);for(var s of hi)s(r)}let Wn=null,Zn=!1;function fi(r){var a=this,s=a.ownerDocument,d=r.type,u=r.composedPath?.()||[],e=u[0]||r.target;Wn=r,Zn||(Zn=!0,setTimeout(()=>{Zn=!1,Wn=null}));var n=0,l=Wn===r&&r[Is];if(l){var i=u.indexOf(l);if(i!==-1&&(a===document||a===window)){r[Is]=a;return}var o=u.indexOf(a);if(o===-1)return;i<=o&&(n=i)}if(e=u[n]||r.target,e!==a){Rl(r,"currentTarget",{configurable:!0,get(){return e||s}});var h=ue,c=de;Rr(null),Sr(null);try{for(var f,w=[];e!==null&&e!==a;){try{var q=e[Is]?.[d];q!=null&&(!e.disabled||r.target===e)&&q.call(e,r)}catch(H){f?w.push(H):f=H}if(r.cancelBubble)break;n++,e=n<u.length?u[n]:null}if(f){for(let H of w)queueMicrotask(()=>{throw H});throw f}}finally{r[Is]=a,delete r.currentTarget,Rr(h),Sr(c)}}}const yh=globalThis?.window?.trustedTypes&&globalThis.window.trustedTypes.createPolicy("svelte-trusted-html",{createHTML:r=>r});function _h(r){return yh?.createHTML(r)??r}function wh(r){var a=nh("template");return a.innerHTML=_h(r.replaceAll("<!>","<!---->")),a.content}function mi(r,a){var s=de;s.nodes===null&&(s.nodes={start:r,end:a,a:null,t:null})}function M(r,a){var s=(a&wc)!==0,d=(a&bc)!==0,u,e=!r.startsWith("<!>");return()=>{u===void 0&&(u=wh(e?r:"<!>"+r),s||(u=Cs(u)));var n=d||Xl?document.importNode(u,!0):u.cloneNode(!0);if(s){var l=Cs(n),i=n.lastChild;mi(l,i)}else mi(n,n);return n}}function _s(){var r=document.createDocumentFragment(),a=document.createComment(""),s=ba();return r.append(a,s),mi(a,s),r}function $(r,a){r!==null&&r.before(a)}const bh=["touchstart","touchmove"];function Ph(r){return bh.includes(r)}function kh(r){let a=0,s=za(0),d;return()=>{Ii()&&(t(s),is(()=>(a===0&&(d=p(()=>r(()=>Es(s)))),a+=1,()=>{oa(()=>{a-=1,a===0&&(d?.(),d=void 0,Es(s))})})))}}var xh=Xa|ss;function Ah(r,a,s,d){new Ih(r,a,s,d)}class Ih{parent;is_pending=!1;transform_error;#t;#i=null;#e;#l;#a;#n=null;#r=null;#o=null;#s=null;#m=0;#d=0;#u=!1;#c=new Set;#v=new Set;#p=null;#_=kh(()=>(this.#p=za(this.#m),()=>{this.#p=null}));constructor(a,s,d,u){this.#t=a,this.#e=s,this.#l=e=>{var n=de;n.b=this,n.f|=ni,d(e)},this.parent=de.b,this.transform_error=u??this.parent?.transform_error??(e=>e),this.#a=qi(()=>{this.#h()},xh)}#g(){try{this.#n=Ar(()=>this.#l(this.#t))}catch(a){this.error(a)}}#b(a){const s=this.#e.failed,{reset:d,invoke_onerror:u}=this.#w(a);oa(u),s&&(this.#o=Ar(()=>{s(this.#t,()=>a,()=>d)}))}#w(a){var s=!1,d=!1;const u=()=>{if(s){Nc();return}s=!0,d&&Bc(),this.#o!==null&&ja(this.#o,()=>{this.#o=null}),this.#f(()=>{this.#h()})};return{reset:u,invoke_onerror:()=>{try{d=!0,this.#e.onerror?.(a,u),d=!1}catch(n){Hr(n,this.#a&&this.#a.parent)}}}}#P(){const a=this.#e.pending;a&&(this.is_pending=!0,this.#r=Ar(()=>a(this.#t)),oa(()=>{var s=this.#s=document.createDocumentFragment(),d=ba(),u=!1;if(s.append(d),this.#n=this.#f(()=>{try{return Ar(()=>this.#l(d))}catch(e){try{this.error(e),u=!0}catch(n){Hr(n,this.#a.parent)}return null}}),this.#n===null){this.#s=null,u&&this.#y(ie);return}this.#d===0&&(this.#t.before(s),this.#s=null,ja(this.#r,()=>{this.#r=null}),this.#y(ie))}))}#h(){try{if(this.is_pending=this.has_pending_snippet(),this.#d=0,this.#m=0,this.#n=Ar(()=>{this.#l(this.#t)}),this.#d>0){var a=this.#s=document.createDocumentFragment();Si(this.#n,a);const s=this.#e.pending;this.#r=Ar(()=>s(this.#t))}else this.#y(ie)}catch(s){this.error(s)}}#y(a){this.is_pending=!1,a.transfer_effects(this.#c,this.#v)}defer_effect(a){Bl(a,this.#c,this.#v)}is_rendered(){return!this.is_pending&&(!this.parent||this.parent.is_rendered())}has_pending_snippet(){return!!this.#e.pending}#f(a){var s=de,d=ue,u=De;Sr(this.#a),Rr(this.#a),es(this.#a.ctx);try{return Pa.ensure(),a()}finally{Sr(s),Rr(d),es(u)}}#k(a,s){if(!this.has_pending_snippet()){this.parent&&this.parent.#k(a,s);return}this.#d+=a,this.#d===0&&(this.#y(s),this.#r&&ja(this.#r,()=>{this.#r=null}),this.#s&&(this.#t.before(this.#s),this.#s=null))}update_pending_count(a,s){this.#k(a,s),this.#m+=a,!(!this.#p||this.#u)&&(this.#u=!0,oa(()=>{this.#u=!1,this.#p&&ts(this.#p,this.#m)}))}get_effect_pending(){return this.#_(),t(this.#p)}error(a){if(!this.#e.onerror&&!this.#e.failed)throw a;ie?.is_fork?(this.#n&&ie.skip_effect(this.#n),this.#r&&ie.skip_effect(this.#r),this.#o&&ie.skip_effect(this.#o),ie.oncommit(()=>{this.#x(a)})):this.#x(a)}#x(a){this.#n&&(pr(this.#n),this.#n=null),this.#r&&(pr(this.#r),this.#r=null),this.#o&&(pr(this.#o),this.#o=null);let s=this.#e.failed;const d=u=>{const{reset:e,invoke_onerror:n}=this.#w(u);n(),s&&(this.#o=this.#f(()=>{try{return Ar(()=>{var l=de;l.b=this,l.f|=ni,s(this.#t,()=>u,()=>e)})}catch(l){return Hr(l,this.#a.parent),null}}))};oa(()=>{var u;try{u=this.transform_error(a)}catch(e){Hr(e,this.#a&&this.#a.parent);return}u!==null&&typeof u=="object"&&typeof u.then=="function"?u.then(d,e=>Hr(e,this.#a&&this.#a.parent)):d(u)})}}function y(r,a){var s=a==null?"":typeof a=="object"?`${a}`:a;s!==(r[li]??=r.nodeValue)&&(r[li]=s,r.nodeValue=`${s}`)}function $h(r,a){return qh(r,a)}const Qs=new Map;function qh(r,{target:a,anchor:s,props:d={},events:u,context:e,intro:n=!0,transformError:l}){ah();var i=void 0,o=dh(()=>{var h=s??a.appendChild(ba());Ah(h,{pending:()=>{}},w=>{Ml({});var q=De;e&&(q.c=e),u&&(d.$$events=u),i=r(w,d)||wi(),Vl()},l);var c=new Set,f=w=>{for(var q=0;q<w.length;q++){var H=w[q];if(!c.has(H)){c.add(H);var R=Ph(H);for(const ae of[a,document]){var W=Qs.get(ae);W===void 0&&(W=new Map,Qs.set(ae,W));var re=W.get(H);re===void 0?(ae.addEventListener(H,fi,{passive:R}),W.set(H,1)):W.set(H,re+1)}}}};return f(_n(gd)),hi.add(f),()=>{for(var w of c)for(const R of[a,document]){var q=Qs.get(R),H=q.get(w);--H==0?(R.removeEventListener(w,fi),q.delete(w),q.size===0&&Qs.delete(R)):q.set(w,H)}hi.delete(f),h!==s&&h.parentNode?.removeChild(h)}});return Rh.set(i,o),i}let Rh=new WeakMap;class Sh{anchor;#t=new Map;#i=new Map;#e=new Map;#l=new Set;#a=!0;constructor(a,s=!0){this.anchor=a,this.#a=s}#n=a=>{if(this.#t.has(a)){var s=this.#t.get(a),d=this.#i.get(s);if(d)vn(d),this.#l.delete(s);else{var u=this.#e.get(s);u&&(vn(u.effect),this.#i.set(s,u.effect),this.#e.delete(s),u.fragment.lastChild.remove(),this.anchor.before(u.fragment),d=u.effect)}for(const[e,n]of this.#t){if(this.#t.delete(e),e===a)break;const l=this.#e.get(n);l&&(pr(l.effect),this.#e.delete(n))}for(const[e,n]of this.#i){if(e===s||this.#l.has(e))continue;const l=()=>{if(Array.from(this.#t.values()).includes(e)){var o=document.createDocumentFragment();Si(n,o),o.append(ba()),this.#e.set(e,{effect:n,fragment:o})}else pr(n);this.#l.delete(e),this.#i.delete(e)};this.#a||!d?(this.#l.add(e),ja(n,l,!1)):l()}}};#r=a=>{this.#t.delete(a);const s=Array.from(this.#t.values());for(const[d,u]of this.#e)s.includes(d)||(pr(u.effect),this.#e.delete(d))};ensure(a,s){var d=ie,u=rd();if(s&&!this.#i.has(a)&&!this.#e.has(a))if(u){var e=document.createDocumentFragment(),n=ba();e.append(n),this.#e.set(a,{effect:Ar(()=>s(n)),fragment:e})}else this.#i.set(a,Ar(()=>s(this.anchor)));if(this.#t.set(d,a),u){for(const[l,i]of this.#i)l===a?d.unskip_effect(i):d.skip_effect(i);for(const[l,i]of this.#e)l===a?d.unskip_effect(i.effect):d.skip_effect(i.effect);d.oncommit(this.#n),d.ondiscard(this.#r)}else this.#n(d)}}function yd(r){De===null&&zl(),Ts&&De.l!==null?Nh(De).m.push(r):pi(()=>{const a=p(r);if(typeof a=="function")return a})}function Eh(r){De===null&&zl(),yd(()=>()=>p(r))}function Nh(r){var a=r.l;return a.u??={a:[],b:[],m:[]}}function J(r,a,s=!1){var d=new Sh(r),u=s?Xa:0;function e(n,l){d.ensure(n,l)}qi(()=>{var n=!1;a((l,i=0)=>{n=!0,e(i,l)}),n||e(-1,null)},u)}function sa(r,a){return a}function Ch(r,a,s){for(var d=[],u=a.length,e,n=a.length,l=0;l<u;l++){let c=a[l];ja(c,()=>{if(e){if(e.pending.delete(c),e.done.add(c),e.pending.size===0){var f=r.outrogroups;vi(r,_n(e.done)),f.delete(e),f.size===0&&(r.outrogroups=null)}}else n-=1},!1)}if(n===0){var i=d.length===0&&s!==null&&r.pending.size===0;if(i){var o=s,h=o.parentNode;sh(h),h.append(o),r.items.clear()}vi(r,a,!i)}else e={pending:new Set(a),done:new Set},(r.outrogroups??=new Set).add(e)}function vi(r,a,s=!0){var d;if(r.pending.size>0){d=new Set;for(const n of r.pending.values())for(const l of n)d.add(r.items.get(l).e)}for(var u=0;u<a.length;u++){var e=a[u];if(d?.has(e)){e.f|=Zr;const n=document.createDocumentFragment();Si(e,n)}else pr(a[u],s)}}var hl;function ye(r,a,s,d,u,e=null){var n=r,l=new Map,i=(a&$l)!==0;if(i){var o=r;n=o.appendChild(ba())}var h=null,c=ya(()=>{var ae=s();return yn(ae)?ae:ae==null?[]:_n(ae)}),f,w=new Map,q=!0;function H(ae){(re.effect.f&wr)===0&&(re.pending.delete(ae),re.fallback=h,Lh(re,f,n,a,d),h!==null&&(f.length===0?(h.f&Zr)===0?vn(h):(h.f^=Zr,$s(h,null,n)):ja(h,()=>{h=null})))}function R(ae){re.pending.delete(ae)}var W=qi(()=>{f=t(c);for(var ae=f.length,oe=new Set,me=ie,ve=rd(),ge=0;ge<ae;ge+=1){var _e=f[ge],Ot=d(_e,ge),Fe=q?null:l.get(Ot);Fe?(Fe.v&&ts(Fe.v,_e),Fe.i&&ts(Fe.i,ge),ve&&me.unskip_effect(Fe.e)):(Fe=jh(l,q?n:hl??=ba(),_e,Ot,ge,u,a,s),q||(Fe.e.f|=Zr),l.set(Ot,Fe)),oe.add(Ot)}if(ae===0&&e&&!h&&(q?h=Ar(()=>e(n)):(h=Ar(()=>e(hl??=ba())),h.f|=Zr)),ae>oe.size&&jc(),!q)if(w.set(me,oe),ve){for(const[U,le]of l)oe.has(U)||me.skip_effect(le.e);me.oncommit(H),me.ondiscard(R)}else H(me);t(c)}),re={effect:W,items:l,pending:w,outrogroups:null,fallback:h};q=!1}function ws(r){for(;r!==null&&(r.f&qr)===0;)r=r.next;return r}function Lh(r,a,s,d,u){var e=(d&yc)!==0,n=a.length,l=r.items,i=ws(r.effect.first),o,h=null,c,f=[],w=[],q,H,R,W;if(e)for(W=0;W<n;W+=1)q=a[W],H=u(q,W),R=l.get(H).e,(R.f&Zr)===0&&(R.nodes?.a?.measure(),(c??=new Set).add(R));for(W=0;W<n;W+=1){if(q=a[W],H=u(q,W),R=l.get(H).e,r.outrogroups!==null)for(const Fe of r.outrogroups)Fe.pending.delete(R),Fe.done.delete(R);if((R.f&Gt)!==0&&(vn(R),e&&(R.nodes?.a?.unfix(),(c??=new Set).delete(R))),(R.f&Zr)!==0)if(R.f^=Zr,R===i)$s(R,null,s);else{var re=h?h.next:i;R===r.effect.last&&(r.effect.last=R.prev),R.prev&&(R.prev.next=R.next),R.next&&(R.next.prev=R.prev),ga(r,h,R),ga(r,R,re),$s(R,re,s),h=R,f=[],w=[],i=ws(h.next);continue}if(R!==i){if(o!==void 0&&o.has(R)){if(f.length<w.length){var ae=w[0],oe;h=ae.prev;var me=f[0],ve=f[f.length-1];for(oe=0;oe<f.length;oe+=1)$s(f[oe],ae,s);for(oe=0;oe<w.length;oe+=1)o.delete(w[oe]);ga(r,me.prev,ve.next),ga(r,h,me),ga(r,ve,ae),i=ae,h=ve,W-=1,f=[],w=[]}else o.delete(R),$s(R,i,s),ga(r,R.prev,R.next),ga(r,R,h===null?r.effect.first:h.next),ga(r,h,R),h=R;continue}for(f=[],w=[];i!==null&&i!==R;)(o??=new Set).add(i),w.push(i),i=ws(i.next);if(i===null)continue}(R.f&Zr)===0&&f.push(R),h=R,i=ws(R.next)}if(r.outrogroups!==null){for(const Fe of r.outrogroups)Fe.pending.size===0&&(vi(r,_n(Fe.done)),r.outrogroups?.delete(Fe));r.outrogroups.size===0&&(r.outrogroups=null)}if(i!==null||o!==void 0){var ge=[];if(o!==void 0)for(R of o)(R.f&Gt)===0&&ge.push(R);for(;i!==null;)(i.f&Gt)===0&&i!==r.fallback&&ge.push(i),i=ws(i.next);var _e=ge.length;if(_e>0){var Ot=(d&$l)!==0&&n===0?s:null;if(e){for(W=0;W<_e;W+=1)ge[W].nodes?.a?.measure();for(W=0;W<_e;W+=1)ge[W].nodes?.a?.fix()}Ch(r,ge,Ot)}}e&&oa(()=>{if(c!==void 0)for(R of c)R.nodes?.a?.apply()})}function jh(r,a,s,d,u,e,n,l){var i=(n&vc)!==0?(n&_c)===0?Y(s,!1,!1):za(s):null,o=(n&gc)!==0?za(u):null;return{v:i,i:o,e:Ar(()=>(e(a,i??s,o??u,l),()=>{r.delete(d)}))}}function $s(r,a,s){if(r.nodes)for(var d=r.nodes.start,u=r.nodes.end,e=a&&(a.f&Zr)===0?a.nodes.start:s;d!==null;){var n=Ds(d);if(e.before(d),d===u)return;d=n}}function ga(r,a,s){a===null?r.effect.first=s:a.next=s,s===null?r.effect.last=a:s.prev=a}const fl=[..." \\t\\n\\r\\f \\u000b\uFEFF"];function Oh(r,a,s){var d=r==null?"":""+r;if(a&&(d=d?d+" "+a:a),s){for(var u of Object.keys(s))if(s[u])d=d?d+" "+u:u;else if(d.length)for(var e=u.length,n=0;(n=d.indexOf(u,n))>=0;){var l=n+e;(n===0||fl.includes(d[n-1]))&&(l===d.length||fl.includes(d[l]))?d=(n===0?"":d.substring(0,n))+d.substring(l+1):n=l}}return d===""?null:d}function Th(r,a){return r==null?null:String(r)}function yr(r,a,s,d,u,e){var n=r[ii];if(n!==s||n===void 0){var l=Oh(s,d,e);l==null?r.removeAttribute("class"):r.className=l,r[ii]=s}else if(e&&u!==e)for(var i in e){var o=!!e[i];(u==null||o!==!!u[i])&&r.classList.toggle(i,o)}return e}function dr(r,a,s,d){var u=r[oi];if(u!==a){var e=Th(a);e==null?r.removeAttribute("style"):r.style.cssText=e,r[oi]=a}return d}function zh(r,a){a?r.hasAttribute("selected")||r.setAttribute("selected",""):r.removeAttribute("selected")}function Mh(r,a){var s=r.__defaultValue,d=r.multiple,u=d?s??[]:null;if(!(d&&!yn(u))){r.selectedIndex;for(var e of r.options){var n=Ga(e);zh(e,d?u.includes(n):Ql(n,s))}}}function Ns(r,a,s=!1){if(r.multiple){if(a==null)return;if(!yn(a))return Ec();for(var d of r.options)d.selected=a.includes(Ga(d));return}for(d of r.options){var u=Ga(d);if(Ql(u,a)){d.selected=!0;return}}(!s||a!==void 0)&&(r.selectedIndex=-1)}function Xs(r){var a=new MutationObserver(s=>{s.every(Dh)||("__defaultValue"in r&&Mh(r),"__value"in r&&Ns(r,r.__value))});a.observe(r,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["value"]}),$i(()=>{a.disconnect()})}function Vh(r,a,s=a){var d=new WeakSet,u=!0;Pi(r,"change",e=>{var n=e?"[selected]":":checked",l;if(r.multiple)l=[].map.call(r.querySelectorAll(n),Ga);else{var i=r.querySelector(n)??r.querySelector("option:not([disabled])");l=i&&Ga(i)}s(l),r.__value=l,ie!==null&&d.add(ie)}),nd(()=>{var e=a();if(r===document.activeElement){var n=ie;if(d.has(n))return}if(Ns(r,e,u),u&&e===void 0){var l=r.querySelector(":checked");l!==null&&(e=Ga(l),s(e))}r.__value=e,u=!1})}function Ga(r){return"__value"in r?r.__value:r.value}function Dh(r){if(r.target.closest("selectedcontent")!==null)return!0;if(r.type==="childList"){var a=[...r.addedNodes,...r.removedNodes];return a.length>0&&a.every(s=>s.nodeName==="SELECTEDCONTENT")}return!1}const Fh=Symbol("is custom element"),Bh=Symbol("is html");function Ua(r,a){var s=_d(r);s.checked!==(s.checked=a??void 0)&&(r.checked=a)}function V(r,a,s,d){var u=_d(r);u[a]!==(u[a]=s)&&(a==="loading"&&(r[Rc]=s),s==null?r.removeAttribute(a):typeof s!="string"&&Hh(r).has(a)?r[a]=s:r.setAttribute(a,s))}function _d(r){return r[jl]??={[Fh]:r.nodeName.includes("-"),[Bh]:r.namespaceURI===Pc}}var ml=new Map;function Hh(r){var a=r.getAttribute("is")||r.nodeName,s=ml.get(a);if(s)return s;ml.set(a,s=new Set);for(var d,u=r,e=Element.prototype;e!==u;){d=Sl(u);for(var n in d)d[n].set&&n!=="innerHTML"&&n!=="textContent"&&n!=="innerText"&&s.add(n);u=yi(u)}return s}function en(r,a,s=a){var d=new WeakSet;Pi(r,"input",async u=>{var e=u?r.defaultValue:r.value;if(e=Un(r)?Kn(e):e,s(e),ie!==null&&d.add(ie),await ln(),e!==(e=a())){var n=r.selectionStart,l=r.selectionEnd,i=r.value.length;if(r.value=e??"",l!==null){var o=r.value.length;n===l&&l===i&&o>i?(r.selectionStart=o,r.selectionEnd=o):(r.selectionStart=n,r.selectionEnd=Math.min(l,o))}}}),p(a)==null&&r.value&&(s(Un(r)?Kn(r.value):r.value),ie!==null&&d.add(ie)),is(()=>{var u=a();if(r===document.activeElement){var e=ie;if(d.has(e))return}Un(r)&&u===Kn(r.value)||r.type==="date"&&!u&&!r.value||u!==r.value&&(r.value=u??"")})}function vl(r,a,s=a){Pi(r,"change",d=>{var u=d?r.defaultChecked:r.checked;s(u)}),p(a)==null&&s(r.checked),is(()=>{var d=a();r.checked=!!d})}function Un(r){var a=r.type;return a==="number"||a==="range"}function Kn(r){return r===""?null:+r}function Jn(r,a){return r===a||r?.[wa]===a}function bs(r=wi(),a,s,d){var u=De.r,e=de;return nd(()=>{var n,l;return is(()=>{n=l,l=[],p(()=>{Jn(s(...l),r)||(a(r,...l),n&&Jn(s(...n),r)&&a(null,...n))})}),()=>{let i=e;for(;i!==u&&i.parent!==null&&i.parent.f&pn;)i=i.parent;const o=()=>{l&&Jn(s(...l),r)&&a(null,...l)},h=i.teardown;i.teardown=()=>{o(),h?.()}}}),r}function Wh(r=!1){const a=De,s=a.l.u;if(!s)return;let d=()=>Ze(a.s);if(r){let u=0,e={};const n=wn(()=>{let l=!1;const i=a.s;for(const o in i)i[o]!==e[o]&&(e[o]=i[o],l=!0);return l&&u++,u});d=()=>t(n)}s.b.length&&lh(()=>{gl(a,d),si(s.b)}),pi(()=>{const u=p(()=>s.m.map($c));return()=>{for(const e of u)typeof e=="function"&&e()}}),s.a.length&&pi(()=>{gl(a,d),si(s.a)})}function gl(r,a){if(r.l.s)for(const s of r.l.s)t(s);a()}async function na(r,a,s){return{...a,fingerprint:await r(s)}}async function Zh(r,a){const s=[];for(const u of r.changes){s.push(na(a,{type:"change",ref:u.id},u));for(const[e,n]of u.verification.gaps.entries())s.push(na(a,{type:"verification-gap",ref:`${u.id}:gap:${e}`},{changeId:u.id,index:e,gap:n}))}for(const u of r.files)s.push(na(a,{type:"file",ref:u.id,path:u.newPath??u.oldPath??void 0},u));for(const u of r.hunks){s.push(na(a,{type:"hunk",ref:u.id,path:u.path},u));for(const[e,n]of u.lines.entries()){if(n.kind==="no-newline")continue;const l=n.kind==="addition"?"after":n.kind==="deletion"?"before":"diff",i=l==="before"?n.oldLine:n.newLine??n.oldLine;!i||i<1||s.push(na(a,{type:"line-range",ref:`${u.id}:${l}:${i}:${e}`,path:u.path,side:l,startLine:i,endLine:i},{path:u.path,side:l,lineNumber:i,content:n.content}))}}for(const u of r.targets)s.push(na(a,{type:"visual-target",ref:u.id},u));for(const u of r.comparisons){const e=r.targets.find(n=>n.id===u.targetRef);for(const n of u.images)for(const l of n.regions)s.push(na(a,{type:"visual-region",ref:`${u.id}:${n.id}:${l.id}`,targetRef:u.targetRef,region:{x:l.x/n.width,y:l.y/n.height,width:l.width/n.width,height:l.height/n.height}},{target:e,comparison:u,image:n,region:l}))}for(const u of r.findings)s.push(na(a,{type:"finding",ref:u.id,targetRef:u.targetRef},u));return(await Promise.all(s)).sort((u,e)=>`${u.type}\\0${u.ref}`.localeCompare(`${e.type}\\0${e.ref}`))}async function wd(r,a){const s=[];for(const d of r.comparisons)for(const u of d.images)for(const e of u.regions)s.push(na(a,{type:"visual-region",ref:`${d.id}:${u.id}:${e.id}`,targetRef:d.targetRef,region:{x:e.x,y:e.y,width:e.width,height:e.height}},{comparisonId:d.id,imageId:u.id,region:e}));return Promise.all(s)}function Uh(r){return!!(r&&typeof r=="object"&&!Array.isArray(r))}function Kh(r){if(!Uh(r))return!1;const a=Object.keys(r);return a.length===4&&a.every(s=>new Set(["x","y","width","height"]).has(s))&&[r.x,r.y,r.width,r.height].every(s=>typeof s=="number"&&Number.isFinite(s))}function bd(r,a,s,d){const u=structuredClone(r);if(!u||typeof u!="object")return u;const e=new Map(a.map(o=>[Wr(o),o])),n=new Map(s.map(o=>[Wr(o),o])),l=[u],i=new WeakSet;for(;l.length>0;){const o=l.pop();if(i.has(o))continue;if(i.add(o),Array.isArray(o)){for(const c of o)c&&typeof c=="object"&&l.push(c);continue}const h=o;if(h.type==="visual-region"&&typeof h.ref=="string"&&typeof h.fingerprint=="string"&&Kh(h.region)){const c=JSON.stringify([h.type,h.ref]),f=e.get(c),w=n.get(c),q=[h.region.x,h.region.y,h.region.width,h.region.height].some(R=>R>1);w?.fingerprint===h.fingerprint&&f?(f.region?h.region=structuredClone(f.region):delete h.region,f.targetRef?h.targetRef=f.targetRef:delete h.targetRef,d&&(h.fingerprint=f.fingerprint)):q&&!d&&delete h.region}for(const c of Object.values(h))c&&typeof c=="object"&&l.push(c)}return u}function Wr(r){return JSON.stringify([r.type,r.ref])}function yl(r,a,s){return r.find(d=>d.type===a&&d.ref===s)}function Yn(r,a){const s=a.find(u=>u.type===r.type&&u.ref===r.ref);if(s?.fingerprint===r.fingerprint)return{source:r,result:"exact",disposition:"matched",candidate:s};if(s)return{source:r,result:"changed",disposition:"stale",candidate:s};const d=a.filter(u=>u.type===r.type&&u.fingerprint===r.fingerprint);return d.length===1?{source:r,result:"probable",disposition:"stale",candidate:d[0]}:{source:r,result:"missing",disposition:"orphaned"}}function gi(r){if(r===null||typeof r=="string"||typeof r=="boolean")return r;if(typeof r=="number"){if(!Number.isFinite(r))throw new TypeError("Review JSON does not support non-finite numbers");return Object.is(r,-0)?0:r}if(Array.isArray(r))return r.map(gi);if(r instanceof Date)return r.toISOString();if(typeof r=="object"){const a={};for(const s of Object.keys(r).sort()){const d=r[s];d!==void 0&&(a[s]=gi(d))}return a}throw new TypeError(`Review JSON does not support ${typeof r}`)}function Na(r){return JSON.stringify(gi(r))}const Mr=async r=>{const a=new TextEncoder().encode(Na(r)),s=await crypto.subtle.digest("SHA-256",a);return[...new Uint8Array(s)].map(d=>d.toString(16).padStart(2,"0")).join("")};var Pd=(r,a)=>()=>{try{return a||r((a={exports:{}}).exports,a),a.exports}catch(s){throw a=0,s}},Jh=Pd(r=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0});function a(s){let d=s.length,u=0,e=0,n;for(;e<d;)u++,n=s.charCodeAt(e++),n>=55296&&n<=56319&&e<d&&(n=s.charCodeAt(e),(n&64512)===56320&&e++);return u}r.default=a,a.code=\'require("ajv/dist/runtime/ucs2length").default\'}),Yh=Pd(r=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.formatNames=r.fastFormats=r.fullFormats=void 0;function a(U,le){return{validate:U,compare:le}}r.fullFormats={date:a(e,n),time:a(i(!0),o),"date-time":a(f(!0),w),"iso-time":a(i(),h),"iso-date-time":a(f(),q),duration:/^P(?!$)((\\d+Y)?(\\d+M)?(\\d+D)?(T(?=\\d)(\\d+H)?(\\d+M)?(\\d+S)?)?|(\\d+W)?)$/,uri:W,"uri-reference":/^(?:[a-z][a-z0-9+\\-.]*:)?(?:\\/?\\/(?:(?:[a-z0-9\\-._~!$&\'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\\d|[01]?\\d\\d?)\\.){3}(?:25[0-5]|2[0-4]\\d|[01]?\\d\\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\\.[a-z0-9\\-._~!$&\'()*+,;=:]+)\\]|(?:(?:25[0-5]|2[0-4]\\d|[01]?\\d\\d?)\\.){3}(?:25[0-5]|2[0-4]\\d|[01]?\\d\\d?)|(?:[a-z0-9\\-._~!$&\'"()*+,;=]|%[0-9a-f]{2})*)(?::\\d*)?(?:\\/(?:[a-z0-9\\-._~!$&\'"()*+,;=:@]|%[0-9a-f]{2})*)*|\\/(?:(?:[a-z0-9\\-._~!$&\'"()*+,;=:@]|%[0-9a-f]{2})+(?:\\/(?:[a-z0-9\\-._~!$&\'"()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\\-._~!$&\'"()*+,;=:@]|%[0-9a-f]{2})+(?:\\/(?:[a-z0-9\\-._~!$&\'"()*+,;=:@]|%[0-9a-f]{2})*)*)?(?:\\?(?:[a-z0-9\\-._~!$&\'"()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\\-._~!$&\'"()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,"uri-template":/^(?:(?:[^\\x00-\\x20"\'<>%\\\\^`{|}]|%[0-9a-f]{2})|\\{[+#./;?&=,!@|]?(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\\*)?(?:,(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\\*)?)*\\})*$/i,url:/^(?:https?|ftp):\\/\\/(?:\\S+(?::\\S*)?@)?(?:(?!(?:10|127)(?:\\.\\d{1,3}){3})(?!(?:169\\.254|192\\.168)(?:\\.\\d{1,3}){2})(?!172\\.(?:1[6-9]|2\\d|3[0-1])(?:\\.\\d{1,3}){2})(?:[1-9]\\d?|1\\d\\d|2[01]\\d|22[0-3])(?:\\.(?:1?\\d{1,2}|2[0-4]\\d|25[0-5])){2}(?:\\.(?:[1-9]\\d?|1\\d\\d|2[0-4]\\d|25[0-4]))|(?:(?:[a-z0-9\\u{00a1}-\\u{ffff}]+-)*[a-z0-9\\u{00a1}-\\u{ffff}]+)(?:\\.(?:[a-z0-9\\u{00a1}-\\u{ffff}]+-)*[a-z0-9\\u{00a1}-\\u{ffff}]+)*(?:\\.(?:[a-z\\u{00a1}-\\u{ffff}]{2,})))(?::\\d{2,5})?(?:\\/[^\\s]*)?$/iu,email:/^[a-z0-9!#$%&\'*+/=?^_`{|}~-]+(?:\\.[a-z0-9!#$%&\'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i,hostname:/^(?=.{1,253}\\.?$)[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\\.[a-z0-9](?:[-0-9a-z]{0,61}[0-9a-z])?)*\\.?$/i,ipv4:/^(?:(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)\\.){3}(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)$/,ipv6:/^((([0-9a-f]{1,4}:){7}([0-9a-f]{1,4}|:))|(([0-9a-f]{1,4}:){6}(:[0-9a-f]{1,4}|((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9a-f]{1,4}:){5}(((:[0-9a-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9a-f]{1,4}:){4}(((:[0-9a-f]{1,4}){1,3})|((:[0-9a-f]{1,4})?:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9a-f]{1,4}:){3}(((:[0-9a-f]{1,4}){1,4})|((:[0-9a-f]{1,4}){0,2}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9a-f]{1,4}:){2}(((:[0-9a-f]{1,4}){1,5})|((:[0-9a-f]{1,4}){0,3}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9a-f]{1,4}:){1}(((:[0-9a-f]{1,4}){1,6})|((:[0-9a-f]{1,4}){0,4}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(:(((:[0-9a-f]{1,4}){1,7})|((:[0-9a-f]{1,4}){0,5}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:)))$/i,regex:Fe,uuid:/^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i,"json-pointer":/^(?:\\/(?:[^~/]|~0|~1)*)*$/,"json-pointer-uri-fragment":/^#(?:\\/(?:[a-z0-9_\\-.!$&\'()*+,;:=@]|%[0-9a-f]{2}|~0|~1)*)*$/i,"relative-json-pointer":/^(?:0|[1-9][0-9]*)(?:#|(?:\\/(?:[^~/]|~0|~1)*)*)$/,byte:ae,int32:{type:"number",validate:ve},int64:{type:"number",validate:ge},float:{type:"number",validate:_e},double:{type:"number",validate:_e},password:!0,binary:!0},r.fastFormats={...r.fullFormats,date:a(/^\\d\\d\\d\\d-[0-1]\\d-[0-3]\\d$/,n),time:a(/^(?:[0-2]\\d:[0-5]\\d:[0-5]\\d|23:59:60)(?:\\.\\d+)?(?:z|[+-]\\d\\d(?::?\\d\\d)?)$/i,o),"date-time":a(/^\\d\\d\\d\\d-[0-1]\\d-[0-3]\\dt(?:[0-2]\\d:[0-5]\\d:[0-5]\\d|23:59:60)(?:\\.\\d+)?(?:z|[+-]\\d\\d(?::?\\d\\d)?)$/i,w),"iso-time":a(/^(?:[0-2]\\d:[0-5]\\d:[0-5]\\d|23:59:60)(?:\\.\\d+)?(?:z|[+-]\\d\\d(?::?\\d\\d)?)?$/i,h),"iso-date-time":a(/^\\d\\d\\d\\d-[0-1]\\d-[0-3]\\d[t\\s](?:[0-2]\\d:[0-5]\\d:[0-5]\\d|23:59:60)(?:\\.\\d+)?(?:z|[+-]\\d\\d(?::?\\d\\d)?)?$/i,q),uri:/^(?:[a-z][a-z0-9+\\-.]*:)(?:\\/?\\/)?[^\\s]*$/i,"uri-reference":/^(?:(?:[a-z][a-z0-9+\\-.]*:)?\\/?\\/)?(?:[^\\\\\\s#][^\\s#]*)?(?:#[^\\\\\\s]*)?$/i,email:/^[a-z0-9.!#$%&\'*+/=?^_`{|}~-]+@[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$/i},r.formatNames=Object.keys(r.fullFormats);function s(U){return U%4===0&&(U%100!==0||U%400===0)}var d=/^(\\d\\d\\d\\d)-(\\d\\d)-(\\d\\d)$/,u=[0,31,28,31,30,31,30,31,31,30,31,30,31];function e(U){let le=d.exec(U);if(!le)return!1;let ke=+le[1],we=+le[2],L=+le[3];return we>=1&&we<=12&&L>=1&&L<=(we===2&&s(ke)?29:u[we])}function n(U,le){if(U&&le)return U>le?1:U<le?-1:0}var l=/^(\\d\\d):(\\d\\d):(\\d\\d(?:\\.\\d+)?)(z|([+-])(\\d\\d)(?::?(\\d\\d))?)?$/i;function i(U){return function(le){let ke=l.exec(le);if(!ke)return!1;let we=+ke[1],L=+ke[2],br=+ke[3],At=ke[4],It=ke[5]==="-"?-1:1,Er=+(ke[6]||0),Wt=+(ke[7]||0);if(Er>23||Wt>59||U&&!At)return!1;if(we<=23&&L<=59&&br<60)return!0;let _t=L-Wt*It,qe=we-Er*It-(_t<0?1:0);return(qe===23||qe===-1)&&(_t===59||_t===-1)&&br<61}}function o(U,le){if(!(U&&le))return;let ke=new Date("2020-01-01T"+U).valueOf(),we=new Date("2020-01-01T"+le).valueOf();if(ke&&we)return ke-we}function h(U,le){if(!(U&&le))return;let ke=l.exec(U),we=l.exec(le);if(ke&&we)return U=ke[1]+ke[2]+ke[3],le=we[1]+we[2]+we[3],U>le?1:U<le?-1:0}var c=/t|\\s/i;function f(U){let le=i(U);return function(ke){let we=ke.split(c);return we.length===2&&e(we[0])&&le(we[1])}}function w(U,le){if(!(U&&le))return;let ke=new Date(U).valueOf(),we=new Date(le).valueOf();if(ke&&we)return ke-we}function q(U,le){if(!(U&&le))return;let[ke,we]=U.split(c),[L,br]=le.split(c),At=n(ke,L);if(At!==void 0)return At||o(we,br)}var H=/\\/|:/,R=/^(?:[a-z][a-z0-9+\\-.]*:)(?:\\/?\\/(?:(?:[a-z0-9\\-._~!$&\'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\\d|[01]?\\d\\d?)\\.){3}(?:25[0-5]|2[0-4]\\d|[01]?\\d\\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\\.[a-z0-9\\-._~!$&\'()*+,;=:]+)\\]|(?:(?:25[0-5]|2[0-4]\\d|[01]?\\d\\d?)\\.){3}(?:25[0-5]|2[0-4]\\d|[01]?\\d\\d?)|(?:[a-z0-9\\-._~!$&\'()*+,;=]|%[0-9a-f]{2})*)(?::\\d*)?(?:\\/(?:[a-z0-9\\-._~!$&\'()*+,;=:@]|%[0-9a-f]{2})*)*|\\/(?:(?:[a-z0-9\\-._~!$&\'()*+,;=:@]|%[0-9a-f]{2})+(?:\\/(?:[a-z0-9\\-._~!$&\'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\\-._~!$&\'()*+,;=:@]|%[0-9a-f]{2})+(?:\\/(?:[a-z0-9\\-._~!$&\'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\\?(?:[a-z0-9\\-._~!$&\'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\\-._~!$&\'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i;function W(U){return H.test(U)&&R.test(U)}var re=/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/gm;function ae(U){return re.lastIndex=0,re.test(U)}var oe=-(2**31),me=2**31-1;function ve(U){return Number.isInteger(U)&&U<=me&&U>=oe}function ge(U){return Number.isInteger(U)}function _e(){return!0}var Ot=/[^\\\\]\\\\Z/;function Fe(U){if(Ot.test(U))return!1;try{return new RegExp(U),!0}catch{return!1}}}),Gh=kd,_l={properties:{source:{properties:{base:{type:["string","null"]},head:{type:["string","null"]}}}}},Gn={properties:{type:{enum:["change","file","hunk","line-range","visual-target","visual-region","finding","verification-gap"]},ref:{type:"string",minLength:1},path:{type:"string"},side:{enum:["before","after","diff"]},startLine:{type:"integer",minimum:1},endLine:{type:"integer",minimum:1},targetRef:{type:"string"},region:{type:"object",additionalProperties:!1,required:["x","y","width","height"],properties:{x:{type:"number",minimum:0,maximum:1},y:{type:"number",minimum:0,maximum:1},width:{type:"number",exclusiveMinimum:0,maximum:1},height:{type:"number",exclusiveMinimum:0,maximum:1}}},selectorHint:{type:"string"},fingerprint:{type:"string",pattern:"^[a-f0-9]{64}$"}}},it=Jh().default,Va=Object.prototype.hasOwnProperty,js=new RegExp("^report[-:][A-Za-z0-9._:-]+$","u"),rs=new RegExp("^[a-f0-9]{64}$","u"),la=Yh().fullFormats["date-time"];function kd(r,{instancePath:a="",parentData:s,parentDataProperty:d,rootData:u=r}={}){let e=null,n=0;if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.schemaVersion===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"schemaVersion"},message:"must have required property \'schemaVersion\'"};e===null?e=[l]:e.push(l),n++}if(r.source===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"source"},message:"must have required property \'source\'"};e===null?e=[l]:e.push(l),n++}if(r.state===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"state"},message:"must have required property \'state\'"};e===null?e=[l]:e.push(l),n++}if(r.threads===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"threads"},message:"must have required property \'threads\'"};e===null?e=[l]:e.push(l),n++}if(r.events===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"events"},message:"must have required property \'events\'"};e===null?e=[l]:e.push(l),n++}if(r.anchorCatalog===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"anchorCatalog"},message:"must have required property \'anchorCatalog\'"};e===null?e=[l]:e.push(l),n++}if(r.exportedAt===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"exportedAt"},message:"must have required property \'exportedAt\'"};e===null?e=[l]:e.push(l),n++}for(let l in r)if(!(l==="schemaVersion"||l==="source"||l==="state"||l==="threads"||l==="events"||l==="anchorCatalog"||l==="exportedAt")){let i={instancePath:a,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:l},message:"must NOT have additional properties"};e===null?e=[i]:e.push(i),n++}if(r.schemaVersion!==void 0&&r.schemaVersion!=="1.0"){let l={instancePath:a+"/schemaVersion",schemaPath:"#/properties/schemaVersion/const",keyword:"const",params:{allowedValue:"1.0"},message:"must be equal to constant"};e===null?e=[l]:e.push(l),n++}if(r.source!==void 0){let l=r.source;if(l&&typeof l=="object"&&!Array.isArray(l)){if(l.reportId===void 0){let i={instancePath:a+"/source",schemaPath:"#/properties/source/required",keyword:"required",params:{missingProperty:"reportId"},message:"must have required property \'reportId\'"};e===null?e=[i]:e.push(i),n++}if(l.reportFingerprint===void 0){let i={instancePath:a+"/source",schemaPath:"#/properties/source/required",keyword:"required",params:{missingProperty:"reportFingerprint"},message:"must have required property \'reportFingerprint\'"};e===null?e=[i]:e.push(i),n++}if(l.base===void 0){let i={instancePath:a+"/source",schemaPath:"#/properties/source/required",keyword:"required",params:{missingProperty:"base"},message:"must have required property \'base\'"};e===null?e=[i]:e.push(i),n++}if(l.head===void 0){let i={instancePath:a+"/source",schemaPath:"#/properties/source/required",keyword:"required",params:{missingProperty:"head"},message:"must have required property \'head\'"};e===null?e=[i]:e.push(i),n++}for(let i in l)if(!(i==="reportId"||i==="reportFingerprint"||i==="base"||i==="head")){let o={instancePath:a+"/source",schemaPath:"#/properties/source/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:i},message:"must NOT have additional properties"};e===null?e=[o]:e.push(o),n++}if(l.reportId!==void 0){let i=l.reportId;if(typeof i=="string"){if(it(i)>256){let o={instancePath:a+"/source/reportId",schemaPath:"#/properties/source/properties/reportId/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};e===null?e=[o]:e.push(o),n++}if(!js.test(i)){let o={instancePath:a+"/source/reportId",schemaPath:"#/properties/source/properties/reportId/pattern",keyword:"pattern",params:{pattern:"^report[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^report[-:][A-Za-z0-9._:-]+$"\'};e===null?e=[o]:e.push(o),n++}}else{let o={instancePath:a+"/source/reportId",schemaPath:"#/properties/source/properties/reportId/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[o]:e.push(o),n++}}if(l.reportFingerprint!==void 0){let i=l.reportFingerprint;if(typeof i=="string"){if(!rs.test(i)){let o={instancePath:a+"/source/reportFingerprint",schemaPath:"#/properties/source/properties/reportFingerprint/pattern",keyword:"pattern",params:{pattern:"^[a-f0-9]{64}$"},message:\'must match pattern "^[a-f0-9]{64}$"\'};e===null?e=[o]:e.push(o),n++}}else{let o={instancePath:a+"/source/reportFingerprint",schemaPath:"#/properties/source/properties/reportFingerprint/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[o]:e.push(o),n++}}if(l.base!==void 0){let i=l.base;if(typeof i!="string"&&i!==null){let o={instancePath:a+"/source/base",schemaPath:"#/properties/source/properties/base/type",keyword:"type",params:{type:_l.properties.source.properties.base.type},message:"must be string,null"};e===null?e=[o]:e.push(o),n++}}if(l.head!==void 0){let i=l.head;if(typeof i!="string"&&i!==null){let o={instancePath:a+"/source/head",schemaPath:"#/properties/source/properties/head/type",keyword:"type",params:{type:_l.properties.source.properties.head.type},message:"must be string,null"};e===null?e=[o]:e.push(o),n++}}}else{let i={instancePath:a+"/source",schemaPath:"#/properties/source/type",keyword:"type",params:{type:"object"},message:"must be object"};e===null?e=[i]:e.push(i),n++}}if(r.state!==void 0){let l=r.state;if(!(l&&typeof l=="object"&&!Array.isArray(l))){let i={instancePath:a+"/state",schemaPath:"#/properties/state/type",keyword:"type",params:{type:"object"},message:"must be object"};e===null?e=[i]:e.push(i),n++}}if(r.threads!==void 0){let l=r.threads;if(Array.isArray(l)){let i=l.length;for(let o=0;o<i;o++){let h=l[o];if(!(h&&typeof h=="object"&&!Array.isArray(h))){let c={instancePath:a+"/threads/"+o,schemaPath:"#/properties/threads/items/type",keyword:"type",params:{type:"object"},message:"must be object"};e===null?e=[c]:e.push(c),n++}}}else{let i={instancePath:a+"/threads",schemaPath:"#/properties/threads/type",keyword:"type",params:{type:"array"},message:"must be array"};e===null?e=[i]:e.push(i),n++}}if(r.events!==void 0){let l=r.events;if(Array.isArray(l)){let i=l.length;for(let o=0;o<i;o++){let h=l[o];if(!(h&&typeof h=="object"&&!Array.isArray(h))){let c={instancePath:a+"/events/"+o,schemaPath:"#/properties/events/items/type",keyword:"type",params:{type:"object"},message:"must be object"};e===null?e=[c]:e.push(c),n++}}}else{let i={instancePath:a+"/events",schemaPath:"#/properties/events/type",keyword:"type",params:{type:"array"},message:"must be array"};e===null?e=[i]:e.push(i),n++}}if(r.anchorCatalog!==void 0){let l=r.anchorCatalog;if(Array.isArray(l)){let i=l.length;for(let o=0;o<i;o++){let h=l[o];if(h&&typeof h=="object"&&!Array.isArray(h)){if(h.type===void 0){let c={instancePath:a+"/anchorCatalog/"+o,schemaPath:"#/$defs/reviewAnchor/required",keyword:"required",params:{missingProperty:"type"},message:"must have required property \'type\'"};e===null?e=[c]:e.push(c),n++}if(h.ref===void 0){let c={instancePath:a+"/anchorCatalog/"+o,schemaPath:"#/$defs/reviewAnchor/required",keyword:"required",params:{missingProperty:"ref"},message:"must have required property \'ref\'"};e===null?e=[c]:e.push(c),n++}if(h.fingerprint===void 0){let c={instancePath:a+"/anchorCatalog/"+o,schemaPath:"#/$defs/reviewAnchor/required",keyword:"required",params:{missingProperty:"fingerprint"},message:"must have required property \'fingerprint\'"};e===null?e=[c]:e.push(c),n++}for(let c in h)if(!Va.call(Gn.properties,c)){let f={instancePath:a+"/anchorCatalog/"+o,schemaPath:"#/$defs/reviewAnchor/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:c},message:"must NOT have additional properties"};e===null?e=[f]:e.push(f),n++}if(h.type!==void 0){let c=h.type;if(!(c==="change"||c==="file"||c==="hunk"||c==="line-range"||c==="visual-target"||c==="visual-region"||c==="finding"||c==="verification-gap")){let f={instancePath:a+"/anchorCatalog/"+o+"/type",schemaPath:"#/$defs/reviewAnchor/properties/type/enum",keyword:"enum",params:{allowedValues:Gn.properties.type.enum},message:"must be equal to one of the allowed values"};e===null?e=[f]:e.push(f),n++}}if(h.ref!==void 0){let c=h.ref;if(typeof c=="string"){if(it(c)<1){let f={instancePath:a+"/anchorCatalog/"+o+"/ref",schemaPath:"#/$defs/reviewAnchor/properties/ref/minLength",keyword:"minLength",params:{limit:1},message:"must NOT have fewer than 1 characters"};e===null?e=[f]:e.push(f),n++}}else{let f={instancePath:a+"/anchorCatalog/"+o+"/ref",schemaPath:"#/$defs/reviewAnchor/properties/ref/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[f]:e.push(f),n++}}if(h.path!==void 0&&typeof h.path!="string"){let c={instancePath:a+"/anchorCatalog/"+o+"/path",schemaPath:"#/$defs/reviewAnchor/properties/path/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[c]:e.push(c),n++}if(h.side!==void 0){let c=h.side;if(!(c==="before"||c==="after"||c==="diff")){let f={instancePath:a+"/anchorCatalog/"+o+"/side",schemaPath:"#/$defs/reviewAnchor/properties/side/enum",keyword:"enum",params:{allowedValues:Gn.properties.side.enum},message:"must be equal to one of the allowed values"};e===null?e=[f]:e.push(f),n++}}if(h.startLine!==void 0){let c=h.startLine;if(!(typeof c=="number"&&!(c%1)&&!isNaN(c))){let f={instancePath:a+"/anchorCatalog/"+o+"/startLine",schemaPath:"#/$defs/reviewAnchor/properties/startLine/type",keyword:"type",params:{type:"integer"},message:"must be integer"};e===null?e=[f]:e.push(f),n++}if(typeof c=="number"&&(c<1||isNaN(c))){let f={instancePath:a+"/anchorCatalog/"+o+"/startLine",schemaPath:"#/$defs/reviewAnchor/properties/startLine/minimum",keyword:"minimum",params:{comparison:">=",limit:1},message:"must be >= 1"};e===null?e=[f]:e.push(f),n++}}if(h.endLine!==void 0){let c=h.endLine;if(!(typeof c=="number"&&!(c%1)&&!isNaN(c))){let f={instancePath:a+"/anchorCatalog/"+o+"/endLine",schemaPath:"#/$defs/reviewAnchor/properties/endLine/type",keyword:"type",params:{type:"integer"},message:"must be integer"};e===null?e=[f]:e.push(f),n++}if(typeof c=="number"&&(c<1||isNaN(c))){let f={instancePath:a+"/anchorCatalog/"+o+"/endLine",schemaPath:"#/$defs/reviewAnchor/properties/endLine/minimum",keyword:"minimum",params:{comparison:">=",limit:1},message:"must be >= 1"};e===null?e=[f]:e.push(f),n++}}if(h.targetRef!==void 0&&typeof h.targetRef!="string"){let c={instancePath:a+"/anchorCatalog/"+o+"/targetRef",schemaPath:"#/$defs/reviewAnchor/properties/targetRef/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[c]:e.push(c),n++}if(h.region!==void 0){let c=h.region;if(c&&typeof c=="object"&&!Array.isArray(c)){if(c.x===void 0){let f={instancePath:a+"/anchorCatalog/"+o+"/region",schemaPath:"#/$defs/reviewAnchor/properties/region/required",keyword:"required",params:{missingProperty:"x"},message:"must have required property \'x\'"};e===null?e=[f]:e.push(f),n++}if(c.y===void 0){let f={instancePath:a+"/anchorCatalog/"+o+"/region",schemaPath:"#/$defs/reviewAnchor/properties/region/required",keyword:"required",params:{missingProperty:"y"},message:"must have required property \'y\'"};e===null?e=[f]:e.push(f),n++}if(c.width===void 0){let f={instancePath:a+"/anchorCatalog/"+o+"/region",schemaPath:"#/$defs/reviewAnchor/properties/region/required",keyword:"required",params:{missingProperty:"width"},message:"must have required property \'width\'"};e===null?e=[f]:e.push(f),n++}if(c.height===void 0){let f={instancePath:a+"/anchorCatalog/"+o+"/region",schemaPath:"#/$defs/reviewAnchor/properties/region/required",keyword:"required",params:{missingProperty:"height"},message:"must have required property \'height\'"};e===null?e=[f]:e.push(f),n++}for(let f in c)if(!(f==="x"||f==="y"||f==="width"||f==="height")){let w={instancePath:a+"/anchorCatalog/"+o+"/region",schemaPath:"#/$defs/reviewAnchor/properties/region/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:f},message:"must NOT have additional properties"};e===null?e=[w]:e.push(w),n++}if(c.x!==void 0){let f=c.x;if(typeof f=="number"){if(f>1||isNaN(f)){let w={instancePath:a+"/anchorCatalog/"+o+"/region/x",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/x/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};e===null?e=[w]:e.push(w),n++}if(f<0||isNaN(f)){let w={instancePath:a+"/anchorCatalog/"+o+"/region/x",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/x/minimum",keyword:"minimum",params:{comparison:">=",limit:0},message:"must be >= 0"};e===null?e=[w]:e.push(w),n++}}else{let w={instancePath:a+"/anchorCatalog/"+o+"/region/x",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/x/type",keyword:"type",params:{type:"number"},message:"must be number"};e===null?e=[w]:e.push(w),n++}}if(c.y!==void 0){let f=c.y;if(typeof f=="number"){if(f>1||isNaN(f)){let w={instancePath:a+"/anchorCatalog/"+o+"/region/y",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/y/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};e===null?e=[w]:e.push(w),n++}if(f<0||isNaN(f)){let w={instancePath:a+"/anchorCatalog/"+o+"/region/y",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/y/minimum",keyword:"minimum",params:{comparison:">=",limit:0},message:"must be >= 0"};e===null?e=[w]:e.push(w),n++}}else{let w={instancePath:a+"/anchorCatalog/"+o+"/region/y",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/y/type",keyword:"type",params:{type:"number"},message:"must be number"};e===null?e=[w]:e.push(w),n++}}if(c.width!==void 0){let f=c.width;if(typeof f=="number"){if(f>1||isNaN(f)){let w={instancePath:a+"/anchorCatalog/"+o+"/region/width",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/width/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};e===null?e=[w]:e.push(w),n++}if(f<=0||isNaN(f)){let w={instancePath:a+"/anchorCatalog/"+o+"/region/width",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/width/exclusiveMinimum",keyword:"exclusiveMinimum",params:{comparison:">",limit:0},message:"must be > 0"};e===null?e=[w]:e.push(w),n++}}else{let w={instancePath:a+"/anchorCatalog/"+o+"/region/width",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/width/type",keyword:"type",params:{type:"number"},message:"must be number"};e===null?e=[w]:e.push(w),n++}}if(c.height!==void 0){let f=c.height;if(typeof f=="number"){if(f>1||isNaN(f)){let w={instancePath:a+"/anchorCatalog/"+o+"/region/height",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/height/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};e===null?e=[w]:e.push(w),n++}if(f<=0||isNaN(f)){let w={instancePath:a+"/anchorCatalog/"+o+"/region/height",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/height/exclusiveMinimum",keyword:"exclusiveMinimum",params:{comparison:">",limit:0},message:"must be > 0"};e===null?e=[w]:e.push(w),n++}}else{let w={instancePath:a+"/anchorCatalog/"+o+"/region/height",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/height/type",keyword:"type",params:{type:"number"},message:"must be number"};e===null?e=[w]:e.push(w),n++}}}else{let f={instancePath:a+"/anchorCatalog/"+o+"/region",schemaPath:"#/$defs/reviewAnchor/properties/region/type",keyword:"type",params:{type:"object"},message:"must be object"};e===null?e=[f]:e.push(f),n++}}if(h.selectorHint!==void 0&&typeof h.selectorHint!="string"){let c={instancePath:a+"/anchorCatalog/"+o+"/selectorHint",schemaPath:"#/$defs/reviewAnchor/properties/selectorHint/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[c]:e.push(c),n++}if(h.fingerprint!==void 0){let c=h.fingerprint;if(typeof c=="string"){if(!rs.test(c)){let f={instancePath:a+"/anchorCatalog/"+o+"/fingerprint",schemaPath:"#/$defs/reviewAnchor/properties/fingerprint/pattern",keyword:"pattern",params:{pattern:"^[a-f0-9]{64}$"},message:\'must match pattern "^[a-f0-9]{64}$"\'};e===null?e=[f]:e.push(f),n++}}else{let f={instancePath:a+"/anchorCatalog/"+o+"/fingerprint",schemaPath:"#/$defs/reviewAnchor/properties/fingerprint/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[f]:e.push(f),n++}}}else{let c={instancePath:a+"/anchorCatalog/"+o,schemaPath:"#/$defs/reviewAnchor/type",keyword:"type",params:{type:"object"},message:"must be object"};e===null?e=[c]:e.push(c),n++}}}else{let i={instancePath:a+"/anchorCatalog",schemaPath:"#/properties/anchorCatalog/type",keyword:"type",params:{type:"array"},message:"must be array"};e===null?e=[i]:e.push(i),n++}}if(r.exportedAt!==void 0){let l=r.exportedAt;if(typeof l=="string"){if(!la.validate(l)){let i={instancePath:a+"/exportedAt",schemaPath:"#/properties/exportedAt/format",keyword:"format",params:{format:"date-time"},message:\'must match format "date-time"\'};e===null?e=[i]:e.push(i),n++}}else{let i={instancePath:a+"/exportedAt",schemaPath:"#/properties/exportedAt/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[i]:e.push(i),n++}}}else{let l={instancePath:a,schemaPath:"#/type",keyword:"type",params:{type:"object"},message:"must be object"};e===null?e=[l]:e.push(l),n++}return kd.errors=e,n===0}var Qh=$d,Ka={properties:{schemaVersion:{const:"1.0"},id:{type:"string",pattern:"^event[-:][A-Za-z0-9._:-]+$",maxLength:256},reportId:{type:"string",pattern:"^report[-:][A-Za-z0-9._:-]+$",maxLength:256},sequence:{type:"integer",minimum:1},type:{enum:["viewed.changed","judgment.changed","thread.created","thread.message-added","thread.resolved","state.imported","agent-attention.changed","feedback-batch.stored","feedback-batch.claimed","feedback-batch.released","feedback-batch.answered"]},createdAt:{type:"string",format:"date-time"},anchor:{$ref:"#/$defs/reviewAnchor"},changeId:{type:"string",pattern:"^change[-:]"},viewState:{enum:["unseen","viewed","stale"]},judgmentState:{enum:["unreviewed","reviewed","follow-up","blocked","stale"]},threadId:{type:"string",pattern:"^thread[-:][A-Za-z0-9._:-]+$",maxLength:256},messageId:{type:"string",pattern:"^message[-:][A-Za-z0-9._:-]+$",maxLength:256},sourceReportId:{type:"string",pattern:"^report[-:][A-Za-z0-9._:-]+$",maxLength:256},attentionState:{enum:["none","requested","batched","submitted","acknowledged","answered","stale"]},batchId:{type:"string",pattern:"^fb[-:][A-Za-z0-9._:-]+$",maxLength:256},threadIds:{type:"array",maxItems:20,items:{type:"string",pattern:"^thread[-:][A-Za-z0-9._:-]+$",maxLength:256},uniqueItems:!0},itemIds:{type:"array",maxItems:20,items:{type:"string",pattern:"^item[-:][A-Za-z0-9._:-]+$",maxLength:256},uniqueItems:!0},itemCount:{type:"integer",minimum:1,maximum:20},deliveryMode:{enum:["direct-same-session","return-to-session","export-only"]},originSessionMatched:{type:"boolean"}}},Qn={properties:{type:{enum:["change","file","hunk","line-range","visual-target","visual-region","finding","verification-gap"]},ref:{type:"string",minLength:1},path:{type:"string"},side:{enum:["before","after","diff"]},startLine:{type:"integer",minimum:1},endLine:{type:"integer",minimum:1},targetRef:{type:"string"},region:{type:"object",additionalProperties:!1,required:["x","y","width","height"],properties:{x:{type:"number",minimum:0,maximum:1},y:{type:"number",minimum:0,maximum:1},width:{type:"number",exclusiveMinimum:0,maximum:1},height:{type:"number",exclusiveMinimum:0,maximum:1}}},selectorHint:{type:"string"},fingerprint:{type:"string",pattern:"^[a-f0-9]{64}$"}}},Xh=new RegExp("^event[-:][A-Za-z0-9._:-]+$","u"),ef=new RegExp("^change[-:]","u"),Os=new RegExp("^thread[-:][A-Za-z0-9._:-]+$","u"),xd=new RegExp("^message[-:][A-Za-z0-9._:-]+$","u"),Ad=new RegExp("^fb[-:][A-Za-z0-9._:-]+$","u"),Id=new RegExp("^item[-:][A-Za-z0-9._:-]+$","u");function $d(r,{instancePath:a="",parentData:s,parentDataProperty:d,rootData:u=r}={}){let e=null,n=0,l=n,i=!0,o=n;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.type!==void 0&&r.type!=="viewed.changed"){let g={};e===null?e=[g]:e.push(g),n++}var h=o===n;if(n=l,e!==null&&(l?e.length=l:e=null),h){let g=n;if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.anchor===void 0){let k={instancePath:a,schemaPath:"#/allOf/0/then/required",keyword:"required",params:{missingProperty:"anchor"},message:"must have required property \'anchor\'"};e===null?e=[k]:e.push(k),n++}if(r.viewState===void 0){let k={instancePath:a,schemaPath:"#/allOf/0/then/required",keyword:"required",params:{missingProperty:"viewState"},message:"must have required property \'viewState\'"};e===null?e=[k]:e.push(k),n++}}var h=g===n;i=h}if(!i){let g={instancePath:a,schemaPath:"#/allOf/0/if",keyword:"if",params:{failingKeyword:"then"},message:\'must match "then" schema\'};e===null?e=[g]:e.push(g),n++}let c=n,f=!0,w=n;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.type!==void 0&&r.type!=="judgment.changed"){let g={};e===null?e=[g]:e.push(g),n++}var q=w===n;if(n=c,e!==null&&(c?e.length=c:e=null),q){let g=n;if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.changeId===void 0){let k={instancePath:a,schemaPath:"#/allOf/1/then/required",keyword:"required",params:{missingProperty:"changeId"},message:"must have required property \'changeId\'"};e===null?e=[k]:e.push(k),n++}if(r.judgmentState===void 0){let k={instancePath:a,schemaPath:"#/allOf/1/then/required",keyword:"required",params:{missingProperty:"judgmentState"},message:"must have required property \'judgmentState\'"};e===null?e=[k]:e.push(k),n++}}var q=g===n;f=q}if(!f){let g={instancePath:a,schemaPath:"#/allOf/1/if",keyword:"if",params:{failingKeyword:"then"},message:\'must match "then" schema\'};e===null?e=[g]:e.push(g),n++}let H=n,R=!0,W=n;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.type!==void 0&&r.type!=="thread.created"){let g={};e===null?e=[g]:e.push(g),n++}var re=W===n;if(n=H,e!==null&&(H?e.length=H:e=null),re){let g=n;if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.anchor===void 0){let k={instancePath:a,schemaPath:"#/allOf/2/then/required",keyword:"required",params:{missingProperty:"anchor"},message:"must have required property \'anchor\'"};e===null?e=[k]:e.push(k),n++}if(r.threadId===void 0){let k={instancePath:a,schemaPath:"#/allOf/2/then/required",keyword:"required",params:{missingProperty:"threadId"},message:"must have required property \'threadId\'"};e===null?e=[k]:e.push(k),n++}if(r.messageId===void 0){let k={instancePath:a,schemaPath:"#/allOf/2/then/required",keyword:"required",params:{missingProperty:"messageId"},message:"must have required property \'messageId\'"};e===null?e=[k]:e.push(k),n++}}var re=g===n;R=re}if(!R){let g={instancePath:a,schemaPath:"#/allOf/2/if",keyword:"if",params:{failingKeyword:"then"},message:\'must match "then" schema\'};e===null?e=[g]:e.push(g),n++}let ae=n,oe=!0,me=n;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.type!==void 0&&r.type!=="thread.message-added"){let g={};e===null?e=[g]:e.push(g),n++}var ve=me===n;if(n=ae,e!==null&&(ae?e.length=ae:e=null),ve){let g=n;if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.threadId===void 0){let k={instancePath:a,schemaPath:"#/allOf/3/then/required",keyword:"required",params:{missingProperty:"threadId"},message:"must have required property \'threadId\'"};e===null?e=[k]:e.push(k),n++}if(r.messageId===void 0){let k={instancePath:a,schemaPath:"#/allOf/3/then/required",keyword:"required",params:{missingProperty:"messageId"},message:"must have required property \'messageId\'"};e===null?e=[k]:e.push(k),n++}}var ve=g===n;oe=ve}if(!oe){let g={instancePath:a,schemaPath:"#/allOf/3/if",keyword:"if",params:{failingKeyword:"then"},message:\'must match "then" schema\'};e===null?e=[g]:e.push(g),n++}let ge=n,_e=!0,Ot=n;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.type!==void 0&&r.type!=="thread.resolved"){let g={};e===null?e=[g]:e.push(g),n++}var Fe=Ot===n;if(n=ge,e!==null&&(ge?e.length=ge:e=null),Fe){let g=n;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.threadId===void 0){let k={instancePath:a,schemaPath:"#/allOf/4/then/required",keyword:"required",params:{missingProperty:"threadId"},message:"must have required property \'threadId\'"};e===null?e=[k]:e.push(k),n++}var Fe=g===n;_e=Fe}if(!_e){let g={instancePath:a,schemaPath:"#/allOf/4/if",keyword:"if",params:{failingKeyword:"then"},message:\'must match "then" schema\'};e===null?e=[g]:e.push(g),n++}let U=n,le=!0,ke=n;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.type!==void 0&&r.type!=="state.imported"){let g={};e===null?e=[g]:e.push(g),n++}var we=ke===n;if(n=U,e!==null&&(U?e.length=U:e=null),we){let g=n;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.sourceReportId===void 0){let k={instancePath:a,schemaPath:"#/allOf/5/then/required",keyword:"required",params:{missingProperty:"sourceReportId"},message:"must have required property \'sourceReportId\'"};e===null?e=[k]:e.push(k),n++}var we=g===n;le=we}if(!le){let g={instancePath:a,schemaPath:"#/allOf/5/if",keyword:"if",params:{failingKeyword:"then"},message:\'must match "then" schema\'};e===null?e=[g]:e.push(g),n++}let L=n,br=!0,At=n;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.type!==void 0&&r.type!=="agent-attention.changed"){let g={};e===null?e=[g]:e.push(g),n++}var It=At===n;if(n=L,e!==null&&(L?e.length=L:e=null),It){let g=n;if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.threadId===void 0){let k={instancePath:a,schemaPath:"#/allOf/6/then/required",keyword:"required",params:{missingProperty:"threadId"},message:"must have required property \'threadId\'"};e===null?e=[k]:e.push(k),n++}if(r.attentionState===void 0){let k={instancePath:a,schemaPath:"#/allOf/6/then/required",keyword:"required",params:{missingProperty:"attentionState"},message:"must have required property \'attentionState\'"};e===null?e=[k]:e.push(k),n++}}var It=g===n;br=It}if(!br){let g={instancePath:a,schemaPath:"#/allOf/6/if",keyword:"if",params:{failingKeyword:"then"},message:\'must match "then" schema\'};e===null?e=[g]:e.push(g),n++}let Er=n,Wt=!0,_t=n;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.type!==void 0&&r.type!=="feedback-batch.stored"){let g={};e===null?e=[g]:e.push(g),n++}var qe=_t===n;if(n=Er,e!==null&&(Er?e.length=Er:e=null),qe){let g=n;if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.batchId===void 0){let k={instancePath:a,schemaPath:"#/allOf/7/then/required",keyword:"required",params:{missingProperty:"batchId"},message:"must have required property \'batchId\'"};e===null?e=[k]:e.push(k),n++}if(r.threadIds===void 0){let k={instancePath:a,schemaPath:"#/allOf/7/then/required",keyword:"required",params:{missingProperty:"threadIds"},message:"must have required property \'threadIds\'"};e===null?e=[k]:e.push(k),n++}if(r.itemCount===void 0){let k={instancePath:a,schemaPath:"#/allOf/7/then/required",keyword:"required",params:{missingProperty:"itemCount"},message:"must have required property \'itemCount\'"};e===null?e=[k]:e.push(k),n++}if(r.deliveryMode===void 0){let k={instancePath:a,schemaPath:"#/allOf/7/then/required",keyword:"required",params:{missingProperty:"deliveryMode"},message:"must have required property \'deliveryMode\'"};e===null?e=[k]:e.push(k),n++}}var qe=g===n;Wt=qe}if(!Wt){let g={instancePath:a,schemaPath:"#/allOf/7/if",keyword:"if",params:{failingKeyword:"then"},message:\'must match "then" schema\'};e===null?e=[g]:e.push(g),n++}let j=n,cr=!0,hr=n;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.type!==void 0&&r.type!=="feedback-batch.claimed"){let g={};e===null?e=[g]:e.push(g),n++}var T=hr===n;if(n=j,e!==null&&(j?e.length=j:e=null),T){let g=n;if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.batchId===void 0){let k={instancePath:a,schemaPath:"#/allOf/8/then/required",keyword:"required",params:{missingProperty:"batchId"},message:"must have required property \'batchId\'"};e===null?e=[k]:e.push(k),n++}if(r.originSessionMatched===void 0){let k={instancePath:a,schemaPath:"#/allOf/8/then/required",keyword:"required",params:{missingProperty:"originSessionMatched"},message:"must have required property \'originSessionMatched\'"};e===null?e=[k]:e.push(k),n++}}var T=g===n;cr=T}if(!cr){let g={instancePath:a,schemaPath:"#/allOf/8/if",keyword:"if",params:{failingKeyword:"then"},message:\'must match "then" schema\'};e===null?e=[g]:e.push(g),n++}let Da=n,xa=!0,wt=n;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.type!==void 0&&r.type!=="feedback-batch.released"){let g={};e===null?e=[g]:e.push(g),n++}var Aa=wt===n;if(n=Da,e!==null&&(Da?e.length=Da:e=null),Aa){let g=n;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.batchId===void 0){let k={instancePath:a,schemaPath:"#/allOf/9/then/required",keyword:"required",params:{missingProperty:"batchId"},message:"must have required property \'batchId\'"};e===null?e=[k]:e.push(k),n++}var Aa=g===n;xa=Aa}if(!xa){let g={instancePath:a,schemaPath:"#/allOf/9/if",keyword:"if",params:{failingKeyword:"then"},message:\'must match "then" schema\'};e===null?e=[g]:e.push(g),n++}let ee=n,Tt=!0,Nr=n;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.type!==void 0&&r.type!=="feedback-batch.answered"){let g={};e===null?e=[g]:e.push(g),n++}var ua=Nr===n;if(n=ee,e!==null&&(ee?e.length=ee:e=null),ua){let g=n;if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.batchId===void 0){let k={instancePath:a,schemaPath:"#/allOf/10/then/required",keyword:"required",params:{missingProperty:"batchId"},message:"must have required property \'batchId\'"};e===null?e=[k]:e.push(k),n++}if(r.itemIds===void 0){let k={instancePath:a,schemaPath:"#/allOf/10/then/required",keyword:"required",params:{missingProperty:"itemIds"},message:"must have required property \'itemIds\'"};e===null?e=[k]:e.push(k),n++}}var ua=g===n;Tt=ua}if(!Tt){let g={instancePath:a,schemaPath:"#/allOf/10/if",keyword:"if",params:{failingKeyword:"then"},message:\'must match "then" schema\'};e===null?e=[g]:e.push(g),n++}if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.schemaVersion===void 0){let g={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"schemaVersion"},message:"must have required property \'schemaVersion\'"};e===null?e=[g]:e.push(g),n++}if(r.id===void 0){let g={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"id"},message:"must have required property \'id\'"};e===null?e=[g]:e.push(g),n++}if(r.reportId===void 0){let g={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"reportId"},message:"must have required property \'reportId\'"};e===null?e=[g]:e.push(g),n++}if(r.sequence===void 0){let g={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"sequence"},message:"must have required property \'sequence\'"};e===null?e=[g]:e.push(g),n++}if(r.type===void 0){let g={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"type"},message:"must have required property \'type\'"};e===null?e=[g]:e.push(g),n++}if(r.createdAt===void 0){let g={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"createdAt"},message:"must have required property \'createdAt\'"};e===null?e=[g]:e.push(g),n++}for(let g in r)if(!Va.call(Ka.properties,g)){let b={instancePath:a,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:g},message:"must NOT have additional properties"};e===null?e=[b]:e.push(b),n++}if(r.schemaVersion!==void 0&&r.schemaVersion!=="1.0"){let g={instancePath:a+"/schemaVersion",schemaPath:"#/properties/schemaVersion/const",keyword:"const",params:{allowedValue:"1.0"},message:"must be equal to constant"};e===null?e=[g]:e.push(g),n++}if(r.id!==void 0){let g=r.id;if(typeof g=="string"){if(it(g)>256){let b={instancePath:a+"/id",schemaPath:"#/properties/id/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};e===null?e=[b]:e.push(b),n++}if(!Xh.test(g)){let b={instancePath:a+"/id",schemaPath:"#/properties/id/pattern",keyword:"pattern",params:{pattern:"^event[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^event[-:][A-Za-z0-9._:-]+$"\'};e===null?e=[b]:e.push(b),n++}}else{let b={instancePath:a+"/id",schemaPath:"#/properties/id/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[b]:e.push(b),n++}}if(r.reportId!==void 0){let g=r.reportId;if(typeof g=="string"){if(it(g)>256){let b={instancePath:a+"/reportId",schemaPath:"#/properties/reportId/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};e===null?e=[b]:e.push(b),n++}if(!js.test(g)){let b={instancePath:a+"/reportId",schemaPath:"#/properties/reportId/pattern",keyword:"pattern",params:{pattern:"^report[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^report[-:][A-Za-z0-9._:-]+$"\'};e===null?e=[b]:e.push(b),n++}}else{let b={instancePath:a+"/reportId",schemaPath:"#/properties/reportId/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[b]:e.push(b),n++}}if(r.sequence!==void 0){let g=r.sequence;if(!(typeof g=="number"&&!(g%1)&&!isNaN(g))){let b={instancePath:a+"/sequence",schemaPath:"#/properties/sequence/type",keyword:"type",params:{type:"integer"},message:"must be integer"};e===null?e=[b]:e.push(b),n++}if(typeof g=="number"&&(g<1||isNaN(g))){let b={instancePath:a+"/sequence",schemaPath:"#/properties/sequence/minimum",keyword:"minimum",params:{comparison:">=",limit:1},message:"must be >= 1"};e===null?e=[b]:e.push(b),n++}}if(r.type!==void 0){let g=r.type;if(!(g==="viewed.changed"||g==="judgment.changed"||g==="thread.created"||g==="thread.message-added"||g==="thread.resolved"||g==="state.imported"||g==="agent-attention.changed"||g==="feedback-batch.stored"||g==="feedback-batch.claimed"||g==="feedback-batch.released"||g==="feedback-batch.answered")){let b={instancePath:a+"/type",schemaPath:"#/properties/type/enum",keyword:"enum",params:{allowedValues:Ka.properties.type.enum},message:"must be equal to one of the allowed values"};e===null?e=[b]:e.push(b),n++}}if(r.createdAt!==void 0){let g=r.createdAt;if(typeof g=="string"){if(!la.validate(g)){let b={instancePath:a+"/createdAt",schemaPath:"#/properties/createdAt/format",keyword:"format",params:{format:"date-time"},message:\'must match format "date-time"\'};e===null?e=[b]:e.push(b),n++}}else{let b={instancePath:a+"/createdAt",schemaPath:"#/properties/createdAt/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[b]:e.push(b),n++}}if(r.anchor!==void 0){let g=r.anchor;if(g&&typeof g=="object"&&!Array.isArray(g)){if(g.type===void 0){let b={instancePath:a+"/anchor",schemaPath:"#/$defs/reviewAnchor/required",keyword:"required",params:{missingProperty:"type"},message:"must have required property \'type\'"};e===null?e=[b]:e.push(b),n++}if(g.ref===void 0){let b={instancePath:a+"/anchor",schemaPath:"#/$defs/reviewAnchor/required",keyword:"required",params:{missingProperty:"ref"},message:"must have required property \'ref\'"};e===null?e=[b]:e.push(b),n++}if(g.fingerprint===void 0){let b={instancePath:a+"/anchor",schemaPath:"#/$defs/reviewAnchor/required",keyword:"required",params:{missingProperty:"fingerprint"},message:"must have required property \'fingerprint\'"};e===null?e=[b]:e.push(b),n++}for(let b in g)if(!Va.call(Qn.properties,b)){let k={instancePath:a+"/anchor",schemaPath:"#/$defs/reviewAnchor/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:b},message:"must NOT have additional properties"};e===null?e=[k]:e.push(k),n++}if(g.type!==void 0){let b=g.type;if(!(b==="change"||b==="file"||b==="hunk"||b==="line-range"||b==="visual-target"||b==="visual-region"||b==="finding"||b==="verification-gap")){let k={instancePath:a+"/anchor/type",schemaPath:"#/$defs/reviewAnchor/properties/type/enum",keyword:"enum",params:{allowedValues:Qn.properties.type.enum},message:"must be equal to one of the allowed values"};e===null?e=[k]:e.push(k),n++}}if(g.ref!==void 0){let b=g.ref;if(typeof b=="string"){if(it(b)<1){let k={instancePath:a+"/anchor/ref",schemaPath:"#/$defs/reviewAnchor/properties/ref/minLength",keyword:"minLength",params:{limit:1},message:"must NOT have fewer than 1 characters"};e===null?e=[k]:e.push(k),n++}}else{let k={instancePath:a+"/anchor/ref",schemaPath:"#/$defs/reviewAnchor/properties/ref/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[k]:e.push(k),n++}}if(g.path!==void 0&&typeof g.path!="string"){let b={instancePath:a+"/anchor/path",schemaPath:"#/$defs/reviewAnchor/properties/path/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[b]:e.push(b),n++}if(g.side!==void 0){let b=g.side;if(!(b==="before"||b==="after"||b==="diff")){let k={instancePath:a+"/anchor/side",schemaPath:"#/$defs/reviewAnchor/properties/side/enum",keyword:"enum",params:{allowedValues:Qn.properties.side.enum},message:"must be equal to one of the allowed values"};e===null?e=[k]:e.push(k),n++}}if(g.startLine!==void 0){let b=g.startLine;if(!(typeof b=="number"&&!(b%1)&&!isNaN(b))){let k={instancePath:a+"/anchor/startLine",schemaPath:"#/$defs/reviewAnchor/properties/startLine/type",keyword:"type",params:{type:"integer"},message:"must be integer"};e===null?e=[k]:e.push(k),n++}if(typeof b=="number"&&(b<1||isNaN(b))){let k={instancePath:a+"/anchor/startLine",schemaPath:"#/$defs/reviewAnchor/properties/startLine/minimum",keyword:"minimum",params:{comparison:">=",limit:1},message:"must be >= 1"};e===null?e=[k]:e.push(k),n++}}if(g.endLine!==void 0){let b=g.endLine;if(!(typeof b=="number"&&!(b%1)&&!isNaN(b))){let k={instancePath:a+"/anchor/endLine",schemaPath:"#/$defs/reviewAnchor/properties/endLine/type",keyword:"type",params:{type:"integer"},message:"must be integer"};e===null?e=[k]:e.push(k),n++}if(typeof b=="number"&&(b<1||isNaN(b))){let k={instancePath:a+"/anchor/endLine",schemaPath:"#/$defs/reviewAnchor/properties/endLine/minimum",keyword:"minimum",params:{comparison:">=",limit:1},message:"must be >= 1"};e===null?e=[k]:e.push(k),n++}}if(g.targetRef!==void 0&&typeof g.targetRef!="string"){let b={instancePath:a+"/anchor/targetRef",schemaPath:"#/$defs/reviewAnchor/properties/targetRef/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[b]:e.push(b),n++}if(g.region!==void 0){let b=g.region;if(b&&typeof b=="object"&&!Array.isArray(b)){if(b.x===void 0){let k={instancePath:a+"/anchor/region",schemaPath:"#/$defs/reviewAnchor/properties/region/required",keyword:"required",params:{missingProperty:"x"},message:"must have required property \'x\'"};e===null?e=[k]:e.push(k),n++}if(b.y===void 0){let k={instancePath:a+"/anchor/region",schemaPath:"#/$defs/reviewAnchor/properties/region/required",keyword:"required",params:{missingProperty:"y"},message:"must have required property \'y\'"};e===null?e=[k]:e.push(k),n++}if(b.width===void 0){let k={instancePath:a+"/anchor/region",schemaPath:"#/$defs/reviewAnchor/properties/region/required",keyword:"required",params:{missingProperty:"width"},message:"must have required property \'width\'"};e===null?e=[k]:e.push(k),n++}if(b.height===void 0){let k={instancePath:a+"/anchor/region",schemaPath:"#/$defs/reviewAnchor/properties/region/required",keyword:"required",params:{missingProperty:"height"},message:"must have required property \'height\'"};e===null?e=[k]:e.push(k),n++}for(let k in b)if(!(k==="x"||k==="y"||k==="width"||k==="height")){let K={instancePath:a+"/anchor/region",schemaPath:"#/$defs/reviewAnchor/properties/region/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:k},message:"must NOT have additional properties"};e===null?e=[K]:e.push(K),n++}if(b.x!==void 0){let k=b.x;if(typeof k=="number"){if(k>1||isNaN(k)){let K={instancePath:a+"/anchor/region/x",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/x/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};e===null?e=[K]:e.push(K),n++}if(k<0||isNaN(k)){let K={instancePath:a+"/anchor/region/x",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/x/minimum",keyword:"minimum",params:{comparison:">=",limit:0},message:"must be >= 0"};e===null?e=[K]:e.push(K),n++}}else{let K={instancePath:a+"/anchor/region/x",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/x/type",keyword:"type",params:{type:"number"},message:"must be number"};e===null?e=[K]:e.push(K),n++}}if(b.y!==void 0){let k=b.y;if(typeof k=="number"){if(k>1||isNaN(k)){let K={instancePath:a+"/anchor/region/y",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/y/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};e===null?e=[K]:e.push(K),n++}if(k<0||isNaN(k)){let K={instancePath:a+"/anchor/region/y",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/y/minimum",keyword:"minimum",params:{comparison:">=",limit:0},message:"must be >= 0"};e===null?e=[K]:e.push(K),n++}}else{let K={instancePath:a+"/anchor/region/y",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/y/type",keyword:"type",params:{type:"number"},message:"must be number"};e===null?e=[K]:e.push(K),n++}}if(b.width!==void 0){let k=b.width;if(typeof k=="number"){if(k>1||isNaN(k)){let K={instancePath:a+"/anchor/region/width",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/width/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};e===null?e=[K]:e.push(K),n++}if(k<=0||isNaN(k)){let K={instancePath:a+"/anchor/region/width",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/width/exclusiveMinimum",keyword:"exclusiveMinimum",params:{comparison:">",limit:0},message:"must be > 0"};e===null?e=[K]:e.push(K),n++}}else{let K={instancePath:a+"/anchor/region/width",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/width/type",keyword:"type",params:{type:"number"},message:"must be number"};e===null?e=[K]:e.push(K),n++}}if(b.height!==void 0){let k=b.height;if(typeof k=="number"){if(k>1||isNaN(k)){let K={instancePath:a+"/anchor/region/height",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/height/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};e===null?e=[K]:e.push(K),n++}if(k<=0||isNaN(k)){let K={instancePath:a+"/anchor/region/height",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/height/exclusiveMinimum",keyword:"exclusiveMinimum",params:{comparison:">",limit:0},message:"must be > 0"};e===null?e=[K]:e.push(K),n++}}else{let K={instancePath:a+"/anchor/region/height",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/height/type",keyword:"type",params:{type:"number"},message:"must be number"};e===null?e=[K]:e.push(K),n++}}}else{let k={instancePath:a+"/anchor/region",schemaPath:"#/$defs/reviewAnchor/properties/region/type",keyword:"type",params:{type:"object"},message:"must be object"};e===null?e=[k]:e.push(k),n++}}if(g.selectorHint!==void 0&&typeof g.selectorHint!="string"){let b={instancePath:a+"/anchor/selectorHint",schemaPath:"#/$defs/reviewAnchor/properties/selectorHint/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[b]:e.push(b),n++}if(g.fingerprint!==void 0){let b=g.fingerprint;if(typeof b=="string"){if(!rs.test(b)){let k={instancePath:a+"/anchor/fingerprint",schemaPath:"#/$defs/reviewAnchor/properties/fingerprint/pattern",keyword:"pattern",params:{pattern:"^[a-f0-9]{64}$"},message:\'must match pattern "^[a-f0-9]{64}$"\'};e===null?e=[k]:e.push(k),n++}}else{let k={instancePath:a+"/anchor/fingerprint",schemaPath:"#/$defs/reviewAnchor/properties/fingerprint/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[k]:e.push(k),n++}}}else{let b={instancePath:a+"/anchor",schemaPath:"#/$defs/reviewAnchor/type",keyword:"type",params:{type:"object"},message:"must be object"};e===null?e=[b]:e.push(b),n++}}if(r.changeId!==void 0){let g=r.changeId;if(typeof g=="string"){if(!ef.test(g)){let b={instancePath:a+"/changeId",schemaPath:"#/properties/changeId/pattern",keyword:"pattern",params:{pattern:"^change[-:]"},message:\'must match pattern "^change[-:]"\'};e===null?e=[b]:e.push(b),n++}}else{let b={instancePath:a+"/changeId",schemaPath:"#/properties/changeId/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[b]:e.push(b),n++}}if(r.viewState!==void 0){let g=r.viewState;if(!(g==="unseen"||g==="viewed"||g==="stale")){let b={instancePath:a+"/viewState",schemaPath:"#/properties/viewState/enum",keyword:"enum",params:{allowedValues:Ka.properties.viewState.enum},message:"must be equal to one of the allowed values"};e===null?e=[b]:e.push(b),n++}}if(r.judgmentState!==void 0){let g=r.judgmentState;if(!(g==="unreviewed"||g==="reviewed"||g==="follow-up"||g==="blocked"||g==="stale")){let b={instancePath:a+"/judgmentState",schemaPath:"#/properties/judgmentState/enum",keyword:"enum",params:{allowedValues:Ka.properties.judgmentState.enum},message:"must be equal to one of the allowed values"};e===null?e=[b]:e.push(b),n++}}if(r.threadId!==void 0){let g=r.threadId;if(typeof g=="string"){if(it(g)>256){let b={instancePath:a+"/threadId",schemaPath:"#/properties/threadId/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};e===null?e=[b]:e.push(b),n++}if(!Os.test(g)){let b={instancePath:a+"/threadId",schemaPath:"#/properties/threadId/pattern",keyword:"pattern",params:{pattern:"^thread[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^thread[-:][A-Za-z0-9._:-]+$"\'};e===null?e=[b]:e.push(b),n++}}else{let b={instancePath:a+"/threadId",schemaPath:"#/properties/threadId/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[b]:e.push(b),n++}}if(r.messageId!==void 0){let g=r.messageId;if(typeof g=="string"){if(it(g)>256){let b={instancePath:a+"/messageId",schemaPath:"#/properties/messageId/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};e===null?e=[b]:e.push(b),n++}if(!xd.test(g)){let b={instancePath:a+"/messageId",schemaPath:"#/properties/messageId/pattern",keyword:"pattern",params:{pattern:"^message[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^message[-:][A-Za-z0-9._:-]+$"\'};e===null?e=[b]:e.push(b),n++}}else{let b={instancePath:a+"/messageId",schemaPath:"#/properties/messageId/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[b]:e.push(b),n++}}if(r.sourceReportId!==void 0){let g=r.sourceReportId;if(typeof g=="string"){if(it(g)>256){let b={instancePath:a+"/sourceReportId",schemaPath:"#/properties/sourceReportId/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};e===null?e=[b]:e.push(b),n++}if(!js.test(g)){let b={instancePath:a+"/sourceReportId",schemaPath:"#/properties/sourceReportId/pattern",keyword:"pattern",params:{pattern:"^report[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^report[-:][A-Za-z0-9._:-]+$"\'};e===null?e=[b]:e.push(b),n++}}else{let b={instancePath:a+"/sourceReportId",schemaPath:"#/properties/sourceReportId/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[b]:e.push(b),n++}}if(r.attentionState!==void 0){let g=r.attentionState;if(!(g==="none"||g==="requested"||g==="batched"||g==="submitted"||g==="acknowledged"||g==="answered"||g==="stale")){let b={instancePath:a+"/attentionState",schemaPath:"#/properties/attentionState/enum",keyword:"enum",params:{allowedValues:Ka.properties.attentionState.enum},message:"must be equal to one of the allowed values"};e===null?e=[b]:e.push(b),n++}}if(r.batchId!==void 0){let g=r.batchId;if(typeof g=="string"){if(it(g)>256){let b={instancePath:a+"/batchId",schemaPath:"#/properties/batchId/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};e===null?e=[b]:e.push(b),n++}if(!Ad.test(g)){let b={instancePath:a+"/batchId",schemaPath:"#/properties/batchId/pattern",keyword:"pattern",params:{pattern:"^fb[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^fb[-:][A-Za-z0-9._:-]+$"\'};e===null?e=[b]:e.push(b),n++}}else{let b={instancePath:a+"/batchId",schemaPath:"#/properties/batchId/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[b]:e.push(b),n++}}if(r.threadIds!==void 0){let g=r.threadIds;if(Array.isArray(g)){if(g.length>20){let te={instancePath:a+"/threadIds",schemaPath:"#/properties/threadIds/maxItems",keyword:"maxItems",params:{limit:20},message:"must NOT have more than 20 items"};e===null?e=[te]:e.push(te),n++}let b=g.length;for(let te=0;te<b;te++){let et=g[te];if(typeof et=="string"){if(it(et)>256){let D={instancePath:a+"/threadIds/"+te,schemaPath:"#/properties/threadIds/items/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};e===null?e=[D]:e.push(D),n++}if(!Os.test(et)){let D={instancePath:a+"/threadIds/"+te,schemaPath:"#/properties/threadIds/items/pattern",keyword:"pattern",params:{pattern:"^thread[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^thread[-:][A-Za-z0-9._:-]+$"\'};e===null?e=[D]:e.push(D),n++}}else{let D={instancePath:a+"/threadIds/"+te,schemaPath:"#/properties/threadIds/items/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[D]:e.push(D),n++}}let k=g.length,K;if(k>1){let te={};for(;k--;){let et=g[k];if(typeof et=="string"){if(typeof te[et]=="number"){K=te[et];let D={instancePath:a+"/threadIds",schemaPath:"#/properties/threadIds/uniqueItems",keyword:"uniqueItems",params:{i:k,j:K},message:"must NOT have duplicate items (items ## "+K+" and "+k+" are identical)"};e===null?e=[D]:e.push(D),n++;break}te[et]=k}}}}else{let b={instancePath:a+"/threadIds",schemaPath:"#/properties/threadIds/type",keyword:"type",params:{type:"array"},message:"must be array"};e===null?e=[b]:e.push(b),n++}}if(r.itemIds!==void 0){let g=r.itemIds;if(Array.isArray(g)){if(g.length>20){let te={instancePath:a+"/itemIds",schemaPath:"#/properties/itemIds/maxItems",keyword:"maxItems",params:{limit:20},message:"must NOT have more than 20 items"};e===null?e=[te]:e.push(te),n++}let b=g.length;for(let te=0;te<b;te++){let et=g[te];if(typeof et=="string"){if(it(et)>256){let D={instancePath:a+"/itemIds/"+te,schemaPath:"#/properties/itemIds/items/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};e===null?e=[D]:e.push(D),n++}if(!Id.test(et)){let D={instancePath:a+"/itemIds/"+te,schemaPath:"#/properties/itemIds/items/pattern",keyword:"pattern",params:{pattern:"^item[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^item[-:][A-Za-z0-9._:-]+$"\'};e===null?e=[D]:e.push(D),n++}}else{let D={instancePath:a+"/itemIds/"+te,schemaPath:"#/properties/itemIds/items/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[D]:e.push(D),n++}}let k=g.length,K;if(k>1){let te={};for(;k--;){let et=g[k];if(typeof et=="string"){if(typeof te[et]=="number"){K=te[et];let D={instancePath:a+"/itemIds",schemaPath:"#/properties/itemIds/uniqueItems",keyword:"uniqueItems",params:{i:k,j:K},message:"must NOT have duplicate items (items ## "+K+" and "+k+" are identical)"};e===null?e=[D]:e.push(D),n++;break}te[et]=k}}}}else{let b={instancePath:a+"/itemIds",schemaPath:"#/properties/itemIds/type",keyword:"type",params:{type:"array"},message:"must be array"};e===null?e=[b]:e.push(b),n++}}if(r.itemCount!==void 0){let g=r.itemCount;if(!(typeof g=="number"&&!(g%1)&&!isNaN(g))){let b={instancePath:a+"/itemCount",schemaPath:"#/properties/itemCount/type",keyword:"type",params:{type:"integer"},message:"must be integer"};e===null?e=[b]:e.push(b),n++}if(typeof g=="number"){if(g>20||isNaN(g)){let b={instancePath:a+"/itemCount",schemaPath:"#/properties/itemCount/maximum",keyword:"maximum",params:{comparison:"<=",limit:20},message:"must be <= 20"};e===null?e=[b]:e.push(b),n++}if(g<1||isNaN(g)){let b={instancePath:a+"/itemCount",schemaPath:"#/properties/itemCount/minimum",keyword:"minimum",params:{comparison:">=",limit:1},message:"must be >= 1"};e===null?e=[b]:e.push(b),n++}}}if(r.deliveryMode!==void 0){let g=r.deliveryMode;if(!(g==="direct-same-session"||g==="return-to-session"||g==="export-only")){let b={instancePath:a+"/deliveryMode",schemaPath:"#/properties/deliveryMode/enum",keyword:"enum",params:{allowedValues:Ka.properties.deliveryMode.enum},message:"must be equal to one of the allowed values"};e===null?e=[b]:e.push(b),n++}}if(r.originSessionMatched!==void 0&&typeof r.originSessionMatched!="boolean"){let g={instancePath:a+"/originSessionMatched",schemaPath:"#/properties/originSessionMatched/type",keyword:"type",params:{type:"boolean"},message:"must be boolean"};e===null?e=[g]:e.push(g),n++}}else{let g={instancePath:a,schemaPath:"#/type",keyword:"type",params:{type:"object"},message:"must be object"};e===null?e=[g]:e.push(g),n++}return $d.errors=e,n===0}var tf=qd,Xn={properties:{schemaVersion:{const:"1.3"},reportId:{type:"string",pattern:"^report[-:][A-Za-z0-9._:-]+$",maxLength:256},reportFingerprint:{type:"string",pattern:"^[a-f0-9]{64}$"},revision:{type:"integer",minimum:0},updatedAt:{type:"string",format:"date-time"},viewed:{type:"object",additionalProperties:{type:"object",additionalProperties:!1,required:["anchor","state","updatedAt"],properties:{anchor:{$ref:"#/$defs/reviewAnchor"},state:{enum:["unseen","viewed","stale"]},updatedAt:{type:"string",format:"date-time"}}}},judgments:{type:"object",additionalProperties:{type:"object",additionalProperties:!1,required:["changeId","state","updatedAt"],properties:{changeId:{type:"string"},state:{enum:["unreviewed","reviewed","follow-up","blocked","stale"]},updatedAt:{type:"string",format:"date-time"}}}},threadIds:{type:"array",items:{type:"string",pattern:"^thread[-:][A-Za-z0-9._:-]+$",maxLength:256},uniqueItems:!0},orphanedThreadIds:{type:"array",items:{type:"string",pattern:"^thread[-:][A-Za-z0-9._:-]+$",maxLength:256},uniqueItems:!0}}},ei={properties:{type:{enum:["change","file","hunk","line-range","visual-target","visual-region","finding","verification-gap"]},ref:{type:"string",minLength:1},path:{type:"string"},side:{enum:["before","after","diff"]},startLine:{type:"integer",minimum:1},endLine:{type:"integer",minimum:1},targetRef:{type:"string"},region:{$ref:"#/$defs/region"},selectorHint:{type:"string"},fingerprint:{type:"string",pattern:"^[a-f0-9]{64}$"}}};function dn(r,{instancePath:a="",parentData:s,parentDataProperty:d,rootData:u=r}={}){let e=null,n=0;if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.type===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"type"},message:"must have required property \'type\'"};e===null?e=[l]:e.push(l),n++}if(r.ref===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"ref"},message:"must have required property \'ref\'"};e===null?e=[l]:e.push(l),n++}if(r.fingerprint===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"fingerprint"},message:"must have required property \'fingerprint\'"};e===null?e=[l]:e.push(l),n++}for(let l in r)if(!Va.call(ei.properties,l)){let i={instancePath:a,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:l},message:"must NOT have additional properties"};e===null?e=[i]:e.push(i),n++}if(r.type!==void 0){let l=r.type;if(!(l==="change"||l==="file"||l==="hunk"||l==="line-range"||l==="visual-target"||l==="visual-region"||l==="finding"||l==="verification-gap")){let i={instancePath:a+"/type",schemaPath:"#/properties/type/enum",keyword:"enum",params:{allowedValues:ei.properties.type.enum},message:"must be equal to one of the allowed values"};e===null?e=[i]:e.push(i),n++}}if(r.ref!==void 0){let l=r.ref;if(typeof l=="string"){if(it(l)<1){let i={instancePath:a+"/ref",schemaPath:"#/properties/ref/minLength",keyword:"minLength",params:{limit:1},message:"must NOT have fewer than 1 characters"};e===null?e=[i]:e.push(i),n++}}else{let i={instancePath:a+"/ref",schemaPath:"#/properties/ref/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[i]:e.push(i),n++}}if(r.path!==void 0&&typeof r.path!="string"){let l={instancePath:a+"/path",schemaPath:"#/properties/path/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[l]:e.push(l),n++}if(r.side!==void 0){let l=r.side;if(!(l==="before"||l==="after"||l==="diff")){let i={instancePath:a+"/side",schemaPath:"#/properties/side/enum",keyword:"enum",params:{allowedValues:ei.properties.side.enum},message:"must be equal to one of the allowed values"};e===null?e=[i]:e.push(i),n++}}if(r.startLine!==void 0){let l=r.startLine;if(!(typeof l=="number"&&!(l%1)&&!isNaN(l))){let i={instancePath:a+"/startLine",schemaPath:"#/properties/startLine/type",keyword:"type",params:{type:"integer"},message:"must be integer"};e===null?e=[i]:e.push(i),n++}if(typeof l=="number"&&(l<1||isNaN(l))){let i={instancePath:a+"/startLine",schemaPath:"#/properties/startLine/minimum",keyword:"minimum",params:{comparison:">=",limit:1},message:"must be >= 1"};e===null?e=[i]:e.push(i),n++}}if(r.endLine!==void 0){let l=r.endLine;if(!(typeof l=="number"&&!(l%1)&&!isNaN(l))){let i={instancePath:a+"/endLine",schemaPath:"#/properties/endLine/type",keyword:"type",params:{type:"integer"},message:"must be integer"};e===null?e=[i]:e.push(i),n++}if(typeof l=="number"&&(l<1||isNaN(l))){let i={instancePath:a+"/endLine",schemaPath:"#/properties/endLine/minimum",keyword:"minimum",params:{comparison:">=",limit:1},message:"must be >= 1"};e===null?e=[i]:e.push(i),n++}}if(r.targetRef!==void 0&&typeof r.targetRef!="string"){let l={instancePath:a+"/targetRef",schemaPath:"#/properties/targetRef/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[l]:e.push(l),n++}if(r.region!==void 0){let l=r.region;if(l&&typeof l=="object"&&!Array.isArray(l)){if(l.x===void 0){let i={instancePath:a+"/region",schemaPath:"#/$defs/region/required",keyword:"required",params:{missingProperty:"x"},message:"must have required property \'x\'"};e===null?e=[i]:e.push(i),n++}if(l.y===void 0){let i={instancePath:a+"/region",schemaPath:"#/$defs/region/required",keyword:"required",params:{missingProperty:"y"},message:"must have required property \'y\'"};e===null?e=[i]:e.push(i),n++}if(l.width===void 0){let i={instancePath:a+"/region",schemaPath:"#/$defs/region/required",keyword:"required",params:{missingProperty:"width"},message:"must have required property \'width\'"};e===null?e=[i]:e.push(i),n++}if(l.height===void 0){let i={instancePath:a+"/region",schemaPath:"#/$defs/region/required",keyword:"required",params:{missingProperty:"height"},message:"must have required property \'height\'"};e===null?e=[i]:e.push(i),n++}for(let i in l)if(!(i==="x"||i==="y"||i==="width"||i==="height")){let o={instancePath:a+"/region",schemaPath:"#/$defs/region/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:i},message:"must NOT have additional properties"};e===null?e=[o]:e.push(o),n++}if(l.x!==void 0){let i=l.x;if(typeof i=="number"){if(i>1||isNaN(i)){let o={instancePath:a+"/region/x",schemaPath:"#/$defs/region/properties/x/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};e===null?e=[o]:e.push(o),n++}if(i<0||isNaN(i)){let o={instancePath:a+"/region/x",schemaPath:"#/$defs/region/properties/x/minimum",keyword:"minimum",params:{comparison:">=",limit:0},message:"must be >= 0"};e===null?e=[o]:e.push(o),n++}}else{let o={instancePath:a+"/region/x",schemaPath:"#/$defs/region/properties/x/type",keyword:"type",params:{type:"number"},message:"must be number"};e===null?e=[o]:e.push(o),n++}}if(l.y!==void 0){let i=l.y;if(typeof i=="number"){if(i>1||isNaN(i)){let o={instancePath:a+"/region/y",schemaPath:"#/$defs/region/properties/y/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};e===null?e=[o]:e.push(o),n++}if(i<0||isNaN(i)){let o={instancePath:a+"/region/y",schemaPath:"#/$defs/region/properties/y/minimum",keyword:"minimum",params:{comparison:">=",limit:0},message:"must be >= 0"};e===null?e=[o]:e.push(o),n++}}else{let o={instancePath:a+"/region/y",schemaPath:"#/$defs/region/properties/y/type",keyword:"type",params:{type:"number"},message:"must be number"};e===null?e=[o]:e.push(o),n++}}if(l.width!==void 0){let i=l.width;if(typeof i=="number"){if(i>1||isNaN(i)){let o={instancePath:a+"/region/width",schemaPath:"#/$defs/region/properties/width/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};e===null?e=[o]:e.push(o),n++}if(i<=0||isNaN(i)){let o={instancePath:a+"/region/width",schemaPath:"#/$defs/region/properties/width/exclusiveMinimum",keyword:"exclusiveMinimum",params:{comparison:">",limit:0},message:"must be > 0"};e===null?e=[o]:e.push(o),n++}}else{let o={instancePath:a+"/region/width",schemaPath:"#/$defs/region/properties/width/type",keyword:"type",params:{type:"number"},message:"must be number"};e===null?e=[o]:e.push(o),n++}}if(l.height!==void 0){let i=l.height;if(typeof i=="number"){if(i>1||isNaN(i)){let o={instancePath:a+"/region/height",schemaPath:"#/$defs/region/properties/height/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};e===null?e=[o]:e.push(o),n++}if(i<=0||isNaN(i)){let o={instancePath:a+"/region/height",schemaPath:"#/$defs/region/properties/height/exclusiveMinimum",keyword:"exclusiveMinimum",params:{comparison:">",limit:0},message:"must be > 0"};e===null?e=[o]:e.push(o),n++}}else{let o={instancePath:a+"/region/height",schemaPath:"#/$defs/region/properties/height/type",keyword:"type",params:{type:"number"},message:"must be number"};e===null?e=[o]:e.push(o),n++}}}else{let i={instancePath:a+"/region",schemaPath:"#/$defs/region/type",keyword:"type",params:{type:"object"},message:"must be object"};e===null?e=[i]:e.push(i),n++}}if(r.selectorHint!==void 0&&typeof r.selectorHint!="string"){let l={instancePath:a+"/selectorHint",schemaPath:"#/properties/selectorHint/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[l]:e.push(l),n++}if(r.fingerprint!==void 0){let l=r.fingerprint;if(typeof l=="string"){if(!rs.test(l)){let i={instancePath:a+"/fingerprint",schemaPath:"#/properties/fingerprint/pattern",keyword:"pattern",params:{pattern:"^[a-f0-9]{64}$"},message:\'must match pattern "^[a-f0-9]{64}$"\'};e===null?e=[i]:e.push(i),n++}}else{let i={instancePath:a+"/fingerprint",schemaPath:"#/properties/fingerprint/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[i]:e.push(i),n++}}}else{let l={instancePath:a,schemaPath:"#/type",keyword:"type",params:{type:"object"},message:"must be object"};e===null?e=[l]:e.push(l),n++}return dn.errors=e,n===0}function qd(r,{instancePath:a="",parentData:s,parentDataProperty:d,rootData:u=r}={}){let e=null,n=0;if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.schemaVersion===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"schemaVersion"},message:"must have required property \'schemaVersion\'"};e===null?e=[l]:e.push(l),n++}if(r.reportId===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"reportId"},message:"must have required property \'reportId\'"};e===null?e=[l]:e.push(l),n++}if(r.reportFingerprint===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"reportFingerprint"},message:"must have required property \'reportFingerprint\'"};e===null?e=[l]:e.push(l),n++}if(r.revision===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"revision"},message:"must have required property \'revision\'"};e===null?e=[l]:e.push(l),n++}if(r.updatedAt===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"updatedAt"},message:"must have required property \'updatedAt\'"};e===null?e=[l]:e.push(l),n++}if(r.viewed===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"viewed"},message:"must have required property \'viewed\'"};e===null?e=[l]:e.push(l),n++}if(r.judgments===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"judgments"},message:"must have required property \'judgments\'"};e===null?e=[l]:e.push(l),n++}if(r.threadIds===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"threadIds"},message:"must have required property \'threadIds\'"};e===null?e=[l]:e.push(l),n++}if(r.orphanedThreadIds===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"orphanedThreadIds"},message:"must have required property \'orphanedThreadIds\'"};e===null?e=[l]:e.push(l),n++}for(let l in r)if(!Va.call(Xn.properties,l)){let i={instancePath:a,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:l},message:"must NOT have additional properties"};e===null?e=[i]:e.push(i),n++}if(r.schemaVersion!==void 0&&r.schemaVersion!=="1.3"){let l={instancePath:a+"/schemaVersion",schemaPath:"#/properties/schemaVersion/const",keyword:"const",params:{allowedValue:"1.3"},message:"must be equal to constant"};e===null?e=[l]:e.push(l),n++}if(r.reportId!==void 0){let l=r.reportId;if(typeof l=="string"){if(it(l)>256){let i={instancePath:a+"/reportId",schemaPath:"#/properties/reportId/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};e===null?e=[i]:e.push(i),n++}if(!js.test(l)){let i={instancePath:a+"/reportId",schemaPath:"#/properties/reportId/pattern",keyword:"pattern",params:{pattern:"^report[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^report[-:][A-Za-z0-9._:-]+$"\'};e===null?e=[i]:e.push(i),n++}}else{let i={instancePath:a+"/reportId",schemaPath:"#/properties/reportId/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[i]:e.push(i),n++}}if(r.reportFingerprint!==void 0){let l=r.reportFingerprint;if(typeof l=="string"){if(!rs.test(l)){let i={instancePath:a+"/reportFingerprint",schemaPath:"#/properties/reportFingerprint/pattern",keyword:"pattern",params:{pattern:"^[a-f0-9]{64}$"},message:\'must match pattern "^[a-f0-9]{64}$"\'};e===null?e=[i]:e.push(i),n++}}else{let i={instancePath:a+"/reportFingerprint",schemaPath:"#/properties/reportFingerprint/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[i]:e.push(i),n++}}if(r.revision!==void 0){let l=r.revision;if(!(typeof l=="number"&&!(l%1)&&!isNaN(l))){let i={instancePath:a+"/revision",schemaPath:"#/properties/revision/type",keyword:"type",params:{type:"integer"},message:"must be integer"};e===null?e=[i]:e.push(i),n++}if(typeof l=="number"&&(l<0||isNaN(l))){let i={instancePath:a+"/revision",schemaPath:"#/properties/revision/minimum",keyword:"minimum",params:{comparison:">=",limit:0},message:"must be >= 0"};e===null?e=[i]:e.push(i),n++}}if(r.updatedAt!==void 0){let l=r.updatedAt;if(typeof l=="string"){if(!la.validate(l)){let i={instancePath:a+"/updatedAt",schemaPath:"#/properties/updatedAt/format",keyword:"format",params:{format:"date-time"},message:\'must match format "date-time"\'};e===null?e=[i]:e.push(i),n++}}else{let i={instancePath:a+"/updatedAt",schemaPath:"#/properties/updatedAt/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[i]:e.push(i),n++}}if(r.viewed!==void 0){let l=r.viewed;if(l&&typeof l=="object"&&!Array.isArray(l))for(let i in l){let o=l[i];if(o&&typeof o=="object"&&!Array.isArray(o)){if(o.anchor===void 0){let h={instancePath:a+"/viewed/"+i.replace(/~/g,"~0").replace(/\\//g,"~1"),schemaPath:"#/properties/viewed/additionalProperties/required",keyword:"required",params:{missingProperty:"anchor"},message:"must have required property \'anchor\'"};e===null?e=[h]:e.push(h),n++}if(o.state===void 0){let h={instancePath:a+"/viewed/"+i.replace(/~/g,"~0").replace(/\\//g,"~1"),schemaPath:"#/properties/viewed/additionalProperties/required",keyword:"required",params:{missingProperty:"state"},message:"must have required property \'state\'"};e===null?e=[h]:e.push(h),n++}if(o.updatedAt===void 0){let h={instancePath:a+"/viewed/"+i.replace(/~/g,"~0").replace(/\\//g,"~1"),schemaPath:"#/properties/viewed/additionalProperties/required",keyword:"required",params:{missingProperty:"updatedAt"},message:"must have required property \'updatedAt\'"};e===null?e=[h]:e.push(h),n++}for(let h in o)if(!(h==="anchor"||h==="state"||h==="updatedAt")){let c={instancePath:a+"/viewed/"+i.replace(/~/g,"~0").replace(/\\//g,"~1"),schemaPath:"#/properties/viewed/additionalProperties/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:h},message:"must NOT have additional properties"};e===null?e=[c]:e.push(c),n++}if(o.anchor!==void 0&&(dn(o.anchor,{instancePath:a+"/viewed/"+i.replace(/~/g,"~0").replace(/\\//g,"~1")+"/anchor",parentData:o,parentDataProperty:"anchor",rootData:u})||(e=e===null?dn.errors:e.concat(dn.errors),n=e.length)),o.state!==void 0){let h=o.state;if(!(h==="unseen"||h==="viewed"||h==="stale")){let c={instancePath:a+"/viewed/"+i.replace(/~/g,"~0").replace(/\\//g,"~1")+"/state",schemaPath:"#/properties/viewed/additionalProperties/properties/state/enum",keyword:"enum",params:{allowedValues:Xn.properties.viewed.additionalProperties.properties.state.enum},message:"must be equal to one of the allowed values"};e===null?e=[c]:e.push(c),n++}}if(o.updatedAt!==void 0){let h=o.updatedAt;if(typeof h=="string"){if(!la.validate(h)){let c={instancePath:a+"/viewed/"+i.replace(/~/g,"~0").replace(/\\//g,"~1")+"/updatedAt",schemaPath:"#/properties/viewed/additionalProperties/properties/updatedAt/format",keyword:"format",params:{format:"date-time"},message:\'must match format "date-time"\'};e===null?e=[c]:e.push(c),n++}}else{let c={instancePath:a+"/viewed/"+i.replace(/~/g,"~0").replace(/\\//g,"~1")+"/updatedAt",schemaPath:"#/properties/viewed/additionalProperties/properties/updatedAt/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[c]:e.push(c),n++}}}else{let h={instancePath:a+"/viewed/"+i.replace(/~/g,"~0").replace(/\\//g,"~1"),schemaPath:"#/properties/viewed/additionalProperties/type",keyword:"type",params:{type:"object"},message:"must be object"};e===null?e=[h]:e.push(h),n++}}else{let i={instancePath:a+"/viewed",schemaPath:"#/properties/viewed/type",keyword:"type",params:{type:"object"},message:"must be object"};e===null?e=[i]:e.push(i),n++}}if(r.judgments!==void 0){let l=r.judgments;if(l&&typeof l=="object"&&!Array.isArray(l))for(let i in l){let o=l[i];if(o&&typeof o=="object"&&!Array.isArray(o)){if(o.changeId===void 0){let h={instancePath:a+"/judgments/"+i.replace(/~/g,"~0").replace(/\\//g,"~1"),schemaPath:"#/properties/judgments/additionalProperties/required",keyword:"required",params:{missingProperty:"changeId"},message:"must have required property \'changeId\'"};e===null?e=[h]:e.push(h),n++}if(o.state===void 0){let h={instancePath:a+"/judgments/"+i.replace(/~/g,"~0").replace(/\\//g,"~1"),schemaPath:"#/properties/judgments/additionalProperties/required",keyword:"required",params:{missingProperty:"state"},message:"must have required property \'state\'"};e===null?e=[h]:e.push(h),n++}if(o.updatedAt===void 0){let h={instancePath:a+"/judgments/"+i.replace(/~/g,"~0").replace(/\\//g,"~1"),schemaPath:"#/properties/judgments/additionalProperties/required",keyword:"required",params:{missingProperty:"updatedAt"},message:"must have required property \'updatedAt\'"};e===null?e=[h]:e.push(h),n++}for(let h in o)if(!(h==="changeId"||h==="state"||h==="updatedAt")){let c={instancePath:a+"/judgments/"+i.replace(/~/g,"~0").replace(/\\//g,"~1"),schemaPath:"#/properties/judgments/additionalProperties/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:h},message:"must NOT have additional properties"};e===null?e=[c]:e.push(c),n++}if(o.changeId!==void 0&&typeof o.changeId!="string"){let h={instancePath:a+"/judgments/"+i.replace(/~/g,"~0").replace(/\\//g,"~1")+"/changeId",schemaPath:"#/properties/judgments/additionalProperties/properties/changeId/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[h]:e.push(h),n++}if(o.state!==void 0){let h=o.state;if(!(h==="unreviewed"||h==="reviewed"||h==="follow-up"||h==="blocked"||h==="stale")){let c={instancePath:a+"/judgments/"+i.replace(/~/g,"~0").replace(/\\//g,"~1")+"/state",schemaPath:"#/properties/judgments/additionalProperties/properties/state/enum",keyword:"enum",params:{allowedValues:Xn.properties.judgments.additionalProperties.properties.state.enum},message:"must be equal to one of the allowed values"};e===null?e=[c]:e.push(c),n++}}if(o.updatedAt!==void 0){let h=o.updatedAt;if(typeof h=="string"){if(!la.validate(h)){let c={instancePath:a+"/judgments/"+i.replace(/~/g,"~0").replace(/\\//g,"~1")+"/updatedAt",schemaPath:"#/properties/judgments/additionalProperties/properties/updatedAt/format",keyword:"format",params:{format:"date-time"},message:\'must match format "date-time"\'};e===null?e=[c]:e.push(c),n++}}else{let c={instancePath:a+"/judgments/"+i.replace(/~/g,"~0").replace(/\\//g,"~1")+"/updatedAt",schemaPath:"#/properties/judgments/additionalProperties/properties/updatedAt/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[c]:e.push(c),n++}}}else{let h={instancePath:a+"/judgments/"+i.replace(/~/g,"~0").replace(/\\//g,"~1"),schemaPath:"#/properties/judgments/additionalProperties/type",keyword:"type",params:{type:"object"},message:"must be object"};e===null?e=[h]:e.push(h),n++}}else{let i={instancePath:a+"/judgments",schemaPath:"#/properties/judgments/type",keyword:"type",params:{type:"object"},message:"must be object"};e===null?e=[i]:e.push(i),n++}}if(r.threadIds!==void 0){let l=r.threadIds;if(Array.isArray(l)){let i=l.length;for(let c=0;c<i;c++){let f=l[c];if(typeof f=="string"){if(it(f)>256){let w={instancePath:a+"/threadIds/"+c,schemaPath:"#/properties/threadIds/items/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};e===null?e=[w]:e.push(w),n++}if(!Os.test(f)){let w={instancePath:a+"/threadIds/"+c,schemaPath:"#/properties/threadIds/items/pattern",keyword:"pattern",params:{pattern:"^thread[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^thread[-:][A-Za-z0-9._:-]+$"\'};e===null?e=[w]:e.push(w),n++}}else{let w={instancePath:a+"/threadIds/"+c,schemaPath:"#/properties/threadIds/items/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[w]:e.push(w),n++}}let o=l.length,h;if(o>1){let c={};for(;o--;){let f=l[o];if(typeof f=="string"){if(typeof c[f]=="number"){h=c[f];let w={instancePath:a+"/threadIds",schemaPath:"#/properties/threadIds/uniqueItems",keyword:"uniqueItems",params:{i:o,j:h},message:"must NOT have duplicate items (items ## "+h+" and "+o+" are identical)"};e===null?e=[w]:e.push(w),n++;break}c[f]=o}}}}else{let i={instancePath:a+"/threadIds",schemaPath:"#/properties/threadIds/type",keyword:"type",params:{type:"array"},message:"must be array"};e===null?e=[i]:e.push(i),n++}}if(r.orphanedThreadIds!==void 0){let l=r.orphanedThreadIds;if(Array.isArray(l)){let i=l.length;for(let c=0;c<i;c++){let f=l[c];if(typeof f=="string"){if(it(f)>256){let w={instancePath:a+"/orphanedThreadIds/"+c,schemaPath:"#/properties/orphanedThreadIds/items/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};e===null?e=[w]:e.push(w),n++}if(!Os.test(f)){let w={instancePath:a+"/orphanedThreadIds/"+c,schemaPath:"#/properties/orphanedThreadIds/items/pattern",keyword:"pattern",params:{pattern:"^thread[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^thread[-:][A-Za-z0-9._:-]+$"\'};e===null?e=[w]:e.push(w),n++}}else{let w={instancePath:a+"/orphanedThreadIds/"+c,schemaPath:"#/properties/orphanedThreadIds/items/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[w]:e.push(w),n++}}let o=l.length,h;if(o>1){let c={};for(;o--;){let f=l[o];if(typeof f=="string"){if(typeof c[f]=="number"){h=c[f];let w={instancePath:a+"/orphanedThreadIds",schemaPath:"#/properties/orphanedThreadIds/uniqueItems",keyword:"uniqueItems",params:{i:o,j:h},message:"must NOT have duplicate items (items ## "+h+" and "+o+" are identical)"};e===null?e=[w]:e.push(w),n++;break}c[f]=o}}}}else{let i={instancePath:a+"/orphanedThreadIds",schemaPath:"#/properties/orphanedThreadIds/type",keyword:"type",params:{type:"array"},message:"must be array"};e===null?e=[i]:e.push(i),n++}}}else{let l={instancePath:a,schemaPath:"#/type",keyword:"type",params:{type:"object"},message:"must be object"};e===null?e=[l]:e.push(l),n++}return qd.errors=e,n===0}var rf=Rd,tn={properties:{id:{type:"string",pattern:"^thread[-:][A-Za-z0-9._:-]+$",maxLength:256},reportId:{type:"string",pattern:"^report[-:][A-Za-z0-9._:-]+$",maxLength:256},anchor:{$ref:"#/$defs/reviewAnchor"},kind:{enum:["note","question","finding","change-request"]},state:{enum:["open","answered","resolved","stale","orphaned"]},messages:{type:"array",items:{$ref:"#/$defs/message"}},agentAttention:{type:"object",additionalProperties:!1,required:["state"],properties:{state:{enum:["none","requested","batched","submitted","acknowledged","answered","stale"]},batchId:{type:"string",pattern:"^fb[-:][A-Za-z0-9._:-]+$",maxLength:256},updatedAt:{type:"string",format:"date-time"}}},createdAt:{type:"string",format:"date-time"},updatedAt:{type:"string",format:"date-time"}}},ti={properties:{type:{enum:["change","file","hunk","line-range","visual-target","visual-region","finding","verification-gap"]},ref:{type:"string"},path:{type:"string"},side:{enum:["before","after","diff"]},startLine:{type:"integer",minimum:1},endLine:{type:"integer",minimum:1},targetRef:{type:"string"},region:{type:"object",additionalProperties:!1,required:["x","y","width","height"],properties:{x:{type:"number",minimum:0,maximum:1},y:{type:"number",minimum:0,maximum:1},width:{type:"number",exclusiveMinimum:0,maximum:1},height:{type:"number",exclusiveMinimum:0,maximum:1}}},selectorHint:{type:"string"},fingerprint:{type:"string",pattern:"^[a-f0-9]{64}$"}}},wl={properties:{kind:{enum:["human-note","agent-answer","system"]},author:{properties:{type:{enum:["human","agent","system"]}}}}};function Rd(r,{instancePath:a="",parentData:s,parentDataProperty:d,rootData:u=r}={}){let e=null,n=0;if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.id===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"id"},message:"must have required property \'id\'"};e===null?e=[l]:e.push(l),n++}if(r.reportId===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"reportId"},message:"must have required property \'reportId\'"};e===null?e=[l]:e.push(l),n++}if(r.anchor===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"anchor"},message:"must have required property \'anchor\'"};e===null?e=[l]:e.push(l),n++}if(r.kind===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"kind"},message:"must have required property \'kind\'"};e===null?e=[l]:e.push(l),n++}if(r.state===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"state"},message:"must have required property \'state\'"};e===null?e=[l]:e.push(l),n++}if(r.messages===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"messages"},message:"must have required property \'messages\'"};e===null?e=[l]:e.push(l),n++}if(r.agentAttention===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"agentAttention"},message:"must have required property \'agentAttention\'"};e===null?e=[l]:e.push(l),n++}if(r.createdAt===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"createdAt"},message:"must have required property \'createdAt\'"};e===null?e=[l]:e.push(l),n++}if(r.updatedAt===void 0){let l={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"updatedAt"},message:"must have required property \'updatedAt\'"};e===null?e=[l]:e.push(l),n++}for(let l in r)if(!Va.call(tn.properties,l)){let i={instancePath:a,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:l},message:"must NOT have additional properties"};e===null?e=[i]:e.push(i),n++}if(r.id!==void 0){let l=r.id;if(typeof l=="string"){if(it(l)>256){let i={instancePath:a+"/id",schemaPath:"#/properties/id/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};e===null?e=[i]:e.push(i),n++}if(!Os.test(l)){let i={instancePath:a+"/id",schemaPath:"#/properties/id/pattern",keyword:"pattern",params:{pattern:"^thread[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^thread[-:][A-Za-z0-9._:-]+$"\'};e===null?e=[i]:e.push(i),n++}}else{let i={instancePath:a+"/id",schemaPath:"#/properties/id/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[i]:e.push(i),n++}}if(r.reportId!==void 0){let l=r.reportId;if(typeof l=="string"){if(it(l)>256){let i={instancePath:a+"/reportId",schemaPath:"#/properties/reportId/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};e===null?e=[i]:e.push(i),n++}if(!js.test(l)){let i={instancePath:a+"/reportId",schemaPath:"#/properties/reportId/pattern",keyword:"pattern",params:{pattern:"^report[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^report[-:][A-Za-z0-9._:-]+$"\'};e===null?e=[i]:e.push(i),n++}}else{let i={instancePath:a+"/reportId",schemaPath:"#/properties/reportId/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[i]:e.push(i),n++}}if(r.anchor!==void 0){let l=r.anchor;if(l&&typeof l=="object"&&!Array.isArray(l)){if(l.type===void 0){let i={instancePath:a+"/anchor",schemaPath:"#/$defs/reviewAnchor/required",keyword:"required",params:{missingProperty:"type"},message:"must have required property \'type\'"};e===null?e=[i]:e.push(i),n++}if(l.ref===void 0){let i={instancePath:a+"/anchor",schemaPath:"#/$defs/reviewAnchor/required",keyword:"required",params:{missingProperty:"ref"},message:"must have required property \'ref\'"};e===null?e=[i]:e.push(i),n++}if(l.fingerprint===void 0){let i={instancePath:a+"/anchor",schemaPath:"#/$defs/reviewAnchor/required",keyword:"required",params:{missingProperty:"fingerprint"},message:"must have required property \'fingerprint\'"};e===null?e=[i]:e.push(i),n++}for(let i in l)if(!Va.call(ti.properties,i)){let o={instancePath:a+"/anchor",schemaPath:"#/$defs/reviewAnchor/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:i},message:"must NOT have additional properties"};e===null?e=[o]:e.push(o),n++}if(l.type!==void 0){let i=l.type;if(!(i==="change"||i==="file"||i==="hunk"||i==="line-range"||i==="visual-target"||i==="visual-region"||i==="finding"||i==="verification-gap")){let o={instancePath:a+"/anchor/type",schemaPath:"#/$defs/reviewAnchor/properties/type/enum",keyword:"enum",params:{allowedValues:ti.properties.type.enum},message:"must be equal to one of the allowed values"};e===null?e=[o]:e.push(o),n++}}if(l.ref!==void 0&&typeof l.ref!="string"){let i={instancePath:a+"/anchor/ref",schemaPath:"#/$defs/reviewAnchor/properties/ref/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[i]:e.push(i),n++}if(l.path!==void 0&&typeof l.path!="string"){let i={instancePath:a+"/anchor/path",schemaPath:"#/$defs/reviewAnchor/properties/path/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[i]:e.push(i),n++}if(l.side!==void 0){let i=l.side;if(!(i==="before"||i==="after"||i==="diff")){let o={instancePath:a+"/anchor/side",schemaPath:"#/$defs/reviewAnchor/properties/side/enum",keyword:"enum",params:{allowedValues:ti.properties.side.enum},message:"must be equal to one of the allowed values"};e===null?e=[o]:e.push(o),n++}}if(l.startLine!==void 0){let i=l.startLine;if(!(typeof i=="number"&&!(i%1)&&!isNaN(i))){let o={instancePath:a+"/anchor/startLine",schemaPath:"#/$defs/reviewAnchor/properties/startLine/type",keyword:"type",params:{type:"integer"},message:"must be integer"};e===null?e=[o]:e.push(o),n++}if(typeof i=="number"&&(i<1||isNaN(i))){let o={instancePath:a+"/anchor/startLine",schemaPath:"#/$defs/reviewAnchor/properties/startLine/minimum",keyword:"minimum",params:{comparison:">=",limit:1},message:"must be >= 1"};e===null?e=[o]:e.push(o),n++}}if(l.endLine!==void 0){let i=l.endLine;if(!(typeof i=="number"&&!(i%1)&&!isNaN(i))){let o={instancePath:a+"/anchor/endLine",schemaPath:"#/$defs/reviewAnchor/properties/endLine/type",keyword:"type",params:{type:"integer"},message:"must be integer"};e===null?e=[o]:e.push(o),n++}if(typeof i=="number"&&(i<1||isNaN(i))){let o={instancePath:a+"/anchor/endLine",schemaPath:"#/$defs/reviewAnchor/properties/endLine/minimum",keyword:"minimum",params:{comparison:">=",limit:1},message:"must be >= 1"};e===null?e=[o]:e.push(o),n++}}if(l.targetRef!==void 0&&typeof l.targetRef!="string"){let i={instancePath:a+"/anchor/targetRef",schemaPath:"#/$defs/reviewAnchor/properties/targetRef/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[i]:e.push(i),n++}if(l.region!==void 0){let i=l.region;if(i&&typeof i=="object"&&!Array.isArray(i)){if(i.x===void 0){let o={instancePath:a+"/anchor/region",schemaPath:"#/$defs/reviewAnchor/properties/region/required",keyword:"required",params:{missingProperty:"x"},message:"must have required property \'x\'"};e===null?e=[o]:e.push(o),n++}if(i.y===void 0){let o={instancePath:a+"/anchor/region",schemaPath:"#/$defs/reviewAnchor/properties/region/required",keyword:"required",params:{missingProperty:"y"},message:"must have required property \'y\'"};e===null?e=[o]:e.push(o),n++}if(i.width===void 0){let o={instancePath:a+"/anchor/region",schemaPath:"#/$defs/reviewAnchor/properties/region/required",keyword:"required",params:{missingProperty:"width"},message:"must have required property \'width\'"};e===null?e=[o]:e.push(o),n++}if(i.height===void 0){let o={instancePath:a+"/anchor/region",schemaPath:"#/$defs/reviewAnchor/properties/region/required",keyword:"required",params:{missingProperty:"height"},message:"must have required property \'height\'"};e===null?e=[o]:e.push(o),n++}for(let o in i)if(!(o==="x"||o==="y"||o==="width"||o==="height")){let h={instancePath:a+"/anchor/region",schemaPath:"#/$defs/reviewAnchor/properties/region/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:o},message:"must NOT have additional properties"};e===null?e=[h]:e.push(h),n++}if(i.x!==void 0){let o=i.x;if(typeof o=="number"){if(o>1||isNaN(o)){let h={instancePath:a+"/anchor/region/x",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/x/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};e===null?e=[h]:e.push(h),n++}if(o<0||isNaN(o)){let h={instancePath:a+"/anchor/region/x",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/x/minimum",keyword:"minimum",params:{comparison:">=",limit:0},message:"must be >= 0"};e===null?e=[h]:e.push(h),n++}}else{let h={instancePath:a+"/anchor/region/x",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/x/type",keyword:"type",params:{type:"number"},message:"must be number"};e===null?e=[h]:e.push(h),n++}}if(i.y!==void 0){let o=i.y;if(typeof o=="number"){if(o>1||isNaN(o)){let h={instancePath:a+"/anchor/region/y",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/y/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};e===null?e=[h]:e.push(h),n++}if(o<0||isNaN(o)){let h={instancePath:a+"/anchor/region/y",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/y/minimum",keyword:"minimum",params:{comparison:">=",limit:0},message:"must be >= 0"};e===null?e=[h]:e.push(h),n++}}else{let h={instancePath:a+"/anchor/region/y",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/y/type",keyword:"type",params:{type:"number"},message:"must be number"};e===null?e=[h]:e.push(h),n++}}if(i.width!==void 0){let o=i.width;if(typeof o=="number"){if(o>1||isNaN(o)){let h={instancePath:a+"/anchor/region/width",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/width/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};e===null?e=[h]:e.push(h),n++}if(o<=0||isNaN(o)){let h={instancePath:a+"/anchor/region/width",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/width/exclusiveMinimum",keyword:"exclusiveMinimum",params:{comparison:">",limit:0},message:"must be > 0"};e===null?e=[h]:e.push(h),n++}}else{let h={instancePath:a+"/anchor/region/width",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/width/type",keyword:"type",params:{type:"number"},message:"must be number"};e===null?e=[h]:e.push(h),n++}}if(i.height!==void 0){let o=i.height;if(typeof o=="number"){if(o>1||isNaN(o)){let h={instancePath:a+"/anchor/region/height",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/height/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};e===null?e=[h]:e.push(h),n++}if(o<=0||isNaN(o)){let h={instancePath:a+"/anchor/region/height",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/height/exclusiveMinimum",keyword:"exclusiveMinimum",params:{comparison:">",limit:0},message:"must be > 0"};e===null?e=[h]:e.push(h),n++}}else{let h={instancePath:a+"/anchor/region/height",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/height/type",keyword:"type",params:{type:"number"},message:"must be number"};e===null?e=[h]:e.push(h),n++}}}else{let o={instancePath:a+"/anchor/region",schemaPath:"#/$defs/reviewAnchor/properties/region/type",keyword:"type",params:{type:"object"},message:"must be object"};e===null?e=[o]:e.push(o),n++}}if(l.selectorHint!==void 0&&typeof l.selectorHint!="string"){let i={instancePath:a+"/anchor/selectorHint",schemaPath:"#/$defs/reviewAnchor/properties/selectorHint/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[i]:e.push(i),n++}if(l.fingerprint!==void 0){let i=l.fingerprint;if(typeof i=="string"){if(!rs.test(i)){let o={instancePath:a+"/anchor/fingerprint",schemaPath:"#/$defs/reviewAnchor/properties/fingerprint/pattern",keyword:"pattern",params:{pattern:"^[a-f0-9]{64}$"},message:\'must match pattern "^[a-f0-9]{64}$"\'};e===null?e=[o]:e.push(o),n++}}else{let o={instancePath:a+"/anchor/fingerprint",schemaPath:"#/$defs/reviewAnchor/properties/fingerprint/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[o]:e.push(o),n++}}}else{let i={instancePath:a+"/anchor",schemaPath:"#/$defs/reviewAnchor/type",keyword:"type",params:{type:"object"},message:"must be object"};e===null?e=[i]:e.push(i),n++}}if(r.kind!==void 0){let l=r.kind;if(!(l==="note"||l==="question"||l==="finding"||l==="change-request")){let i={instancePath:a+"/kind",schemaPath:"#/properties/kind/enum",keyword:"enum",params:{allowedValues:tn.properties.kind.enum},message:"must be equal to one of the allowed values"};e===null?e=[i]:e.push(i),n++}}if(r.state!==void 0){let l=r.state;if(!(l==="open"||l==="answered"||l==="resolved"||l==="stale"||l==="orphaned")){let i={instancePath:a+"/state",schemaPath:"#/properties/state/enum",keyword:"enum",params:{allowedValues:tn.properties.state.enum},message:"must be equal to one of the allowed values"};e===null?e=[i]:e.push(i),n++}}if(r.messages!==void 0){let l=r.messages;if(Array.isArray(l)){let i=l.length;for(let o=0;o<i;o++){let h=l[o];if(h&&typeof h=="object"&&!Array.isArray(h)){if(h.id===void 0){let c={instancePath:a+"/messages/"+o,schemaPath:"#/$defs/message/required",keyword:"required",params:{missingProperty:"id"},message:"must have required property \'id\'"};e===null?e=[c]:e.push(c),n++}if(h.kind===void 0){let c={instancePath:a+"/messages/"+o,schemaPath:"#/$defs/message/required",keyword:"required",params:{missingProperty:"kind"},message:"must have required property \'kind\'"};e===null?e=[c]:e.push(c),n++}if(h.author===void 0){let c={instancePath:a+"/messages/"+o,schemaPath:"#/$defs/message/required",keyword:"required",params:{missingProperty:"author"},message:"must have required property \'author\'"};e===null?e=[c]:e.push(c),n++}if(h.body===void 0){let c={instancePath:a+"/messages/"+o,schemaPath:"#/$defs/message/required",keyword:"required",params:{missingProperty:"body"},message:"must have required property \'body\'"};e===null?e=[c]:e.push(c),n++}if(h.createdAt===void 0){let c={instancePath:a+"/messages/"+o,schemaPath:"#/$defs/message/required",keyword:"required",params:{missingProperty:"createdAt"},message:"must have required property \'createdAt\'"};e===null?e=[c]:e.push(c),n++}for(let c in h)if(!(c==="id"||c==="kind"||c==="author"||c==="body"||c==="feedbackItemId"||c==="evidenceRefs"||c==="createdAt")){let f={instancePath:a+"/messages/"+o,schemaPath:"#/$defs/message/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:c},message:"must NOT have additional properties"};e===null?e=[f]:e.push(f),n++}if(h.id!==void 0){let c=h.id;if(typeof c=="string"){if(it(c)>256){let f={instancePath:a+"/messages/"+o+"/id",schemaPath:"#/$defs/message/properties/id/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};e===null?e=[f]:e.push(f),n++}if(!xd.test(c)){let f={instancePath:a+"/messages/"+o+"/id",schemaPath:"#/$defs/message/properties/id/pattern",keyword:"pattern",params:{pattern:"^message[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^message[-:][A-Za-z0-9._:-]+$"\'};e===null?e=[f]:e.push(f),n++}}else{let f={instancePath:a+"/messages/"+o+"/id",schemaPath:"#/$defs/message/properties/id/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[f]:e.push(f),n++}}if(h.kind!==void 0){let c=h.kind;if(!(c==="human-note"||c==="agent-answer"||c==="system")){let f={instancePath:a+"/messages/"+o+"/kind",schemaPath:"#/$defs/message/properties/kind/enum",keyword:"enum",params:{allowedValues:wl.properties.kind.enum},message:"must be equal to one of the allowed values"};e===null?e=[f]:e.push(f),n++}}if(h.author!==void 0){let c=h.author;if(c&&typeof c=="object"&&!Array.isArray(c)){if(c.type===void 0){let f={instancePath:a+"/messages/"+o+"/author",schemaPath:"#/$defs/message/properties/author/required",keyword:"required",params:{missingProperty:"type"},message:"must have required property \'type\'"};e===null?e=[f]:e.push(f),n++}if(c.label===void 0){let f={instancePath:a+"/messages/"+o+"/author",schemaPath:"#/$defs/message/properties/author/required",keyword:"required",params:{missingProperty:"label"},message:"must have required property \'label\'"};e===null?e=[f]:e.push(f),n++}for(let f in c)if(!(f==="type"||f==="label")){let w={instancePath:a+"/messages/"+o+"/author",schemaPath:"#/$defs/message/properties/author/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:f},message:"must NOT have additional properties"};e===null?e=[w]:e.push(w),n++}if(c.type!==void 0){let f=c.type;if(!(f==="human"||f==="agent"||f==="system")){let w={instancePath:a+"/messages/"+o+"/author/type",schemaPath:"#/$defs/message/properties/author/properties/type/enum",keyword:"enum",params:{allowedValues:wl.properties.author.properties.type.enum},message:"must be equal to one of the allowed values"};e===null?e=[w]:e.push(w),n++}}if(c.label!==void 0&&typeof c.label!="string"){let f={instancePath:a+"/messages/"+o+"/author/label",schemaPath:"#/$defs/message/properties/author/properties/label/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[f]:e.push(f),n++}}else{let f={instancePath:a+"/messages/"+o+"/author",schemaPath:"#/$defs/message/properties/author/type",keyword:"type",params:{type:"object"},message:"must be object"};e===null?e=[f]:e.push(f),n++}}if(h.body!==void 0){let c=h.body;if(typeof c=="string"){if(it(c)>16384){let f={instancePath:a+"/messages/"+o+"/body",schemaPath:"#/$defs/message/properties/body/maxLength",keyword:"maxLength",params:{limit:16384},message:"must NOT have more than 16384 characters"};e===null?e=[f]:e.push(f),n++}if(it(c)<1){let f={instancePath:a+"/messages/"+o+"/body",schemaPath:"#/$defs/message/properties/body/minLength",keyword:"minLength",params:{limit:1},message:"must NOT have fewer than 1 characters"};e===null?e=[f]:e.push(f),n++}}else{let f={instancePath:a+"/messages/"+o+"/body",schemaPath:"#/$defs/message/properties/body/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[f]:e.push(f),n++}}if(h.feedbackItemId!==void 0){let c=h.feedbackItemId;if(typeof c=="string"){if(it(c)>256){let f={instancePath:a+"/messages/"+o+"/feedbackItemId",schemaPath:"#/$defs/message/properties/feedbackItemId/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};e===null?e=[f]:e.push(f),n++}if(!Id.test(c)){let f={instancePath:a+"/messages/"+o+"/feedbackItemId",schemaPath:"#/$defs/message/properties/feedbackItemId/pattern",keyword:"pattern",params:{pattern:"^item[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^item[-:][A-Za-z0-9._:-]+$"\'};e===null?e=[f]:e.push(f),n++}}else{let f={instancePath:a+"/messages/"+o+"/feedbackItemId",schemaPath:"#/$defs/message/properties/feedbackItemId/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[f]:e.push(f),n++}}if(h.evidenceRefs!==void 0){let c=h.evidenceRefs;if(Array.isArray(c)){if(c.length>100){let H={instancePath:a+"/messages/"+o+"/evidenceRefs",schemaPath:"#/$defs/message/properties/evidenceRefs/maxItems",keyword:"maxItems",params:{limit:100},message:"must NOT have more than 100 items"};e===null?e=[H]:e.push(H),n++}let f=c.length;for(let H=0;H<f;H++)if(typeof c[H]!="string"){let R={instancePath:a+"/messages/"+o+"/evidenceRefs/"+H,schemaPath:"#/$defs/message/properties/evidenceRefs/items/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[R]:e.push(R),n++}let w=c.length,q;if(w>1){let H={};for(;w--;){let R=c[w];if(typeof R=="string"){if(typeof H[R]=="number"){q=H[R];let W={instancePath:a+"/messages/"+o+"/evidenceRefs",schemaPath:"#/$defs/message/properties/evidenceRefs/uniqueItems",keyword:"uniqueItems",params:{i:w,j:q},message:"must NOT have duplicate items (items ## "+q+" and "+w+" are identical)"};e===null?e=[W]:e.push(W),n++;break}H[R]=w}}}}else{let f={instancePath:a+"/messages/"+o+"/evidenceRefs",schemaPath:"#/$defs/message/properties/evidenceRefs/type",keyword:"type",params:{type:"array"},message:"must be array"};e===null?e=[f]:e.push(f),n++}}if(h.createdAt!==void 0){let c=h.createdAt;if(typeof c=="string"){if(!la.validate(c)){let f={instancePath:a+"/messages/"+o+"/createdAt",schemaPath:"#/$defs/message/properties/createdAt/format",keyword:"format",params:{format:"date-time"},message:\'must match format "date-time"\'};e===null?e=[f]:e.push(f),n++}}else{let f={instancePath:a+"/messages/"+o+"/createdAt",schemaPath:"#/$defs/message/properties/createdAt/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[f]:e.push(f),n++}}}else{let c={instancePath:a+"/messages/"+o,schemaPath:"#/$defs/message/type",keyword:"type",params:{type:"object"},message:"must be object"};e===null?e=[c]:e.push(c),n++}}}else{let i={instancePath:a+"/messages",schemaPath:"#/properties/messages/type",keyword:"type",params:{type:"array"},message:"must be array"};e===null?e=[i]:e.push(i),n++}}if(r.agentAttention!==void 0){let l=r.agentAttention;if(l&&typeof l=="object"&&!Array.isArray(l)){if(l.state===void 0){let i={instancePath:a+"/agentAttention",schemaPath:"#/properties/agentAttention/required",keyword:"required",params:{missingProperty:"state"},message:"must have required property \'state\'"};e===null?e=[i]:e.push(i),n++}for(let i in l)if(!(i==="state"||i==="batchId"||i==="updatedAt")){let o={instancePath:a+"/agentAttention",schemaPath:"#/properties/agentAttention/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:i},message:"must NOT have additional properties"};e===null?e=[o]:e.push(o),n++}if(l.state!==void 0){let i=l.state;if(!(i==="none"||i==="requested"||i==="batched"||i==="submitted"||i==="acknowledged"||i==="answered"||i==="stale")){let o={instancePath:a+"/agentAttention/state",schemaPath:"#/properties/agentAttention/properties/state/enum",keyword:"enum",params:{allowedValues:tn.properties.agentAttention.properties.state.enum},message:"must be equal to one of the allowed values"};e===null?e=[o]:e.push(o),n++}}if(l.batchId!==void 0){let i=l.batchId;if(typeof i=="string"){if(it(i)>256){let o={instancePath:a+"/agentAttention/batchId",schemaPath:"#/properties/agentAttention/properties/batchId/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};e===null?e=[o]:e.push(o),n++}if(!Ad.test(i)){let o={instancePath:a+"/agentAttention/batchId",schemaPath:"#/properties/agentAttention/properties/batchId/pattern",keyword:"pattern",params:{pattern:"^fb[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^fb[-:][A-Za-z0-9._:-]+$"\'};e===null?e=[o]:e.push(o),n++}}else{let o={instancePath:a+"/agentAttention/batchId",schemaPath:"#/properties/agentAttention/properties/batchId/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[o]:e.push(o),n++}}if(l.updatedAt!==void 0){let i=l.updatedAt;if(typeof i=="string"){if(!la.validate(i)){let o={instancePath:a+"/agentAttention/updatedAt",schemaPath:"#/properties/agentAttention/properties/updatedAt/format",keyword:"format",params:{format:"date-time"},message:\'must match format "date-time"\'};e===null?e=[o]:e.push(o),n++}}else{let o={instancePath:a+"/agentAttention/updatedAt",schemaPath:"#/properties/agentAttention/properties/updatedAt/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[o]:e.push(o),n++}}}else{let i={instancePath:a+"/agentAttention",schemaPath:"#/properties/agentAttention/type",keyword:"type",params:{type:"object"},message:"must be object"};e===null?e=[i]:e.push(i),n++}}if(r.createdAt!==void 0){let l=r.createdAt;if(typeof l=="string"){if(!la.validate(l)){let i={instancePath:a+"/createdAt",schemaPath:"#/properties/createdAt/format",keyword:"format",params:{format:"date-time"},message:\'must match format "date-time"\'};e===null?e=[i]:e.push(i),n++}}else{let i={instancePath:a+"/createdAt",schemaPath:"#/properties/createdAt/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[i]:e.push(i),n++}}if(r.updatedAt!==void 0){let l=r.updatedAt;if(typeof l=="string"){if(!la.validate(l)){let i={instancePath:a+"/updatedAt",schemaPath:"#/properties/updatedAt/format",keyword:"format",params:{format:"date-time"},message:\'must match format "date-time"\'};e===null?e=[i]:e.push(i),n++}}else{let i={instancePath:a+"/updatedAt",schemaPath:"#/properties/updatedAt/type",keyword:"type",params:{type:"string"},message:"must be string"};e===null?e=[i]:e.push(i),n++}}}else{let l={instancePath:a,schemaPath:"#/type",keyword:"type",params:{type:"object"},message:"must be object"};e===null?e=[l]:e.push(l),n++}return Rd.errors=e,n===0}const af={"review-bundle":Gh,"review-event":Qh,"review-state":tf,"review-thread":rf};function sf(r){return`${r.instancePath||"/"} ${r.message??"is invalid"}`}function gn(r){return Array.isArray(r)?`[${r.map(gn).join(",")}]`:r&&typeof r=="object"?`{${Object.entries(r).sort(([a],[s])=>a.localeCompare(s)).map(([a,s])=>`${JSON.stringify(a)}:${gn(s)}`).join(",")}}`:JSON.stringify(r)??"null"}function qs(r,a){const s=af[r],d=s(a);return{ok:!!d,errors:d?[]:(s.errors??[]).map(sf)}}function Sd(r){const a=qs("review-bundle",r);if(!a.ok)return a;const s=r,d=[],u=qs("review-state",s.state);d.push(...u.errors.map(c=>`state${c}`));for(const[c,f]of s.threads.entries()){const w=qs("review-thread",f);d.push(...w.errors.map(q=>`threads/${c}${q}`))}for(const[c,f]of s.events.entries()){const w=qs("review-event",f);d.push(...w.errors.map(q=>`events/${c}${q}`))}if(d.length>0)return{ok:!1,errors:d};s.state.reportId!==s.source.reportId&&d.push("state.reportId does not match source.reportId"),s.state.reportFingerprint!==s.source.reportFingerprint&&d.push("state.reportFingerprint does not match source.reportFingerprint");const e=s.threads.map(c=>c.id);new Set(e).size!==e.length&&d.push("threads contains duplicate IDs"),[...new Set(s.state.threadIds)].sort().join(`\n`)!==[...new Set(e)].sort().join(`\n`)&&d.push("state.threadIds does not match bundled threads");const n=new Set(s.state.orphanedThreadIds);for(const c of s.threads){c.reportId!==s.source.reportId&&d.push(`${c.id} reportId does not match source.reportId`),c.state==="orphaned"!==n.has(c.id)&&d.push(`${c.id} orphaned state is inconsistent`);for(const[f,w]of c.messages.entries()){const q=new TextEncoder().encode(w.body).byteLength;w.body.trim()||d.push(`${c.id}.messages/${f} body is empty`),q>16*1024&&d.push(`${c.id}.messages/${f} body exceeds 16 KiB`)}}for(const c of n)e.includes(c)||d.push(`orphaned thread is missing: ${c}`);const l=s.events.map(c=>c.id);new Set(l).size!==l.length&&d.push("events contains duplicate IDs");for(const[c,f]of s.events.entries())f.sequence!==c+1&&d.push(`events/${c} sequence is not contiguous`),f.reportId!==s.source.reportId&&d.push(`events/${c} reportId does not match source.reportId`);const i=s.anchorCatalog.map(c=>`${c.type}\\0${c.ref}`);new Set(i).size!==i.length&&d.push("anchorCatalog contains duplicate type/ref pairs");const o=new Map(s.anchorCatalog.map(c=>[`${c.type}\\0${c.ref}`,c])),h=(c,f)=>{const w=o.get(`${f.type}\\0${f.ref}`);(!w||gn(w)!==gn(f))&&d.push(`${c} does not match anchorCatalog`)};for(const[c,f]of Object.entries(s.state.viewed))c!==JSON.stringify([f.anchor.type,f.anchor.ref])&&d.push(`state.viewed key does not match its anchor: ${c}`),h(`state.viewed/${c}.anchor`,f.anchor);for(const[c,f]of s.threads.entries())h(`threads/${c}.anchor`,f.anchor);for(const[c,f]of s.events.entries())f.anchor&&h(`events/${c}.anchor`,f.anchor);return{ok:d.length===0,errors:d}}const Ed=4*1024*1024;function Ve(r,a){const s=new Error(a);return s.name=r,s}function Oe(r){return structuredClone(r)}function Nd(r){return`utsuri:review:v1:${encodeURIComponent(r)}`}function Cd(r){if(new TextEncoder().encode(r).byteLength>Ed)throw Ve("REVIEW_BROWSER_LIMIT","Stored review state exceeds 4 MiB");const a=JSON.parse(r),s=[a];for(;s.length>0;){const d=s.pop();if(!(!d||typeof d!="object"))if(Array.isArray(d))s.push(...d);else for(const[u,e]of Object.entries(d)){if(new Set(["__proto__","constructor","prototype"]).has(u))throw Ve("REVIEW_BROWSER_KEY","Stored review state has a forbidden key");s.push(e)}}return a}function nf(r){if(!r||typeof r!="object"||Array.isArray(r))return!1;const a=r;return a.schemaVersion==="1.0"&&typeof a.reportFingerprint=="string"&&!!(a.state&&typeof a.state=="object")&&Array.isArray(a.threads)&&Array.isArray(a.events)}function ri(r,a){const s=qs(r,a);if(!s.ok)throw Ve("REVIEW_BROWSER_INVALID",`${r}: ${s.errors.join("; ")}`)}function of(r){for(const a of r)for(const s of a.messages){if(!s.body.trim())throw Ve("REVIEW_BROWSER_INVALID","Stored review comment body is empty");if(new TextEncoder().encode(s.body).byteLength>16*1024)throw Ve("REVIEW_BROWSER_INVALID","Stored review comment exceeds 16 KiB")}}function bn(r){ri("review-state",r.state);for(const u of r.threads)ri("review-thread",u);for(const u of r.events)ri("review-event",u);if(of(r.threads),r.state.schemaVersion!=="1.3"||r.state.reportId!==r.report.reportId||r.state.reportFingerprint.length!==64||r.state.revision!==r.events.length)throw Ve("REVIEW_BROWSER_INVALID","Stored review state is inconsistent");if(new Set(r.state.threadIds).size!==r.state.threadIds.length)throw Ve("REVIEW_BROWSER_INVALID","Stored review threads are duplicated");const a=new Set(r.threads.map(u=>u.id));if(a.size!==r.threads.length||r.state.threadIds.length!==r.threads.length||r.state.threadIds.some(u=>!a.has(u)))throw Ve("REVIEW_BROWSER_INVALID","Stored review thread inventory is inconsistent");const s=new Set(r.state.orphanedThreadIds);for(const u of r.threads)if(u.reportId!==r.report.reportId||u.state==="orphaned"!==s.has(u.id))throw Ve("REVIEW_BROWSER_INVALID","Stored review thread identity is inconsistent");const d=new Set;for(const[u,e]of r.events.entries()){if(d.has(e.id)||e.sequence!==u+1||e.reportId!==r.report.reportId)throw Ve("REVIEW_BROWSER_INVALID","Stored review event sequence is invalid");d.add(e.id)}}async function Ld(r,a){const s=Cd(a);if(!nf(s))throw Ve("REVIEW_BROWSER_INVALID","Stored review state has an invalid shape");if(s.reportFingerprint!==r.state.reportFingerprint||s.state.reportFingerprint!==s.reportFingerprint)throw Ve("REVIEW_BROWSER_STALE","Stored review state belongs to an older report; export it before re-anchoring");const d=bd(s,r.anchorCatalog,await wd(r.report,Mr),!0);return bn({...r,state:Oe(d.state),threads:Oe(d.threads),events:Oe(d.events)}),d}function lf(){const r=globalThis.navigator?.locks;if(!r)throw Ve("REVIEW_BROWSER_LOCK_UNAVAILABLE","Concurrent-safe review storage requires utsuri serve in a browser with Web Locks support");return r}function ls(r,a){return{...Oe(r.state),revision:r.state.revision+1,updatedAt:a}}async function ds(r,a,s){const d=r.events.length+1,u={reportId:r.report.reportId,sequence:d,createdAt:a,...s};return{schemaVersion:"1.0",id:`event:${(await Mr(u)).slice(0,24)}`,...u}}async function jd(r,a){const s=await Mr(r);return{report:Oe(r),state:{schemaVersion:"1.3",reportId:r.reportId,reportFingerprint:s,revision:0,updatedAt:a,viewed:{},judgments:Object.fromEntries(r.changes.map(d=>[d.id,{changeId:d.id,state:"unreviewed",updatedAt:a}])),threadIds:[],orphanedThreadIds:[]},threads:[],events:[],anchorCatalog:await Zh(r,Mr),sidecarFiles:{}}}async function df(r){const a=await jd(r,new Date().toISOString()),s=localStorage.getItem(Nd(r.reportId));if(!s)return a;const d=await Ld(a,s),u={...a,state:Oe(d.state),threads:Oe(d.threads),events:Oe(d.events)};return bn(u),u}async function uf(r,a=r.state.revision-1){if(bn(r),a<0||r.state.revision!==a+1)throw Ve("REVIEW_REVISION_INVALID","Review mutation must advance one revision");const s={schemaVersion:"1.0",reportFingerprint:r.state.reportFingerprint,state:Oe(r.state),threads:Oe(r.threads),events:Oe(r.events)},d=JSON.stringify(s);if(new TextEncoder().encode(d).byteLength>Ed)throw Ve("REVIEW_BROWSER_LIMIT","Review state is near browser-storage limits; export it before adding more comments");const u=Nd(r.report.reportId);await lf().request(`${u}:write`,{mode:"exclusive"},async()=>{const e=localStorage.getItem(u);if((e?(await Ld(r,e)).state.revision:0)!==a)throw Ve("REVIEW_REVISION_CONFLICT","Review state changed in another tab; reload before retrying this edit");localStorage.setItem(u,d)})}async function pf(r,a,s,d=new Date().toISOString()){const u=ls(r,d);u.viewed[Wr(a)]={anchor:Oe(a),state:s,updatedAt:d};const e=await ds(r,d,{type:"viewed.changed",anchor:Oe(a),viewState:s});return{...r,state:u,events:[...r.events,e]}}async function cf(r,a,s,d=new Date().toISOString()){if(!r.report.changes.some(n=>n.id===a))throw Ve("REVIEW_CHANGE_MISSING","Review change does not exist");const u=ls(r,d);u.judgments[a]={changeId:a,state:s,updatedAt:d};const e=await ds(r,d,{type:"judgment.changed",changeId:a,judgmentState:s});return{...r,state:u,events:[...r.events,e]}}async function hf(r,a,s,d,u=new Date().toISOString(),e=!1){const n=s.trim();if(!n)throw Ve("REVIEW_COMMENT_EMPTY","Review comments must not be empty");if(new TextEncoder().encode(n).byteLength>16*1024)throw Ve("REVIEW_COMMENT_LIMIT","Review comment exceeds 16 KiB");const l=`thread:${(await Mr({reportId:r.report.reportId,anchor:a,kind:d,normalized:n,createdAt:u})).slice(0,24)}`,i=`message:${(await Mr({threadId:l,normalized:n,createdAt:u})).slice(0,24)}`,o={id:l,reportId:r.report.reportId,anchor:Oe(a),kind:d,state:"open",messages:[{id:i,kind:"human-note",author:{type:"human",label:"Reviewer"},body:n,createdAt:u}],agentAttention:e?{state:"requested",updatedAt:u}:{state:"none"},createdAt:u,updatedAt:u},h=ls(r,u);h.threadIds=[...h.threadIds,l];const c=await ds(r,u,{type:"thread.created",anchor:Oe(a),threadId:l,messageId:i,attentionState:e?"requested":"none"});return{...r,state:h,threads:[...r.threads,o],events:[...r.events,c]}}async function ff(r,a,s,d=new Date().toISOString()){const u=r.threads.findIndex(h=>h.id===a);if(u===-1)throw Ve("REVIEW_THREAD_MISSING","Review thread does not exist");const e=r.threads[u];if(new Set(["stale","orphaned","resolved"]).has(e.state))throw Ve("REVIEW_THREAD_NOT_CURRENT","Stale, orphaned, or resolved comments cannot request Agent attention");const n=s?"requested":"none";if(e.agentAttention.state!=="none"&&e.agentAttention.state!=="requested")throw Ve("REVIEW_ATTENTION_SUBMITTED","Submitted Agent attention cannot be changed");if(e.agentAttention.state===n)return r;const l=Oe(r.threads);l[u]={...l[u],agentAttention:{state:n,updatedAt:d},updatedAt:d};const i=ls(r,d),o=await ds(r,d,{type:"agent-attention.changed",threadId:a,attentionState:n});return{...r,state:i,threads:l,events:[...r.events,o]}}async function mf(r,a,s=new Date().toISOString()){const d=r.threads.findIndex(i=>i.id===a);if(d===-1)throw Ve("REVIEW_THREAD_MISSING","Review thread does not exist");const u=r.threads[d];if(u.state==="stale"||u.state==="orphaned")throw Ve("REVIEW_THREAD_NOT_CURRENT","Stale or orphaned comments cannot be resolved");const e=Oe(r.threads);e[d]={...e[d],state:"resolved",updatedAt:s};const n=ls(r,s),l=await ds(r,s,{type:"thread.resolved",threadId:a});return{...r,state:n,threads:e,events:[...r.events,l]}}function vf(r){const a=new Map(r.anchorCatalog.map(s=>[Wr(s),Oe(s)]));for(const s of Object.values(r.state.viewed))a.set(Wr(s.anchor),Oe(s.anchor));for(const s of r.threads)a.set(Wr(s.anchor),Oe(s.anchor));return[...a.values()].sort((s,d)=>Wr(s).localeCompare(Wr(d)))}function gf(r,a,s=new Date().toISOString()){const d={schemaVersion:"1.0",source:{reportId:r.report.reportId,reportFingerprint:r.state.reportFingerprint,base:a.base,head:a.head},state:Oe(r.state),threads:Oe(r.threads),events:Oe(r.events),anchorCatalog:vf(r),exportedAt:s},u=Sd(d);if(!u.ok)throw Ve("REVIEW_BUNDLE_INVALID",u.errors.join("; "));return d}async function yf(r,a,s={}){const d=s.importedAt??new Date().toISOString(),u=JSON.stringify(a),e=Cd(u),n=e&&typeof e=="object"&&!Array.isArray(e)&&"source"in e?e.source:null,l=!!(n&&typeof n=="object"&&!Array.isArray(n)&&"reportId"in n&&"reportFingerprint"in n&&n.reportId===r.report.reportId&&n.reportFingerprint===r.state.reportFingerprint),i=bd(e,r.anchorCatalog,await wd(r.report,Mr),l),o=Sd(i);if(!o.ok)throw Ve("REVIEW_BUNDLE_INVALID",o.errors.join("; "));const h=i;if(!l&&!s.reanchor)throw Ve("REVIEW_REPORT_MISMATCH","Review bundle belongs to another report; explicitly enable re-anchoring to import it");const c=[],f=[],w=ls(r,d);for(const[re,ae]of Object.entries(h.state.viewed)){const oe=Yn(ae.anchor,r.anchorCatalog);f.push(oe);const me=oe.result==="exact"?oe.candidate:ae.anchor,ve=oe.result==="exact"?Wr(me):re,ge={anchor:Oe(me),state:oe.result==="exact"?ae.state:"stale",updatedAt:d},_e=w.viewed[ve];_e&&Na(_e)!==Na(ge)?c.push({kind:"viewed",id:ve,current:_e,incoming:ge}):w.viewed[ve]=ge}const q=new Map(h.anchorCatalog.filter(re=>re.type==="change").map(re=>[re.ref,re]));for(const[re,ae]of Object.entries(h.state.judgments)){const oe=q.get(re),me=oe?Yn(oe,r.anchorCatalog):void 0;me&&f.push(me);const ve=me?.result==="exact"?me.candidate.ref:re,ge={changeId:ve,state:me?.result==="exact"?ae.state:"stale",updatedAt:d},_e=w.judgments[ve];_e&&_e.state!=="unreviewed"&&Na(_e)!==Na(ge)?c.push({kind:"judgment",id:ve,current:_e,incoming:ge}):w.judgments[ve]=ge}const H=Oe(r.threads);for(const re of h.threads){const ae=Yn(re.anchor,r.anchorCatalog);f.push(ae);const oe={...Oe(re),reportId:r.report.reportId,anchor:ae.result==="exact"?Oe(ae.candidate):Oe(re.anchor),state:ae.result==="exact"?re.state:ae.result==="missing"?"orphaned":"stale",updatedAt:d},me=H.find(ve=>ve.id===oe.id);me&&Na(me)!==Na(oe)?c.push({kind:"thread",id:oe.id,current:me,incoming:oe}):me||H.push(oe)}w.threadIds=H.map(re=>re.id),w.orphanedThreadIds=H.filter(re=>re.state==="orphaned").map(re=>re.id);const R=await ds(r,d,{type:"state.imported",sourceReportId:h.source.reportId}),W={...r,state:w,threads:H,events:[...r.events,R]};return bn(W),{store:W,reanchored:f,conflicts:c}}const _f=512*1024;function Ps(r,a,s){const d=[/\\bBearer\\s+[A-Za-z0-9._~+/=-]{8,}\\b/giu,/\\b(?:api[_-]?key|access[_-]?token|auth[_-]?token|token|password|passwd|secret)\\b\\s*[:=]\\s*[^\\s,;]+/giu,/\\bAKIA[0-9A-Z]{16}\\b/gu,/\\b(?:gh[pousr]_[A-Za-z0-9_]{20,}|github_pat_[A-Za-z0-9_]{20,}|sk-[A-Za-z0-9_-]{12,})\\b/gu];let u=r;for(const e of d)e.test(u)&&(s.push({category:"secret-pattern",ref:a}),u=u.replace(e,"[REDACTED]")),e.lastIndex=0;return u}function wf(r,a){const s=a.anchor;return s.type==="change"?r.changes.find(d=>d.id===s.ref):s.type==="hunk"||s.type==="line-range"?r.changes.find(d=>d.hunkRefs.some(u=>s.ref===u||s.ref.startsWith(`${u}:`))):s.type==="visual-target"||s.type==="visual-region"?r.changes.find(d=>d.targetRefs.includes(s.targetRef??s.ref)):s.type==="finding"?r.changes.find(d=>d.findingRefs.includes(s.ref)):r.changes.find(d=>s.ref.startsWith(`${d.id}:gap:`))}function bf(r,a,s){return a.anchor.type==="hunk"||a.anchor.type==="line-range"?r.hunks.filter(d=>a.anchor.ref===d.id||a.anchor.ref.startsWith(`${d.id}:`)):s?r.hunks.filter(d=>s.hunkRefs.includes(d.id)):[]}function Pf(r,a){const s=a.anchor.targetRef??(a.anchor.type==="visual-target"?a.anchor.ref:void 0);if(!s)return[];const d=a.anchor.type==="visual-region"?a.anchor.region:void 0;return r.comparisons.filter(u=>u.targetRef===s).flatMap(u=>u.images.flatMap(e=>[{role:"before",assetRef:e.beforeRef,...d?{crop:d}:{}},{role:"after",assetRef:e.afterRef,...d?{crop:d}:{}},{role:"diff",assetRef:e.diffRef,...d?{crop:d}:{}}])).slice(0,10)}async function kf(r,a=new Date().toISOString()){const s=r.threads.filter(i=>i.agentAttention.state==="requested"&&!new Set(["stale","orphaned","resolved"]).has(i.state));if(s.length===0)throw new Error("No current comments request Agent attention");if(s.length>20)throw new Error("Feedback Batch exceeds 20 items");const d=`fb:${(await Mr({reportId:r.report.reportId,threads:s.map(i=>i.id),createdAt:a})).slice(0,24)}`,u=await Promise.all(s.map(async i=>{const o=[...i.messages].reverse().find(c=>c.author.type==="human");if(!o)throw new Error("Feedback thread has no human source message");const h=i.anchor.type==="visual-target"||i.anchor.type==="visual-region";return{id:`item:${(await Mr({batchId:d,threadId:i.id,messageId:o.id})).slice(0,24)}`,threadId:i.id,anchor:structuredClone(i.anchor),sourceMessageId:o.id,requestKind:i.kind==="question"?"explain":"freeform",question:o.body,contextSelection:{includeCodeDiff:!h,includeVisualCrop:h,includeComputedStyle:!1,includeDomAria:!1,includeRelatedTests:!1},state:"ready"}})),e=structuredClone(r.report.origin),n=[];for(const[i,o]of u.entries()){const h=s[i],c=wf(r.report,h),f=[],w=bf(r.report,h,c),q={schemaVersion:"1.1",reportId:r.report.reportId,batchId:d,itemId:o.id,baseSha:"",headSha:"",anchor:structuredClone(o.anchor),question:Ps(o.question,`item:${o.id}:question`,f),...c?{semanticChange:{id:c.id,title:Ps(c.title,`change:${c.id}:title`,f),summary:Ps(c.summary,`change:${c.id}:summary`,f),intent:{text:Ps(c.intent.text,`change:${c.id}:intent`,f),source:c.intent.source,evidenceRefs:[...c.intent.evidenceRefs]},risk:structuredClone(c.risk)}}:{},code:o.contextSelection.includeCodeDiff?w.map(R=>({path:R.path,startLine:Math.max(1,R.newStart||R.oldStart),endLine:Math.max(1,(R.newStart||R.oldStart)+Math.max(R.newLines,R.oldLines)-1),textRef:R.id})):[],images:o.contextSelection.includeVisualCrop?Pf(r.report,h):[],evidenceRefs:c?[...c.intent.evidenceRefs]:[],priorThreadMessages:h.messages.map(R=>({role:R.author.type==="agent"?"agent":"human",text:Ps(R.body,`message:${R.id}`,f)})),redactions:f},H={...q,contextHash:await Mr(q)};if(new TextEncoder().encode(JSON.stringify(H)).byteLength>_f)throw new Error("Context Pack exceeds 512 KiB");n.push(H)}return{batch:{id:d,reportId:r.report.reportId,origin:e,items:u.map((i,o)=>({...i,question:n[o].question})),state:"ready",deliveryMode:"export-only",contextHash:await Mr(n.map(i=>i.contextHash)),createdAt:a},contexts:n,shared:{comments:u.length,codeRanges:n.reduce((i,o)=>i+o.code.length,0),imageCrops:n.reduce((i,o)=>i+o.images.length,0),evidenceReferences:n.reduce((i,o)=>i+o.evidenceRefs.length,0)},excluded:["raw DOM and ARIA artifacts","environment variables","files outside the report","related tests"],redactionCount:n.reduce((i,o)=>i+o.redactions.length,0),contextBytes:n.reduce((i,o)=>i+new TextEncoder().encode(JSON.stringify(o)).byteLength,0),warnings:["Static mode exports files; it cannot submit to an Origin Session"],destination:{host:e.host,bound:!!e.sessionRef,deliveryMode:"export-only"}}}var rn=M("<span> </span>"),xf=M(\'<li><a><span class="queue-index"> </span> <span class="queue-copy"><strong> </strong> <span class="badges"><span> </span> <!></span></span></a></li>\'),Af=M(\'<section class="queue-section"><h3><span> </span> <span class="count"> </span></h3> <ol></ol></section>\'),If=M(\'<li><a><span class="queue-index"> </span> <span class="queue-copy"><strong> </strong><span> </span></span></a></li>\'),$f=M(\'<section class="queue-section unclassified"><h3><span> </span><span class="count"> </span></h3> <ol></ol></section>\'),qf=M(\'<p class="review-overview"> </p>\'),Rf=M(\'<p class="route-status"> </p> <h3> </h3> <p> </p> <button type="button"> <span aria-hidden="true">→</span></button>\',1),Sa=M("<p> </p>"),Sf=M(\'<li><button type="button"><span class="map-index"> </span> <span class="map-copy"><strong> </strong> <span> </span></span> <span class="map-meta"> <span aria-hidden="true">·</span> </span></button></li>\'),Ef=M(\'<li class="map-remainder"> </li>\'),Nf=M(\'<section class="review-map" aria-labelledby="review-map-heading"><header><div><p class="kicker">Map / semantic</p> <h2 id="review-map-heading"> </h2></div> <p> </p></header> <ol><!> <!></ol></section>\'),Cf=M(\'<label class="viewed-control compact-control"><input type="checkbox"/> <span> </span></label>\'),Lf=M(\'<li><span class="file-status"> </span> <code> </code> <span> </span> <!></li>\'),an=M("<option> </option>"),jf=M(\'<div class="review-controls"><label><span> </span> <select><!><!></select></label> <label class="viewed-control"><input type="checkbox"/> <span> </span></label> <button type="button"> </button></div> <p class="local-only-note"> </p>\',1),Of=M(\'<p class="review-message" role="alert"> </p>\'),Tf=M(\'<p class="review-message" role="status"> </p>\'),ai=M("<li> </li>"),zf=M("<ul></ul>"),Mf=M(\'<button type="button" class="inline-comment-action"> </button>\'),Vf=M("<li><span> </span> <!></li>"),Df=M("<label><span>Target</span> <select></select></label>"),Ff=M("<label><span> </span> <select></select></label>"),Bf=M(\'<label class="viewed-control visual-viewed-control"><input type="checkbox"/> <span> </span></label>\'),Hf=M(\'<div class="persistent-error" role="alert"><strong>INCOMPLETE</strong> <span> </span></div>\'),bl=M(\'<span aria-hidden="true"> </span>\'),ks=M(\'<button class="visual-comment-pin" type="button"> </button>\'),Wf=M(\'<div class="visual-panes" data-visual-mode="side-by-side"><figure><figcaption> </figcaption> <div class="visual-scroll"><div class="image-stage"><img/></div></div></figure> <figure><figcaption> </figcaption> <div class="visual-scroll"><div class="image-stage"><img/> <!> <!></div></div></figure></div>\'),Zf=M(\'<label class="wipe-control"><span> </span> <input type="range" min="0" max="100"/></label> <figure class="single-visual"><figcaption> </figcaption> <div class="visual-scroll"><div class="image-stage"><img/> <img class="wipe-after"/> <!></div></div></figure>\',1),Uf=M(\'<figure class="single-visual"><figcaption> </figcaption> <div class="visual-scroll"><div class="image-stage"><img/> <img/> <!></div></div></figure>\'),Kf=M(\'<figure class="single-visual pixel-diff-view"><figcaption> </figcaption> <div class="visual-scroll"><div class="image-stage"><img/> <!></div></div></figure>\'),Jf=M(\'<figure class="single-visual"><figcaption> </figcaption> <div class="visual-scroll"><div class="image-stage"><img/> <!> <!></div></div></figure>\'),Ea=M(\'<button type="button"> </button>\'),Yf=M(\'<li><div class="region-actions"><button type="button"> </button> <!></div></li>\'),Pl=M("<ol></ol>"),Gf=M(\'<dl class="visual-metrics"><div><dt>Pixels changed</dt> <dd> </dd></div> <div><dt>Pixel ratio</dt> <dd> </dd></div> <div><dt> </dt> <dd> </dd></div> <div><dt>Canvas</dt> <dd> </dd></div></dl> <!> <section class="region-list" aria-labelledby="region-heading"><h4 id="region-heading"> </h4> <!></section>\',1),Qf=M(\'<div class="visual-selectors"><!> <!> <!> <label class="visual-slider"><span> </span> <input type="range" min="50" max="200" step="10"/></label></div> <div class="visual-mode-control" role="group"><button type="button"> </button> <button type="button"> </button> <button type="button"> </button> <button type="button"> </button> <button type="button"> </button></div> <!> <!>\',1),Xf=M(\'<div class="verification-gap" role="status"><strong>UNCOVERED</strong> <span> </span></div>\'),em=M(\'<li><article tabindex="-1"><div class="finding-badges"><span> </span><span> </span><span> </span></div> <h5> </h5> <p> </p> <!> <!></article></li>\'),tm=M("<li><span> </span><strong> </strong> <p> </p></li>"),rm=M("<li><strong> </strong> </li>"),am=M(\'<details class="more-evidence"><summary> </summary> <ul></ul></details>\'),sm=M(\'<label class="viewed-control dark-control"><input type="checkbox"/> <span> </span></label> <button type="button"> </button>\',1),nm=M(\'<dl class="hunk-explanation"><div><dt> </dt> <dd> </dd></div> <div><dt> </dt> <dd> </dd></div></dl>\'),kl=M(\'<button class="context-fold" type="button"> </button>\'),xl=M(\'<button class="line-comment" type="button">✎</button>\'),im=M(\'<div role="group"><span class="line-number" aria-hidden="true"> </span> <span class="line-number" aria-hidden="true"> </span> <span class="line-sign" aria-hidden="true"> </span> <code></code> <!></div>\'),Al=M("<code></code>"),om=M(\'<div class="split-row" role="group"><div><span class="line-number" aria-hidden="true"> </span> <span class="line-sign" aria-hidden="true"> </span> <!></div> <div><span class="line-number" aria-hidden="true"> </span> <span class="line-sign" aria-hidden="true"> </span> <!></div> <!></div>\'),lm=M(\'<button class="back-link hunk-back" type="button"> </button>\'),dm=M(\'<section tabindex="-1"><header><div><p> </p> <h4> </h4></div> <div class="hunk-actions"><!> <!> <button type="button" class="anchor-button">#</button></div></header> <!> <div role="region"></div> <!></section>\'),um=M(\'<form class="comment-composer"><div><p class="kicker"> </p> <code> </code></div> <label><span>Kind</span> <select><option>Note</option><option>Question</option><option>Finding</option><option>Change request</option></select></label> <label class="comment-body"><span> </span> <textarea rows="4" maxlength="16384" required=""></textarea></label> <label class="agent-attention-control"><input type="checkbox"/> <span> </span> <small> </small></label> <p> </p> <div class="comment-actions"><button type="submit"> </button> <button type="button"> </button></div></form>\'),pm=M(\'<label class="agent-attention-control compact-attention"><input type="checkbox"/> <span> </span></label>\'),cm=M(\'<p class="attention-state"> </p>\'),hm=M(\'<li tabindex="-1"><header><div><span> </span> <strong> </strong></div> <span> </span></header> <code> </code> <!> <!> <!></li>\'),fm=M(\'<ol class="thread-list"></ol>\'),mm=M(\'<p class="empty-comments"> </p>\'),vm=M(\'<article class="focused-change" tabindex="-1"><button class="back-link" type="button"> </button> <header class="change-header"><div><p class="kicker"> </p> <h2> </h2></div> <div class="change-badges" aria-label="Change status"><span> </span> <span> </span> <span> </span></div></header> <section class="review-workspace" aria-labelledby="review-workspace-heading"><div class="review-workspace-heading"><div><p class="kicker">State / human-owned</p> <h3 id="review-workspace-heading"> </h3> <!></div> <div class="review-transfer-actions"><label><input type="checkbox"/> <span> </span></label> <button type="button"> </button> <button type="button"> </button> <input class="visually-hidden" type="file" accept="application/json,.json"/></div></div> <!> <!> <!></section> <section class="interpretation-section" aria-labelledby="interpretation-heading"><div class="section-heading"><div><p class="kicker">Interpretation / Agent</p> <h3 id="interpretation-heading"> </h3></div></div> <div class="explanation-grid"><section><h3> </h3> <p> </p> <p class="technical"> </p></section> <section><h3> </h3> <p> </p></section> <section><h3> </h3> <!></section> <section class="risk-block"><h3> </h3> <ul></ul></section> <section class="gap-block"><h3> </h3> <ul></ul></section> <section><h3> </h3> <ul></ul></section></div></section> <section class="visual-evidence-section" aria-labelledby="measured-evidence-heading"><div class="section-heading visual-heading"><div><p class="kicker"> </p> <h3 id="measured-evidence-heading"> </h3> <h4 id="visual-evidence-heading" tabindex="-1"> </h4> <p> </p></div></div> <!> <section class="finding-list" aria-labelledby="finding-heading"><div class="section-heading"><div><p class="kicker"> </p> <h4 id="finding-heading"> </h4></div></div> <!></section></section> <section class="evidence-section" aria-labelledby="evidence-heading"><div class="section-heading"><div><p class="kicker"> </p> <h3 id="evidence-heading"> </h3></div></div> <ul class="evidence-list"></ul> <!></section> <section class="diff-section" aria-labelledby="diff-heading"><div class="section-heading"><div><p class="kicker"> </p> <h3 id="diff-heading"> </h3></div> <div class="segmented-control" aria-label="Diff layout"><button type="button"> </button> <button type="button"> </button></div></div> <!></section> <section class="review-comments" aria-labelledby="review-comments-heading"><div class="section-heading"><div><p class="kicker"> </p> <h3 id="review-comments-heading"> </h3></div></div> <!> <!></section></article>\'),gm=M(\'<div class="hunk-actions"><label class="viewed-control dark-control"><input type="checkbox"/> <span> </span></label> <button type="button"> </button></div>\'),ym=M(\'<div><span class="line-number"> </span><span class="line-number"> </span><span class="line-sign"> </span><code> </code></div>\'),_m=M(\'<section class="focused-change unclassified-focus"><button class="back-link" type="button"> </button> <p class="kicker"> </p> <h2> </h2> <section class="hunk active-hunk" tabindex="-1"><header><h3> </h3> <!></header> <div class="diff-table"></div></section></section>\'),wm=M(\'<section class="focused-change empty-focus"><h2> </h2></section>\'),bm=M(\'<span class="unread-badge"> </span>\'),Pm=M("<li><strong> </strong> <code> </code> <span> </span></li>"),km=M(\'<p class="feedback-warning"> </p>\'),xm=M("<pre> </pre>"),Am=M(\'<section class="feedback-preview" aria-labelledby="feedback-preview-heading"><h2 id="feedback-preview-heading"> </h2> <ol></ol> <div class="feedback-preview-grid"><section><h3> </h3> <p> </p></section> <section><h3> </h3> <p> </p></section> <section><h3> </h3> <p> </p></section></div> <!> <div class="feedback-actions"><button type="button"> </button> <!></div> <!></section>\'),Im=M(\'<aside class="feedback-dock" aria-live="polite"><header><div><strong> </strong> <!></div> <!></header> <!></aside>\'),$m=M(\'<div class="report-shell"><header class="report-header"><a class="wordmark" href="#summary" aria-label="Utsuri review summary"><span aria-hidden="true">UT</span> <strong>Utsuri</strong></a> <div class="report-state"><span class="state-mark" aria-hidden="true"></span> <span> </span> <small> </small></div> <p class="report-id"> </p></header> <aside class="review-rail" aria-labelledby="queue-heading"><div class="rail-heading"><p class="kicker">Focus / 01</p> <h2 id="queue-heading" tabindex="-1"> </h2></div> <label class="queue-search"><span> </span> <input type="search" autocomplete="off"/></label> <nav><!> <!></nav></aside> <main id="main-content"><section aria-labelledby="summary-heading" class="decision-summary"><div class="brief-lead"><p class="kicker"> </p> <h1 id="summary-heading" tabindex="-1"> </h1> <!> <div class="evidence-posture"><p class="kicker"> </p> <p class="decision-statement"> </p></div></div> <aside class="review-route" aria-labelledby="review-route-heading"><p class="kicker">Next / 01</p> <h2 id="review-route-heading"> </h2> <!></aside> <dl class="metrics"><div><dt> </dt> <dd> </dd></div> <div><dt> </dt> <dd class="positive"> </dd></div> <div><dt> </dt> <dd class="negative"> </dd></div> <div><dt> </dt> <dd> </dd></div> <div><dt> </dt> <dd> </dd></div></dl> <!> <section class="coverage-overview" aria-labelledby="coverage-heading"><div><p class="kicker">Coverage / structured</p> <h2 id="coverage-heading"> </h2> <p> </p></div> <dl><div><dt> </dt> <dd> </dd></div> <div><dt> </dt> <dd> </dd></div> <div><dt> </dt> <dd> </dd></div></dl></section> <details class="file-inventory"><summary> </summary> <ul></ul></details></section> <!></main> <!></div>\'),qm=M(\'<p class="loading" aria-live="polite"> </p>\');function Rm(r,a){Ml(a,!1);const s=Y(),d=Y(),u=Y(),e=Y(),n={critical:0,high:1,medium:2,low:3,info:4},l={"action-required":0,"needs-confirmation":1,"no-issue":2},i={en:{queue:"Review queue",search:"Filter changes",action:"Action required",confirm:"Needs confirmation",clear:"No issue found",unclassified:"Unclassified hunks",summary:"Review brief",reviewMap:"Change map",reviewerRoute:"Reviewer route",evidencePosture:"Evidence posture",startReview:"Start with highest attention",files:"Files",additions:"Additions",deletions:"Deletions",changes:"Change groups",lowSignal:"Low-signal files",inventory:"File inventory",backQueue:"Back to review queue",what:"What changed",why:"Why",userImpact:"User impact",noImpact:"User impact is not established.",risk:"Risk",gaps:"Not verified",verified:"Verified",evidence:"Evidence",codeDiff:"Code diff",unified:"Unified",split:"Side by side",context:"Show {count} hidden context lines",moreEvidence:"More evidence",measured:"Measured evidence",interpretation:"Agent interpretation",hunkPurpose:"Purpose",hunkMeaning:"Meaning",visualEvidence:"Visual comparison",sideBySide:"Side by side",wipe:"Wipe",blink:"Blink",stopBlink:"Stop blink",pixelDiff:"Pixel diff",afterOnly:"After only",imageScope:"Image scope",zoom:"Zoom",wipePosition:"Wipe position",changedRegions:"Changed regions",noRegions:"No changed pixel regions",findings:"Findings",noFindings:"No linked findings",coverage:"Visual coverage",planned:"Planned targets",captured:"Captured targets",failed:"Failed targets",viewCode:"View linked code",viewVisual:"View visual evidence",reducedMotion:"Blink unavailable because reduced motion is enabled",backChange:"Back to focused change",visualGap:"Visual verification has not run",reviewWorkspace:"Human review",reviewProgress:"Review progress",viewed:"Viewed",humanJudgment:"Human judgment",unreviewed:"Unreviewed",reviewed:"Reviewed",followUp:"Follow-up",blocked:"Blocked",comments:"Comments",comment:"Comment",commentOn:"Comment on",commentBody:"Review note",saveComment:"Save comment",cancel:"Cancel",resolve:"Resolve",resolved:"Resolved",noComments:"No comments for this change",localOnly:"Saved locally. Plain comments are never sent to an Agent.",askAgent:"Ask the current Agent",askAgentHelp:"This only saves the selection. It does not submit or create a conversation.",selectedItems:"Items for Agent review",reviewItems:"Review items",feedbackPreview:"Feedback Batch preview",shared:"Shared",notShared:"Not shared",delivery:"Delivery",returnConversation:"Return to current conversation",prepareRequest:"Prepare review request",copyHandoff:"Copy handoff",handoffCopied:"Handoff copied",unreadAnswers:"Unread answers",exportReview:"Export review",importReview:"Import review",reviewBundleFile:"Review bundle file",reanchorImport:"Re-anchor another report",stale:"Stale",orphaned:"Orphaned",reviewUnavailable:"Review state unavailable",empty:"No semantic changes",dataUnavailable:"Review data unavailable",intentUnknown:"Intent unknown",loading:"Loading review data…"},ja:{queue:"レビューキュー",search:"変更を絞り込む",action:"対応が必要",confirm:"確認が必要",clear:"問題なし",unclassified:"未分類のハンク",summary:"レビュー要旨",reviewMap:"変更の全体像",reviewerRoute:"レビュー経路",evidencePosture:"根拠の状態",startReview:"要確認から見る",files:"ファイル",additions:"追加",deletions:"削除",changes:"変更グループ",lowSignal:"低シグナル",inventory:"ファイル一覧",backQueue:"レビューキューへ戻る",what:"変更内容",why:"変更理由",userImpact:"ユーザー影響",noImpact:"ユーザー影響は未確定です。",risk:"リスク",gaps:"未検証",verified:"検証済み",evidence:"根拠",codeDiff:"コード差分",unified:"統合表示",split:"左右表示",context:"非表示のコンテキスト {count} 行を表示",moreEvidence:"その他の根拠",measured:"計測された根拠",interpretation:"Agent の解釈",hunkPurpose:"目的",hunkMeaning:"この差分の意味",visualEvidence:"画面比較",sideBySide:"左右比較",wipe:"ワイプ",blink:"点滅比較",stopBlink:"点滅を停止",pixelDiff:"ピクセル差分",afterOnly:"変更後のみ",imageScope:"画像の範囲",zoom:"拡大率",wipePosition:"ワイプ位置",changedRegions:"変更領域",noRegions:"変更ピクセル領域はありません",findings:"検出事項",noFindings:"関連する検出事項はありません",coverage:"画面カバレッジ",planned:"予定 target",captured:"取得済み target",failed:"失敗 target",viewCode:"関連コードを見る",viewVisual:"画面根拠を見る",reducedMotion:"視差低減が有効なため点滅比較は利用できません",backChange:"変更グループへ戻る",visualGap:"画面の検証は未実施です",reviewWorkspace:"人によるレビュー",reviewProgress:"レビュー進捗",viewed:"確認済み",humanJudgment:"人の判断",unreviewed:"未レビュー",reviewed:"レビュー済み",followUp:"要フォロー",blocked:"ブロック中",comments:"コメント",comment:"コメント",commentOn:"コメント対象",commentBody:"レビューメモ",saveComment:"コメントを保存",cancel:"キャンセル",resolve:"解決済みにする",resolved:"解決済み",noComments:"この変更へのコメントはありません",localOnly:"ローカルに保存します。通常コメントを Agent へ送信することはありません。",askAgent:"現在の Agent に確認を依頼",askAgentHelp:"選択状態だけを保存します。送信や新しい会話の作成は行いません。",selectedItems:"Agent 確認対象",reviewItems:"確認項目をレビュー",feedbackPreview:"Feedback Batch プレビュー",shared:"共有する情報",notShared:"共有しない情報",delivery:"受け渡し",returnConversation:"現在の会話へ戻す",prepareRequest:"レビュー依頼を準備",copyHandoff:"引き継ぎ文をコピー",handoffCopied:"引き継ぎ文をコピーしました",unreadAnswers:"未読回答",exportReview:"レビューを書き出す",importReview:"レビューを読み込む",reviewBundleFile:"レビューバンドルファイル",reanchorImport:"別レポートへ再アンカーする",stale:"古い状態",orphaned:"参照先なし",reviewUnavailable:"レビュー状態を利用できません",empty:"意味単位の変更はありません",dataUnavailable:"レビューデータを利用できません",intentUnknown:"変更意図は不明です",loading:"レビューデータを読み込んでいます…"}};let o=Y(null),h=Y(""),c=Y("en"),f=Y(""),w=Y(""),q=Y(""),H="",R=Y("unified"),W=Y("side-by-side"),re=Y(""),ae=Y(""),oe=Y(0),me=Y(0),ve=Y(100),ge=Y(50),_e=Y(!1),Ot=Y(!1),Fe=Y(),U=Y(),le=Y(),ke=!1,we=new Set,L=Y(),br=Y([]),At=Y([]),It=Y([]),Er=Y([]),Wt=Y([]),_t=Y([]),qe=Y(),j=Y(),cr=Y([]),hr=Y(),T=Y(null),Da={base:null,head:null},xa=Y(""),wt=Y(""),Aa=Y(!1),ee=Y(!1),Tt=Y(null),Nr=Y(""),ua=Y("note"),g=Y(!1),b=Y(),k=Y(),K=Y([]),te=Y(""),et=Y([]),D=Y(null),pa=Y(""),Ei="",Ia=Y(!1),Pn=null;function Ue(m,x){return`${m}-${x.replace(/[^a-zA-Z0-9_-]/gu,"-")}`}function us(m){const x=m.region;return x?`left:${(x.x+x.width/2)*100}%;top:${(x.y+x.height/2)*100}%`:"display:none"}function Yr(m){return m.risk.level==="critical"||m.risk.level==="high"?"action-required":m.risk.level==="medium"||m.verification.gaps.length>0||m.intent.source==="unknown"?"needs-confirmation":"no-issue"}function Ni(m){return n[m.risk.level]*3+l[Yr(m)]}function Od(m){return t(o)?new Set(m.hunkRefs.map(x=>t(o)?.hunks.find(N=>N.id===x)?.path).filter(x=>x!==void 0)).size:0}function Td(m,x){return/^ja(?:-|$)/iu.test(x)?`${m}ファイル`:`${m} file${m===1?"":"s"}`}function zd(m,x){return/^ja(?:-|$)/iu.test(x)?`ほか${m}件の対応`:`${m} more change group${m===1?"":"s"}`}function Md(m,x){return m==="reviewed"?x.reviewed:m==="follow-up"?x.followUp:m==="blocked"?x.blocked:m==="stale"?x.stale:x.unreviewed}function kn(m,x){return m?.state.judgments[x]?.state??"unreviewed"}function ca(m,x){return t(T)?yl(t(T).anchorCatalog,m,x):void 0}function ps(m,x,N){const B=m?yl(m.anchorCatalog,x,N):void 0;return!B||!m?!1:m.state.viewed[Wr(B)]?.state==="viewed"}function Ci(m,x){const N=m.lines[x];if(!N||N.kind==="no-newline")return;const B=N.kind==="addition"?"after":N.kind==="deletion"?"before":"diff",F=B==="before"?N.oldLine:N.newLine??N.oldLine;return F?ca("line-range",`${m.id}:${B}:${F}:${x}`):void 0}function Vd(m,x){return m.type==="change"?m.ref===x.id:m.type==="hunk"||m.type==="line-range"?x.hunkRefs.some(N=>m.ref===N||m.ref.startsWith(`${N}:`)):m.type==="visual-target"||m.type==="visual-region"?!!(m.targetRef&&x.targetRefs.includes(m.targetRef))||x.targetRefs.includes(m.ref):m.type==="finding"?x.findingRefs.includes(m.ref):m.type==="verification-gap"?m.ref.startsWith(`${x.id}:gap:`):!1}function Dd(){const x=new URLSearchParams(location.hash.startsWith("#")?location.hash.slice(1):"").get("token")??"";if(x){if(!/^[A-Za-z0-9_-]{32,128}$/u.test(x)){A(xa,"Interactive capability token is invalid"),history.replaceState(null,"",`${location.pathname}${location.search}`);return}A(te,x),history.replaceState(null,"",`${location.pathname}${location.search}`)}}async function cs(m,x={}){if(!t(te)||!t(o))throw new Error("Interactive review capability is unavailable");const N=await fetch(`./api/v1/${m}`,{...x,credentials:"omit",headers:{authorization:`Bearer ${t(te)}`,"x-utsuri-report-id":t(o).reportId,...x.body?{"content-type":"application/json"}:{},...x.headers??{}}}),B=await N.json();if(!N.ok)throw new Error(B?.error?.message??`HTTP ${N.status}`);return B}function xn(m){t(T)&&(A(T,{...t(T),state:structuredClone(m.state),threads:structuredClone(m.threads),events:t(T).events}),A(et,structuredClone(m.inbox?.entries??t(et))))}async function Li(){const m=await cs("review-state");xn(m)}async function hs(m){if(!t(T)||!t(o))return;const x=await cs("review-events",{method:"POST",body:JSON.stringify({schemaVersion:"1.0",reportId:t(o).reportId,expectedRevision:t(T).state.revision,action:m})});xn(x)}async function Fd(){if(!t(te)||!t(o))return;Pn?.abort();const m=new AbortController;Pn=m;try{const x=await fetch("./api/v1/events",{credentials:"omit",headers:{authorization:`Bearer ${t(te)}`,"x-utsuri-report-id":t(o).reportId},signal:m.signal});if(!x.ok||!x.body)return;const N=x.body.getReader(),B=new TextDecoder;let F="";for(;!m.signal.aborted;){const{value:Te,done:Dr}=await N.read();if(Dr)break;F+=B.decode(Te,{stream:!0});const Hs=F.split(`\n\n`);F=Hs.pop()??"",Hs.some(Ws=>Ws.startsWith("data:")&&!Ws.includes(\'"type":"ready"\'))&&await Li()}}catch(x){m.signal.aborted||A(wt,x instanceof Error?x.message:String(x))}}Eh(()=>Pn?.abort());async function Fa(m){await uf(m,m.state.revision-1),A(T,m),A(wt,"")}async function fs(m,x,N){const B=ca(m,x);if(!(!t(T)||!B)){A(ee,!0);try{t(te)?await hs({type:"viewed.changed",anchor:{type:B.type,ref:B.ref,fingerprint:B.fingerprint},viewState:N?"viewed":"unseen"}):await Fa(await pf(t(T),B,N?"viewed":"unseen"))}catch(F){A(wt,F instanceof Error?F.message:String(F))}finally{A(ee,!1)}}}async function Bd(m,x){if(!(!t(T)||x==="stale")){A(ee,!0);try{t(te)?await hs({type:"judgment.changed",changeId:m,judgmentState:x}):await Fa(await cf(t(T),m,x))}catch(N){A(wt,N instanceof Error?N.message:String(N))}finally{A(ee,!1)}}}async function ha(m){!m||t(ee)||(A(Tt,m),A(Nr,""),A(g,!1),await ln(),t(b)?.focus())}async function Hd(){if(!(!t(T)||!t(Tt))){A(ee,!0);try{t(te)?await hs({type:"thread.created",anchor:{type:t(Tt).type,ref:t(Tt).ref,fingerprint:t(Tt).fingerprint},body:t(Nr),kind:t(ua),requestAgentAttention:t(g)}):await Fa(await hf(t(T),t(Tt),t(Nr),t(ua),new Date().toISOString(),t(g))),A(Tt,null),A(Nr,""),A(g,!1)}catch(m){A(wt,m instanceof Error?m.message:String(m))}finally{A(ee,!1)}}}async function Wd(m){if(t(T)){A(ee,!0);try{t(te)?await hs({type:"thread.resolved",threadId:m}):await Fa(await mf(t(T),m))}catch(x){A(wt,x instanceof Error?x.message:String(x))}finally{A(ee,!1)}}}async function Zd(m,x){if(t(T)){A(ee,!0);try{t(te)?await hs({type:"agent-attention.changed",threadId:m,requested:x}):await Fa(await ff(t(T),m,x)),A(D,null),A(pa,"")}catch(N){A(wt,N instanceof Error?N.message:String(N))}finally{A(ee,!1)}}}async function Ud(){if(!(!t(T)||!t(o))){A(ee,!0);try{const m=t(te)?await cs("review/export",{method:"POST",body:JSON.stringify({schemaVersion:"1.0",reportId:t(o).reportId,expectedRevision:t(T).state.revision})}):gf(t(T),Da);ji(`${t(o)?.reportId??"utsuri"}-review.json`,m)}catch(m){A(wt,m instanceof Error?m.message:String(m))}finally{A(ee,!1)}}}function ji(m,x){const N=new Blob([`${JSON.stringify(x,null,2)}\n`],{type:"application/json"}),B=URL.createObjectURL(N),F=document.createElement("a");F.href=B,F.download=m,F.click(),URL.revokeObjectURL(B)}function Kd(m){return`Process the pending Utsuri review items.\nReport: ${m.reportId}\nBatch: ${m.id}`}async function Jd(){if(!(!t(T)||!t(o))){A(Ia,!0);try{if(t(te)){const m=await cs("feedback-batches/preview",{method:"POST",body:JSON.stringify({schemaVersion:"1.0",reportId:t(o).reportId,expectedRevision:t(T).state.revision,deliveryMode:"return-to-session"})});A(D,m.preview)}else A(D,await kf(t(T)));Ei=`ui:${t(D).batch.id}`,A(pa,"")}catch(m){A(wt,m instanceof Error?m.message:String(m))}finally{A(Ia,!1)}}}async function Yd(){if(!(!t(D)||!t(T)||!t(o))){A(Ia,!0);try{if(t(te)){const m=await cs("feedback-batches",{method:"POST",body:JSON.stringify({schemaVersion:"1.0",reportId:t(o).reportId,expectedRevision:t(T).state.revision,idempotencyKey:Ei,deliveryMode:"return-to-session"})});A(D,m.preview),xn(m)}else ji(`${t(o).reportId}-${t(D).batch.id.replace(":","-")}.json`,{schemaVersion:"1.0",batch:t(D).batch,contexts:t(D).contexts,preview:{shared:t(D).shared,excluded:t(D).excluded,redactionCount:t(D).redactionCount,contextBytes:t(D).contextBytes,destination:t(D).destination}});A(pa,Kd(t(D).batch))}catch(m){A(wt,m instanceof Error?m.message:String(m))}finally{A(Ia,!1)}}}async function Gd(){if(t(pa))try{await navigator.clipboard.writeText(t(pa)),A(wt,t(s).handoffCopied)}catch(m){A(wt,m instanceof Error?m.message:String(m))}}async function Qd(m){if(!(!t(T)||!m)){if(t(te)){A(wt,"Import is available only in static report mode"),ol(k,t(k).value="");return}A(ee,!0);try{if(m.size>16*1024*1024)throw new Error("Review bundle exceeds 16 MiB");const x=await yf(t(T),JSON.parse(await m.text()),{reanchor:t(Aa)});await Fa(x.store);const N=x.reanchored.reduce((B,F)=>(B[F.disposition]+=1,B),{matched:0,stale:0,orphaned:0});A(wt,`${N.matched} matched · ${N.stale} stale · ${N.orphaned} orphaned · ${x.conflicts.length} conflicts`)}catch(x){A(wt,x instanceof Error?x.message:String(x))}finally{ol(k,t(k).value=""),A(ee,!1)}}}function Fs(m,x){return m==="action-required"?x.action:m==="needs-confirmation"?x.confirm:x.clear}function Xd(m){return t(Er).filter(x=>Yr(x)===m).length}function An(m,x){history.pushState(null,"",`#${m}=${encodeURIComponent(x)}`)}async function Qt(m){await ln(),document.getElementById(m)?.focus({preventScroll:!1})}function Bs(m,x=!0){x&&(H=Ue("queue",m.id)),A(w,m.id),A(q,""),A(re,""),A(ae,""),A(oe,0),A(me,0),A(_e,!1),An("change",m.id),Qt(Ue("change",m.id))}function Oi(){A(w,""),A(q,""),history.pushState(null,"","#summary"),Qt("summary-heading")}function In(m){A(q,m),An("hunk",m),Qt(Ue("hunk",m))}function Ti(){A(q,""),Qt("visual-evidence-heading")}function Vr(m){if(m==="blink"&&t(Ot)){A(W,"side-by-side"),A(_e,!1);return}A(W,m),A(_e,m==="blink"&&!t(Ot))}function eu(m){A(re,m),A(ae,""),A(oe,0)}function tu(m){A(ae,m),A(oe,0)}async function ru(m){A(oe,m),await ln(),document.getElementById(`visual-region-${m}`)?.scrollIntoView({block:"center",inline:"center",behavior:"smooth"})}function zi(m,x){if(ke||!m||!x)return;ke=!0;const N=m.scrollHeight-m.clientHeight,B=m.scrollWidth-m.clientWidth,F=x.scrollHeight-x.clientHeight,Te=x.scrollWidth-x.clientWidth;x.scrollTop=N>0?m.scrollTop/N*F:0,x.scrollLeft=B>0?m.scrollLeft/B*Te:0,requestAnimationFrame(()=>ke=!1)}function $n(m,x){const N=m.coverage.knownUsages;if(x==="ja"){const F=N===null?`${m.coverage.verifiedUsages}件を検証済み、既知の利用件数は不明`:`既知の利用箇所${N}件中${m.coverage.verifiedUsages}件を検証済み`;return m.coverage.unknownPossible?`${F}。ほかの利用箇所が存在する可能性があります`:F}const B=N===null?`${m.coverage.verifiedUsages} verified; known usage count unavailable`:`${m.coverage.verifiedUsages} of ${N} known usages verified`;return m.coverage.unknownPossible?`${B}; additional usage may exist`:B}function Mi(m){const x=m.target;if(!(x?.isContentEditable||new Set(["INPUT","TEXTAREA","SELECT"]).has(x?.tagName??"")||m.metaKey||m.ctrlKey||m.altKey)){if(m.key==="b"){m.preventDefault(),Oi();return}if(m.key==="/"){m.preventDefault(),t(Fe)?.focus();return}if(m.key==="1")Vr("side-by-side");else if(m.key==="2")Vr("wipe");else if(m.key==="3")Vr("pixel-diff");else if(m.key==="4")Vr("blink");else if(m.key==="5")Vr("after-only");else if((m.key==="j"||m.key==="k")&&t(It).length){const N=t(It).findIndex(Te=>Te.id===t(w)),B=m.key==="j"?1:-1,F=N===-1?m.key==="j"?0:t(It).length-1:(N+B+t(It).length)%t(It).length;Bs(t(It)[F])}else if((m.key==="n"||m.key==="p")&&t(cr).length){const N=m.key==="n"?1:-1;A(me,(t(me)+N+t(cr).length)%t(cr).length),Qt(Ue("finding",t(cr)[t(me)].id))}else m.key==="e"&&Ti()}}function au(m){H=Ue("queue-hunk",m),A(w,""),In(m)}function Vi(){A(q,""),history.pushState(null,"","#queue"),Qt(H||"queue-heading")}function su(){A(q,""),t(L)&&(An("change",t(L).id),Qt(Ue("change",t(L).id)))}function qn(){if(!t(o))return;const m=location.hash.match(/^#(change|hunk)=(.+)$/u);if(!m){A(w,""),A(q,"");return}let x="";try{x=decodeURIComponent(m[2]??"")}catch{A(w,""),A(q,"");return}if(m[1]==="change"&&t(o).changes.some(N=>N.id===x)){A(w,x),A(q,""),Qt(Ue("change",x));return}m[1]==="hunk"&&t(o).hunks.some(N=>N.id===x)&&(A(w,t(o).changes.find(N=>N.hunkRefs.includes(x))?.id??""),A(q,x),Qt(Ue("hunk",x)))}async function nu(){try{Dd();const m=document.querySelector("[data-utsuri-report]"),x=document.querySelector("[data-utsuri-manifest]");let N=null,B;if(m?.textContent)B=JSON.parse(m.textContent),N=x?.textContent?JSON.parse(x.textContent):null;else{const[F,Te]=await Promise.all([fetch("./report.json",{credentials:"omit"}),fetch("./manifest.json",{credentials:"omit"})]);if(!F.ok)throw new Error(`HTTP ${F.status}`);B=await F.json(),N=Te.ok?await Te.json():null}A(o,B),document.querySelector("[data-static-fallback]")?.remove(),A(c,/^ja(?:-|$)/iu.test(t(o).language)?"ja":"en"),document.documentElement.lang=t(o).language,N&&(Da={base:N.source?.base??null,head:N.source?.head??null});try{t(te)?(A(T,await jd(t(o),new Date().toISOString())),await Li(),Fd()):A(T,await df(t(o)))}catch(F){A(xa,F instanceof Error?F.message:String(F))}qn()}catch(m){A(h,`${t(s).dataUnavailable}: ${m instanceof Error?m.message:String(m)}`)}}function Di(m){if(we.has(m.id))return m.lines.map((B,F)=>({kind:"line",line:B,index:F}));const x=m.lines.map(()=>!1);m.lines.forEach((B,F)=>{if(B.kind==="addition"||B.kind==="deletion")for(let Te=Math.max(0,F-3);Te<=Math.min(m.lines.length-1,F+3);Te+=1)x[Te]=!0}),x.some(Boolean)||x.fill(!0);const N=[];for(let B=0;B<m.lines.length;)if(x[B])N.push({kind:"line",line:m.lines[B],index:B}),B+=1;else{let F=B+1;for(;F<m.lines.length&&!x[F];)F+=1;N.push({kind:"fold",count:F-B}),B=F}return N}function Fi(m){we=new Set([...we,m])}function iu(m,x){const N=m.lines[x];if(!N||N.kind!=="addition"&&N.kind!=="deletion")return;const B=N.kind==="addition"?"deletion":"addition";for(let F=1;F<=6;F+=1)for(const Te of[x-F,x+F]){const Dr=m.lines[Te];if(Dr?.kind===B)return Dr;if(Dr&&Dr.kind==="context")break}}function Rn(m,x){const N=m.lines[x],B=iu(m,x);if(!B)return[{text:N.content,changed:N.kind==="addition"||N.kind==="deletion"}];let F=0;for(;F<N.content.length&&N.content[F]===B.content[F];)F+=1;let Te=0;for(;Te<N.content.length-F&&Te<B.content.length-F&&N.content[N.content.length-Te-1]===B.content[B.content.length-Te-1];)Te+=1;return[{text:N.content.slice(0,F),changed:!1},{text:N.content.slice(F,Te?-Te:void 0),changed:!0},{text:Te?N.content.slice(-Te):"",changed:!1}].filter(Dr=>Dr.text.length>0)}yd(()=>(A(c,navigator.language.toLowerCase().startsWith("ja")?"ja":"en"),nu(),A(Ot,window.matchMedia("(prefers-reduced-motion: reduce)").matches),window.addEventListener("hashchange",qn),window.addEventListener("keydown",Mi),()=>{window.removeEventListener("hashchange",qn),window.removeEventListener("keydown",Mi)})),Kt(()=>t(c),()=>{A(s,i[t(c)])}),Kt(()=>(t(o),t(w)),()=>{A(L,t(o)?.changes.find(m=>m.id===t(w)))}),Kt(()=>(t(L),t(o)),()=>{A(br,t(L)?t(L).hunkRefs.map(m=>t(o)?.hunks.find(x=>x.id===m)).filter(m=>m!==void 0):[])}),Kt(()=>(t(L),t(o)),()=>{A(At,t(L)&&t(o)?t(o).evidence.filter(m=>t(L)?.intent.evidenceRefs.includes(m.id)||m.hunkRefs.some(x=>t(L)?.hunkRefs.includes(x))):[])}),Kt(()=>t(o),()=>{A(It,t(o)?[...t(o).changes].sort((m,x)=>Ni(m)-Ni(x)):[])}),Kt(()=>(t(It),t(f)),()=>{A(Er,t(It).filter(m=>`${m.title} ${m.summary}`.toLocaleLowerCase().includes(t(f).toLocaleLowerCase())))}),Kt(()=>t(It),()=>{A(Wt,t(It).slice(0,5))}),Kt(()=>t(Wt),()=>{A(hr,t(Wt)[0])}),Kt(()=>(t(L),t(o)),()=>{A(_t,t(L)&&t(o)?t(o).comparisons.filter(m=>t(L)?.targetRefs.includes(m.targetRef)):[])}),Kt(()=>(t(_t),t(re)),()=>{A(qe,t(_t).find(m=>m.id===t(re))??t(_t)[0])}),Kt(()=>(t(qe),t(ae)),()=>{A(j,t(qe)?.images.find(m=>m.id===t(ae))??t(qe)?.images[0])}),Kt(()=>(t(L),t(o)),()=>{A(cr,t(L)&&t(o)?t(o).findings.filter(m=>t(L)?.findingRefs.includes(m.id)||(m.targetRef?t(L)?.targetRefs.includes(m.targetRef):!1)):[])}),Kt(()=>(t(L),t(T)),()=>{A(K,t(L)&&t(T)?t(T).threads.filter(m=>Vd(m.anchor,t(L))):[])}),Kt(()=>(t(K),t(qe),t(j)),()=>{A(d,t(K).filter(m=>m.state!=="resolved"&&m.anchor.type==="visual-region"&&!!m.anchor.region&&!!(t(qe)&&t(j))&&m.anchor.ref.startsWith(`${t(qe).id}:${t(j).id}:`)))}),Kt(()=>t(T),()=>{A(u,t(T)?.threads.filter(m=>m.agentAttention.state==="requested").length??0)}),Kt(()=>t(et),()=>{A(e,t(et).reduce((m,x)=>m+x.unreadAnswerItemIds.length,0))}),uh(),Wh();var Bi=_s(),ou=jr(Bi);{var lu=m=>{var x=$m(),N=P(x),B=P(N),F=v(B,2),Te=v(P(F),2),Dr=_(Te,!0),Hs=v(Te,2),Ws=_(Hs,!0),uu=v(F,2),pu=_(uu,!0),Hi=v(N,2),Wi=P(Hi),cu=v(P(Wi),2),hu=_(cu,!0),Zi=v(Wi,2),Ui=P(Zi),fu=_(Ui,!0),Ki=v(Ui,2);bs(Ki,Q=>A(Fe,Q),()=>t(Fe));var Ji=v(Zi,2),Yi=P(Ji);ye(Yi,0,()=>["action-required","needs-confirmation","no-issue"],Q=>Q,(Q,z)=>{var pe=Af(),tt=P(pe),bt=P(tt),ot=_(bt,!0),$t=v(bt,2),qt=_($t,!0),Pt=v(tt,2);ye(Pt,7,()=>(t(Er),p(()=>t(Er).filter(Ne=>Yr(Ne)===z))),Ne=>Ne.id,(Ne,xe,ze)=>{var ce=xf(),ne=P(ce),Ye=P(ne),rt=_(Ye,!0),Rt=v(Ye,2),St=P(Rt),Xt=_(St,!0),er=v(St,2),dt=P(er),Ce=_(dt,!0),Jt=v(dt,2);{var zt=ut=>{var kt=rn(),Ge=_(kt);S(()=>y(Ge,`${t(xe),p(()=>t(xe).verification.gaps.length)??""} gaps`)),$(ut,kt)};J(Jt,ut=>{t(xe),p(()=>t(xe).verification.gaps.length>0)&&ut(zt)})}S((ut,kt,Ge)=>{V(ne,"id",ut),V(ne,"href",kt),V(ne,"aria-current",(t(w),t(xe),p(()=>t(w)===t(xe).id?"page":void 0))),y(rt,Ge),y(Xt,(t(xe),p(()=>t(xe).title))),y(Ce,(t(xe),p(()=>t(xe).risk.level)))},[()=>(t(xe),p(()=>Ue("queue",t(xe).id))),()=>(t(xe),p(()=>`#change=${encodeURIComponent(t(xe).id)}`)),()=>(Ze(t(ze)),p(()=>String(t(ze)+1).padStart(2,"0")))]),G("click",ne,ut=>{ut.preventDefault(),Bs(t(xe))}),$(Ne,ce)}),S((Ne,xe)=>{V(pe,"data-queue",z),y(ot,Ne),y(qt,xe)},[()=>(t(s),p(()=>Fs(z,t(s)))),()=>p(()=>Xd(z))]),$(Q,pe)});var mu=v(Yi,2);{var vu=Q=>{var z=$f(),pe=P(z),tt=P(pe),bt=_(tt,!0),ot=v(tt),$t=_(ot,!0),qt=v(pe,2);ye(qt,7,()=>(t(o),p(()=>t(o).unclassifiedHunkRefs)),Pt=>Pt,(Pt,Ne,xe)=>{const ze=ya(()=>(t(o),t(Ne),p(()=>t(o).hunks.find(rt=>rt.id===t(Ne)))));var ce=_s(),ne=jr(ce);{var Ye=rt=>{var Rt=If(),St=P(Rt),Xt=P(St),er=_(Xt),dt=v(Xt,2),Ce=P(dt),Jt=_(Ce,!0),zt=v(Ce),ut=_(zt);S((kt,Ge)=>{V(St,"id",kt),V(St,"href",Ge),y(er,`U${t(xe)+1}`),y(Jt,(Ze(t(ze)),p(()=>t(ze).path))),y(ut,`@@ ${Ze(t(ze)),p(()=>t(ze).oldStart)??""} → ${Ze(t(ze)),p(()=>t(ze).newStart)??""}`)},[()=>(t(Ne),p(()=>Ue("queue-hunk",t(Ne)))),()=>(t(Ne),p(()=>`#hunk=${encodeURIComponent(t(Ne))}`))]),G("click",St,kt=>{kt.preventDefault(),au(t(Ne))}),$(rt,Rt)};J(ne,rt=>{t(ze)&&rt(Ye)})}$(Pt,ce)}),S(()=>{y(bt,(t(s),p(()=>t(s).unclassified))),y($t,(t(o),p(()=>t(o).unclassifiedHunkRefs.length)))}),$(Q,z)};J(mu,Q=>{t(o),p(()=>t(o).unclassifiedHunkRefs.length>0)&&Q(vu)})}var Gi=v(Hi,2),Qi=P(Gi),Xi=P(Qi),eo=P(Xi),gu=_(eo),to=v(eo,2),yu=_(to,!0),ro=v(to,2);{var _u=Q=>{var z=qf(),pe=_(z,!0);S(()=>y(pe,(t(o),p(()=>t(o).summary.overview)))),$(Q,z)};J(ro,Q=>{t(o),p(()=>t(o).summary.overview)&&Q(_u)})}var ao=v(ro,2),so=P(ao),wu=_(so,!0),bu=v(so,2),Pu=_(bu,!0),no=v(Xi,2),io=v(P(no),2),ku=_(io,!0),xu=v(io,2);{var Au=Q=>{var z=Rf(),pe=jr(z),tt=_(pe,!0),bt=v(pe,2),ot=_(bt,!0),$t=v(bt,2),qt=_($t,!0),Pt=v($t,2),Ne=P(Pt);S((xe,ze)=>{V(pe,"data-queue",xe),y(tt,ze),y(ot,(t(hr),p(()=>t(hr).title))),y(qt,(t(hr),p(()=>t(hr).summary))),y(Ne,`${t(s),p(()=>t(s).startReview)??""} `)},[()=>(t(hr),p(()=>Yr(t(hr)))),()=>(t(hr),t(s),p(()=>Fs(Yr(t(hr)),t(s))))]),G("click",Pt,()=>Bs(t(hr),!1)),$(Q,z)},Iu=Q=>{var z=Sa(),pe=_(z,!0);S(()=>y(pe,(t(s),p(()=>t(s).empty)))),$(Q,z)};J(xu,Q=>{t(hr)?Q(Au):Q(Iu,-1)})}var oo=v(no,2),lo=P(oo),uo=P(lo),$u=_(uo,!0),qu=v(uo,2),Ru=_(qu,!0),po=v(lo,2),co=P(po),Su=_(co,!0),Eu=v(co,2),Nu=_(Eu),ho=v(po,2),fo=P(ho),Cu=_(fo,!0),Lu=v(fo,2),ju=_(Lu),mo=v(ho,2),vo=P(mo),Ou=_(vo,!0),Tu=v(vo,2),zu=_(Tu,!0),Mu=v(mo,2),go=P(Mu),Vu=_(go,!0),Du=v(go,2),Fu=_(Du,!0),yo=v(oo,2);{var Bu=Q=>{var z=Nf(),pe=P(z),tt=P(pe),bt=v(P(tt),2),ot=_(bt,!0),$t=v(tt,2),qt=_($t),Pt=v(pe,2),Ne=P(Pt);ye(Ne,3,()=>t(Wt),ce=>ce.id,(ce,ne,Ye)=>{var rt=Sf(),Rt=P(rt),St=P(Rt),Xt=_(St,!0),er=v(St,2),dt=P(er),Ce=_(dt,!0),Jt=v(dt,2),zt=_(Jt,!0),ut=v(er,2),kt=P(ut),Ge=v(kt,2);S((Mt,tr,Fr,Cr)=>{V(rt,"data-queue",Mt),y(Xt,tr),y(Ce,(t(ne),p(()=>t(ne).title))),y(zt,(t(ne),p(()=>t(ne).summary))),y(kt,`${Fr??""} `),y(Ge,` ${Cr??""}`)},[()=>(t(ne),p(()=>Yr(t(ne)))),()=>(Ze(t(Ye)),p(()=>String(t(Ye)+1).padStart(2,"0"))),()=>(t(ne),t(s),p(()=>Fs(Yr(t(ne)),t(s)))),()=>(t(ne),t(o),p(()=>Td(Od(t(ne)),t(o).language)))]),G("click",Rt,()=>Bs(t(ne),!1)),$(ce,rt)});var xe=v(Ne,2);{var ze=ce=>{var ne=Ef(),Ye=_(ne,!0);S(rt=>y(Ye,rt),[()=>(t(o),t(Wt),p(()=>zd(t(o).changes.length-t(Wt).length,t(o).language)))]),$(ce,ne)};J(xe,ce=>{t(o),t(Wt),p(()=>t(o).changes.length>t(Wt).length)&&ce(ze)})}S(ce=>{y(ot,(t(s),p(()=>t(s).reviewMap))),y(qt,`${t(o),p(()=>t(o).changes.length)??""} ${ce??""}`)},[()=>(t(s),p(()=>t(s).changes.toLocaleLowerCase()))]),$(Q,z)};J(yo,Q=>{t(Wt),p(()=>t(Wt).length>0)&&Q(Bu)})}var _o=v(yo,2),wo=P(_o),bo=v(P(wo),2),Hu=_(bo,!0),Wu=v(bo,2),Zu=_(Wu,!0),Uu=v(wo,2),Po=P(Uu),ko=P(Po),Ku=_(ko,!0),Ju=v(ko,2),Yu=_(Ju,!0),xo=v(Po,2),Ao=P(xo),Gu=_(Ao,!0),Qu=v(Ao,2),Xu=_(Qu,!0),ep=v(xo,2),Io=P(ep),tp=_(Io,!0),rp=v(Io,2),ap=_(rp,!0),sp=v(_o,2),$o=P(sp),np=_($o,!0),ip=v($o,2);ye(ip,5,()=>(t(o),p(()=>t(o).files)),Q=>Q.id,(Q,z)=>{var pe=Lf(),tt=P(pe),bt=_(tt,!0),ot=v(tt,2),$t=_(ot,!0),qt=v(ot,2),Pt=_(qt,!0),Ne=v(qt,2);{var xe=ze=>{var ce=Cf(),ne=P(ce),Ye=v(ne,2),rt=_(Ye,!0);S(Rt=>{Ua(ne,Rt),ne.disabled=t(ee),y(rt,(t(s),p(()=>t(s).viewed)))},[()=>(t(T),t(z),p(()=>ps(t(T),"file",t(z).id)))]),G("change",ne,Rt=>{fs("file",t(z).id,Rt.currentTarget.checked)}),$(ze,ce)};J(Ne,ze=>{t(T)&&ze(xe)})}S(()=>{y(bt,(t(z),p(()=>t(z).status))),y($t,(t(z),p(()=>t(z).oldPath&&t(z).newPath&&t(z).oldPath!==t(z).newPath?`${t(z).oldPath} → ${t(z).newPath}`:t(z).newPath??t(z).oldPath))),y(Pt,(t(z),p(()=>t(z).binary?"binary":`+${t(z).additions??0} / −${t(z).deletions??0}`)))}),$(Q,pe)});var op=v(Qi,2);{var lp=Q=>{var z=vm(),pe=P(z),tt=_(pe),bt=v(pe,2),ot=P(bt),$t=P(ot),qt=_($t),Pt=v($t,2),Ne=_(Pt,!0),xe=v(ot,2),ze=P(xe),ce=_(ze,!0),ne=v(ze,2),Ye=_(ne),rt=v(ne,2),Rt=_(rt,!0),St=v(bt,2),Xt=P(St),er=P(Xt),dt=v(P(er),2),Ce=_(dt,!0),Jt=v(dt,2);{var zt=O=>{var I=Sa(),Z=_(I);S((C,Re,Se)=>y(Z,`${t(s),p(()=>t(s).reviewProgress)??""}: ${C??""}\n ${Re??""} ·\n ${t(T),p(()=>t(T).threads.length)??""}\n ${Se??""}`),[()=>(t(T),p(()=>Object.values(t(T).state.viewed).filter(C=>C.state==="viewed").length)),()=>(t(s),p(()=>t(s).viewed.toLocaleLowerCase())),()=>(t(s),p(()=>t(s).comments.toLocaleLowerCase()))]),$(O,I)},ut=O=>{var I=Sa(),Z=_(I,!0);S(()=>y(Z,(t(s),p(()=>t(s).reviewUnavailable)))),$(O,I)};J(Jt,O=>{t(T)?O(zt):O(ut,-1)})}var kt=v(er,2),Ge=P(kt),Mt=P(Ge),tr=v(Mt,2),Fr=_(tr,!0),Cr=v(Ge,2),ms=_(Cr,!0),Gr=v(Cr,2),Ba=_(Gr,!0),fa=v(Gr,2);bs(fa,O=>A(k,O),()=>t(k));var Qr=v(Xt,2);{var Sn=O=>{var I=jf(),Z=jr(I),C=P(Z),Re=P(C),Se=_(Re,!0),be=v(Re,2),Be=P(be);ye(Be,0,()=>["unreviewed","reviewed","follow-up","blocked"],Me=>Me,(Me,he)=>{var Pe=an(),X=_(Pe,!0),E={};S(He=>{y(X,He),E!==(E=he)&&(Pe.value=(Pe.__value=E)??"")},[()=>(t(s),p(()=>Md(he,t(s))))]),$(Me,Pe)});var Ke=v(Be);{var at=Me=>{var he=an(),Pe=_(he,!0);he.value=he.__value="stale",S(()=>y(Pe,(t(s),p(()=>t(s).stale)))),$(Me,he)},Et=Yc(()=>(t(T),t(L),p(()=>kn(t(T),t(L).id)==="stale")));J(Ke,Me=>{t(Et)&&Me(at)})}var Vt;Xs(be);var rr=v(C,2),Nt=P(rr),Zt=v(Nt,2),fr=_(Zt,!0),ct=v(rr,2),ar=_(ct,!0),Ct=v(Z,2),Ut=_(Ct,!0);S((Me,he,Pe)=>{y(Se,(t(s),p(()=>t(s).humanJudgment))),be.disabled=Me,Vt!==(Vt=he)&&(be.value=(be.__value=Vt)??"",Ns(be,Vt)),Ua(Nt,Pe),Nt.disabled=t(ee),y(fr,(t(s),p(()=>t(s).viewed))),ct.disabled=t(ee),y(ar,(t(s),p(()=>t(s).comment))),y(Ut,(t(s),p(()=>t(s).localOnly)))},[()=>(t(ee),t(T),t(L),p(()=>t(ee)||kn(t(T),t(L).id)==="stale")),()=>(t(T),t(L),p(()=>kn(t(T),t(L).id))),()=>(t(T),t(L),p(()=>ps(t(T),"change",t(L).id)))]),G("change",be,Me=>{Bd(t(L).id,Me.currentTarget.value)}),G("change",Nt,Me=>{fs("change",t(L).id,Me.currentTarget.checked)}),G("click",ct,()=>{ha(ca("change",t(L).id))}),$(O,I)};J(Qr,O=>{t(T)&&O(Sn)})}var Zs=v(Qr,2);{var En=O=>{var I=Of(),Z=_(I,!0);S(()=>y(Z,t(xa))),$(O,I)};J(Zs,O=>{t(xa)&&O(En)})}var Nn=v(Zs,2);{var Cn=O=>{var I=Tf(),Z=_(I,!0);S(()=>y(Z,t(wt))),$(O,I)};J(Nn,O=>{t(wt)&&O(Cn)})}var pt=v(St,2),lt=P(pt),Lr=P(lt),Ha=v(P(Lr),2),Ln=_(Ha,!0),Us=v(lt,2),Ks=P(Us),Js=P(Ks),jn=_(Js,!0),qo=v(Js,2),hp=_(qo,!0),fp=v(qo,2),mp=_(fp,!0),Ro=v(Ks,2),So=P(Ro),vp=_(So,!0),gp=v(So,2),yp=_(gp,!0),Eo=v(Ro,2),No=P(Eo),_p=_(No,!0),wp=v(No,2);{var bp=O=>{var I=zf();ye(I,5,()=>(t(L),p(()=>t(L).userImpact)),sa,(Z,C)=>{var Re=ai(),Se=_(Re,!0);S(()=>y(Se,t(C))),$(Z,Re)}),$(O,I)},Pp=O=>{var I=Sa(),Z=_(I,!0);S(()=>y(Z,(t(s),p(()=>t(s).noImpact)))),$(O,I)};J(wp,O=>{t(L),p(()=>t(L).userImpact.length>0)?O(bp):O(Pp,-1)})}var Co=v(Eo,2),Lo=P(Co),kp=_(Lo,!0),xp=v(Lo,2);ye(xp,5,()=>(t(L),p(()=>t(L).risk.reasons)),sa,(O,I)=>{var Z=ai(),C=_(Z,!0);S(()=>y(C,t(I))),$(O,Z)});var jo=v(Co,2),Oo=P(jo),Ap=_(Oo,!0),Ip=v(Oo,2);ye(Ip,5,()=>(t(L),p(()=>t(L).verification.gaps)),sa,(O,I,Z)=>{var C=Vf(),Re=P(C),Se=_(Re,!0),be=v(Re,2);{var Be=Ke=>{var at=Mf(),Et=_(at,!0);S(()=>{at.disabled=t(ee),y(Et,(t(s),p(()=>t(s).comment)))}),G("click",at,()=>{ha(ca("verification-gap",`${t(L).id}:gap:${Z}`))}),$(Ke,at)};J(be,Ke=>{t(T)&&Ke(Be)})}S(()=>y(Se,t(I))),$(O,C)});var $p=v(jo,2),To=P($p),qp=_(To,!0),Rp=v(To,2);ye(Rp,5,()=>(t(L),p(()=>t(L).verification.verified)),sa,(O,I)=>{var Z=ai(),C=_(Z,!0);S(()=>y(C,t(I))),$(O,Z)});var zo=v(pt,2),Mo=P(zo),Sp=P(Mo),Vo=P(Sp),Ep=_(Vo),Do=v(Vo,2),Np=_(Do,!0),Fo=v(Do,2),Cp=_(Fo,!0),Lp=v(Fo,2),jp=_(Lp,!0),Bo=v(Mo,2);{var Op=O=>{var I=Qf(),Z=jr(I),C=P(Z);{var Re=Ae=>{var Je=Df(),se=v(P(Je),2);ye(se,5,()=>t(_t),Ie=>Ie.id,(Ie,Le)=>{const st=ya(()=>(t(o),t(Le),p(()=>t(o).targets.find(kr=>kr.id===t(Le).targetRef))));var Ft=an(),Pr=_(Ft),sr={};S(()=>{y(Pr,`${Ze(t(st)),t(Le),p(()=>t(st)?.routeOrStory??t(Le).targetRef)??""} · ${Ze(t(st)),p(()=>t(st)?.viewport)??""} · ${Ze(t(st)),p(()=>t(st)?.state)??""}`),sr!==(sr=(t(Le),p(()=>t(Le).id)))&&(Ft.value=(Ft.__value=sr)??"")}),$(Ie,Ft)});var fe;Xs(se),S(()=>{fe!==(fe=(t(qe),p(()=>t(qe)?.id)))&&(se.value=(se.__value=fe)??"",Ns(se,fe))}),G("change",se,Ie=>eu(Ie.currentTarget.value)),$(Ae,Je)};J(C,Ae=>{t(_t),p(()=>t(_t).length>1)&&Ae(Re)})}var Se=v(C,2);{var be=Ae=>{var Je=Ff(),se=P(Je),fe=_(se,!0),Ie=v(se,2);ye(Ie,5,()=>(t(qe),p(()=>t(qe).images)),st=>st.id,(st,Ft)=>{var Pr=an(),sr=_(Pr,!0),kr={};S(()=>{y(sr,(t(Ft),p(()=>t(Ft).label))),kr!==(kr=(t(Ft),p(()=>t(Ft).id)))&&(Pr.value=(Pr.__value=kr)??"")}),$(st,Pr)});var Le;Xs(Ie),S(()=>{y(fe,(t(s),p(()=>t(s).imageScope))),Le!==(Le=(t(j),p(()=>t(j)?.id)))&&(Ie.value=(Ie.__value=Le)??"",Ns(Ie,Le))}),G("change",Ie,st=>tu(st.currentTarget.value)),$(Ae,Je)};J(Se,Ae=>{t(qe),p(()=>t(qe)&&t(qe).images.length>1)&&Ae(be)})}var Be=v(Se,2);{var Ke=Ae=>{var Je=Bf(),se=P(Je),fe=v(se,2),Ie=_(fe,!0);S(Le=>{Ua(se,Le),se.disabled=t(ee),y(Ie,(t(s),p(()=>t(s).viewed)))},[()=>(t(T),t(qe),p(()=>ps(t(T),"visual-target",t(qe).targetRef)))]),G("change",se,Le=>{fs("visual-target",t(qe).targetRef,Le.currentTarget.checked)}),$(Ae,Je)};J(Be,Ae=>{t(qe)&&t(T)&&Ae(Ke)})}var at=v(Be,2),Et=P(at),Vt=_(Et),rr=v(Et,2),Nt=v(Z,2),Zt=P(Nt),fr=_(Zt,!0),ct=v(Zt,2),ar=_(ct,!0),Ct=v(ct,2),Ut=_(Ct,!0),Me=v(Ct,2),he=_(Me,!0),Pe=v(Me,2),X=_(Pe,!0),E=v(Nt,2);{var He=Ae=>{var Je=Hf(),se=v(P(Je),2),fe=_(se,!0);S(Ie=>y(fe,Ie),[()=>(t(qe),p(()=>t(qe).incompleteReasons.join(", ")))]),$(Ae,Je)};J(E,Ae=>{t(qe),p(()=>t(qe)?.status==="incomplete")&&Ae(He)})}var Dt=v(E,2);{var Xr=Ae=>{var Je=Gf(),se=jr(Je),fe=P(se),Ie=v(P(fe),2),Le=_(Ie,!0),st=v(fe,2),Ft=v(P(st),2),Pr=_(Ft),sr=v(st,2),kr=P(sr),Wa=_(kr,!0),vs=v(kr,2),$a=_(vs,!0),Br=v(sr,2),nr=v(P(Br),2),qa=_(nr),ma=v(se,2);{var gs=je=>{var ht=Wf(),ft=P(ht),Qe=P(ft),vr=_(Qe),Bt=v(Qe,2),Lt=P(Bt),mt=_(Lt);bs(Bt,Yt=>A(U,Yt),()=>t(U));var or=v(ft,2),nt=P(or),We=_(nt),$e=v(nt,2),Ee=P($e),vt=P(Ee),lr=v(vt,2);ye(lr,3,()=>(t(j),p(()=>t(j).regions)),Yt=>Yt.id,(Yt,Ht,aa)=>{var gr=bl();let Gs;var Dn=_(gr,!0);S(()=>{V(gr,"id",`visual-region-${t(aa)}`),Gs=yr(gr,1,"region-marker",null,Gs,{"active-region":t(oe)===t(aa)}),dr(gr,(t(Ht),t(j),p(()=>`left:${t(Ht).x/t(j).width*100}%;top:${t(Ht).y/t(j).height*100}%;width:${t(Ht).width/t(j).width*100}%;height:${t(Ht).height/t(j).height*100}%`))),y(Dn,t(aa)+1)}),$(Yt,gr)});var ra=v(lr,2);ye(ra,3,()=>t(d),Yt=>Yt.id,(Yt,Ht,aa)=>{var gr=ks(),Gs=_(gr,!0);S(Dn=>{dr(gr,Dn),V(gr,"aria-label",(t(s),Ze(t(aa)),t(Ht),p(()=>`${t(s).comment} pin ${t(aa)+1}: ${t(Ht).state}`))),y(Gs,t(aa)+1)},[()=>(t(Ht),p(()=>us(t(Ht).anchor)))]),G("click",gr,()=>{Qt(Ue("thread",t(Ht).id))}),$(Yt,gr)}),bs($e,Yt=>A(le,Yt),()=>t(le)),S(()=>{y(vr,`Before · ${t(j),p(()=>t(j).label)??""}`),dr(Lt,`width: ${t(ve)}%`),V(mt,"src",(t(j),p(()=>`./${t(j).beforeRef}`))),V(mt,"alt",(t(j),p(()=>`Before capture for ${t(j).label}`))),y(We,`After · ${t(j),p(()=>t(j).label)??""}`),dr(Ee,`width: ${t(ve)}%`),V(vt,"src",(t(j),p(()=>`./${t(j).afterRef}`))),V(vt,"alt",(t(j),p(()=>`After capture for ${t(j).label}`)))}),Hn("scroll",Bt,()=>zi(t(U),t(le))),Hn("scroll",$e,()=>zi(t(le),t(U))),$(je,ht)},Tn=je=>{var ht=Zf(),ft=jr(ht),Qe=P(ft),vr=_(Qe),Bt=v(Qe,2),Lt=v(ft,2),mt=P(Lt),or=_(mt),nt=v(mt,2),We=P(nt),$e=P(We),Ee=v($e,2),vt=v(Ee,2);ye(vt,3,()=>t(d),lr=>lr.id,(lr,ra,Yt)=>{var Ht=ks(),aa=_(Ht,!0);S(gr=>{dr(Ht,gr),V(Ht,"aria-label",(t(s),Ze(t(Yt)),t(ra),p(()=>`${t(s).comment} pin ${t(Yt)+1}: ${t(ra).state}`))),y(aa,t(Yt)+1)},[()=>(t(ra),p(()=>us(t(ra).anchor)))]),G("click",Ht,()=>{Qt(Ue("thread",t(ra).id))}),$(lr,Ht)}),S(()=>{y(vr,`${t(s),p(()=>t(s).wipePosition)??""}: ${t(ge)??""}%`),y(or,`Before / after wipe · ${t(j),p(()=>t(j).label)??""}`),dr(We,`width: ${t(ve)}%`),V($e,"src",(t(j),p(()=>`./${t(j).beforeRef}`))),V($e,"alt",(t(j),p(()=>`Before capture for ${t(j).label}`))),dr(Ee,`clip-path: inset(0 ${100-t(ge)}% 0 0)`),V(Ee,"src",(t(j),p(()=>`./${t(j).afterRef}`))),V(Ee,"alt",`After capture revealed to ${t(ge)}%`)}),en(Bt,()=>t(ge),lr=>A(ge,lr)),$(je,ht)},zn=je=>{var ht=Uf(),ft=P(ht),Qe=_(ft),vr=v(ft,2),Bt=P(vr),Lt=P(Bt),mt=v(Lt,2);let or;var nt=v(mt,2);ye(nt,3,()=>t(d),We=>We.id,(We,$e,Ee)=>{var vt=ks(),lr=_(vt,!0);S(ra=>{dr(vt,ra),V(vt,"aria-label",(t(s),Ze(t(Ee)),t($e),p(()=>`${t(s).comment} pin ${t(Ee)+1}: ${t($e).state}`))),y(lr,t(Ee)+1)},[()=>(t($e),p(()=>us(t($e).anchor)))]),G("click",vt,()=>{Qt(Ue("thread",t($e).id))}),$(We,vt)}),S(()=>{y(Qe,`${t(_e)?"Blink running; use Stop blink to pause":"Blink paused"} ·\n ${t(j),p(()=>t(j).label)??""}`),dr(Bt,`width: ${t(ve)}%`),V(Lt,"src",(t(j),p(()=>`./${t(j).beforeRef}`))),V(Lt,"alt",(t(j),p(()=>`Before capture for ${t(j).label}`))),or=yr(mt,1,"blink-after",null,or,{"blink-running":t(_e)}),V(mt,"src",(t(j),p(()=>`./${t(j).afterRef}`))),V(mt,"alt",(t(j),p(()=>`After capture for ${t(j).label}`)))}),$(je,ht)},Mn=je=>{var ht=Kf(),ft=P(ht),Qe=_(ft),vr=v(ft,2),Bt=P(vr),Lt=P(Bt),mt=v(Lt,2);ye(mt,3,()=>t(d),or=>or.id,(or,nt,We)=>{var $e=ks(),Ee=_($e,!0);S(vt=>{dr($e,vt),V($e,"aria-label",(t(s),Ze(t(We)),t(nt),p(()=>`${t(s).comment} pin ${t(We)+1}: ${t(nt).state}`))),y(Ee,t(We)+1)},[()=>(t(nt),p(()=>us(t(nt).anchor)))]),G("click",$e,()=>{Qt(Ue("thread",t(nt).id))}),$(or,$e)}),S(()=>{y(Qe,`${t(s),p(()=>t(s).pixelDiff)??""} · ${t(j),p(()=>t(j).label)??""}`),dr(Bt,`width: ${t(ve)}%`),V(Lt,"src",(t(j),p(()=>`./${t(j).diffRef}`))),V(Lt,"alt",(t(j),p(()=>`Pixel difference bitmap with ${t(j).diffPixelCount} changed pixels`)))}),$(je,ht)},Vn=je=>{var ht=Jf(),ft=P(ht),Qe=_(ft),vr=v(ft,2),Bt=P(vr),Lt=P(Bt),mt=v(Lt,2);ye(mt,3,()=>(t(j),p(()=>t(j).regions)),nt=>nt.id,(nt,We,$e)=>{var Ee=bl();let vt;var lr=_(Ee,!0);S(()=>{V(Ee,"id",`visual-region-${t($e)}`),vt=yr(Ee,1,"region-marker",null,vt,{"active-region":t(oe)===t($e)}),dr(Ee,(t(We),t(j),p(()=>`left:${t(We).x/t(j).width*100}%;top:${t(We).y/t(j).height*100}%;width:${t(We).width/t(j).width*100}%;height:${t(We).height/t(j).height*100}%`))),y(lr,t($e)+1)}),$(nt,Ee)});var or=v(mt,2);ye(or,3,()=>t(d),nt=>nt.id,(nt,We,$e)=>{var Ee=ks(),vt=_(Ee,!0);S(lr=>{dr(Ee,lr),V(Ee,"aria-label",(t(s),Ze(t($e)),t(We),p(()=>`${t(s).comment} pin ${t($e)+1}: ${t(We).state}`))),y(vt,t($e)+1)},[()=>(t(We),p(()=>us(t(We).anchor)))]),G("click",Ee,()=>{Qt(Ue("thread",t(We).id))}),$(nt,Ee)}),S(()=>{y(Qe,`${t(s),p(()=>t(s).afterOnly)??""} · ${t(j),p(()=>t(j).label)??""}`),dr(Bt,`width: ${t(ve)}%`),V(Lt,"src",(t(j),p(()=>`./${t(j).afterRef}`))),V(Lt,"alt",(t(j),p(()=>`After capture for ${t(j).label}`)))}),$(je,ht)};J(ma,je=>{t(W)==="side-by-side"?je(gs):t(W)==="wipe"?je(Tn,1):t(W)==="blink"?je(zn,2):t(W)==="pixel-diff"?je(Mn,3):je(Vn,-1)})}var mr=v(ma,2),ir=P(mr),ys=_(ir,!0),ea=v(ir,2);{var ta=je=>{var ht=Pl();ye(ht,7,()=>(t(j),p(()=>t(j).regions)),ft=>ft.id,(ft,Qe,vr)=>{var Bt=Yf(),Lt=P(Bt),mt=P(Lt),or=_(mt),nt=v(mt,2);{var We=$e=>{var Ee=Ea(),vt=_(Ee,!0);S(()=>{Ee.disabled=t(ee),y(vt,(t(s),p(()=>t(s).comment)))}),G("click",Ee,()=>{ha(ca("visual-region",`${t(qe).id}:${t(j).id}:${t(Qe).id}`))}),$($e,Ee)};J(nt,$e=>{t(T)&&$e(We)})}S(()=>{V(mt,"aria-current",t(oe)===t(vr)?"true":void 0),y(or,`Region ${t(vr)+1} · ${t(Qe),p(()=>t(Qe).pixels)??""} px · (${t(Qe),p(()=>t(Qe).x)??""}, ${t(Qe),p(()=>t(Qe).y)??""}) ${t(Qe),p(()=>t(Qe).width)??""}\n × ${t(Qe),p(()=>t(Qe).height)??""}`)}),G("click",mt,()=>{ru(t(vr))}),$(ft,Bt)}),$(je,ht)},Ra=je=>{var ht=Sa(),ft=_(ht,!0);S(()=>y(ft,(t(s),p(()=>t(s).noRegions)))),$(je,ht)};J(ea,je=>{t(j),p(()=>t(j).regions.length>0)?je(ta):je(Ra,-1)})}S(je=>{y(Le,(t(j),p(()=>t(j).diffPixelCount))),y(Pr,`${je??""}%`),y(Wa,(t(s),p(()=>t(s).changedRegions))),y($a,(t(j),p(()=>t(j).regions.length))),y(qa,`${t(j),p(()=>t(j).width)??""} × ${t(j),p(()=>t(j).height)??""}`),y(ys,(t(s),p(()=>t(s).changedRegions)))},[()=>(t(j),p(()=>(t(j).diffRatio*100).toFixed(3)))]),$(Ae,Je)};J(Dt,Ae=>{t(j)&&Ae(Xr)})}S(()=>{y(Vt,`${t(s),p(()=>t(s).zoom)??""}: ${t(ve)??""}%`),V(Nt,"aria-label",(t(s),p(()=>t(s).visualEvidence))),V(Zt,"aria-pressed",t(W)==="side-by-side"),y(fr,(t(s),p(()=>t(s).sideBySide))),V(ct,"aria-pressed",t(W)==="wipe"),y(ar,(t(s),p(()=>t(s).wipe))),V(Ct,"aria-pressed",t(W)==="blink"),Ct.disabled=t(Ot),V(Ct,"title",(t(Ot),t(s),p(()=>t(Ot)?t(s).reducedMotion:void 0))),y(Ut,(t(W),t(_e),t(s),p(()=>t(W)==="blink"&&t(_e)?t(s).stopBlink:t(s).blink))),V(Me,"aria-pressed",t(W)==="pixel-diff"),y(he,(t(s),p(()=>t(s).pixelDiff))),V(Pe,"aria-pressed",t(W)==="after-only"),y(X,(t(s),p(()=>t(s).afterOnly)))}),en(rr,()=>t(ve),Ae=>A(ve,Ae)),G("click",Zt,()=>Vr("side-by-side")),G("click",ct,()=>Vr("wipe")),G("click",Ct,()=>{t(W)==="blink"?A(_e,!t(_e)):Vr("blink")}),G("click",Me,()=>Vr("pixel-diff")),G("click",Pe,()=>Vr("after-only")),$(O,I)},Tp=O=>{var I=Xf(),Z=v(P(I),2),C=_(Z,!0);S(()=>y(C,(t(s),p(()=>t(s).visualGap)))),$(O,I)};J(Bo,O=>{t(_t),p(()=>t(_t).length>0)?O(Op):O(Tp,-1)})}var zp=v(Bo,2),Ho=P(zp),Mp=P(Ho),Wo=P(Mp),Vp=_(Wo),Dp=v(Wo,2),Fp=_(Dp,!0),Bp=v(Ho,2);{var Hp=O=>{var I=Pl();ye(I,7,()=>t(cr),Z=>Z.id,(Z,C,Re)=>{var Se=em(),be=P(Se);let Be;var Ke=P(be),at=P(Ke),Et=_(at,!0),Vt=v(at),rr=_(Vt,!0),Nt=v(Vt),Zt=_(Nt,!0),fr=v(Ke,2),ct=_(fr,!0),ar=v(fr,2),Ct=_(ar,!0),Ut=v(ar,2);{var Me=X=>{var E=Ea(),He=_(E,!0);S(()=>y(He,(t(s),p(()=>t(s).viewCode)))),G("click",E,()=>In(t(C).hunkRefs[0])),$(X,E)};J(Ut,X=>{t(C),p(()=>t(C).hunkRefs[0])&&X(Me)})}var he=v(Ut,2);{var Pe=X=>{var E=Ea(),He=_(E,!0);S(()=>{E.disabled=t(ee),y(He,(t(s),p(()=>t(s).comment)))}),G("click",E,()=>{ha(ca("finding",t(C).id))}),$(X,E)};J(he,X=>{t(T)&&X(Pe)})}S(X=>{V(be,"id",X),Be=yr(be,1,"",null,Be,{"active-finding":t(me)===t(Re)}),y(Et,(t(C),p(()=>t(C).state))),y(rr,(t(C),p(()=>t(C).severity))),y(Zt,(t(C),p(()=>t(C).category))),y(ct,(t(C),p(()=>t(C).title))),y(Ct,(t(C),p(()=>t(C).description)))},[()=>(t(C),p(()=>Ue("finding",t(C).id)))]),$(Z,Se)}),$(O,I)},Wp=O=>{var I=Sa(),Z=_(I,!0);S(()=>y(Z,(t(s),p(()=>t(s).noFindings)))),$(O,I)};J(Bp,O=>{t(cr),p(()=>t(cr).length>0)?O(Hp):O(Wp,-1)})}var Zo=v(zo,2),Uo=P(Zo),Zp=P(Uo),Ko=P(Zp),Up=_(Ko),Kp=v(Ko,2),Jp=_(Kp,!0),Jo=v(Uo,2);ye(Jo,5,()=>(t(At),p(()=>t(At).slice(0,3))),O=>O.id,(O,I)=>{var Z=tm(),C=P(Z),Re=_(C,!0),Se=v(C),be=_(Se,!0),Be=v(Se,2),Ke=_(Be,!0);S(()=>{y(Re,(t(I),p(()=>t(I).type))),y(be,(t(I),p(()=>t(I).path))),y(Ke,(t(I),p(()=>t(I).summary)))}),$(O,Z)});var Yp=v(Jo,2);{var Gp=O=>{var I=am(),Z=P(I),C=_(Z),Re=v(Z,2);ye(Re,5,()=>(t(At),p(()=>t(At).slice(3))),Se=>Se.id,(Se,be)=>{var Be=rm(),Ke=P(Be),at=_(Ke,!0),Et=v(Ke);S(()=>{y(at,(t(be),p(()=>t(be).path))),y(Et,` — ${t(be),p(()=>t(be).summary)??""}`)}),$(Se,Be)}),S(()=>y(C,`${t(s),p(()=>t(s).moreEvidence)??""} (${t(At),p(()=>t(At).length-3)??""})`)),$(O,I)};J(Yp,O=>{t(At),p(()=>t(At).length>3)&&O(Gp)})}var Yo=v(Zo,2),Go=P(Yo),Qo=P(Go),Xo=P(Qo),Qp=_(Xo),Xp=v(Xo,2),ec=_(Xp,!0),tc=v(Qo,2),Ys=P(tc),rc=_(Ys,!0),On=v(Ys,2),ac=_(On,!0),sc=v(Go,2);ye(sc,1,()=>t(br),O=>O.id,(O,I)=>{const Z=ya(()=>(t(L),t(I),p(()=>t(L).hunkExplanations?.find(({hunkRef:X})=>X===t(I).id))));var C=dm();let Re;var Se=P(C),be=P(Se),Be=P(be),Ke=_(Be,!0),at=v(Be,2),Et=_(at),Vt=v(be,2),rr=P(Vt);{var Nt=X=>{var E=sm(),He=jr(E),Dt=P(He),Xr=v(Dt,2),Ae=_(Xr,!0),Je=v(He,2),se=_(Je,!0);S(fe=>{Ua(Dt,fe),Dt.disabled=t(ee),y(Ae,(t(s),p(()=>t(s).viewed))),Je.disabled=t(ee),y(se,(t(s),p(()=>t(s).comment)))},[()=>(t(T),t(I),p(()=>ps(t(T),"hunk",t(I).id)))]),G("change",Dt,fe=>{fs("hunk",t(I).id,fe.currentTarget.checked)}),G("click",Je,()=>{ha(ca("hunk",t(I).id))}),$(X,E)};J(rr,X=>{t(T)&&X(Nt)})}var Zt=v(rr,2);{var fr=X=>{var E=Ea(),He=_(E,!0);S(()=>y(He,(t(s),p(()=>t(s).viewVisual)))),G("click",E,Ti),$(X,E)};J(Zt,X=>{t(_t),p(()=>t(_t).length>0)&&X(fr)})}var ct=v(Zt,2),ar=v(Se,2);{var Ct=X=>{var E=nm(),He=P(E),Dt=P(He),Xr=_(Dt,!0),Ae=v(Dt,2),Je=_(Ae,!0),se=v(He,2),fe=P(se),Ie=_(fe,!0),Le=v(fe,2),st=_(Le,!0);S(()=>{V(E,"aria-label",(t(s),p(()=>t(s).interpretation))),y(Xr,(t(s),p(()=>t(s).hunkPurpose))),y(Je,(Ze(t(Z)),p(()=>t(Z).purpose))),y(Ie,(t(s),p(()=>t(s).hunkMeaning))),y(st,(Ze(t(Z)),p(()=>t(Z).meaning)))}),$(X,E)};J(ar,X=>{t(Z)&&X(Ct)})}var Ut=v(ar,2);let Me;ye(Ut,5,()=>(t(I),p(()=>Di(t(I)))),sa,(X,E)=>{var He=_s(),Dt=jr(He);{var Xr=se=>{var fe=kl(),Ie=_(fe,!0);S(Le=>y(Ie,Le),[()=>(t(s),t(E),p(()=>t(s).context.replace("{count}",String(t(E).count))))]),G("click",fe,()=>Fi(t(I).id)),$(se,fe)},Ae=se=>{const fe=ya(()=>(t(I),t(E),p(()=>Ci(t(I),t(E).index))));var Ie=im(),Le=P(Ie),st=_(Le,!0),Ft=v(Le,2),Pr=_(Ft,!0),sr=v(Ft,2),kr=_(sr,!0),Wa=v(sr,2);ye(Wa,5,()=>(t(I),t(E),p(()=>Rn(t(I),t(E).index))),sa,(Br,nr)=>{var qa=rn();let ma;var gs=_(qa,!0);S(()=>{ma=yr(qa,1,"",null,ma,{"word-change":t(nr).changed}),y(gs,(t(nr),p(()=>t(nr).text)))}),$(Br,qa)});var vs=v(Wa,2);{var $a=Br=>{var nr=xl();S(()=>{nr.disabled=t(ee),V(nr,"aria-label",(t(s),t(I),Ze(t(fe)),p(()=>`${t(s).commentOn} ${t(I).path}:${t(fe).startLine}`))),V(nr,"title",(t(s),p(()=>t(s).comment)))}),G("click",nr,()=>{ha(t(fe))}),$(Br,nr)};J(vs,Br=>{t(T)&&t(fe)&&Br($a)})}S(()=>{yr(Ie,1,(t(E),p(()=>`diff-line ${t(E).line.kind}`))),V(Ie,"aria-label",(t(E),p(()=>`${t(E).line.kind}, old line ${t(E).line.oldLine??"none"}, new line ${t(E).line.newLine??"none"}`))),y(st,(t(E),p(()=>t(E).line.oldLine??""))),y(Pr,(t(E),p(()=>t(E).line.newLine??""))),y(kr,(t(E),p(()=>t(E).line.kind==="addition"?"+":t(E).line.kind==="deletion"?"−":" ")))}),$(se,Ie)},Je=se=>{const fe=ya(()=>(t(I),t(E),p(()=>Ci(t(I),t(E).index))));var Ie=om(),Le=P(Ie);let st;var Ft=P(Le),Pr=_(Ft,!0),sr=v(Ft,2),kr=_(sr,!0),Wa=v(sr,2);{var vs=mr=>{var ir=Al();ye(ir,5,()=>(t(I),t(E),p(()=>Rn(t(I),t(E).index))),sa,(ys,ea)=>{var ta=rn();let Ra;var je=_(ta,!0);S(()=>{Ra=yr(ta,1,"",null,Ra,{"word-change":t(ea).changed}),y(je,(t(ea),p(()=>t(ea).text)))}),$(ys,ta)}),$(mr,ir)};J(Wa,mr=>{t(E),p(()=>t(E).line.kind!=="addition")&&mr(vs)})}var $a=v(Le,2);let Br;var nr=P($a),qa=_(nr,!0),ma=v(nr,2),gs=_(ma,!0),Tn=v(ma,2);{var zn=mr=>{var ir=Al();ye(ir,5,()=>(t(I),t(E),p(()=>Rn(t(I),t(E).index))),sa,(ys,ea)=>{var ta=rn();let Ra;var je=_(ta,!0);S(()=>{Ra=yr(ta,1,"",null,Ra,{"word-change":t(ea).changed}),y(je,(t(ea),p(()=>t(ea).text)))}),$(ys,ta)}),$(mr,ir)};J(Tn,mr=>{t(E),p(()=>t(E).line.kind!=="deletion")&&mr(zn)})}var Mn=v($a,2);{var Vn=mr=>{var ir=xl();S(()=>{ir.disabled=t(ee),V(ir,"aria-label",(t(s),t(I),Ze(t(fe)),p(()=>`${t(s).commentOn} ${t(I).path}:${t(fe).startLine}`))),V(ir,"title",(t(s),p(()=>t(s).comment)))}),G("click",ir,()=>{ha(t(fe))}),$(mr,ir)};J(Mn,mr=>{t(T)&&t(fe)&&mr(Vn)})}S(()=>{V(Ie,"aria-label",(t(E),p(()=>`${t(E).line.kind}, old line ${t(E).line.oldLine??"none"}, new line ${t(E).line.newLine??"none"}`))),st=yr(Le,1,(t(E),p(()=>`diff-line ${t(E).line.kind==="addition"?"empty":t(E).line.kind}`)),null,st,{"empty-side":t(E).line.kind==="addition"}),y(Pr,(t(E),p(()=>t(E).line.oldLine??""))),y(kr,(t(E),p(()=>t(E).line.kind==="deletion"?"−":" "))),Br=yr($a,1,(t(E),p(()=>`diff-line ${t(E).line.kind==="deletion"?"empty":t(E).line.kind}`)),null,Br,{"empty-side":t(E).line.kind==="deletion"}),y(qa,(t(E),p(()=>t(E).line.newLine??""))),y(gs,(t(E),p(()=>t(E).line.kind==="addition"?"+":" ")))}),$(se,Ie)};J(Dt,se=>{t(E),p(()=>t(E).kind==="fold")?se(Xr):t(R)==="unified"?se(Ae,1):se(Je,-1)})}$(X,He)});var he=v(Ut,2);{var Pe=X=>{var E=lm(),He=_(E);S(()=>y(He,`← ${t(s),p(()=>t(s).backChange)??""}`)),G("click",E,su),$(X,E)};J(he,X=>{t(q),t(I),p(()=>t(q)===t(I).id)&&X(Pe)})}S((X,E,He)=>{Re=yr(C,1,"hunk",null,Re,{"active-hunk":t(q)===t(I).id}),V(C,"id",X),V(C,"aria-labelledby",E),y(Ke,(t(I),p(()=>t(I).path))),V(at,"id",He),y(Et,`@@ −${t(I),p(()=>t(I).oldStart)??""},${t(I),p(()=>t(I).oldLines)??""} +${t(I),p(()=>t(I).newStart)??""},${t(I),p(()=>t(I).newLines)??""} @@ ${t(I),p(()=>t(I).heading)??""}`),V(ct,"aria-label",(t(I),p(()=>`Link to hunk in ${t(I).path}`))),Me=yr(Ut,1,"diff-table",null,Me,{"split-diff":t(R)==="split"}),V(Ut,"aria-label",(t(I),p(()=>`Diff for ${t(I).path}`)))},[()=>(t(I),p(()=>Ue("hunk",t(I).id))),()=>(t(I),p(()=>Ue("hunk-title",t(I).id))),()=>(t(I),p(()=>Ue("hunk-title",t(I).id)))]),G("click",ct,()=>In(t(I).id)),$(O,C)});var nc=v(Yo,2),el=P(nc),ic=P(el),tl=P(ic),oc=_(tl),lc=v(tl,2),dc=_(lc,!0),rl=v(el,2);{var uc=O=>{var I=um(),Z=P(I),C=P(Z),Re=_(C),Se=v(C,2),be=_(Se,!0),Be=v(Z,2),Ke=v(P(Be),2),at=P(Ke);at.value=at.__value="note";var Et=v(at);Et.value=Et.__value="question";var Vt=v(Et);Vt.value=Vt.__value="finding";var rr=v(Vt);rr.value=rr.__value="change-request",Xs(Ke);var Nt=v(Be,2),Zt=P(Nt),fr=_(Zt,!0),ct=v(Zt,2);bs(ct,se=>A(b,se),()=>t(b));var ar=v(Nt,2),Ct=P(ar),Ut=v(Ct,2),Me=_(Ut,!0),he=v(Ut,2),Pe=_(he,!0),X=v(ar,2),E=_(X,!0),He=v(X,2),Dt=P(He),Xr=_(Dt,!0),Ae=v(Dt,2),Je=_(Ae,!0);S(se=>{y(Re,`${t(s),p(()=>t(s).commentOn)??""} / ${t(Tt),p(()=>t(Tt).type)??""}`),y(be,(t(Tt),p(()=>t(Tt).path??t(Tt).ref))),Ke.disabled=t(ee),y(fr,(t(s),p(()=>t(s).commentBody))),ct.disabled=t(ee),Ct.disabled=t(ee),y(Me,(t(s),p(()=>t(s).askAgent))),y(Pe,(t(s),p(()=>t(s).askAgentHelp))),y(E,(t(s),p(()=>t(s).localOnly))),Dt.disabled=se,y(Xr,(t(s),p(()=>t(s).saveComment))),Ae.disabled=t(ee),y(Je,(t(s),p(()=>t(s).cancel)))},[()=>(t(ee),t(Nr),p(()=>t(ee)||!t(Nr).trim()))]),Hn("submit",I,se=>{se.preventDefault(),Hd()}),Vh(Ke,()=>t(ua),se=>A(ua,se)),en(ct,()=>t(Nr),se=>A(Nr,se)),vl(Ct,()=>t(g),se=>A(g,se)),G("click",Ae,()=>{A(Tt,null),A(Nr,""),A(g,!1)}),$(O,I)};J(rl,O=>{t(Tt)&&O(uc)})}var pc=v(rl,2);{var cc=O=>{var I=fm();ye(I,5,()=>t(K),Z=>Z.id,(Z,C)=>{var Re=hm(),Se=P(Re),be=P(Se),Be=P(be),Ke=_(Be,!0),at=v(Be,2),Et=_(at,!0),Vt=v(be,2),rr=_(Vt,!0),Nt=v(Se,2),Zt=_(Nt,!0),fr=v(Nt,2);ye(fr,1,()=>(t(C),p(()=>t(C).messages)),he=>he.id,(he,Pe)=>{var X=Sa(),E=_(X,!0);S(()=>y(E,(t(Pe),p(()=>t(Pe).body)))),$(he,X)});var ct=v(fr,2);{var ar=he=>{var Pe=pm(),X=P(Pe),E=v(X,2),He=_(E,!0);S(()=>{Ua(X,(t(C),p(()=>t(C).agentAttention.state==="requested"))),X.disabled=(t(ee),t(C),p(()=>t(ee)||t(C).state!=="open")),y(He,(t(s),p(()=>t(s).askAgent)))}),G("change",X,Dt=>{Zd(t(C).id,Dt.currentTarget.checked)}),$(he,Pe)},Ct=he=>{var Pe=cm(),X=_(Pe);S(()=>y(X,`Agent attention: ${t(C),p(()=>t(C).agentAttention.state)??""}`)),$(he,Pe)};J(ct,he=>{t(C),p(()=>t(C).agentAttention.state==="none"||t(C).agentAttention.state==="requested")?he(ar):he(Ct,-1)})}var Ut=v(ct,2);{var Me=he=>{var Pe=Ea(),X=_(Pe,!0);S(()=>{Pe.disabled=t(ee),y(X,(t(s),p(()=>t(s).resolve)))}),G("click",Pe,()=>{Wd(t(C).id)}),$(he,Pe)};J(Ut,he=>{t(C),p(()=>t(C).state==="open")&&he(Me)})}S(he=>{V(Re,"id",he),V(Re,"data-thread-state",(t(C),p(()=>t(C).state))),y(Ke,(t(C),p(()=>t(C).kind))),y(Et,(t(C),p(()=>t(C).anchor.type))),y(rr,(t(C),t(s),p(()=>t(C).state==="resolved"?t(s).resolved:t(C).state))),y(Zt,(t(C),p(()=>t(C).anchor.path??t(C).anchor.ref)))},[()=>(t(C),p(()=>Ue("thread",t(C).id)))]),$(Z,Re)}),$(O,I)},hc=O=>{var I=mm(),Z=_(I,!0);S(()=>y(Z,(t(s),p(()=>t(s).noComments)))),$(O,I)};J(pc,O=>{t(K),p(()=>t(K).length>0)?O(cc):O(hc,-1)})}S((O,I,Z,C,Re,Se,be,Be)=>{V(z,"id",O),V(z,"aria-labelledby",I),y(tt,`← ${t(s),p(()=>t(s).backQueue)??""}`),y(qt,`Focused change / ${t(L),p(()=>t(L).kind)??""}`),V(Pt,"id",Z),y(Ne,(t(L),p(()=>t(L).title))),V(ze,"data-queue",C),y(ce,Re),y(Ye,`${t(L),p(()=>t(L).risk.level)??""} risk`),y(Rt,(t(L),p(()=>t(L).intent.source))),y(Ce,(t(s),p(()=>t(s).reviewWorkspace))),Mt.disabled=Se,y(Fr,(t(s),p(()=>t(s).reanchorImport))),Cr.disabled=!t(T)||t(ee),y(ms,(t(s),p(()=>t(s).exportReview))),Gr.disabled=be,y(Ba,(t(s),p(()=>t(s).importReview))),V(fa,"aria-label",(t(s),p(()=>t(s).reviewBundleFile))),y(Ln,(t(s),p(()=>t(s).interpretation))),y(jn,(t(s),p(()=>t(s).what))),y(hp,(t(L),p(()=>t(L).summary))),y(mp,(t(L),p(()=>t(L).implementation))),y(vp,(t(s),p(()=>t(s).why))),y(yp,(t(L),t(s),p(()=>t(L).intent.text||t(s).intentUnknown))),y(_p,(t(s),p(()=>t(s).userImpact))),y(kp,(t(s),p(()=>t(s).risk))),y(Ap,(t(s),p(()=>t(s).gaps))),y(qp,(t(s),p(()=>t(s).verified))),y(Ep,`Evidence / ${t(_t),p(()=>t(_t).length)??""}`),y(Np,(t(s),p(()=>t(s).measured))),y(Cp,(t(s),p(()=>t(s).visualEvidence))),y(jp,Be),y(Vp,`Finding states / ${t(cr),p(()=>t(cr).length)??""}`),y(Fp,(t(s),p(()=>t(s).findings))),y(Up,`Evidence / ${t(At),p(()=>t(At).length)??""}`),y(Jp,(t(s),p(()=>t(s).evidence))),y(Qp,`Structured patch / ${t(br),p(()=>t(br).length)??""}`),y(ec,(t(s),p(()=>t(s).codeDiff))),V(Ys,"aria-pressed",t(R)==="unified"),y(rc,(t(s),p(()=>t(s).unified))),V(On,"aria-pressed",t(R)==="split"),y(ac,(t(s),p(()=>t(s).split))),y(oc,`Notes / ${t(K),p(()=>t(K).length)??""}`),y(dc,(t(s),p(()=>t(s).comments)))},[()=>(t(L),p(()=>Ue("change",t(L).id))),()=>(t(L),p(()=>Ue("title",t(L).id))),()=>(t(L),p(()=>Ue("title",t(L).id))),()=>(t(L),p(()=>Yr(t(L)))),()=>(t(L),t(s),p(()=>Fs(Yr(t(L)),t(s)))),()=>(t(ee),t(te),p(()=>t(ee)||!!t(te))),()=>(t(T),t(ee),t(te),p(()=>!t(T)||t(ee)||!!t(te))),()=>(t(o),t(c),p(()=>$n(t(o),t(c))))]),G("click",pe,Vi),vl(Mt,()=>t(Aa),O=>A(Aa,O)),G("click",Cr,()=>{Ud()}),G("click",Gr,()=>t(k)?.click()),G("change",fa,O=>{Qd(O.currentTarget.files?.[0])}),G("click",Ys,()=>A(R,"unified")),G("click",On,()=>A(R,"split")),$(Q,z)},dp=Q=>{const z=ya(()=>(t(o),t(q),p(()=>t(o).hunks.find(ot=>ot.id===t(q)))));var pe=_s(),tt=jr(pe);{var bt=ot=>{var $t=_m(),qt=P($t),Pt=_(qt),Ne=v(qt,2),xe=_(Ne,!0),ze=v(Ne,2),ce=_(ze,!0),ne=v(ze,2),Ye=P(ne),rt=P(Ye),Rt=_(rt),St=v(rt,2);{var Xt=dt=>{var Ce=gm(),Jt=P(Ce),zt=P(Jt),ut=v(zt,2),kt=_(ut,!0),Ge=v(Jt,2),Mt=_(Ge,!0);S(tr=>{Ua(zt,tr),zt.disabled=t(ee),y(kt,(t(s),p(()=>t(s).viewed))),Ge.disabled=t(ee),y(Mt,(t(s),p(()=>t(s).comment)))},[()=>(t(T),Ze(t(z)),p(()=>ps(t(T),"hunk",t(z).id)))]),G("change",zt,tr=>{fs("hunk",t(z).id,tr.currentTarget.checked)}),G("click",Ge,()=>{ha(ca("hunk",t(z).id))}),$(dt,Ce)};J(St,dt=>{t(T)&&dt(Xt)})}var er=v(Ye,2);ye(er,5,()=>(Ze(t(z)),p(()=>Di(t(z)))),sa,(dt,Ce)=>{var Jt=_s(),zt=jr(Jt);{var ut=Ge=>{var Mt=kl(),tr=_(Mt,!0);S(Fr=>y(tr,Fr),[()=>(t(s),t(Ce),p(()=>t(s).context.replace("{count}",String(t(Ce).count))))]),G("click",Mt,()=>Fi(t(z).id)),$(Ge,Mt)},kt=Ge=>{var Mt=ym(),tr=P(Mt),Fr=_(tr,!0),Cr=v(tr),ms=_(Cr,!0),Gr=v(Cr),Ba=_(Gr,!0),fa=v(Gr),Qr=_(fa,!0);S(()=>{yr(Mt,1,(t(Ce),p(()=>`diff-line ${t(Ce).line.kind}`))),y(Fr,(t(Ce),p(()=>t(Ce).line.oldLine??""))),y(ms,(t(Ce),p(()=>t(Ce).line.newLine??""))),y(Ba,(t(Ce),p(()=>t(Ce).line.kind==="addition"?"+":t(Ce).line.kind==="deletion"?"−":" "))),y(Qr,(t(Ce),p(()=>t(Ce).line.content)))}),$(Ge,Mt)};J(zt,Ge=>{t(Ce),p(()=>t(Ce).kind==="fold")?Ge(ut):Ge(kt,-1)})}$(dt,Jt)}),S(dt=>{y(Pt,`← ${t(s),p(()=>t(s).backQueue)??""}`),y(xe,(t(s),p(()=>t(s).unclassified))),y(ce,(Ze(t(z)),p(()=>t(z).path))),V(ne,"id",dt),y(Rt,`@@ −${Ze(t(z)),p(()=>t(z).oldStart)??""},${Ze(t(z)),p(()=>t(z).oldLines)??""} +${Ze(t(z)),p(()=>t(z).newStart)??""},${Ze(t(z)),p(()=>t(z).newLines)??""} @@`)},[()=>(Ze(t(z)),p(()=>Ue("hunk",t(z).id)))]),G("click",qt,Vi),$(ot,$t)};J(tt,ot=>{t(z)&&ot(bt)})}$(Q,pe)},up=Q=>{var z=wm(),pe=P(z),tt=_(pe,!0);S(()=>y(tt,(t(s),p(()=>t(s).empty)))),$(Q,z)};J(op,Q=>{t(L)?Q(lp):t(q)?Q(dp,1):(t(o),p(()=>t(o).changes.length===0)&&Q(up,2))})}var pp=v(Gi,2);{var cp=Q=>{var z=Im(),pe=P(z),tt=P(pe),bt=P(tt),ot=_(bt),$t=v(bt,2);{var qt=ce=>{var ne=bm(),Ye=_(ne);S(()=>y(Ye,`${t(s),p(()=>t(s).unreadAnswers)??""}: ${t(e)??""}`)),$(ce,ne)};J($t,ce=>{t(e)>0&&ce(qt)})}var Pt=v(tt,2);{var Ne=ce=>{var ne=Ea(),Ye=_(ne,!0);S(()=>{ne.disabled=t(Ia)||t(ee),y(Ye,(t(s),p(()=>t(s).reviewItems)))}),G("click",ne,()=>{Jd()}),$(ce,ne)};J(Pt,ce=>{t(u)>0&&ce(Ne)})}var xe=v(pe,2);{var ze=ce=>{var ne=Am(),Ye=P(ne),rt=_(Ye,!0),Rt=v(Ye,2);ye(Rt,5,()=>(t(D),p(()=>t(D).batch.items)),pt=>pt.id,(pt,lt)=>{var Lr=Pm(),Ha=P(Lr),Ln=_(Ha,!0),Us=v(Ha,2),Ks=_(Us),Js=v(Us,2),jn=_(Js,!0);S(()=>{y(Ln,(t(lt),p(()=>t(lt).question))),y(Ks,`${t(lt),p(()=>t(lt).anchor.type)??""}: ${t(lt),p(()=>t(lt).anchor.ref)??""}`),y(jn,(t(lt),p(()=>t(lt).state)))}),$(pt,Lr)});var St=v(Rt,2),Xt=P(St),er=P(Xt),dt=_(er,!0),Ce=v(er,2),Jt=_(Ce),zt=v(Xt,2),ut=P(zt),kt=_(ut,!0),Ge=v(ut,2),Mt=_(Ge,!0),tr=v(zt,2),Fr=P(tr),Cr=_(Fr,!0),ms=v(Fr,2),Gr=_(ms),Ba=v(St,2);ye(Ba,1,()=>(t(D),p(()=>t(D).warnings)),pt=>pt,(pt,lt)=>{var Lr=km(),Ha=_(Lr,!0);S(()=>y(Ha,t(lt))),$(pt,Lr)});var fa=v(Ba,2),Qr=P(fa),Sn=_(Qr,!0),Zs=v(Qr,2);{var En=pt=>{var lt=Ea(),Lr=_(lt,!0);S(()=>{lt.disabled=t(Ia),y(Lr,(t(s),p(()=>t(s).copyHandoff)))}),G("click",lt,()=>{Gd()}),$(pt,lt)};J(Zs,pt=>{t(pa)&&pt(En)})}var Nn=v(fa,2);{var Cn=pt=>{var lt=xm(),Lr=_(lt,!0);S(()=>y(Lr,t(pa))),$(pt,lt)};J(Nn,pt=>{t(pa)&&pt(Cn)})}S(pt=>{y(rt,(t(s),p(()=>t(s).feedbackPreview))),y(dt,(t(s),p(()=>t(s).shared))),y(Jt,`${t(D),p(()=>t(D).shared.comments)??""} comments · ${t(D),p(()=>t(D).shared.codeRanges)??""}\n code ranges · ${t(D),p(()=>t(D).shared.imageCrops)??""} image crops ·\n ${t(D),p(()=>t(D).shared.evidenceReferences)??""} evidence refs`),y(kt,(t(s),p(()=>t(s).notShared))),y(Mt,pt),y(Cr,(t(s),p(()=>t(s).delivery))),y(Gr,`${t(D),p(()=>t(D).destination.deliveryMode)??""} · ${t(D),p(()=>t(D).contextBytes)??""} bytes ·\n ${t(D),p(()=>t(D).redactionCount)??""} redactions`),Qr.disabled=t(Ia),y(Sn,(t(te),t(s),p(()=>t(te)?t(s).returnConversation:t(s).prepareRequest)))},[()=>(t(D),p(()=>t(D).excluded.join(" · ")))]),G("click",Qr,()=>{Yd()}),$(ce,ne)};J(xe,ce=>{t(D)&&ce(ze)})}S(()=>{V(z,"aria-label",(t(s),p(()=>t(s).selectedItems))),y(ot,`${t(s),p(()=>t(s).selectedItems)??""}: ${t(u)??""}`)}),$(Q,z)};J(pp,Q=>{t(T)&&(t(u)>0||t(e)>0||t(D))&&Q(cp)})}S((Q,z,pe)=>{V(F,"data-status",(t(o),p(()=>t(o).status))),y(Dr,(t(o),p(()=>t(o).status))),y(Ws,Q),y(pu,(t(o),p(()=>t(o).reportId))),y(hu,(t(s),p(()=>t(s).queue))),y(fu,(t(s),p(()=>t(s).search))),V(Ji,"aria-label",(t(s),p(()=>t(s).queue))),y(gu,`Brief / ${t(o),p(()=>t(o).status)??""}`),y(yu,(t(s),p(()=>t(s).summary))),V(ao,"data-status",(t(o),p(()=>t(o).status))),y(wu,(t(s),p(()=>t(s).evidencePosture))),y(Pu,(t(o),p(()=>t(o).summary.statement))),y(ku,(t(s),p(()=>t(s).reviewerRoute))),y($u,(t(s),p(()=>t(s).files))),y(Ru,(t(o),p(()=>t(o).summary.filesChanged))),y(Su,(t(s),p(()=>t(s).additions))),y(Nu,`+${t(o),p(()=>t(o).summary.additions)??""}`),y(Cu,(t(s),p(()=>t(s).deletions))),y(ju,`−${t(o),p(()=>t(o).summary.deletions)??""}`),y(Ou,(t(s),p(()=>t(s).changes))),y(zu,(t(o),p(()=>t(o).changes.length))),y(Vu,(t(s),p(()=>t(s).lowSignal))),y(Fu,z),y(Hu,(t(s),p(()=>t(s).coverage))),y(Zu,pe),y(Ku,(t(s),p(()=>t(s).planned))),y(Yu,(t(o),p(()=>t(o).coverage.planned))),y(Gu,(t(s),p(()=>t(s).captured))),y(Xu,(t(o),p(()=>t(o).coverage.succeeded))),y(tp,(t(s),p(()=>t(s).failed))),y(ap,(t(o),p(()=>t(o).coverage.failed))),y(np,(t(s),p(()=>t(s).inventory)))},[()=>(t(o),t(c),p(()=>$n(t(o),t(c)))),()=>(t(o),p(()=>t(o).files.filter(Q=>Q.lowSignal).length)),()=>(t(o),t(c),p(()=>$n(t(o),t(c))))]),G("click",B,Q=>{Q.preventDefault(),Oi()}),en(Ki,()=>t(f),Q=>A(f,Q)),$(m,x)},du=m=>{var x=qm(),N=_(x,!0);S(()=>{V(x,"role",t(h)?"alert":"status"),y(N,(t(h),p(()=>t(h)||i.en.loading)))}),$(m,x)};J(ou,m=>{t(o)?m(lu):m(du,-1)})}$(r,Bi),Vl()}gh(["click","change"]);const Il=document.querySelector("[data-utsuri-app]");Il&&$h(Rm,{target:Il});\n';
|
|
220032
|
-
var reportUiCss = ':root{color-scheme:light dark;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Hiragino Sans,Yu Gothic UI,sans-serif;font-size:16px;--paper: #f2efe7;--paper-raised: #fffdf7;--ink: #171a1f;--ink-muted: #61656d;--line: #c9c4b8;--line-strong: #7c7b77;--rail: #e4e0d6;--blue: #1558d6;--blue-soft: #dce7ff;--coral: #b73f2d;--coral-soft: #fae1db;--green: #176948;--green-soft: #d8eee3;--amber: #805400;--amber-soft: #f5e7bf;--focus: #0066ff;--code-bg: #20242b;--code-text: #f5f2e9;--code-muted: #a9afb9;--addition: #123d2e;--deletion: #4d2524;--word-addition: #297553;--word-deletion: #9c4139;--radius: .25rem;--shadow: 0 1px 0 rgb(23 26 31 / 8%), 0 12px 34px rgb(23 26 31 / 7%)}@media(prefers-color-scheme:dark){:root{--paper: #15171a;--paper-raised: #1e2126;--ink: #f4f0e7;--ink-muted: #b3b5ba;--line: #3b3f45;--line-strong: #71757c;--rail: #1a1d21;--blue: #80a9ff;--blue-soft: #25395f;--coral: #ff9b89;--coral-soft: #542e2a;--green: #76d4ac;--green-soft: #1c4637;--amber: #f0c66c;--amber-soft: #4b3b1c;--focus: #8ab4ff;--code-bg: #0c0e11}}*{box-sizing:border-box}html{background:var(--paper);color:var(--ink);scroll-behavior:smooth}body{margin:0;min-width:320px;background-image:linear-gradient(rgb(23 26 31 / 3%) 1px,transparent 1px);background-size:100% 2rem}button,input,select{font:inherit}button,a,summary{-webkit-tap-highlight-color:transparent}a{color:inherit}:focus-visible{outline:3px solid var(--focus);outline-offset:3px}.skip-link{position:fixed;inset:0 auto auto 0;z-index:100;transform:translateY(-120%);padding:.75rem 1rem;background:var(--paper-raised);color:var(--ink)}.skip-link:focus{transform:translateY(0)}.report-shell{display:grid;grid-template-columns:clamp(17rem,23vw,22rem) minmax(0,1fr);grid-template-rows:4.5rem minmax(calc(100vh - 4.5rem),auto);min-height:100vh}.report-header{position:sticky;top:0;z-index:20;grid-column:1 / -1;display:grid;grid-template-columns:clamp(17rem,23vw,22rem) 1fr auto;align-items:stretch;min-height:4.5rem;border-bottom:1px solid var(--line-strong);background:color-mix(in srgb,var(--paper-raised) 94%,transparent);-webkit-backdrop-filter:blur(14px);backdrop-filter:blur(14px)}.wordmark{display:flex;align-items:center;gap:.8rem;padding:0 1.25rem;border-right:1px solid var(--line-strong);text-decoration:none}.wordmark>span{display:grid;width:2rem;height:2rem;place-items:center;border-radius:50%;background:var(--ink);color:var(--paper-raised);font-size:.68rem;font-weight:800;letter-spacing:-.08em}.wordmark strong{font-size:1.05rem;letter-spacing:-.025em}.report-state{display:flex;align-items:center;gap:.65rem;padding:0 1.5rem;font-size:.78rem;font-weight:760;letter-spacing:.075em}.report-state small{color:var(--ink-muted);font-size:.75rem;font-weight:500;letter-spacing:0}.state-mark{width:.72rem;height:.72rem;border:2px solid currentColor;transform:rotate(45deg)}.report-state[data-status=UNCOVERED],.report-state[data-status=INCOMPLETE]{color:var(--amber)}.report-state[data-status=REGRESSION]{color:var(--coral)}.report-state[data-status=PASS]{color:var(--green)}.report-state[data-status=CHANGED]{color:var(--blue)}.report-id{align-self:center;margin:0;padding:0 1.25rem;color:var(--ink-muted);font:.7rem/1.2 ui-monospace,SFMono-Regular,Menlo,monospace}.review-rail{position:sticky;top:4.5rem;align-self:start;height:calc(100vh - 4.5rem);overflow-y:auto;border-right:1px solid var(--line-strong);background:color-mix(in srgb,var(--rail) 96%,transparent)}.rail-heading,.queue-search,.queue-section h3{padding-right:1.25rem;padding-left:1.25rem}.rail-heading{padding-top:1.6rem;padding-bottom:1rem}.kicker{margin:0 0 .55rem;color:var(--ink-muted);font-size:.69rem;font-weight:750;letter-spacing:.12em;text-transform:uppercase}.rail-heading h2,.decision-summary h1,.focused-change h2,.section-heading h3{margin:0;letter-spacing:-.04em}.rail-heading h2{font-size:1.55rem}.queue-search{display:grid;gap:.42rem;padding-bottom:1.4rem;color:var(--ink-muted);font-size:.72rem;font-weight:650}.queue-search input{width:100%;border:1px solid var(--line-strong);border-radius:var(--radius);padding:.72rem .8rem;background:var(--paper-raised);color:var(--ink)}.queue-section{border-top:1px solid var(--line)}.queue-section h3{display:flex;align-items:center;justify-content:space-between;margin:0;padding-top:.75rem;padding-bottom:.75rem;color:var(--ink-muted);font-size:.7rem;letter-spacing:.055em;text-transform:uppercase}.count{min-width:1.7rem;border:1px solid var(--line);border-radius:1rem;padding:.12rem .38rem;text-align:center}.queue-section ol{margin:0;padding:0;list-style:none}.queue-section a{display:grid;grid-template-columns:2rem minmax(0,1fr);gap:.65rem;padding:.9rem 1.25rem;border-top:1px solid color-mix(in srgb,var(--line) 70%,transparent);text-decoration:none}.queue-section a:hover,.queue-section a[aria-current=page]{background:var(--paper-raised)}.queue-section a[aria-current=page]{box-shadow:inset .24rem 0 var(--blue)}.queue-index{padding-top:.08rem;color:var(--ink-muted);font:.68rem/1.2 ui-monospace,SFMono-Regular,Menlo,monospace}.queue-copy{min-width:0}.queue-copy strong{display:block;overflow:hidden;font-size:.84rem;line-height:1.35;text-overflow:ellipsis}.queue-copy>span:not(.badges){color:var(--ink-muted);font-size:.7rem}.badges{display:flex;flex-wrap:wrap;gap:.35rem;margin-top:.48rem}.badges span,.change-badges span{border:1px solid var(--line);border-radius:99px;padding:.16rem .45rem;color:var(--ink-muted);font-size:.63rem;font-weight:700}main{min-width:0;padding:clamp(1.25rem,3vw,3rem)}.decision-summary,.focused-change{width:min(100%,90rem);margin:0 auto;border:1px solid var(--line-strong);background:var(--paper-raised);box-shadow:var(--shadow)}.decision-summary{display:grid;grid-template-columns:minmax(0,1.45fr) minmax(18rem,.55fr);gap:clamp(1.5rem,4vw,4rem);padding:clamp(1.4rem,3vw,2.6rem)}.decision-summary h1{font-size:clamp(1.9rem,4vw,3.6rem);line-height:.98}.review-overview{max-width:54rem;margin:1.4rem 0 0;font-size:clamp(1.25rem,2.25vw,2rem);font-weight:680;letter-spacing:-.028em;line-height:1.34}.evidence-posture{max-width:48rem;margin-top:2rem;border-left:.24rem solid var(--amber);padding:.15rem 0 .15rem 1rem}.evidence-posture .kicker{margin-bottom:.3rem}.decision-statement{margin:0;color:var(--ink-muted);font-size:.9rem;line-height:1.55}.review-route{position:relative;display:flex;min-width:0;flex-direction:column;align-items:flex-start;overflow:hidden;border-left:1px solid var(--line-strong);padding-left:clamp(1.25rem,3vw,2.4rem)}.review-route:before{position:absolute;top:-1.25rem;right:-.3rem;content:"01";color:color-mix(in srgb,var(--ink) 8%,transparent);font:800 clamp(5rem,9vw,8rem)/1 ui-monospace,SFMono-Regular,Menlo,monospace;letter-spacing:-.12em;pointer-events:none}.review-route h2,.review-route h3,.review-route>p{position:relative;margin:0}.review-route h2{font-size:.9rem;letter-spacing:.06em;text-transform:uppercase}.review-route h3{max-width:min(100%,28rem);overflow-wrap:anywhere;margin-top:1.25rem;font-size:clamp(1.25rem,2vw,1.75rem);letter-spacing:-.035em;line-height:1.12}.review-route>p:not(.kicker,.route-status){max-width:30rem;margin-top:.8rem;color:var(--ink-muted);font-size:.82rem;line-height:1.5}.route-status{margin-top:1.5rem!important;border:1px solid currentColor;padding:.28rem .48rem;color:var(--amber);font-size:.65rem;font-weight:760;letter-spacing:.065em;text-transform:uppercase}.route-status[data-queue=action-required]{color:var(--coral)}.route-status[data-queue=no-issue]{color:var(--green)}.review-route button{position:relative;width:100%;margin-top:auto;border:0;border-top:1px solid var(--line-strong);border-bottom:1px solid var(--line-strong);padding:.8rem 0;background:transparent;color:var(--ink);font-size:.78rem;font-weight:760;text-align:left;cursor:pointer}.review-route button span{float:right;transition:transform .14s ease}.review-route button:hover span{transform:translate(.3rem)}.metrics{grid-column:1 / -1;display:grid;grid-template-columns:repeat(5,minmax(0,1fr));align-self:end;margin:0;border-top:1px solid var(--line-strong);border-bottom:1px solid var(--line-strong)}.metrics div{min-width:0;padding:.85rem .65rem;border-right:1px solid var(--line)}.metrics div:last-child{border-right:0}.metrics dt{min-height:2.2em;color:var(--ink-muted);font-size:.65rem}.metrics dd{margin:.35rem 0 0;font:700 clamp(1.25rem,2vw,1.8rem)/1 ui-monospace,SFMono-Regular,Menlo,monospace}.positive{color:var(--green)}.negative{color:var(--coral)}.review-map{grid-column:1 / -1;border-top:1px solid var(--line);padding-top:1.15rem}.review-map header{display:flex;align-items:end;justify-content:space-between;gap:1rem;padding-bottom:.9rem}.review-map h2,.review-map header p{margin:0}.review-map h2{font-size:clamp(1.15rem,2vw,1.55rem);letter-spacing:-.03em}.review-map header>p{color:var(--ink-muted);font:.68rem/1.2 ui-monospace,SFMono-Regular,Menlo,monospace}.review-map ol{margin:0;border-top:1px solid var(--line-strong);padding:0;list-style:none}.review-map li{animation:brief-row-enter .32s ease-out both}.review-map li:nth-child(2){animation-delay:45ms}.review-map li:nth-child(3){animation-delay:90ms}.review-map li:nth-child(4){animation-delay:135ms}.review-map li:nth-child(5){animation-delay:.18s}.review-map button{display:grid;width:100%;grid-template-columns:2.5rem minmax(0,1fr) auto;gap:1rem;align-items:center;border:0;border-bottom:1px solid var(--line);padding:1rem .75rem;background:transparent;color:var(--ink);text-align:left;cursor:pointer}.review-map button:hover{background:color-mix(in srgb,var(--amber-soft) 58%,transparent)}.review-map li[data-queue=action-required] button{box-shadow:inset .22rem 0 var(--coral)}.review-map li[data-queue=needs-confirmation] button{box-shadow:inset .22rem 0 var(--amber)}.review-map li[data-queue=no-issue] button{box-shadow:inset .22rem 0 var(--green)}.map-index{color:var(--ink-muted);font:.7rem/1 ui-monospace,SFMono-Regular,Menlo,monospace}.map-copy{min-width:0}.map-copy strong,.map-copy>span{display:block}.map-copy strong{overflow-wrap:anywhere;font-size:.92rem;line-height:1.3}.map-copy>span{overflow:hidden;margin-top:.25rem;color:var(--ink-muted);font-size:.74rem;line-height:1.4;text-overflow:ellipsis;white-space:nowrap}.map-meta{display:flex;gap:.4rem;color:var(--ink-muted);font-size:.68rem;white-space:nowrap}.map-remainder{border-bottom:1px solid var(--line);padding:.7rem .75rem .7rem 3.25rem;color:var(--ink-muted);font-size:.72rem}@keyframes brief-row-enter{0%{transform:translateY(.4rem)}to{transform:translateY(0)}}.file-inventory{grid-column:1 / -1;border-top:1px solid var(--line);padding-top:1rem}.coverage-overview{grid-column:1 / -1;display:grid;grid-template-columns:minmax(0,1fr) auto;gap:2rem;align-items:end;border-top:1px solid var(--line);padding-top:1rem}.coverage-overview h2,.coverage-overview p{margin:0}.coverage-overview h2{font-size:1rem}.coverage-overview p{margin-top:.35rem;color:var(--ink-muted);font-size:.82rem}.coverage-overview dl{display:grid;grid-template-columns:repeat(3,minmax(6rem,1fr));margin:0}.coverage-overview dl div{border-left:1px solid var(--line);padding-left:1rem}.coverage-overview dt{color:var(--ink-muted);font-size:.65rem}.coverage-overview dd{margin:.25rem 0 0;font:700 1.2rem/1 ui-monospace,SFMono-Regular,Menlo,monospace}.file-inventory summary,.more-evidence summary{cursor:pointer;font-size:.78rem;font-weight:720}.file-inventory ul{display:grid;gap:0;margin:.8rem 0 0;padding:0;list-style:none}.file-inventory li{display:grid;grid-template-columns:6rem minmax(0,1fr) auto auto;gap:1rem;padding:.48rem 0;border-top:1px solid var(--line);color:var(--ink-muted);font-size:.72rem}.file-inventory code{overflow-wrap:anywhere;color:var(--ink)}.file-status{font-weight:750;text-transform:uppercase}.focused-change{margin-top:1.4rem;padding:clamp(1.4rem,3vw,2.6rem)}.back-link,.anchor-button{border:0;padding:0;background:transparent;color:var(--blue);cursor:pointer;font-size:.75rem;font-weight:720}.change-header{display:flex;align-items:end;justify-content:space-between;gap:2rem;margin-top:1.8rem;padding-bottom:1.5rem;border-bottom:2px solid var(--ink)}.change-header h2{max-width:50rem;overflow-wrap:anywhere;font-size:clamp(1.8rem,4vw,3.25rem);line-height:1.04}.change-header>div,.finding-list li,.finding-list article{min-width:0}.change-badges{display:flex;flex-wrap:wrap;justify-content:end;gap:.4rem}.change-badges span[data-queue=action-required]{border-color:var(--coral);background:var(--coral-soft);color:var(--coral)}.change-badges span[data-queue=needs-confirmation]{border-color:var(--amber);background:var(--amber-soft);color:var(--amber)}.change-badges span[data-queue=no-issue]{border-color:var(--green);background:var(--green-soft);color:var(--green)}.review-workspace{margin-top:1rem;border:1px solid var(--line-strong);border-left:.35rem solid var(--blue);padding:1rem 1.1rem;background:linear-gradient(90deg,color-mix(in srgb,var(--blue-soft) 48%,transparent),transparent 54%),var(--paper)}.review-workspace-heading{display:flex;align-items:end;justify-content:space-between;gap:1rem}.review-workspace h3,.review-workspace p{margin:0}.review-workspace h3{font-size:1.05rem}.review-workspace-heading p:not(.kicker),.local-only-note,.review-message{margin-top:.35rem;color:var(--ink-muted);font-size:.74rem}.review-transfer-actions,.review-controls,.comment-actions{display:flex;flex-wrap:wrap;gap:.45rem;align-items:center}.review-controls{margin-top:.9rem;border-top:1px solid var(--line);padding-top:.9rem}.review-transfer-actions button,.review-controls button,.comment-actions button,.thread-list button,.feedback-dock button,.inline-comment-action{min-height:2.25rem;border:1px solid var(--line-strong);border-radius:var(--radius);padding:.45rem .7rem;background:var(--paper-raised);color:var(--ink);cursor:pointer;font-size:.7rem;font-weight:720}.review-transfer-actions button:disabled,.review-controls button:disabled,.comment-actions button:disabled,.thread-list button:disabled,.feedback-dock button:disabled{cursor:not-allowed;opacity:.55}.review-controls>label:not(.viewed-control),.comment-composer label{display:grid;gap:.28rem;color:var(--ink-muted);font-size:.68rem;font-weight:700}.review-controls select,.comment-composer select,.comment-composer textarea{border:1px solid var(--line-strong);border-radius:var(--radius);padding:.5rem .65rem;background:var(--paper-raised);color:var(--ink)}.viewed-control{display:inline-flex;gap:.4rem;align-items:center;min-height:2.25rem;color:var(--ink-muted);font-size:.7rem;font-weight:720}.viewed-control input{width:1rem;height:1rem;accent-color:var(--blue)}.compact-control{min-height:auto;justify-self:end}.dark-control{color:#d8e3ff}.visual-viewed-control{align-self:end}.visually-hidden{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;clip-path:inset(50%)}.review-message{border-left:.2rem solid var(--amber);padding:.45rem .6rem;background:var(--amber-soft);color:var(--amber)}.explanation-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));border-bottom:1px solid var(--line-strong)}.explanation-grid section{min-width:0;padding:1.5rem 1.5rem 1.5rem 0;border-bottom:1px solid var(--line)}.explanation-grid section:nth-child(2n){padding-right:0;padding-left:1.5rem;border-left:1px solid var(--line)}.explanation-grid h3{margin:0 0 .7rem;font-size:.74rem;letter-spacing:.08em;text-transform:uppercase}.explanation-grid p,.explanation-grid li{font-size:.9rem;line-height:1.62}.explanation-grid ul{margin:0;padding-left:1.1rem}.technical{color:var(--ink-muted)}.risk-block{box-shadow:inset .22rem 0 var(--coral);padding-left:1.2rem!important}.gap-block{background:var(--amber-soft);box-shadow:inset .22rem 0 var(--amber)}.gap-block li{display:flex;gap:.6rem;align-items:start;justify-content:space-between}.inline-comment-action{min-height:1.7rem;flex:none;padding:.18rem .45rem;background:transparent}.interpretation-section,.visual-evidence-section{padding-top:2.2rem}.interpretation-section>.section-heading{margin-bottom:0}.visual-evidence-section{border-top:2px solid var(--ink)}.visual-heading p:not(.kicker){max-width:42rem;margin:.5rem 0 0;color:var(--ink-muted);font-size:.82rem}.visual-heading h4{margin:.35rem 0 0;font-size:1rem}.visual-selectors{display:flex;flex-wrap:wrap;gap:.8rem;align-items:end;margin-bottom:.8rem}.visual-selectors label,.wipe-control{display:grid;gap:.35rem;min-width:min(100%,13rem);color:var(--ink-muted);font-size:.7rem;font-weight:680}.visual-selectors select,.visual-selectors input,.wipe-control input{min-height:2.5rem}.visual-selectors select{max-width:24rem;border:1px solid var(--line-strong);border-radius:var(--radius);padding:.5rem .65rem;background:var(--paper-raised);color:var(--ink)}.visual-slider{margin-left:auto}.visual-mode-control{display:flex;flex-wrap:wrap;gap:.35rem;margin-bottom:1rem}.visual-mode-control button,.region-list button,.finding-list button,.hunk-actions button{min-height:2rem;border:1px solid var(--line-strong);border-radius:var(--radius);padding:.42rem .65rem;background:transparent;color:var(--ink);cursor:pointer;font-size:.7rem;font-weight:700}.visual-mode-control button[aria-pressed=true]{background:var(--ink);color:var(--paper-raised)}.visual-mode-control button:disabled{cursor:not-allowed;opacity:.55}.persistent-error,.verification-gap{display:flex;gap:.7rem;align-items:baseline;margin:0 0 1rem;border-left:.3rem solid var(--amber);padding:.85rem 1rem;background:var(--amber-soft);color:var(--amber);font-size:.8rem}.persistent-error strong,.verification-gap strong{letter-spacing:.08em}.visual-metrics{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));margin:0 0 .8rem;border:1px solid var(--line)}.visual-metrics div{padding:.65rem .8rem;border-right:1px solid var(--line)}.visual-metrics div:last-child{border-right:0}.visual-metrics dt{color:var(--ink-muted);font-size:.64rem}.visual-metrics dd{margin:.25rem 0 0;font:700 .82rem/1.2 ui-monospace,SFMono-Regular,Menlo,monospace}.visual-panes{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.8rem}.visual-panes figure,.single-visual{min-width:0;margin:0}.visual-panes figcaption,.single-visual figcaption{border:1px solid var(--line-strong);border-bottom:0;padding:.5rem .7rem;background:var(--rail);color:var(--ink);font-size:.7rem;font-weight:720}.visual-scroll{overflow:auto;max-height:32rem;min-height:12rem;border:1px solid var(--line-strong);background:linear-gradient(45deg,color-mix(in srgb,var(--line) 25%,transparent) 25%,transparent 25%) 0 0 / 1rem 1rem,linear-gradient(45deg,transparent 75%,color-mix(in srgb,var(--line) 25%,transparent) 75%) 0 0 / 1rem 1rem,var(--paper-raised);overscroll-behavior:contain}.image-stage{position:relative;min-width:20rem}.image-stage img{display:block;width:100%;height:auto}.wipe-after,.blink-after{position:absolute;inset:0}.blink-after{opacity:0}.blink-after.blink-running{animation:utsuri-blink 1s steps(1,end) infinite}@keyframes utsuri-blink{0%,49%{opacity:0}50%,to{opacity:1}}.pixel-diff-view .visual-scroll{background-color:#16191e}.region-marker{position:absolute;display:grid;min-width:1.5rem;min-height:1.5rem;place-items:center;border:2px solid #fff;border-radius:0;padding:0;background:#b73f2d4d;box-shadow:0 0 0 2px var(--coral);color:#fff;font-size:.65rem;font-weight:800;pointer-events:none}.region-marker.active-region{border-width:4px;background:#b73f2d7f}.visual-comment-pin{position:absolute;z-index:4;display:grid;width:2rem;height:2rem;place-items:center;transform:translate(-50%,-50%);border:2px solid #fff;border-radius:50%;padding:0;background:var(--blue);box-shadow:0 0 0 3px #0e1117a6;color:#fff;font-size:.72rem;font-weight:820}.visual-comment-pin:hover{background:var(--coral)}.wipe-control{width:min(100%,28rem);margin:0 0 .75rem}.region-list,.finding-list{margin-top:1rem;border-top:1px solid var(--line);padding-top:1rem}.region-list h4,.finding-list h4{margin:0 0 .65rem;font-size:.82rem}.region-list ol,.finding-list ol{display:grid;gap:.5rem;margin:0;padding:0;list-style:none}.region-list ol{grid-template-columns:repeat(auto-fit,minmax(14rem,1fr))}.region-list button{width:100%;text-align:left}.region-actions{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:.35rem}.region-list button[aria-current=true]{border-color:var(--coral);box-shadow:inset .22rem 0 var(--coral)}.finding-list article{border:1px solid var(--line);padding:1rem;background:color-mix(in srgb,var(--paper) 55%,var(--paper-raised))}.finding-list article.active-finding{border-color:var(--blue)}.finding-list h5{margin:.65rem 0 .35rem;overflow-wrap:anywhere;font-size:.95rem}.finding-list p{margin:0 0 .8rem;color:var(--ink-muted);font-size:.82rem;line-height:1.5}.finding-badges{display:flex;flex-wrap:wrap;gap:.35rem}.finding-badges span{border:1px solid var(--line-strong);border-radius:99px;padding:.15rem .45rem;font-size:.63rem;font-weight:720;text-transform:uppercase}.hunk-actions{display:flex;flex-shrink:0;gap:.5rem;align-items:center}.hunk-actions button{border-color:#707987;color:#d8e3ff}.evidence-section,.diff-section{padding-top:2.2rem}.section-heading{display:flex;align-items:end;justify-content:space-between;gap:1.5rem;margin-bottom:1rem}.section-heading h3{font-size:clamp(1.35rem,2.5vw,2rem)}.evidence-list{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:.75rem;margin:0;padding:0;list-style:none}.evidence-list li{min-width:0;border:1px solid var(--line);padding:1rem;background:color-mix(in srgb,var(--blue-soft) 35%,transparent)}.evidence-list span{display:block;color:var(--blue);font-size:.64rem;font-weight:780;letter-spacing:.08em;text-transform:uppercase}.evidence-list strong{display:block;overflow-wrap:anywhere;margin-top:.55rem;font:.77rem/1.4 ui-monospace,SFMono-Regular,Menlo,monospace}.evidence-list p{margin:.55rem 0 0;color:var(--ink-muted);font-size:.78rem;line-height:1.45}.more-evidence{margin-top:.8rem}.segmented-control{display:inline-flex;border:1px solid var(--line-strong);border-radius:var(--radius);overflow:hidden}.segmented-control button{border:0;border-right:1px solid var(--line-strong);padding:.48rem .72rem;background:transparent;color:var(--ink-muted);cursor:pointer;font-size:.7rem;font-weight:700}.segmented-control button:last-child{border-right:0}.segmented-control button[aria-pressed=true]{background:var(--ink);color:var(--paper-raised)}.hunk{overflow:hidden;margin-top:1rem;border:1px solid #555c66;border-radius:var(--radius);background:var(--code-bg);color:var(--code-text)}.hunk.active-hunk{box-shadow:0 0 0 4px var(--focus)}.hunk>header{display:flex;align-items:center;justify-content:space-between;gap:1rem;padding:.75rem 1rem;border-bottom:1px solid #555c66;background:#292e36}.hunk>header p,.hunk>header h4,.hunk>header h3{margin:0;overflow-wrap:anywhere;font:.72rem/1.45 ui-monospace,SFMono-Regular,Menlo,monospace}.hunk>header p{color:#d6d9de;font-weight:760}.hunk>header h4{color:var(--code-muted);font-weight:500}.anchor-button{min-width:2rem;min-height:2rem;color:#9bbaff;font:700 1rem/1 ui-monospace,SFMono-Regular,Menlo,monospace}.hunk-explanation{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));margin:0;border-bottom:1px solid #555c66;background:#20262e}.hunk-explanation div{padding:.85rem 1rem .95rem}.hunk-explanation div+div{border-left:1px solid #555c66}.hunk-explanation dt{margin-bottom:.3rem;color:#a9bce9;font-size:.68rem;font-weight:800;letter-spacing:.08em;text-transform:uppercase}.hunk-explanation dd{margin:0;color:#f2f5fb;font-size:.84rem;line-height:1.55;overflow-wrap:anywhere}.diff-table{overflow-x:auto;font:.76rem/1.55 ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;font-variant-ligatures:none}.diff-line{display:grid;grid-template-columns:3.4rem 3.4rem 1.4rem minmax(max-content,1fr) 2.2rem;min-height:1.55rem}.diff-line.addition{background:var(--addition)}.diff-line.deletion{background:var(--deletion)}.diff-line.no-newline{color:var(--code-muted);font-style:italic}.line-number{padding:0 .65rem;border-right:1px solid rgb(255 255 255 / 8%);color:var(--code-muted);text-align:right;-webkit-user-select:none;user-select:none}.line-sign{color:var(--code-muted);text-align:center;-webkit-user-select:none;user-select:none}.diff-line code{padding:0 .75rem 0 0;white-space:pre}.word-change{border-radius:.12rem;background:var(--word-addition);box-shadow:0 0 0 .08rem var(--word-addition)}.deletion .word-change{background:var(--word-deletion);box-shadow:0 0 0 .08rem var(--word-deletion)}.context-fold{width:100%;border:0;border-top:1px solid #3a4049;border-bottom:1px solid #3a4049;padding:.4rem;background:#252a31;color:#a9c0ef;cursor:pointer;font:inherit;text-align:center}.split-row{display:grid;grid-template-columns:repeat(2,minmax(max-content,1fr)) 2.2rem;border-bottom:1px solid rgb(255 255 255 / 5%)}.split-row .diff-line{grid-template-columns:3.4rem 1.4rem minmax(max-content,1fr)}.split-row .diff-line:first-child{border-right:1px solid #555c66}.empty-side{background:#171a1f!important}.line-comment{position:sticky;right:0;min-width:2.2rem;border:0;border-left:1px solid rgb(255 255 255 / 14%);background:#292e36;color:#b8ccff;cursor:pointer;font:700 .82rem/1 ui-monospace,SFMono-Regular,Menlo,monospace}.line-comment:hover{background:#384252;color:#fff}.review-comments{margin-top:2.2rem;border-top:2px solid var(--ink);padding-top:2.2rem}.comment-composer{display:grid;grid-template-columns:minmax(0,1fr) 11rem;gap:.9rem 1rem;margin-bottom:1rem;border:1px solid var(--line-strong);border-left:.35rem solid var(--blue);padding:1rem;background:var(--paper)}.comment-composer code{overflow-wrap:anywhere;font-size:.74rem}.comment-body,.agent-attention-control,.comment-composer>p,.comment-actions{grid-column:1 / -1}.comment-composer textarea{width:100%;resize:vertical;line-height:1.5}.comment-composer>p,.empty-comments{margin:0;color:var(--ink-muted);font-size:.75rem}.agent-attention-control{grid-template-columns:1.15rem minmax(0,1fr);align-items:center;border:1px solid var(--line);border-radius:var(--radius);padding:.65rem .75rem;background:var(--blue-soft);color:var(--ink);font-size:.78rem;font-weight:720}.agent-attention-control small{grid-column:2;color:var(--ink-muted);font-size:.68rem;font-weight:500}.compact-attention{display:inline-grid;margin-top:.4rem;padding:.45rem .55rem}.attention-state{color:var(--blue);font-size:.72rem!important;font-weight:720}.feedback-dock{position:fixed;z-index:20;right:1rem;bottom:1rem;width:min(44rem,calc(100vw - 22rem));max-height:min(70vh,42rem);overflow:auto;border:1px solid var(--line-strong);border-top:.35rem solid var(--blue);border-radius:var(--radius);padding:.9rem 1rem;background:var(--paper-raised);box-shadow:0 1.1rem 3rem #141e2d33}.feedback-dock>header,.feedback-dock>header>div,.feedback-actions{display:flex;flex-wrap:wrap;gap:.55rem;align-items:center}.feedback-dock>header{justify-content:space-between}.unread-badge{border-radius:999px;padding:.25rem .5rem;background:var(--blue);color:#fff;font-size:.68rem;font-weight:750}.feedback-preview{margin-top:.8rem;border-top:1px solid var(--line);padding-top:.8rem}.feedback-preview h2,.feedback-preview h3,.feedback-preview p{margin:0}.feedback-preview h2{font-size:.95rem}.feedback-preview ol{display:grid;gap:.35rem;margin:.65rem 0;padding-left:1.3rem}.feedback-preview li{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:.2rem .7rem;font-size:.75rem}.feedback-preview li code{overflow-wrap:anywhere;color:var(--ink-muted);font-size:.66rem}.feedback-preview li span{grid-row:1 / 3;grid-column:2;color:var(--ink-muted);font-size:.64rem;text-transform:uppercase}.feedback-preview-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:.55rem}.feedback-preview-grid section{border:1px solid var(--line);padding:.6rem;background:var(--paper)}.feedback-preview-grid h3{margin-bottom:.25rem;font-size:.7rem}.feedback-preview-grid p,.feedback-warning{color:var(--ink-muted);font-size:.66rem;line-height:1.45}.feedback-warning{margin-top:.55rem!important;color:var(--amber)}.feedback-actions{margin-top:.65rem}.feedback-preview pre{overflow:auto;margin:.65rem 0 0;border:1px solid var(--line);padding:.65rem;background:var(--paper);white-space:pre-wrap;font-size:.67rem}.thread-list{display:grid;gap:.65rem;margin:0;padding:0;list-style:none}.thread-list li{border:1px solid var(--line);padding:.9rem 1rem;background:color-mix(in srgb,var(--paper) 60%,var(--paper-raised))}.thread-list li[data-thread-state=stale],.thread-list li[data-thread-state=orphaned]{border-left:.35rem solid var(--amber);background:var(--amber-soft)}.thread-list header{display:flex;justify-content:space-between;gap:1rem;color:var(--ink-muted);font-size:.66rem;text-transform:uppercase}.thread-list header div{display:flex;gap:.45rem}.thread-list code{display:block;overflow-wrap:anywhere;margin-top:.5rem;color:var(--ink-muted);font-size:.68rem}.thread-list p{margin:.65rem 0;white-space:pre-wrap;font-size:.86rem;line-height:1.55}.hunk-back{margin:.75rem 1rem;color:#9bbaff}.loading{margin:3rem;color:var(--ink-muted)}.empty-focus{min-height:12rem}@media(max-width:1100px){.report-shell{grid-template-columns:16rem minmax(0,1fr)}.report-header{grid-template-columns:16rem 1fr}.report-id{display:none}.decision-summary{grid-template-columns:1fr}.review-route{border-top:1px solid var(--line-strong);border-left:0;padding-top:1.25rem;padding-left:0}.review-route button{margin-top:1.5rem}.coverage-overview{grid-template-columns:1fr}.metrics{grid-template-columns:repeat(5,minmax(5rem,1fr));overflow-x:auto}.evidence-list{grid-template-columns:1fr}}@media(max-width:760px){.report-shell{display:block}.report-header{position:sticky;display:flex;min-height:3.75rem}.wordmark{border-right:0}.report-state{margin-left:auto;padding-right:1rem}.report-state small{display:none}.review-rail{position:static;width:100%;height:auto;max-height:26rem;border-right:0;border-bottom:1px solid var(--line-strong)}main{padding:.8rem}.feedback-dock{right:.5rem;bottom:.5rem;left:.5rem;width:auto}.feedback-preview-grid{grid-template-columns:1fr}.decision-summary,.focused-change{box-shadow:none}.change-header{display:block}.change-badges{justify-content:start;margin-top:1rem}.review-map button{grid-template-columns:2rem minmax(0,1fr);gap:.7rem}.map-meta{grid-column:2;flex-wrap:wrap;white-space:normal}.explanation-grid{display:block}.explanation-grid section,.explanation-grid section:nth-child(2n){padding:1.15rem 0;border-left:0}.risk-block,.gap-block{padding-left:1rem!important}.section-heading{display:block}.coverage-overview dl,.visual-metrics{grid-template-columns:repeat(2,minmax(0,1fr))}.coverage-overview dl div:nth-child(3),.visual-metrics div:nth-child(3){border-top:1px solid var(--line)}.visual-panes{grid-template-columns:1fr}.visual-slider{margin-left:0}.visual-mode-control button{flex:1 1 8rem}.segmented-control{margin-top:.8rem}.hunk-explanation{grid-template-columns:1fr}.hunk-explanation div+div{border-top:1px solid #555c66;border-left:0}.file-inventory li{grid-template-columns:1fr;gap:.25rem}.review-workspace-heading,.comment-composer{display:block}.review-transfer-actions,.review-controls,.comment-composer label,.comment-actions{margin-top:.75rem}.region-actions{grid-template-columns:1fr}}@media(prefers-reduced-motion:reduce){*,*:before,*:after{scroll-behavior:auto!important;transition-duration:.01ms!important;animation-duration:.01ms!important}.blink-after.blink-running{animation:none!important;opacity:1}}@media print{.review-rail,.segmented-control,.back-link,.anchor-button,.visual-mode-control,.visual-selectors,.wipe-control,.region-list,.review-transfer-actions,.review-controls,.comment-composer,.line-comment{display:none!important}.report-shell,.report-header{display:block}main{padding:0}.decision-summary,.focused-change{border:0;box-shadow:none}}\n';
|
|
220254
|
+
var reportUiJavaScript = 'typeof window<"u"&&((window.__svelte??={}).v??=new Set).add("5");let qs=!1,hh=!1;function fh(){qs=!0}fh();const mh=1,vh=2,Ld=4,gh=8,yh=16,_h=1,wh=2,Lt=Symbol("uninitialized"),bh="http://www.w3.org/1999/xhtml",jd=!1;var Ai=Array.isArray,Ph=Array.prototype.indexOf,vi=Array.prototype.includes,Ii=Array.from,Od=Object.defineProperty,bs=Object.getOwnPropertyDescriptor,Td=Object.getOwnPropertyDescriptors,kh=Object.prototype,xh=Array.prototype,jo=Object.getPrototypeOf,pd=Object.isExtensible;const Md=()=>{};function Ah(r){return r()}function bo(r){for(var a=0;a<r.length;a++)r[a]()}function zd(){var r,a,n=new Promise((l,p)=>{r=l,a=p});return{promise:n,resolve:r,reject:a}}const Bt=2,Cn=4,Rs=8,Vd=1<<24,na=16,Wr=32,Na=64,Po=128,Oo=256,Hr=512,qt=1024,Rt=2048,Ur=4096,cr=8192,Mr=16384,Mn=32768,gi=1<<25,Ln=65536,yi=1<<17,Ih=1<<18,zn=1<<19,Fd=1<<20,fa=1<<25,pn=65536,_i=1<<21,En=1<<22,Ba=1<<23,Ha=Symbol("$state"),Dd=Symbol("component"),$h=Symbol(""),Bd=Symbol("attributes"),ko=Symbol("class"),xo=Symbol("style"),Ao=Symbol("text"),ci=Symbol("form reset"),Ss=new class extends Error{name="StaleReactionError";message="The reaction that called `getAbortSignal()` was re-run or destroyed"};function qh(){console.warn("https://svelte.dev/e/derived_inert")}function Rh(){console.warn("https://svelte.dev/e/select_multiple_invalid_value")}function Sh(){console.warn("https://svelte.dev/e/svelte_boundary_reset_noop")}function Hd(r){return r===this.v}function Ud(r,a){return r!=r?a==a:r!==a||r!==null&&typeof r=="object"||typeof r=="function"}function Wd(r){return!Ud(r,this.v)}function Zd(r){throw new Error("https://svelte.dev/e/lifecycle_outside_component")}function Eh(){throw new Error("https://svelte.dev/e/async_derived_orphan")}function Nh(r,a,n){throw new Error("https://svelte.dev/e/each_key_duplicate")}function Ch(r){throw new Error("https://svelte.dev/e/effect_in_teardown")}function Lh(){throw new Error("https://svelte.dev/e/effect_in_unowned_derived")}function jh(r){throw new Error("https://svelte.dev/e/effect_orphan")}function Oh(){throw new Error("https://svelte.dev/e/effect_update_depth_exceeded")}function Th(){throw new Error("https://svelte.dev/e/state_descriptors_fixed")}function Mh(){throw new Error("https://svelte.dev/e/state_prototype_fixed")}function zh(){throw new Error("https://svelte.dev/e/state_unsafe_mutation")}function Vh(){throw new Error("https://svelte.dev/e/svelte_boundary_reset_onerror")}let tt=null;function jn(r){tt=r}function Kd(r,a=!1,n){tt={p:tt,i:!1,c:null,e:null,s:r,x:null,r:he,l:qs&&!a?{s:null,u:null,$:[]}:null}}function Jd(r){var a=tt,n=a.e;if(n!==null){a.e=null;for(var l of n)hu(l)}return a.i=!0,tt=a.p,To(r)}function To(r={}){return Od(r,Dd,{value:!0}),r}function Es(){return!qs||tt!==null&&tt.l===null}let ln=[];function Gd(){var r=ln;ln=[],bo(r)}function Ra(r){if(ln.length===0&&!Ps){var a=ln;queueMicrotask(()=>{a===ln&&Gd()})}ln.push(r)}function Fh(){for(;ln.length>0;)Gd()}const Dh=-7169;function ft(r,a){r.f=r.f&Dh|a}function Mo(r){(r.f&Hr)!==0||r.deps===null?ft(r,qt):ft(r,Ur)}function Yd(r){if(r!==null)for(const a of r)(a.f&Bt)===0||(a.f&pn)===0||(a.f^=pn,Yd(a.deps))}function Qd(r,a,n){(r.f&Rt)!==0?a.add(r):(r.f&Ur)!==0&&n.add(r),Yd(r.deps),ft(r,qt)}let cd=!1;function Bh(){cd||(cd=!0,document.addEventListener("reset",r=>{Promise.resolve().then(()=>{if(!r.defaultPrevented)for(const a of r.target.elements)a[ci]?.()})},{capture:!0}))}function Vn(r){var a=be,n=he;Zr(null),Kr(null);try{return r()}finally{Zr(a),Kr(n)}}function zo(r,a,n,l=n){r.addEventListener(a,()=>Vn(n));const p=r[ci];p?r[ci]=()=>{p(),l(!0)}:r[ci]=()=>l(!0),Bh()}function Hh(r,a,n,l){const p=Es()?$i:Ia;var t=r.filter(P=>!P.settled),s=a.map(p);if(n.length===0&&t.length===0){l(s);return}var o=he,i=Uh(),d=t.length===1?t[0].promise:t.length>1?Promise.all(t.map(P=>P.promise)):null;function m(P){if((o.f&Mr)===0){i();try{l([...s,...P])}catch(N){ha(N,o)}wi()}}var h=Xd();if(n.length===0){d.then(()=>m([])).finally(h);return}function c(){Promise.all(n.map(P=>Wh(P))).then(m).catch(P=>ha(P,o)).finally(h)}d?d.then(()=>{i(),c(),wi()}):c()}function Uh(){var r=he,a=be,n=tt,l=oe;return function(t=!0){Kr(r),Zr(a),jn(n),t&&(r.f&Mr)===0&&(l?.activate(),l?.apply())}}function wi(r=!0){Kr(null),Zr(null),jn(null),r&&oe?.deactivate()}function Xd(){var r=he,a=r.b,n=oe,l=!!a?.is_rendered();return a?.update_pending_count(1,n),n.increment(l,r),()=>{a?.update_pending_count(-1,n),n.decrement(l,r)}}function $i(r){var a=Bt|Rt;return he!==null&&(he.f|=zn),{ctx:tt,deps:null,effects:null,equals:Hd,f:a,fn:r,reactions:null,rv:0,v:Lt,wv:0,parent:he,ac:null}}const ms=Symbol("obsolete");function Wh(r,a,n){let l=he;l===null&&Eh();var p=void 0,t=Ka(Lt),s=!be,o=new Set;return df(()=>{var i=he,d=zd();p=d.promise;try{Promise.resolve(r()).then(d.resolve,P=>{P!==Ss&&d.reject(P)}).finally(wi)}catch(P){d.reject(P),wi()}var m=oe;if(s){if((i.f&Mn)!==0)var h=Xd();if(l.b?.is_rendered())m.async_deriveds.get(i)?.reject(ms);else for(const P of o.values())P.reject(ms);o.add(d),m.async_deriveds.set(i,d)}const c=(P,N=void 0)=>{h?.(),o.delete(d),N!==ms&&(m.activate(),N?(t.f|=Ba,On(t,N)):((t.f&Ba)!==0&&(t.f^=Ba),On(t,P)),m.deactivate())};d.promise.then(c,P=>c(null,P||"unknown"))}),Ho(()=>{for(const i of o)i.reject(ms)}),new Promise(i=>{function d(m){function h(){m===p?i(t):d(p)}m.then(h,h)}d(p)})}function Zh(r){const a=$i(r);return yu(a),a}function Ia(r){const a=$i(r);return a.equals=Wd,a}function Kh(r){var a=r.effects;if(a!==null){r.effects=null;for(var n=0;n<a.length;n+=1)Pr(a[n])}}function Vo(r){var a,n=he,l=r.parent;if(!Ja&&l!==null&&r.v!==Lt&&(l.f&(Mr|cr))!==0)return qh(),r.v;Kr(l);try{r.f&=~pn,Kh(r),a=Pu(r)}finally{Kr(n)}return a}function eu(r){var a=Vo(r);if(!r.equals(a)&&(r.wv=wu(),(!oe?.is_fork||r.deps===null)&&(oe!==null?(oe.capture(r,a,!0),Io?.capture(r,a,!0)):r.v=a,r.deps===null))){ft(r,qt);return}Ja||(sa!==null?(Bo()||oe?.is_fork)&&sa.set(r,a):Mo(r))}function Jh(r){if(r.effects!==null)for(const a of r.effects)(a.teardown||a.ac)&&(a.teardown?.(),a.ac!==null&&Vn(()=>{a.ac.abort(Ss),a.ac=null}),a.fn!==null&&(a.teardown=Md),As(a,0),Zo(a))}function tu(r){if(r.effects!==null)for(const a of r.effects)a.teardown&&a.fn!==null&&cn(a)}let ro=null,In=null,oe=null,Io=null,sa=null,$o=null,Ps=!1,ao=!1,Sn=null,hi=null;var hd=0;let Gh=1;class Za{id=Gh++;#t=!1;linked=!0;#r=null;#e=null;async_deriveds=new Map;current=new Map;previous=new Map;#o=new Set;#a=new Set;#s=0;#n=new Map;#l=null;#i=[];#m=[];#d=new Set;#u=new Set;#c=new Map;#v=new Set;is_fork=!1;#p=!1;constructor(){In===null?ro=In=this:(In.#e=this,this.#r=In),In=this}#_(){if(this.is_fork)return!0;for(const l of this.#n.keys()){for(var a=l,n=!1;a.parent!==null;){if(this.#c.has(a)){n=!0;break}a=a.parent}if(!n)return!0}return!1}skip_effect(a){this.#c.has(a)||this.#c.set(a,{d:[],m:[]}),this.#v.delete(a)}unskip_effect(a,n=l=>this.schedule(l)){var l=this.#c.get(a);if(l){this.#c.delete(a);for(var p of l.d)ft(p,Rt),n(p);for(p of l.m)ft(p,Ur),n(p)}this.#v.add(a)}#g(){this.#t=!0,hd++>1e3&&(this.#f(),Qh());for(const i of this.#d)this.#u.delete(i),ft(i,Rt),this.schedule(i);for(const i of this.#u)ft(i,Ur),this.schedule(i);const a=this.#i;this.#i=[],this.apply();var n=Sn=[],l=[],p=hi=[];for(const i of a)try{this.#b(i,n,l)}catch(d){throw nu(i),this.#_()||this.discard(),d}if(oe=null,p.length>0){var t=Za.ensure();for(const i of p)t.schedule(i)}if(Sn=null,hi=null,this.#_()){this.#h(l),this.#h(n);for(const[i,d]of this.#c)au(i,d);p.length>0&&oe.#g();return}const s=this.#w();if(s){this.#h(l),this.#h(n),s.#P(this);return}this.#d.clear(),this.#u.clear();for(const i of this.#o)i(this);this.#o.clear(),Io=this,fd(l),fd(n),Io=null,this.#l?.resolve();var o=oe;if(this.#s===0&&(this.#i.length===0||o!==null)&&this.#f(),this.#i.length>0)if(o!==null){const i=o;i.#i.push(...this.#i.filter(d=>!i.#i.includes(d)))}else o=this;o!==null&&(ma.clear(),o.#g())}#b(a,n,l){a.f^=qt;for(var p=a.first;p!==null;){var t=p.f,s=(t&(Wr|Na))!==0,o=s&&(t&qt)!==0,i=o||(t&cr)!==0||this.#c.has(p);if(!i&&p.fn!==null){s?p.f^=qt:(t&Cn)!==0?n.push(p):Fn(p)&&((t&na)!==0&&this.#u.add(p),cn(p));var d=p.first;if(d!==null){p=d;continue}}for(;p!==null;){var m=p.next;if(m!==null){p=m;break}p=p.parent}}}#w(){for(var a=this.#r;a!==null;){if(!a.is_fork){for(const[n,[,l]]of this.current)if(a.current.has(n)&&!l)return a}a=a.#r}return null}#P(a){for(const[l,p]of a.current)!this.previous.has(l)&&a.previous.has(l)&&this.previous.set(l,a.previous.get(l)),this.current.set(l,p);for(const[l,p]of a.async_deriveds){const t=this.async_deriveds.get(l);t&&p.promise.then(t.resolve).catch(t.reject)}a.async_deriveds.clear(),this.transfer_effects(a.#d,a.#u);const n=l=>{var p=l.reactions;if(p!==null&&!((l.f&Bt)!==0&&(l.f&(Rt|Ur))===0))for(const o of p){var t=o.f;if((t&Bt)!==0)n(o);else{var s=o;t&(En|na)&&!this.async_deriveds.has(s)&&(this.#u.delete(s),ft(s,Rt),this.schedule(s))}}};for(const l of this.current.keys())n(l);this.oncommit(()=>a.discard()),a.#f(),oe=this,this.#g()}#h(a){for(var n=0;n<a.length;n+=1)Qd(a[n],this.#d,this.#u)}capture(a,n,l=!1){a.v!==Lt&&!this.previous.has(a)&&this.previous.set(a,a.v),(a.f&Ba)===0&&(this.current.set(a,[n,l]),sa?.set(a,n)),this.is_fork||(a.v=n)}activate(){oe=this}deactivate(){oe=null,sa=null}flush(){try{ao=!0,oe=this,this.#g()}finally{hd=0,$o=null,Sn=null,hi=null,ao=!1,oe=null,sa=null,ma.clear()}}discard(){for(const a of this.#a)a(this);this.#a.clear();for(const a of this.async_deriveds.values())a.reject(ms);this.#f(),this.#l?.resolve()}register_created_effect(a){this.#m.push(a)}#y(){for(let h=ro;h!==null;h=h.#e){var a=h.id<this.id,n=[];for(const[c,[P,N]]of this.current){if(h.current.has(c)){var l=h.current.get(c)[0];if(a&&P!==l)h.current.set(c,[P,N]);else continue}n.push(c)}if(a)for(const[c,P]of this.async_deriveds){const N=h.async_deriveds.get(c);N&&P.promise.then(N.resolve).catch(N.reject)}var p=[...h.current.keys()].filter(c=>!h.current.get(c)[1]);if(!(!h.#t||p.length===0)){var t=p.filter(c=>!this.current.has(c));if(t.length===0)a&&h.discard();else if(n.length>0){if(a)for(const c of this.#v)h.unskip_effect(c,P=>{(P.f&(na|En))!==0?h.schedule(P):h.#h([P])});h.activate();var s=new Set,o=new Map;for(var i of n)ru(i,t,s,o);o=new Map;var d=[...h.current].filter(([c,P])=>{const N=this.current.get(c);return N?N[0]!==P[0]||N[1]!==P[1]:!0}).map(([c])=>c);if(d.length>0)for(const c of this.#m)(c.f&(Mr|cr|yi))===0&&Fo(c,d,o)&&((c.f&(En|na))!==0?(ft(c,Rt),h.schedule(c)):h.#d.add(c));if(h.#i.length>0&&!h.#p){h.apply();for(var m of h.#i)h.#b(m,[],[]);h.#i=[]}h.deactivate()}}}}increment(a,n){if(this.#s+=1,a){let l=this.#n.get(n)??0;this.#n.set(n,l+1)}}decrement(a,n){if(this.#s-=1,a){let l=this.#n.get(n)??0;l===1?this.#n.delete(n):this.#n.set(n,l-1)}this.#p||(this.#p=!0,Ra(()=>{this.#p=!1,this.linked&&this.flush()}))}transfer_effects(a,n){for(const l of a)this.#d.add(l);for(const l of n)this.#u.add(l);a.clear(),n.clear()}oncommit(a){this.#o.add(a)}ondiscard(a){this.#a.add(a)}settled(){return(this.#l??=zd()).promise}static ensure(){if(oe===null){const a=oe=new Za;!ao&&!Ps&&Ra(()=>{a.#t||a.flush()})}return oe}apply(){{sa=null;return}}schedule(a){if($o=a,a.b?.is_pending&&(a.f&(Cn|Rs|Vd))!==0&&(a.f&Mn)===0){a.b.defer_effect(a);return}for(var n=a;n.parent!==null;){n=n.parent;var l=n.f;if(Sn!==null&&n===he&&(be===null||(be.f&Bt)===0))return;if((l&(Na|Wr))!==0){if((l&qt)===0)return;n.f^=qt}}this.#i.push(n)}#f(){if(this.linked){var a=this.#r,n=this.#e;a===null?ro=n:a.#e=n,n===null?In=a:n.#r=a,this.linked=!1}}}function Yh(r){var a=Ps;Ps=!0;try{for(var n;;){if(Fh(),oe===null)return n;oe.flush()}}finally{Ps=a}}function Qh(){try{Oh()}catch(r){ha(r,$o)}}let $a=null;function fd(r){var a=r.length;if(a!==0){for(var n=0;n<a;){var l=r[n++];if((l.f&(Mr|cr))===0&&Fn(l)&&($a=new Set,cn(l),l.deps===null&&l.first===null&&l.nodes===null&&l.teardown===null&&l.ac===null&&mu(l),$a?.size>0)){ma.clear();for(const p of $a){if((p.f&(Mr|cr))!==0)continue;const t=[p];let s=p.parent;for(;s!==null;)$a.has(s)&&($a.delete(s),t.push(s)),s=s.parent;for(let o=t.length-1;o>=0;o--){const i=t[o];(i.f&(Mr|cr))===0&&cn(i)}}$a.clear()}}$a=null}}function ru(r,a,n,l){if(!n.has(r)&&(n.add(r),r.reactions!==null))for(const p of r.reactions){const t=p.f;(t&Bt)!==0?ru(p,a,n,l):(t&(En|na))!==0&&(t&Rt)===0&&Fo(p,a,l)&&(ft(p,Rt),Do(p))}}function Fo(r,a,n){const l=n.get(r);if(l!==void 0)return l;if(r.deps!==null)for(const p of r.deps){if(vi.call(a,p))return!0;if((p.f&Bt)!==0&&Fo(p,a,n))return n.set(p,!0),!0}return n.set(r,!1),!1}function Do(r){oe.schedule(r)}function au(r,a){if(!((r.f&Wr)!==0&&(r.f&qt)!==0)){(r.f&Rt)!==0?a.d.push(r):(r.f&Ur)!==0&&a.m.push(r),ft(r,qt);for(var n=r.first;n!==null;)au(n,a),n=n.next}}function nu(r){ft(r,qt);for(var a=r.first;a!==null;)nu(a),a=a.next}let bi=new Set;const ma=new Map;let su=!1;function Ka(r,a){var n={f:0,v:r,reactions:null,equals:Hd,rv:0,wv:0};return n}function aa(r,a){const n=Ka(r);return yu(n),n}function W(r,a=!1,n=!0){const l=Ka(r);return a||(l.equals=Wd),qs&&n&&tt!==null&&tt.l!==null&&(tt.l.s??=[]).push(l),l}function md(r,a){return A(r,u(()=>e(r))),a}function A(r,a,n=!1){be!==null&&(!ia||(be.f&yi)!==0)&&Es()&&(be.f&(Bt|na|En|yi))!==0&&(va===null||!va.has(r))&&zh();let l=n?vs(a):a;return On(r,l,hi)}function On(r,a,n=null){if(!r.equals(a)){Ja?ma.set(r,a):ma.has(r)||ma.set(r,r.v);var l=Za.ensure();if(l.capture(r,a),(r.f&Bt)!==0){const p=r;(r.f&Rt)!==0&&Vo(p),sa===null&&Mo(p)}r.wv=wu(),iu(r,Rt,n),Es()&&he!==null&&(he.f&qt)!==0&&(he.f&(Wr|Na))===0&&(Fr===null?cf([r]):Fr.push(r)),!l.is_fork&&bi.size>0&&!su&&Xh()}return a}function Xh(){su=!1;for(const r of bi){(r.f&qt)!==0&&ft(r,Ur);let a;try{a=Fn(r)}catch{a=!0}a&&cn(r)}bi.clear()}function Ua(r){A(r,r.v+1)}function iu(r,a,n){var l=r.reactions;if(l!==null)for(var p=Es(),t=l.length,s=0;s<t;s++){var o=l[s],i=o.f;if(!(!p&&o===he)){var d=(i&Rt)===0;if(d&&ft(o,a),(i&yi)!==0)bi.add(o);else if((i&Bt)!==0){var m=o;sa?.delete(m),(i&pn)===0&&(i&Hr&&(he===null||(he.f&_i)===0)&&(o.f|=pn),iu(m,Ur,n))}else if(d){var h=o;(i&na)!==0&&$a!==null&&$a.add(h),n!==null?n.push(h):Do(h)}}}}function vs(r){if(typeof r!="object"||r===null||Ha in r||Dd in r)return r;const a=jo(r);if(a!==kh&&a!==xh)return r;var n=new Map,l=Ai(r),p=aa(0),t=Ea,s=o=>{if(Ea===t)return o();var i=be,d=Ea;Zr(null),_d(t);var m=o();return Zr(i),_d(d),m};return l&&n.set("length",aa(r.length)),new Proxy(r,{defineProperty(o,i,d){(!("value"in d)||d.configurable===!1||d.enumerable===!1||d.writable===!1)&&Th();var m=n.get(i);return m===void 0?s(()=>{var h=aa(d.value);return n.set(i,h),h}):A(m,d.value,!0),!0},deleteProperty(o,i){var d=n.get(i);if(d===void 0){if(i in o){const m=s(()=>aa(Lt));n.set(i,m),Ua(p)}}else A(d,Lt),Ua(p);return!0},get(o,i,d){if(i===Ha)return r;var m=n.get(i),h=i in o;if(m===void 0&&(!h||bs(o,i)?.writable)&&(m=s(()=>{var P=vs(h?o[i]:Lt),N=aa(P);return N}),n.set(i,m)),m!==void 0){var c=e(m);return c===Lt?void 0:c}return Reflect.get(o,i,d)},getOwnPropertyDescriptor(o,i){var d=Reflect.getOwnPropertyDescriptor(o,i);if(d&&"value"in d){var m=n.get(i);m&&(d.value=e(m))}else if(d===void 0){var h=n.get(i),c=h?.v;if(h!==void 0&&c!==Lt)return{enumerable:!0,configurable:!0,value:c,writable:!0}}return d},has(o,i){if(i===Ha)return!0;var d=n.get(i),m=d!==void 0&&d.v!==Lt||Reflect.has(o,i);if(d!==void 0||he!==null&&(!m||bs(o,i)?.writable)){d===void 0&&(d=s(()=>{var c=m?vs(o[i]):Lt,P=aa(c);return P}),n.set(i,d));var h=e(d);if(h===Lt)return!1}return m},set(o,i,d,m){var h=n.get(i),c=i in o;if(l&&i==="length")for(var P=d;P<h.v;P+=1){var N=n.get(P+"");N!==void 0?A(N,Lt):P in o&&(N=s(()=>aa(Lt)),n.set(P+"",N))}if(h===void 0)(!c||bs(o,i)?.writable)&&(h=s(()=>aa(void 0)),A(h,vs(d)),n.set(i,h));else{c=h.v!==Lt;var Z=s(()=>vs(d));A(h,Z)}var E=Reflect.getOwnPropertyDescriptor(o,i);if(E?.set&&E.set.call(m,d),!c){if(l&&typeof i=="string"){var K=n.get("length"),X=Number(i);Number.isInteger(X)&&X>=K.v&&A(K,X+1)}Ua(p)}return!0},ownKeys(o){e(p);var i=Reflect.ownKeys(o).filter(h=>{var c=n.get(h);return c===void 0||c.v!==Lt});for(var[d,m]of n)m.v!==Lt&&!(d in o)&&i.push(d);return i},setPrototypeOf(){Mh()}})}function vd(r){try{if(r!==null&&typeof r=="object"&&Ha in r)return r[Ha]}catch{}return r}function ou(r,a){return Object.is(vd(r),vd(a))}var gd,lu,du,uu;function ef(){if(gd===void 0){gd=window,lu=/Firefox/.test(navigator.userAgent);var r=Element.prototype,a=Node.prototype,n=Text.prototype;du=bs(a,"firstChild").get,uu=bs(a,"nextSibling").get,pd(r)&&(r[ko]=void 0,r[Bd]=null,r[xo]=void 0,r.__e=void 0),pd(n)&&(n[Ao]=void 0)}}function Wa(r=""){return document.createTextNode(r)}function xs(r){return du.call(r)}function Ns(r){return uu.call(r)}function k(r,a){return xs(r)}function yr(r,a=!1){{var n=xs(r);return n instanceof Comment&&n.data===""?Ns(n):n}}function _(r,a=!1){return xs(r)}function v(r,a=1,n=!1){let l=r;for(;a--;)l=Ns(l);return l}function tf(r){r.textContent=""}function pu(){return!1}function rf(r,a,n){return n?document.createElement(r,{is:n}):document.createElement(r)}function af(r){var a=he;if(a===null)return be.f|=Ba,r;if((a.f&Mn)===0&&(a.f&Cn)===0)throw r;ha(r,a)}function ha(r,a){if(!(a!==null&&(a.f&Mr)!==0)){for(;a!==null;){if((a.f&Po)!==0&&(a.f&(Mr|gi))===0){if((a.f&Mn)===0)throw r;try{a.b.error(r);return}catch(n){r=n}}a=a.parent}throw r}}function cu(r){he===null&&(be===null&&jh(),Lh()),Ja&&Ch()}function nf(r,a){var n=a.last;n===null?a.last=a.first=r:(n.next=r,r.prev=n,a.last=r)}function ga(r,a){var n=he;n!==null&&(n.f&cr)!==0&&(r|=cr);var l={ctx:tt,deps:null,nodes:null,f:r|Rt|Hr,first:null,fn:a,last:null,next:null,parent:n,b:n&&n.b,prev:null,teardown:null,wv:0,ac:null};oe?.register_created_effect(l);var p=l;if((r&Cn)!==0)Sn!==null?Sn.push(l):Za.ensure().schedule(l);else if(a!==null){try{cn(l)}catch(s){throw Pr(l),s}p.deps===null&&p.teardown===null&&p.nodes===null&&p.first===p.last&&(p.f&zn)===0&&(p=p.first,(r&na)!==0&&(r&Ln)!==0&&p!==null&&(p.f|=Ln))}if(p!==null&&(p.parent=n,n!==null&&nf(p,n),be!==null&&(be.f&Bt)!==0&&(r&Na)===0)){var t=be;(t.effects??=[]).push(p)}return l}function Bo(){return be!==null&&!ia}function Ho(r){const a=ga(Rs,null);return ft(a,qt),a.teardown=r,a}function qo(r){cu();var a=he.f,n=!be&&(a&Wr)!==0&&tt!==null&&!tt.i;if(n){var l=tt;(l.e??=[]).push(r)}else return hu(r)}function hu(r){return ga(Cn|Fd,r)}function sf(r){return cu(),ga(Rs|Fd,r)}function of(r){Za.ensure();const a=ga(Na|zn,r);return(n={})=>new Promise(l=>{n.outro?un(a,()=>{Pr(a),l(void 0)}):(Pr(a),l(void 0))})}function Uo(r){return ga(Cn,r)}function Ft(r,a){var n=tt,l={effect:null,ran:!1,deps:r};n.l.$.push(l),l.effect=fn(()=>{if(r(),!l.ran){l.ran=!0;var p=he;try{Kr(p.parent),u(a)}finally{Kr(p)}}})}function lf(){var r=tt;fn(()=>{for(var a of r.l.$){a.deps();var n=a.effect;(n.f&qt)!==0&&n.deps!==null&&ft(n,Ur),Fn(n)&&cn(n),a.ran=!1}})}function df(r){return ga(En|zn,r)}function fn(r,a=0){return ga(Rs|a,r)}function S(r,a=[],n=[],l=[]){Hh(l,a,n,p=>{ga(Rs,()=>{r(...p.map(e))})})}function Wo(r,a=0){var n=ga(na|a,r);return n}function Dr(r){return ga(Wr|zn,r)}function fu(r){var a=r.teardown;if(a!==null){const n=Ja,l=be;yd(!0),Zr(null);try{a.call(null)}catch(p){ha(p,r.parent)}finally{yd(n),Zr(l)}}}function Zo(r,a=!1){var n=r.first;for(r.first=r.last=null;n!==null;){const p=n.ac;p!==null&&Vn(()=>{p.abort(Ss)});var l=n.next;(n.f&Na)!==0?n.parent=null:Pr(n,a),n=l}}function uf(r){for(var a=r.first;a!==null;){var n=a.next;(a.f&Wr)===0&&Pr(a),a=n}}function Pr(r,a=!0){var n=!1;(a||(r.f&Ih)!==0)&&r.nodes!==null&&r.nodes.end!==null&&(pf(r.nodes.start,r.nodes.end),n=!0),r.f|=gi,Zo(r,a&&!n),As(r,0);var l=r.nodes&&r.nodes.t;if(l!==null)for(const t of l)t.stop();fu(r),r.f^=gi,r.f|=Mr;var p=r.parent;p!==null&&p.first!==null&&mu(r),r.next=r.prev=r.teardown=r.ctx=r.deps=r.fn=r.nodes=r.ac=r.b=null}function pf(r,a){for(;r!==null;){var n=r===a?null:Ns(r);r.remove(),r=n}}function mu(r){var a=r.parent,n=r.prev,l=r.next;n!==null&&(n.next=l),l!==null&&(l.prev=n),a!==null&&(a.first===r&&(a.first=l),a.last===r&&(a.last=n))}function un(r,a,n=!0){var l=[];r.f|=Oo,vu(r,l,!0);var p=()=>{n&&Pr(r),a&&a()},t=l.length;if(t>0){var s=()=>--t||p();for(var o of l)o.out(s)}else p()}function vu(r,a,n){if((r.f&cr)===0){r.f^=cr;var l=r.nodes&&r.nodes.t;if(l!==null)for(const o of l)(o.is_global||n)&&a.push(o);for(var p=r.first;p!==null;){var t=p.next;if((p.f&Na)===0){var s=(p.f&Ln)!==0||(p.f&Wr)!==0&&(r.f&na)!==0;vu(p,a,s?n:!1)}p=t}}}function Pi(r){r.f&=~Oo,gu(r,!0)}function gu(r,a){if((r.f&Oo)===0&&(r.f&cr)!==0){r.f^=cr,(r.f&qt)===0&&(ft(r,Rt),Za.ensure().schedule(r));for(var n=r.first;n!==null;){var l=n.next,p=(n.f&Ln)!==0||(n.f&Wr)!==0;gu(n,p?a:!1),n=l}var t=r.nodes&&r.nodes.t;if(t!==null)for(const s of t)(s.is_global||a)&&s.in()}}function Ko(r,a){if(r.nodes)for(var n=r.nodes.start,l=r.nodes.end;n!==null;){var p=n===l?null:Ns(n);a.append(n),n=p}}let fi=!1,Ja=!1;function yd(r){Ja=r}let be=null,ia=!1;function Zr(r){be=r}let he=null;function Kr(r){he=r}let va=null;function yu(r){be!==null&&(va??=new Set).add(r)}let wr=null,Tr=0,Fr=null;function cf(r){Fr=r}let _u=1,dn=0,Ea=dn;function _d(r){Ea=r}function wu(){return++_u}function Fn(r){var a=r.f;if((a&Rt)!==0)return!0;if(a&Bt&&(r.f&=~pn),(a&Ur)!==0){for(var n=r.deps,l=n.length,p=0;p<l;p++){var t=n[p];if(Fn(t)&&eu(t),t.wv>r.wv)return!0}(a&Hr)!==0&&sa===null&&ft(r,qt)}return!1}function bu(r,a,n=!0){var l=r.reactions;if(l!==null&&!(va!==null&&va.has(r)))for(var p=0;p<l.length;p++){var t=l[p];(t.f&Bt)!==0?bu(t,a,!1):a===t&&(n?ft(t,Rt):(t.f&qt)!==0&&ft(t,Ur),Do(t))}}function Pu(r){var a=wr,n=Tr,l=Fr,p=be,t=va,s=tt,o=ia,i=Ea,d=r.f;wr=null,Tr=0,Fr=null,be=(d&(Wr|Na))===0?r:null,va=null,jn(r.ctx),ia=!1,Ea=++dn,r.ac!==null&&(Vn(()=>{r.ac.abort(Ss)}),r.ac=null);try{r.f|=_i;var m=r.fn,h=m();r.f|=Mn;var c=wd(r);if(Es()&&Fr!==null&&!ia&&c!==null&&(r.f&(Bt|Ur|Rt))===0)for(var P=0;P<Fr.length;P++)bu(Fr[P],r);if(p!==null&&p!==r){if(dn++,p.deps!==null)for(let N=0;N<n;N+=1)p.deps[N].rv=dn;if(a!==null)for(const N of a)N.rv=dn;Fr!==null&&(l===null?l=Fr:l.push(...Fr))}return(r.f&Ba)!==0&&(r.f^=Ba),h}catch(N){return wd(r),af(N)}finally{r.f^=_i,wr=a,Tr=n,Fr=l,be=p,va=t,jn(s),ia=o,Ea=i}}function wd(r){var a=r.deps,n=oe?.is_fork;if(wr!==null){var l;if(n||As(r,Tr),a!==null&&Tr>0)for(a.length=Tr+wr.length,l=0;l<wr.length;l++)a[Tr+l]=wr[l];else r.deps=a=wr;if(Bo()&&(r.f&Hr)!==0)for(l=Tr;l<a.length;l++)(a[l].reactions??=[]).push(r)}else!n&&a!==null&&Tr<a.length&&(As(r,Tr),a.length=Tr);return a}function hf(r,a){let n=a.reactions;if(n!==null){var l=Ph.call(n,r);if(l!==-1){var p=n.length-1;p===0?n=a.reactions=null:(n[l]=n[p],n.pop())}}if(n===null&&(a.f&Bt)!==0&&(wr===null||!vi.call(wr,a))){var t=a;(t.f&Hr)!==0&&(t.f^=Hr,t.f&=~pn),t.v!==Lt&&Mo(t),t.ac!==null&&Vn(()=>{t.ac.abort(Ss),t.ac=null,ft(t,Rt)}),Jh(t),As(t,0)}}function As(r,a){var n=r.deps;if(n!==null)for(var l=a;l<n.length;l++)hf(r,n[l])}function cn(r){var a=r.f;if((a&Mr)===0){ft(r,qt);var n=he,l=fi;he=r,fi=(a&(Wr|Na))===0;try{(a&(na|Vd))!==0?uf(r):Zo(r),fu(r);var p=Pu(r);r.teardown=typeof p=="function"?p:null,r.wv=_u;var t;jd&&hh&&(r.f&Rt)!==0&&r.deps}finally{fi=l,he=n}}}async function gs(){await Promise.resolve(),Yh()}function e(r){var a=r.f,n=(a&Bt)!==0;if(be!==null&&!ia){var l=he!==null&&(he.f&Mr)!==0;if(!l&&(va===null||!va.has(r))){var p=be.deps;if((be.f&_i)!==0)r.rv<dn&&(r.rv=dn,wr===null&&p!==null&&p[Tr]===r?Tr++:wr===null?wr=[r]:wr.push(r));else{be.deps??=[],vi.call(be.deps,r)||be.deps.push(r);var t=r.reactions;t===null?r.reactions=[be]:vi.call(t,be)||t.push(be)}}}if(Ja&&ma.has(r))return ma.get(r);if(n){var s=r;if(Ja){var o=s.v;return((s.f&qt)===0&&s.reactions!==null||xu(s))&&(o=Vo(s)),ma.set(s,o),o}var i=(s.f&Hr)===0&&!ia&&be!==null&&(fi||(be.f&Hr)!==0),d=(s.f&Mn)===0;Fn(s)&&(i&&(s.f|=Hr),eu(s)),i&&!d&&(tu(s),ku(s))}if(sa?.has(r))return sa.get(r);if((r.f&Ba)!==0)throw r.v;return r.v}function ku(r){if(r.f|=Hr,r.deps!==null)for(const a of r.deps)(a.reactions??=[]).push(r),(a.f&Bt)!==0&&(a.f&Hr)===0&&(tu(a),ku(a))}function xu(r){if(r.v===Lt)return!0;if(r.deps===null)return!1;for(const a of r.deps)if(ma.has(a)||(a.f&Bt)!==0&&xu(a))return!0;return!1}function u(r){var a=ia;try{return ia=!0,r()}finally{ia=a}}function et(r){if(!(typeof r!="object"||!r||r instanceof EventTarget)){if(Ha in r)Ro(r);else if(!Array.isArray(r))for(let a in r){const n=r[a];typeof n=="object"&&n&&Ha in n&&Ro(n)}}}function Ro(r,a=new Set){if(typeof r=="object"&&r!==null&&!(r instanceof EventTarget)&&!a.has(r)){a.add(r),r instanceof Date&&r.getTime();for(let l in r)try{Ro(r[l],a)}catch{}const n=jo(r);if(n!==Object.prototype&&n!==Array.prototype&&n!==Map.prototype&&n!==Set.prototype&&n!==Date.prototype){const l=Td(n);for(let p in l){const t=l[p].get;if(t)try{t.call(r)}catch{}}}}}const ys=Symbol("events"),Au=new Set,So=new Set;function ff(r,a,n,l={}){function p(t){if(l.capture||Eo.call(a,t),!t.cancelBubble)return Vn(()=>n?.call(this,t))}return r.startsWith("pointer")||r.startsWith("touch")||r==="wheel"?Ra(()=>{a.addEventListener(r,p,l)}):a.addEventListener(r,p,l),p}function no(r,a,n,l,p){var t={capture:l,passive:p},s=ff(r,a,n,t);(a===document.body||a===window||a===document||a instanceof HTMLMediaElement)&&Ho(()=>{a.removeEventListener(r,s,t)})}function U(r,a,n){(a[ys]??={})[r]=n}function mf(r){for(var a=0;a<r.length;a++)Au.add(r[a]);for(var n of So)n(r)}let so=null,io=!1;function Eo(r){var a=this,n=a.ownerDocument,l=r.type,p=r.composedPath?.()||[],t=p[0]||r.target;so=r,io||(io=!0,setTimeout(()=>{io=!1,so=null}));var s=0,o=so===r&&r[ys];if(o){var i=p.indexOf(o);if(i!==-1&&(a===document||a===window)){r[ys]=a;return}var d=p.indexOf(a);if(d===-1)return;i<=d&&(s=i)}if(t=p[s]||r.target,t!==a){Od(r,"currentTarget",{configurable:!0,get(){return t||n}});var m=be,h=he;Zr(null),Kr(null);try{for(var c,P=[];t!==null&&t!==a;){try{var N=t[ys]?.[l];N!=null&&(!t.disabled||r.target===t)&&N.call(t,r)}catch(Z){c?P.push(Z):c=Z}if(r.cancelBubble)break;s++,t=s<p.length?p[s]:null}if(c){for(let Z of P)queueMicrotask(()=>{throw Z});throw c}}finally{r[ys]=a,delete r.currentTarget,Zr(m),Kr(h)}}}const vf=globalThis?.window?.trustedTypes&&globalThis.window.trustedTypes.createPolicy("svelte-trusted-html",{createHTML:r=>r});function gf(r){return vf?.createHTML(r)??r}function yf(r){var a=rf("template");return a.innerHTML=gf(r.replaceAll("<!>","<!---->")),a.content}function No(r,a){var n=he;n.nodes===null&&(n.nodes={start:r,end:a,a:null,t:null})}function F(r,a){var n=(a&_h)!==0,l=(a&wh)!==0,p,t=!r.startsWith("<!>");return()=>{p===void 0&&(p=yf(t?r:"<!>"+r),n||(p=xs(p)));var s=l||lu?document.importNode(p,!0):p.cloneNode(!0);if(n){var o=xs(s),i=s.lastChild;No(o,i)}else No(s,s);return s}}function $n(){var r=document.createDocumentFragment(),a=document.createComment(""),n=Wa();return r.append(a,n),No(a,n),r}function $(r,a){r!==null&&r.before(a)}const _f=["touchstart","touchmove"];function wf(r){return _f.includes(r)}function bf(r){let a=0,n=Ka(0),l;return()=>{Bo()&&(e(n),fn(()=>(a===0&&(l=u(()=>r(()=>Ua(n)))),a+=1,()=>{Ra(()=>{a-=1,a===0&&(l?.(),l=void 0,Ua(n))})})))}}var Pf=Ln|zn;function kf(r,a,n,l){new xf(r,a,n,l)}class xf{parent;is_pending=!1;transform_error;#t;#r=null;#e;#o;#a;#s=null;#n=null;#l=null;#i=null;#m=0;#d=0;#u=!1;#c=new Set;#v=new Set;#p=null;#_=bf(()=>(this.#p=Ka(this.#m),()=>{this.#p=null}));constructor(a,n,l,p){this.#t=a,this.#e=n,this.#o=t=>{var s=he;s.b=this,s.f|=Po,l(t)},this.parent=he.b,this.transform_error=p??this.parent?.transform_error??(t=>t),this.#a=Wo(()=>{this.#h()},Pf)}#g(){try{this.#s=Dr(()=>this.#o(this.#t))}catch(a){this.error(a)}}#b(a){const n=this.#e.failed,{reset:l,invoke_onerror:p}=this.#w(a);Ra(p),n&&(this.#l=Dr(()=>{n(this.#t,()=>a,()=>l)}))}#w(a){var n=!1,l=!1;const p=()=>{if(n){Sh();return}n=!0,l&&Vh(),this.#l!==null&&un(this.#l,()=>{this.#l=null}),this.#f(()=>{this.#h()})};return{reset:p,invoke_onerror:()=>{try{l=!0,this.#e.onerror?.(a,p),l=!1}catch(s){ha(s,this.#a&&this.#a.parent)}}}}#P(){const a=this.#e.pending;a&&(this.is_pending=!0,this.#n=Dr(()=>a(this.#t)),Ra(()=>{var n=this.#i=document.createDocumentFragment(),l=Wa(),p=!1;if(n.append(l),this.#s=this.#f(()=>{try{return Dr(()=>this.#o(l))}catch(t){try{this.error(t),p=!0}catch(s){ha(s,this.#a.parent)}return null}}),this.#s===null){this.#i=null,p&&this.#y(oe);return}this.#d===0&&(this.#t.before(n),this.#i=null,un(this.#n,()=>{this.#n=null}),this.#y(oe))}))}#h(){try{if(this.is_pending=this.has_pending_snippet(),this.#d=0,this.#m=0,this.#s=Dr(()=>{this.#o(this.#t)}),this.#d>0){var a=this.#i=document.createDocumentFragment();Ko(this.#s,a);const n=this.#e.pending;this.#n=Dr(()=>n(this.#t))}else this.#y(oe)}catch(n){this.error(n)}}#y(a){this.is_pending=!1,a.transfer_effects(this.#c,this.#v)}defer_effect(a){Qd(a,this.#c,this.#v)}is_rendered(){return!this.is_pending&&(!this.parent||this.parent.is_rendered())}has_pending_snippet(){return!!this.#e.pending}#f(a){var n=he,l=be,p=tt;Kr(this.#a),Zr(this.#a),jn(this.#a.ctx);try{return Za.ensure(),a()}finally{Kr(n),Zr(l),jn(p)}}#k(a,n){if(!this.has_pending_snippet()){this.parent&&this.parent.#k(a,n);return}this.#d+=a,this.#d===0&&(this.#y(n),this.#n&&un(this.#n,()=>{this.#n=null}),this.#i&&(this.#t.before(this.#i),this.#i=null))}update_pending_count(a,n){this.#k(a,n),this.#m+=a,!(!this.#p||this.#u)&&(this.#u=!0,Ra(()=>{this.#u=!1,this.#p&&On(this.#p,this.#m)}))}get_effect_pending(){return this.#_(),e(this.#p)}error(a){if(!this.#e.onerror&&!this.#e.failed)throw a;oe?.is_fork?(this.#s&&oe.skip_effect(this.#s),this.#n&&oe.skip_effect(this.#n),this.#l&&oe.skip_effect(this.#l),oe.oncommit(()=>{this.#x(a)})):this.#x(a)}#x(a){this.#s&&(Pr(this.#s),this.#s=null),this.#n&&(Pr(this.#n),this.#n=null),this.#l&&(Pr(this.#l),this.#l=null);let n=this.#e.failed;const l=p=>{const{reset:t,invoke_onerror:s}=this.#w(p);s(),n&&(this.#l=this.#f(()=>{try{return Dr(()=>{var o=he;o.b=this,o.f|=Po,n(this.#t,()=>p,()=>t)})}catch(o){return ha(o,this.#a.parent),null}}))};Ra(()=>{var p;try{p=this.transform_error(a)}catch(t){ha(t,this.#a&&this.#a.parent);return}p!==null&&typeof p=="object"&&typeof p.then=="function"?p.then(l,t=>ha(t,this.#a&&this.#a.parent)):l(p)})}}function y(r,a){var n=a==null?"":typeof a=="object"?`${a}`:a;n!==(r[Ao]??=r.nodeValue)&&(r[Ao]=n,r.nodeValue=`${n}`)}function Af(r,a){return If(r,a)}const si=new Map;function If(r,{target:a,anchor:n,props:l={},events:p,context:t,intro:s=!0,transformError:o}){ef();var i=void 0,d=of(()=>{var m=n??a.appendChild(Wa());kf(m,{pending:()=>{}},P=>{Kd({});var N=tt;t&&(N.c=t),p&&(l.$$events=p),i=r(P,l)||To(),Jd()},o);var h=new Set,c=P=>{for(var N=0;N<P.length;N++){var Z=P[N];if(!h.has(Z)){h.add(Z);var E=wf(Z);for(const ne of[a,document]){var K=si.get(ne);K===void 0&&(K=new Map,si.set(ne,K));var X=K.get(Z);X===void 0?(ne.addEventListener(Z,Eo,{passive:E}),K.set(Z,1)):K.set(Z,X+1)}}}};return c(Ii(Au)),So.add(c),()=>{for(var P of h)for(const E of[a,document]){var N=si.get(E),Z=N.get(P);--Z==0?(E.removeEventListener(P,Eo),N.delete(P),N.size===0&&si.delete(E)):N.set(P,Z)}So.delete(c),m!==n&&m.parentNode?.removeChild(m)}});return $f.set(i,d),i}let $f=new WeakMap;class qf{anchor;#t=new Map;#r=new Map;#e=new Map;#o=new Set;#a=!0;constructor(a,n=!0){this.anchor=a,this.#a=n}#s=a=>{if(this.#t.has(a)){var n=this.#t.get(a),l=this.#r.get(n);if(l)Pi(l),this.#o.delete(n);else{var p=this.#e.get(n);p&&(Pi(p.effect),this.#r.set(n,p.effect),this.#e.delete(n),p.fragment.lastChild.remove(),this.anchor.before(p.fragment),l=p.effect)}for(const[t,s]of this.#t){if(this.#t.delete(t),t===a)break;const o=this.#e.get(s);o&&(Pr(o.effect),this.#e.delete(s))}for(const[t,s]of this.#r){if(t===n||this.#o.has(t))continue;const o=()=>{if(Array.from(this.#t.values()).includes(t)){var d=document.createDocumentFragment();Ko(s,d),d.append(Wa()),this.#e.set(t,{effect:s,fragment:d})}else Pr(s);this.#o.delete(t),this.#r.delete(t)};this.#a||!l?(this.#o.add(t),un(s,o,!1)):o()}}};#n=a=>{this.#t.delete(a);const n=Array.from(this.#t.values());for(const[l,p]of this.#e)n.includes(l)||(Pr(p.effect),this.#e.delete(l))};ensure(a,n){var l=oe,p=pu();if(n&&!this.#r.has(a)&&!this.#e.has(a))if(p){var t=document.createDocumentFragment(),s=Wa();t.append(s),this.#e.set(a,{effect:Dr(()=>n(s)),fragment:t})}else this.#r.set(a,Dr(()=>n(this.anchor)));if(this.#t.set(l,a),p){for(const[o,i]of this.#r)o===a?l.unskip_effect(i):l.skip_effect(i);for(const[o,i]of this.#e)o===a?l.unskip_effect(i.effect):l.skip_effect(i.effect);l.oncommit(this.#s),l.ondiscard(this.#n)}else this.#s(l)}}function Iu(r){tt===null&&Zd(),qs&&tt.l!==null?Sf(tt).m.push(r):qo(()=>{const a=u(r);if(typeof a=="function")return a})}function Rf(r){tt===null&&Zd(),Iu(()=>()=>u(r))}function Sf(r){var a=r.l;return a.u??={a:[],b:[],m:[]}}function B(r,a,n=!1){var l=new qf(r),p=n?Ln:0;function t(s,o){l.ensure(s,o)}Wo(()=>{var s=!1;a((o,i=0)=>{s=!0,t(i,o)}),s||t(-1,null)},p)}function xa(r,a){return a}function Ef(r,a,n){for(var l=[],p=a.length,t,s=a.length,o=0;o<p;o++){let h=a[o];un(h,()=>{if(t){if(t.pending.delete(h),t.done.add(h),t.pending.size===0){var c=r.outrogroups;Co(r,Ii(t.done)),c.delete(t),c.size===0&&(r.outrogroups=null)}}else s-=1},!1)}if(s===0){var i=l.length===0&&n!==null&&r.pending.size===0;if(i){var d=n,m=d.parentNode;tf(m),m.append(d),r.items.clear()}Co(r,a,!i)}else t={pending:new Set(a),done:new Set},(r.outrogroups??=new Set).add(t)}function Co(r,a,n=!0){var l;if(r.pending.size>0){l=new Set;for(const s of r.pending.values())for(const o of s)l.add(r.items.get(o).e)}for(var p=0;p<a.length;p++){var t=a[p];if(l?.has(t)){t.f|=fa;const s=document.createDocumentFragment();Ko(t,s)}else Pr(a[p],n)}}var bd;function we(r,a,n,l,p,t=null){var s=r,o=new Map,i=(a&Ld)!==0;if(i){var d=r;s=d.appendChild(Wa())}var m=null,h=Ia(()=>{var ne=n();return Ai(ne)?ne:ne==null?[]:Ii(ne)}),c,P=new Map,N=!0;function Z(ne){(X.effect.f&Mr)===0&&(X.pending.delete(ne),X.fallback=m,Nf(X,c,s,a,l),m!==null&&(c.length===0?(m.f&fa)===0?Pi(m):(m.f^=fa,_s(m,null,s)):un(m,()=>{m=null})))}function E(ne){X.pending.delete(ne)}var K=Wo(()=>{c=e(h);for(var ne=c.length,ee=new Set,$e=oe,Fe=pu(),ge=0;ge<ne;ge+=1){var He=c[ge],Pt=l(He,ge),Ue=N?null:o.get(Pt);Ue?(Ue.v&&On(Ue.v,He),Ue.i&&On(Ue.i,ge),Fe&&$e.unskip_effect(Ue.e)):(Ue=Cf(o,N?s:bd??=Wa(),He,Pt,ge,p,a,n),N||(Ue.e.f|=fa),o.set(Pt,Ue)),ee.add(Pt)}if(ne===0&&t&&!m&&(N?m=Dr(()=>t(s)):(m=Dr(()=>t(bd??=Wa())),m.f|=fa)),ne>ee.size&&Nh(),!N)if(P.set($e,ee),Fe){for(const[H,le]of o)ee.has(H)||$e.skip_effect(le.e);$e.oncommit(Z),$e.ondiscard(E)}else Z($e);e(h)}),X={effect:K,items:o,pending:P,outrogroups:null,fallback:m};N=!1}function ps(r){for(;r!==null&&(r.f&Wr)===0;)r=r.next;return r}function Nf(r,a,n,l,p){var t=(l&gh)!==0,s=a.length,o=r.items,i=ps(r.effect.first),d,m=null,h,c=[],P=[],N,Z,E,K;if(t)for(K=0;K<s;K+=1)N=a[K],Z=p(N,K),E=o.get(Z).e,(E.f&fa)===0&&(E.nodes?.a?.measure(),(h??=new Set).add(E));for(K=0;K<s;K+=1){if(N=a[K],Z=p(N,K),E=o.get(Z).e,r.outrogroups!==null)for(const Ue of r.outrogroups)Ue.pending.delete(E),Ue.done.delete(E);if((E.f&cr)!==0&&(Pi(E),t&&(E.nodes?.a?.unfix(),(h??=new Set).delete(E))),(E.f&fa)!==0)if(E.f^=fa,E===i)_s(E,null,n);else{var X=m?m.next:i;E===r.effect.last&&(r.effect.last=E.prev),E.prev&&(E.prev.next=E.next),E.next&&(E.next.prev=E.prev),Da(r,m,E),Da(r,E,X),_s(E,X,n),m=E,c=[],P=[],i=ps(m.next);continue}if(E!==i){if(d!==void 0&&d.has(E)){if(c.length<P.length){var ne=P[0],ee;m=ne.prev;var $e=c[0],Fe=c[c.length-1];for(ee=0;ee<c.length;ee+=1)_s(c[ee],ne,n);for(ee=0;ee<P.length;ee+=1)d.delete(P[ee]);Da(r,$e.prev,Fe.next),Da(r,m,$e),Da(r,Fe,ne),i=ne,m=Fe,K-=1,c=[],P=[]}else d.delete(E),_s(E,i,n),Da(r,E.prev,E.next),Da(r,E,m===null?r.effect.first:m.next),Da(r,m,E),m=E;continue}for(c=[],P=[];i!==null&&i!==E;)(d??=new Set).add(i),P.push(i),i=ps(i.next);if(i===null)continue}(E.f&fa)===0&&c.push(E),m=E,i=ps(E.next)}if(r.outrogroups!==null){for(const Ue of r.outrogroups)Ue.pending.size===0&&(Co(r,Ii(Ue.done)),r.outrogroups?.delete(Ue));r.outrogroups.size===0&&(r.outrogroups=null)}if(i!==null||d!==void 0){var ge=[];if(d!==void 0)for(E of d)(E.f&cr)===0&&ge.push(E);for(;i!==null;)(i.f&cr)===0&&i!==r.fallback&&ge.push(i),i=ps(i.next);var He=ge.length;if(He>0){var Pt=(l&Ld)!==0&&s===0?n:null;if(t){for(K=0;K<He;K+=1)ge[K].nodes?.a?.measure();for(K=0;K<He;K+=1)ge[K].nodes?.a?.fix()}Ef(r,ge,Pt)}}t&&Ra(()=>{if(h!==void 0)for(E of h)E.nodes?.a?.apply()})}function Cf(r,a,n,l,p,t,s,o){var i=(s&mh)!==0?(s&yh)===0?W(n,!1,!1):Ka(n):null,d=(s&vh)!==0?Ka(p):null;return{v:i,i:d,e:Dr(()=>(t(a,i??n,d??p,o),()=>{r.delete(l)}))}}function _s(r,a,n){if(r.nodes)for(var l=r.nodes.start,p=r.nodes.end,t=a&&(a.f&fa)===0?a.nodes.start:n;l!==null;){var s=Ns(l);if(t.before(l),l===p)return;l=s}}function Da(r,a,n){a===null?r.effect.first=n:a.next=n,n===null?r.effect.last=a:n.prev=a}function Lf(r,a,n){Uo(()=>{var l=u(()=>a(r,n?.())||{});if(n&&l?.update){var p=!1,t={};fn(()=>{var s=n();et(s),p&&Ud(t,s)&&(t=s,l.update(s))}),p=!0}if(l?.destroy)return()=>l.destroy()})}const Pd=[..." \\t\\n\\r\\f \\u000b\uFEFF"];function jf(r,a,n){var l=r==null?"":""+r;if(a&&(l=l?l+" "+a:a),n){for(var p of Object.keys(n))if(n[p])l=l?l+" "+p:p;else if(l.length)for(var t=p.length,s=0;(s=l.indexOf(p,s))>=0;){var o=s+t;(s===0||Pd.includes(l[s-1]))&&(o===l.length||Pd.includes(l[o]))?l=(s===0?"":l.substring(0,s))+l.substring(o+1):s=o}}return l===""?null:l}function Of(r,a){return r==null?null:String(r)}function Dt(r,a,n,l,p,t){var s=r[ko];if(s!==n||s===void 0){var o=jf(n,l,t);o==null?r.removeAttribute("class"):r.className=o,r[ko]=n}else if(t&&p!==t)for(var i in t){var d=!!t[i];(p==null||d!==!!p[i])&&r.classList.toggle(i,d)}return t}function _r(r,a,n,l){var p=r[xo];if(p!==a){var t=Of(a);t==null?r.removeAttribute("style"):r.style.cssText=t,r[xo]=a}return l}function Tf(r,a){a?r.hasAttribute("selected")||r.setAttribute("selected",""):r.removeAttribute("selected")}function Mf(r,a){var n=r.__defaultValue,l=r.multiple,p=l?n??[]:null;if(!(l&&!Ai(p))){r.selectedIndex;for(var t of r.options){var s=Nn(t);Tf(t,l?p.includes(s):ou(s,n))}}}function ks(r,a,n=!1){if(r.multiple){if(a==null)return;if(!Ai(a))return Rh();for(var l of r.options)l.selected=a.includes(Nn(l));return}for(l of r.options){var p=Nn(l);if(ou(p,a)){l.selected=!0;return}}(!n||a!==void 0)&&(r.selectedIndex=-1)}function ii(r){var a=new MutationObserver(n=>{n.every(Vf)||("__defaultValue"in r&&Mf(r),"__value"in r&&ks(r,r.__value))});a.observe(r,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["value"]}),Ho(()=>{a.disconnect()})}function zf(r,a,n=a){var l=new WeakSet,p=!0;zo(r,"change",t=>{var s=t?"[selected]":":checked",o;if(r.multiple)o=[].map.call(r.querySelectorAll(s),Nn);else{var i=r.querySelector(s)??r.querySelector("option:not([disabled])");o=i&&Nn(i)}n(o),r.__value=o,oe!==null&&l.add(oe)}),Uo(()=>{var t=a();if(r===document.activeElement){var s=oe;if(l.has(s))return}if(ks(r,t,p),p&&t===void 0){var o=r.querySelector(":checked");o!==null&&(t=Nn(o),n(t))}r.__value=t,p=!1})}function Nn(r){return"__value"in r?r.__value:r.value}function Vf(r){if(r.target.closest("selectedcontent")!==null)return!0;if(r.type==="childList"){var a=[...r.addedNodes,...r.removedNodes];return a.length>0&&a.every(n=>n.nodeName==="SELECTEDCONTENT")}return!1}const Ff=Symbol("is custom element"),Df=Symbol("is html");function qn(r,a){var n=$u(r);n.checked!==(n.checked=a??void 0)&&(r.checked=a)}function z(r,a,n,l){var p=$u(r);p[a]!==(p[a]=n)&&(a==="loading"&&(r[$h]=n),n==null?r.removeAttribute(a):typeof n!="string"&&Bf(r).has(a)?r[a]=n:r.setAttribute(a,n))}function $u(r){return r[Bd]??={[Ff]:r.nodeName.includes("-"),[Df]:r.namespaceURI===bh}}var kd=new Map;function Bf(r){var a=r.getAttribute("is")||r.nodeName,n=kd.get(a);if(n)return n;kd.set(a,n=new Set);for(var l,p=r,t=Element.prototype;t!==p;){l=Td(p);for(var s in l)l[s].set&&s!=="innerHTML"&&s!=="textContent"&&s!=="innerText"&&n.add(s);p=jo(p)}return n}function oi(r,a,n=a){var l=new WeakSet;zo(r,"input",async p=>{var t=p?r.defaultValue:r.value;if(t=lo(r)?uo(t):t,n(t),oe!==null&&l.add(oe),await gs(),t!==(t=a())){var s=r.selectionStart,o=r.selectionEnd,i=r.value.length;if(r.value=t??"",o!==null){var d=r.value.length;s===o&&o===i&&d>i?(r.selectionStart=d,r.selectionEnd=d):(r.selectionStart=s,r.selectionEnd=Math.min(o,d))}}}),u(a)==null&&r.value&&(n(lo(r)?uo(r.value):r.value),oe!==null&&l.add(oe)),fn(()=>{var p=a();if(r===document.activeElement){var t=oe;if(l.has(t))return}lo(r)&&p===uo(r.value)||r.type==="date"&&!p&&!r.value||p!==r.value&&(r.value=p??"")})}function oo(r,a,n=a){zo(r,"change",l=>{var p=l?r.defaultChecked:r.checked;n(p)}),u(a)==null&&n(r.checked),fn(()=>{var l=a();r.checked=!!l})}function lo(r){var a=r.type;return a==="number"||a==="range"}function uo(r){return r===""?null:+r}function po(r,a){return r===a||r?.[Ha]===a}function cs(r=To(),a,n,l){var p=tt.r,t=he;return Uo(()=>{var s,o;return fn(()=>{s=o,o=[],u(()=>{po(n(...o),r)||(a(r,...o),s&&po(n(...s),r)&&a(null,...s))})}),()=>{let i=t;for(;i!==p&&i.parent!==null&&i.parent.f&gi;)i=i.parent;const d=()=>{o&&po(n(...o),r)&&a(null,...o)},m=i.teardown;i.teardown=()=>{d(),m?.()}}}),r}function Hf(r=!1){const a=tt,n=a.l.u;if(!n)return;let l=()=>et(a.s);if(r){let p=0,t={};const s=$i(()=>{let o=!1;const i=a.s;for(const d in i)i[d]!==t[d]&&(t[d]=i[d],o=!0);return o&&p++,p});l=()=>e(s)}n.b.length&&sf(()=>{xd(a,l),bo(n.b)}),qo(()=>{const p=u(()=>n.m.map(Ah));return()=>{for(const t of p)typeof t=="function"&&t()}}),n.a.length&&qo(()=>{xd(a,l),bo(n.a)})}function xd(r,a){if(r.l.s)for(const n of r.l.s)e(n);a()}var Uf=["forEach","isDisjointFrom","isSubsetOf","isSupersetOf"],Wf=["difference","intersection","symmetricDifference","union"],Ad=!1;class ki extends Set{#t=new Map;#r=aa(0);#e=aa(0);#o=Ea||-1;constructor(a){if(super(),a){for(var n of a)super.add(n);this.#e.v=super.size}Ad||this.#s()}#a(a){return Ea===this.#o?aa(a):Ka(a)}#s(){Ad=!0;var a=ki.prototype,n=Set.prototype;for(const l of Uf)a[l]=function(...p){return e(this.#r),n[l].apply(this,p)};for(const l of Wf)a[l]=function(...p){e(this.#r);var t=n[l].apply(this,p);return new ki(t)}}has(a){var n=super.has(a),l=this.#t,p=l.get(a);if(p===void 0){if(!n)return e(this.#r),!1;p=this.#a(!0),l.set(a,p)}return e(p),n}add(a){return super.has(a)||(super.add(a),A(this.#e,super.size),Ua(this.#r)),this}delete(a){var n=super.delete(a),l=this.#t,p=l.get(a);return p!==void 0&&(l.delete(a),A(p,!1)),n&&(A(this.#e,super.size),Ua(this.#r)),n}clear(){if(super.size!==0){super.clear();var a=this.#t;for(var n of a.values())A(n,!1);a.clear(),A(this.#e,0),Ua(this.#r)}}keys(){return this.values()}values(){return e(this.#r),super.values()}entries(){return e(this.#r),super.entries()}[Symbol.iterator](){return this.keys()}get size(){return e(this.#e)}}async function ca(r,a,n){return{...a,fingerprint:await r(n)}}async function Zf(r,a){const n=[];for(const p of r.changes){n.push(ca(a,{type:"change",ref:p.id},p));for(const[t,s]of p.verification.gaps.entries())n.push(ca(a,{type:"verification-gap",ref:`${p.id}:gap:${t}`},{changeId:p.id,index:t,gap:s}))}for(const p of r.files)n.push(ca(a,{type:"file",ref:p.id,path:p.newPath??p.oldPath??void 0},p));for(const p of r.hunks){n.push(ca(a,{type:"hunk",ref:p.id,path:p.path},p));for(const[t,s]of p.lines.entries()){if(s.kind==="no-newline")continue;const o=s.kind==="addition"?"after":s.kind==="deletion"?"before":"diff",i=o==="before"?s.oldLine:s.newLine??s.oldLine;!i||i<1||n.push(ca(a,{type:"line-range",ref:`${p.id}:${o}:${i}:${t}`,path:p.path,side:o,startLine:i,endLine:i},{path:p.path,side:o,lineNumber:i,content:s.content}))}}for(const p of r.targets)n.push(ca(a,{type:"visual-target",ref:p.id},p));for(const p of r.comparisons){const t=r.targets.find(s=>s.id===p.targetRef);for(const s of p.images)for(const o of s.regions)n.push(ca(a,{type:"visual-region",ref:`${p.id}:${s.id}:${o.id}`,targetRef:p.targetRef,region:{x:o.x/s.width,y:o.y/s.height,width:o.width/s.width,height:o.height/s.height}},{target:t,comparison:p,image:s,region:o}))}for(const p of r.findings)n.push(ca(a,{type:"finding",ref:p.id,targetRef:p.targetRef},p));return(await Promise.all(n)).sort((p,t)=>`${p.type}\\0${p.ref}`.localeCompare(`${t.type}\\0${t.ref}`))}async function qu(r,a,n,l,p,t){const s=r.hunks.find(i=>i.id===a);if(!s||n!=="before"&&n!=="after"||!Number.isSafeInteger(l)||!Number.isSafeInteger(p)||l<1||p<l||p-l>1e3)return;const o=s.lines.filter(i=>{const d=n==="before"?i.oldLine:i.newLine;return i.kind!=="no-newline"&&d!==null&&d!==void 0&&d>=l&&d<=p});if(!(o.length!==p-l+1||o.some((i,d)=>(n==="before"?i.oldLine:i.newLine)!==l+d)))return ca(t,{type:"line-range",ref:`${s.id}:range:${n}:${l}:${p}`,path:s.path,side:n,startLine:l,endLine:p},{path:s.path,side:n,startLine:l,endLine:p,lines:o.map(i=>i.content)})}async function Ru(r,a,n){const l=a.match(/^(.*):range:(before|after):(\\d+):(\\d+)$/u);return l?qu(r,l[1],l[2],Number(l[3]),Number(l[4]),n):void 0}async function Kf(r,a,n,l){const p=new Map(a.map(t=>[Br(t),t]));for(const t of n){if(t.type!=="line-range")continue;const s=await Ru(r,t.ref,l);s&&p.set(Br(s),s)}return[...p.values()]}async function Su(r,a){const n=[];for(const l of r.comparisons)for(const p of l.images)for(const t of p.regions)n.push(ca(a,{type:"visual-region",ref:`${l.id}:${p.id}:${t.id}`,targetRef:l.targetRef,region:{x:t.x,y:t.y,width:t.width,height:t.height}},{comparisonId:l.id,imageId:p.id,region:t}));return Promise.all(n)}function Jf(r){return!!(r&&typeof r=="object"&&!Array.isArray(r))}function Gf(r){if(!Jf(r))return!1;const a=Object.keys(r);return a.length===4&&a.every(n=>new Set(["x","y","width","height"]).has(n))&&[r.x,r.y,r.width,r.height].every(n=>typeof n=="number"&&Number.isFinite(n))}function Eu(r,a,n,l){const p=structuredClone(r);if(!p||typeof p!="object")return p;const t=new Map(a.map(d=>[Br(d),d])),s=new Map(n.map(d=>[Br(d),d])),o=[p],i=new WeakSet;for(;o.length>0;){const d=o.pop();if(i.has(d))continue;if(i.add(d),Array.isArray(d)){for(const h of d)h&&typeof h=="object"&&o.push(h);continue}const m=d;if(m.type==="visual-region"&&typeof m.ref=="string"&&typeof m.fingerprint=="string"&&Gf(m.region)){const h=JSON.stringify([m.type,m.ref]),c=t.get(h),P=s.get(h),N=[m.region.x,m.region.y,m.region.width,m.region.height].some(E=>E>1);P?.fingerprint===m.fingerprint&&c?(c.region?m.region=structuredClone(c.region):delete m.region,c.targetRef?m.targetRef=c.targetRef:delete m.targetRef,l&&(m.fingerprint=c.fingerprint)):N&&!l&&delete m.region}for(const h of Object.values(m))h&&typeof h=="object"&&o.push(h)}return p}function Br(r){return JSON.stringify([r.type,r.ref])}function Id(r,a,n){return r.find(l=>l.type===a&&l.ref===n)}function co(r,a){const n=a.find(p=>p.type===r.type&&p.ref===r.ref);if(n?.fingerprint===r.fingerprint)return{source:r,result:"exact",disposition:"matched",candidate:n};if(n)return{source:r,result:"changed",disposition:"stale",candidate:n};const l=a.filter(p=>p.type===r.type&&p.fingerprint===r.fingerprint);return l.length===1?{source:r,result:"probable",disposition:"stale",candidate:l[0]}:{source:r,result:"missing",disposition:"orphaned"}}function Lo(r){if(r===null||typeof r=="string"||typeof r=="boolean")return r;if(typeof r=="number"){if(!Number.isFinite(r))throw new TypeError("Review JSON does not support non-finite numbers");return Object.is(r,-0)?0:r}if(Array.isArray(r))return r.map(Lo);if(r instanceof Date)return r.toISOString();if(typeof r=="object"){const a={};for(const n of Object.keys(r).sort()){const l=r[n];l!==void 0&&(a[n]=Lo(l))}return a}throw new TypeError(`Review JSON does not support ${typeof r}`)}function qa(r){return JSON.stringify(Lo(r))}const br=async r=>{const a=new TextEncoder().encode(qa(r)),n=await crypto.subtle.digest("SHA-256",a);return[...new Uint8Array(n)].map(l=>l.toString(16).padStart(2,"0")).join("")};var Nu=(r,a)=>()=>{try{return a||r((a={exports:{}}).exports,a),a.exports}catch(n){throw a=0,n}},Yf=Nu(r=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0});function a(n){let l=n.length,p=0,t=0,s;for(;t<l;)p++,s=n.charCodeAt(t++),s>=55296&&s<=56319&&t<l&&(s=n.charCodeAt(t),(s&64512)===56320&&t++);return p}r.default=a,a.code=\'require("ajv/dist/runtime/ucs2length").default\'}),Qf=Nu(r=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.formatNames=r.fastFormats=r.fullFormats=void 0;function a(H,le){return{validate:H,compare:le}}r.fullFormats={date:a(t,s),time:a(i(!0),d),"date-time":a(c(!0),P),"iso-time":a(i(),m),"iso-date-time":a(c(),N),duration:/^P(?!$)((\\d+Y)?(\\d+M)?(\\d+D)?(T(?=\\d)(\\d+H)?(\\d+M)?(\\d+S)?)?|(\\d+W)?)$/,uri:K,"uri-reference":/^(?:[a-z][a-z0-9+\\-.]*:)?(?:\\/?\\/(?:(?:[a-z0-9\\-._~!$&\'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\\d|[01]?\\d\\d?)\\.){3}(?:25[0-5]|2[0-4]\\d|[01]?\\d\\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\\.[a-z0-9\\-._~!$&\'()*+,;=:]+)\\]|(?:(?:25[0-5]|2[0-4]\\d|[01]?\\d\\d?)\\.){3}(?:25[0-5]|2[0-4]\\d|[01]?\\d\\d?)|(?:[a-z0-9\\-._~!$&\'"()*+,;=]|%[0-9a-f]{2})*)(?::\\d*)?(?:\\/(?:[a-z0-9\\-._~!$&\'"()*+,;=:@]|%[0-9a-f]{2})*)*|\\/(?:(?:[a-z0-9\\-._~!$&\'"()*+,;=:@]|%[0-9a-f]{2})+(?:\\/(?:[a-z0-9\\-._~!$&\'"()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\\-._~!$&\'"()*+,;=:@]|%[0-9a-f]{2})+(?:\\/(?:[a-z0-9\\-._~!$&\'"()*+,;=:@]|%[0-9a-f]{2})*)*)?(?:\\?(?:[a-z0-9\\-._~!$&\'"()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\\-._~!$&\'"()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,"uri-template":/^(?:(?:[^\\x00-\\x20"\'<>%\\\\^`{|}]|%[0-9a-f]{2})|\\{[+#./;?&=,!@|]?(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\\*)?(?:,(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\\*)?)*\\})*$/i,url:/^(?:https?|ftp):\\/\\/(?:\\S+(?::\\S*)?@)?(?:(?!(?:10|127)(?:\\.\\d{1,3}){3})(?!(?:169\\.254|192\\.168)(?:\\.\\d{1,3}){2})(?!172\\.(?:1[6-9]|2\\d|3[0-1])(?:\\.\\d{1,3}){2})(?:[1-9]\\d?|1\\d\\d|2[01]\\d|22[0-3])(?:\\.(?:1?\\d{1,2}|2[0-4]\\d|25[0-5])){2}(?:\\.(?:[1-9]\\d?|1\\d\\d|2[0-4]\\d|25[0-4]))|(?:(?:[a-z0-9\\u{00a1}-\\u{ffff}]+-)*[a-z0-9\\u{00a1}-\\u{ffff}]+)(?:\\.(?:[a-z0-9\\u{00a1}-\\u{ffff}]+-)*[a-z0-9\\u{00a1}-\\u{ffff}]+)*(?:\\.(?:[a-z\\u{00a1}-\\u{ffff}]{2,})))(?::\\d{2,5})?(?:\\/[^\\s]*)?$/iu,email:/^[a-z0-9!#$%&\'*+/=?^_`{|}~-]+(?:\\.[a-z0-9!#$%&\'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i,hostname:/^(?=.{1,253}\\.?$)[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\\.[a-z0-9](?:[-0-9a-z]{0,61}[0-9a-z])?)*\\.?$/i,ipv4:/^(?:(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)\\.){3}(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)$/,ipv6:/^((([0-9a-f]{1,4}:){7}([0-9a-f]{1,4}|:))|(([0-9a-f]{1,4}:){6}(:[0-9a-f]{1,4}|((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9a-f]{1,4}:){5}(((:[0-9a-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9a-f]{1,4}:){4}(((:[0-9a-f]{1,4}){1,3})|((:[0-9a-f]{1,4})?:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9a-f]{1,4}:){3}(((:[0-9a-f]{1,4}){1,4})|((:[0-9a-f]{1,4}){0,2}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9a-f]{1,4}:){2}(((:[0-9a-f]{1,4}){1,5})|((:[0-9a-f]{1,4}){0,3}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9a-f]{1,4}:){1}(((:[0-9a-f]{1,4}){1,6})|((:[0-9a-f]{1,4}){0,4}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(:(((:[0-9a-f]{1,4}){1,7})|((:[0-9a-f]{1,4}){0,5}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:)))$/i,regex:Ue,uuid:/^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i,"json-pointer":/^(?:\\/(?:[^~/]|~0|~1)*)*$/,"json-pointer-uri-fragment":/^#(?:\\/(?:[a-z0-9_\\-.!$&\'()*+,;:=@]|%[0-9a-f]{2}|~0|~1)*)*$/i,"relative-json-pointer":/^(?:0|[1-9][0-9]*)(?:#|(?:\\/(?:[^~/]|~0|~1)*)*)$/,byte:ne,int32:{type:"number",validate:Fe},int64:{type:"number",validate:ge},float:{type:"number",validate:He},double:{type:"number",validate:He},password:!0,binary:!0},r.fastFormats={...r.fullFormats,date:a(/^\\d\\d\\d\\d-[0-1]\\d-[0-3]\\d$/,s),time:a(/^(?:[0-2]\\d:[0-5]\\d:[0-5]\\d|23:59:60)(?:\\.\\d+)?(?:z|[+-]\\d\\d(?::?\\d\\d)?)$/i,d),"date-time":a(/^\\d\\d\\d\\d-[0-1]\\d-[0-3]\\dt(?:[0-2]\\d:[0-5]\\d:[0-5]\\d|23:59:60)(?:\\.\\d+)?(?:z|[+-]\\d\\d(?::?\\d\\d)?)$/i,P),"iso-time":a(/^(?:[0-2]\\d:[0-5]\\d:[0-5]\\d|23:59:60)(?:\\.\\d+)?(?:z|[+-]\\d\\d(?::?\\d\\d)?)?$/i,m),"iso-date-time":a(/^\\d\\d\\d\\d-[0-1]\\d-[0-3]\\d[t\\s](?:[0-2]\\d:[0-5]\\d:[0-5]\\d|23:59:60)(?:\\.\\d+)?(?:z|[+-]\\d\\d(?::?\\d\\d)?)?$/i,N),uri:/^(?:[a-z][a-z0-9+\\-.]*:)(?:\\/?\\/)?[^\\s]*$/i,"uri-reference":/^(?:(?:[a-z][a-z0-9+\\-.]*:)?\\/?\\/)?(?:[^\\\\\\s#][^\\s#]*)?(?:#[^\\\\\\s]*)?$/i,email:/^[a-z0-9.!#$%&\'*+/=?^_`{|}~-]+@[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$/i},r.formatNames=Object.keys(r.fullFormats);function n(H){return H%4===0&&(H%100!==0||H%400===0)}var l=/^(\\d\\d\\d\\d)-(\\d\\d)-(\\d\\d)$/,p=[0,31,28,31,30,31,30,31,31,30,31,30,31];function t(H){let le=l.exec(H);if(!le)return!1;let Ne=+le[1],xe=+le[2],er=+le[3];return xe>=1&&xe<=12&&er>=1&&er<=(xe===2&&n(Ne)?29:p[xe])}function s(H,le){if(H&&le)return H>le?1:H<le?-1:0}var o=/^(\\d\\d):(\\d\\d):(\\d\\d(?:\\.\\d+)?)(z|([+-])(\\d\\d)(?::?(\\d\\d))?)?$/i;function i(H){return function(le){let Ne=o.exec(le);if(!Ne)return!1;let xe=+Ne[1],er=+Ne[2],Jr=+Ne[3],oa=Ne[4],O=Ne[5]==="-"?-1:1,Gr=+(Ne[6]||0),Ht=+(Ne[7]||0);if(Gr>23||Ht>59||H&&!oa)return!1;if(xe<=23&&er<=59&&Jr<60)return!0;let ir=er-Ht*O,kr=xe-Gr*O-(ir<0?1:0);return(kr===23||kr===-1)&&(ir===59||ir===-1)&&Jr<61}}function d(H,le){if(!(H&&le))return;let Ne=new Date("2020-01-01T"+H).valueOf(),xe=new Date("2020-01-01T"+le).valueOf();if(Ne&&xe)return Ne-xe}function m(H,le){if(!(H&&le))return;let Ne=o.exec(H),xe=o.exec(le);if(Ne&&xe)return H=Ne[1]+Ne[2]+Ne[3],le=xe[1]+xe[2]+xe[3],H>le?1:H<le?-1:0}var h=/t|\\s/i;function c(H){let le=i(H);return function(Ne){let xe=Ne.split(h);return xe.length===2&&t(xe[0])&&le(xe[1])}}function P(H,le){if(!(H&&le))return;let Ne=new Date(H).valueOf(),xe=new Date(le).valueOf();if(Ne&&xe)return Ne-xe}function N(H,le){if(!(H&&le))return;let[Ne,xe]=H.split(h),[er,Jr]=le.split(h),oa=s(Ne,er);if(oa!==void 0)return oa||d(xe,Jr)}var Z=/\\/|:/,E=/^(?:[a-z][a-z0-9+\\-.]*:)(?:\\/?\\/(?:(?:[a-z0-9\\-._~!$&\'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\\d|[01]?\\d\\d?)\\.){3}(?:25[0-5]|2[0-4]\\d|[01]?\\d\\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\\.[a-z0-9\\-._~!$&\'()*+,;=:]+)\\]|(?:(?:25[0-5]|2[0-4]\\d|[01]?\\d\\d?)\\.){3}(?:25[0-5]|2[0-4]\\d|[01]?\\d\\d?)|(?:[a-z0-9\\-._~!$&\'()*+,;=]|%[0-9a-f]{2})*)(?::\\d*)?(?:\\/(?:[a-z0-9\\-._~!$&\'()*+,;=:@]|%[0-9a-f]{2})*)*|\\/(?:(?:[a-z0-9\\-._~!$&\'()*+,;=:@]|%[0-9a-f]{2})+(?:\\/(?:[a-z0-9\\-._~!$&\'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\\-._~!$&\'()*+,;=:@]|%[0-9a-f]{2})+(?:\\/(?:[a-z0-9\\-._~!$&\'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\\?(?:[a-z0-9\\-._~!$&\'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\\-._~!$&\'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i;function K(H){return Z.test(H)&&E.test(H)}var X=/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/gm;function ne(H){return X.lastIndex=0,X.test(H)}var ee=-(2**31),$e=2**31-1;function Fe(H){return Number.isInteger(H)&&H<=$e&&H>=ee}function ge(H){return Number.isInteger(H)}function He(){return!0}var Pt=/[^\\\\]\\\\Z/;function Ue(H){if(Pt.test(H))return!1;try{return new RegExp(H),!0}catch{return!1}}}),Xf=Cu,$d={properties:{source:{properties:{base:{type:["string","null"]},head:{type:["string","null"]}}}}},ho={properties:{type:{enum:["change","file","hunk","line-range","visual-target","visual-region","finding","verification-gap"]},ref:{type:"string",minLength:1},path:{type:"string"},side:{enum:["before","after","diff"]},startLine:{type:"integer",minimum:1},endLine:{type:"integer",minimum:1},targetRef:{type:"string"},region:{type:"object",additionalProperties:!1,required:["x","y","width","height"],properties:{x:{type:"number",minimum:0,maximum:1},y:{type:"number",minimum:0,maximum:1},width:{type:"number",exclusiveMinimum:0,maximum:1},height:{type:"number",exclusiveMinimum:0,maximum:1}}},selectorHint:{type:"string"},fingerprint:{type:"string",pattern:"^[a-f0-9]{64}$"}}},wt=Yf().default,hn=Object.prototype.hasOwnProperty,Is=new RegExp("^report[-:][A-Za-z0-9._:-]+$","u"),Tn=new RegExp("^[a-f0-9]{64}$","u"),Sa=Qf().fullFormats["date-time"];function Cu(r,{instancePath:a="",parentData:n,parentDataProperty:l,rootData:p=r}={}){let t=null,s=0;if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.schemaVersion===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"schemaVersion"},message:"must have required property \'schemaVersion\'"};t===null?t=[o]:t.push(o),s++}if(r.source===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"source"},message:"must have required property \'source\'"};t===null?t=[o]:t.push(o),s++}if(r.state===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"state"},message:"must have required property \'state\'"};t===null?t=[o]:t.push(o),s++}if(r.threads===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"threads"},message:"must have required property \'threads\'"};t===null?t=[o]:t.push(o),s++}if(r.events===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"events"},message:"must have required property \'events\'"};t===null?t=[o]:t.push(o),s++}if(r.anchorCatalog===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"anchorCatalog"},message:"must have required property \'anchorCatalog\'"};t===null?t=[o]:t.push(o),s++}if(r.exportedAt===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"exportedAt"},message:"must have required property \'exportedAt\'"};t===null?t=[o]:t.push(o),s++}for(let o in r)if(!(o==="schemaVersion"||o==="source"||o==="state"||o==="threads"||o==="events"||o==="anchorCatalog"||o==="exportedAt")){let i={instancePath:a,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:o},message:"must NOT have additional properties"};t===null?t=[i]:t.push(i),s++}if(r.schemaVersion!==void 0&&r.schemaVersion!=="1.0"){let o={instancePath:a+"/schemaVersion",schemaPath:"#/properties/schemaVersion/const",keyword:"const",params:{allowedValue:"1.0"},message:"must be equal to constant"};t===null?t=[o]:t.push(o),s++}if(r.source!==void 0){let o=r.source;if(o&&typeof o=="object"&&!Array.isArray(o)){if(o.reportId===void 0){let i={instancePath:a+"/source",schemaPath:"#/properties/source/required",keyword:"required",params:{missingProperty:"reportId"},message:"must have required property \'reportId\'"};t===null?t=[i]:t.push(i),s++}if(o.reportFingerprint===void 0){let i={instancePath:a+"/source",schemaPath:"#/properties/source/required",keyword:"required",params:{missingProperty:"reportFingerprint"},message:"must have required property \'reportFingerprint\'"};t===null?t=[i]:t.push(i),s++}if(o.base===void 0){let i={instancePath:a+"/source",schemaPath:"#/properties/source/required",keyword:"required",params:{missingProperty:"base"},message:"must have required property \'base\'"};t===null?t=[i]:t.push(i),s++}if(o.head===void 0){let i={instancePath:a+"/source",schemaPath:"#/properties/source/required",keyword:"required",params:{missingProperty:"head"},message:"must have required property \'head\'"};t===null?t=[i]:t.push(i),s++}for(let i in o)if(!(i==="reportId"||i==="reportFingerprint"||i==="base"||i==="head")){let d={instancePath:a+"/source",schemaPath:"#/properties/source/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:i},message:"must NOT have additional properties"};t===null?t=[d]:t.push(d),s++}if(o.reportId!==void 0){let i=o.reportId;if(typeof i=="string"){if(wt(i)>256){let d={instancePath:a+"/source/reportId",schemaPath:"#/properties/source/properties/reportId/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};t===null?t=[d]:t.push(d),s++}if(!Is.test(i)){let d={instancePath:a+"/source/reportId",schemaPath:"#/properties/source/properties/reportId/pattern",keyword:"pattern",params:{pattern:"^report[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^report[-:][A-Za-z0-9._:-]+$"\'};t===null?t=[d]:t.push(d),s++}}else{let d={instancePath:a+"/source/reportId",schemaPath:"#/properties/source/properties/reportId/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[d]:t.push(d),s++}}if(o.reportFingerprint!==void 0){let i=o.reportFingerprint;if(typeof i=="string"){if(!Tn.test(i)){let d={instancePath:a+"/source/reportFingerprint",schemaPath:"#/properties/source/properties/reportFingerprint/pattern",keyword:"pattern",params:{pattern:"^[a-f0-9]{64}$"},message:\'must match pattern "^[a-f0-9]{64}$"\'};t===null?t=[d]:t.push(d),s++}}else{let d={instancePath:a+"/source/reportFingerprint",schemaPath:"#/properties/source/properties/reportFingerprint/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[d]:t.push(d),s++}}if(o.base!==void 0){let i=o.base;if(typeof i!="string"&&i!==null){let d={instancePath:a+"/source/base",schemaPath:"#/properties/source/properties/base/type",keyword:"type",params:{type:$d.properties.source.properties.base.type},message:"must be string,null"};t===null?t=[d]:t.push(d),s++}}if(o.head!==void 0){let i=o.head;if(typeof i!="string"&&i!==null){let d={instancePath:a+"/source/head",schemaPath:"#/properties/source/properties/head/type",keyword:"type",params:{type:$d.properties.source.properties.head.type},message:"must be string,null"};t===null?t=[d]:t.push(d),s++}}}else{let i={instancePath:a+"/source",schemaPath:"#/properties/source/type",keyword:"type",params:{type:"object"},message:"must be object"};t===null?t=[i]:t.push(i),s++}}if(r.state!==void 0){let o=r.state;if(!(o&&typeof o=="object"&&!Array.isArray(o))){let i={instancePath:a+"/state",schemaPath:"#/properties/state/type",keyword:"type",params:{type:"object"},message:"must be object"};t===null?t=[i]:t.push(i),s++}}if(r.threads!==void 0){let o=r.threads;if(Array.isArray(o)){let i=o.length;for(let d=0;d<i;d++){let m=o[d];if(!(m&&typeof m=="object"&&!Array.isArray(m))){let h={instancePath:a+"/threads/"+d,schemaPath:"#/properties/threads/items/type",keyword:"type",params:{type:"object"},message:"must be object"};t===null?t=[h]:t.push(h),s++}}}else{let i={instancePath:a+"/threads",schemaPath:"#/properties/threads/type",keyword:"type",params:{type:"array"},message:"must be array"};t===null?t=[i]:t.push(i),s++}}if(r.events!==void 0){let o=r.events;if(Array.isArray(o)){let i=o.length;for(let d=0;d<i;d++){let m=o[d];if(!(m&&typeof m=="object"&&!Array.isArray(m))){let h={instancePath:a+"/events/"+d,schemaPath:"#/properties/events/items/type",keyword:"type",params:{type:"object"},message:"must be object"};t===null?t=[h]:t.push(h),s++}}}else{let i={instancePath:a+"/events",schemaPath:"#/properties/events/type",keyword:"type",params:{type:"array"},message:"must be array"};t===null?t=[i]:t.push(i),s++}}if(r.anchorCatalog!==void 0){let o=r.anchorCatalog;if(Array.isArray(o)){let i=o.length;for(let d=0;d<i;d++){let m=o[d];if(m&&typeof m=="object"&&!Array.isArray(m)){if(m.type===void 0){let h={instancePath:a+"/anchorCatalog/"+d,schemaPath:"#/$defs/reviewAnchor/required",keyword:"required",params:{missingProperty:"type"},message:"must have required property \'type\'"};t===null?t=[h]:t.push(h),s++}if(m.ref===void 0){let h={instancePath:a+"/anchorCatalog/"+d,schemaPath:"#/$defs/reviewAnchor/required",keyword:"required",params:{missingProperty:"ref"},message:"must have required property \'ref\'"};t===null?t=[h]:t.push(h),s++}if(m.fingerprint===void 0){let h={instancePath:a+"/anchorCatalog/"+d,schemaPath:"#/$defs/reviewAnchor/required",keyword:"required",params:{missingProperty:"fingerprint"},message:"must have required property \'fingerprint\'"};t===null?t=[h]:t.push(h),s++}for(let h in m)if(!hn.call(ho.properties,h)){let c={instancePath:a+"/anchorCatalog/"+d,schemaPath:"#/$defs/reviewAnchor/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:h},message:"must NOT have additional properties"};t===null?t=[c]:t.push(c),s++}if(m.type!==void 0){let h=m.type;if(!(h==="change"||h==="file"||h==="hunk"||h==="line-range"||h==="visual-target"||h==="visual-region"||h==="finding"||h==="verification-gap")){let c={instancePath:a+"/anchorCatalog/"+d+"/type",schemaPath:"#/$defs/reviewAnchor/properties/type/enum",keyword:"enum",params:{allowedValues:ho.properties.type.enum},message:"must be equal to one of the allowed values"};t===null?t=[c]:t.push(c),s++}}if(m.ref!==void 0){let h=m.ref;if(typeof h=="string"){if(wt(h)<1){let c={instancePath:a+"/anchorCatalog/"+d+"/ref",schemaPath:"#/$defs/reviewAnchor/properties/ref/minLength",keyword:"minLength",params:{limit:1},message:"must NOT have fewer than 1 characters"};t===null?t=[c]:t.push(c),s++}}else{let c={instancePath:a+"/anchorCatalog/"+d+"/ref",schemaPath:"#/$defs/reviewAnchor/properties/ref/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[c]:t.push(c),s++}}if(m.path!==void 0&&typeof m.path!="string"){let h={instancePath:a+"/anchorCatalog/"+d+"/path",schemaPath:"#/$defs/reviewAnchor/properties/path/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[h]:t.push(h),s++}if(m.side!==void 0){let h=m.side;if(!(h==="before"||h==="after"||h==="diff")){let c={instancePath:a+"/anchorCatalog/"+d+"/side",schemaPath:"#/$defs/reviewAnchor/properties/side/enum",keyword:"enum",params:{allowedValues:ho.properties.side.enum},message:"must be equal to one of the allowed values"};t===null?t=[c]:t.push(c),s++}}if(m.startLine!==void 0){let h=m.startLine;if(!(typeof h=="number"&&!(h%1)&&!isNaN(h))){let c={instancePath:a+"/anchorCatalog/"+d+"/startLine",schemaPath:"#/$defs/reviewAnchor/properties/startLine/type",keyword:"type",params:{type:"integer"},message:"must be integer"};t===null?t=[c]:t.push(c),s++}if(typeof h=="number"&&(h<1||isNaN(h))){let c={instancePath:a+"/anchorCatalog/"+d+"/startLine",schemaPath:"#/$defs/reviewAnchor/properties/startLine/minimum",keyword:"minimum",params:{comparison:">=",limit:1},message:"must be >= 1"};t===null?t=[c]:t.push(c),s++}}if(m.endLine!==void 0){let h=m.endLine;if(!(typeof h=="number"&&!(h%1)&&!isNaN(h))){let c={instancePath:a+"/anchorCatalog/"+d+"/endLine",schemaPath:"#/$defs/reviewAnchor/properties/endLine/type",keyword:"type",params:{type:"integer"},message:"must be integer"};t===null?t=[c]:t.push(c),s++}if(typeof h=="number"&&(h<1||isNaN(h))){let c={instancePath:a+"/anchorCatalog/"+d+"/endLine",schemaPath:"#/$defs/reviewAnchor/properties/endLine/minimum",keyword:"minimum",params:{comparison:">=",limit:1},message:"must be >= 1"};t===null?t=[c]:t.push(c),s++}}if(m.targetRef!==void 0&&typeof m.targetRef!="string"){let h={instancePath:a+"/anchorCatalog/"+d+"/targetRef",schemaPath:"#/$defs/reviewAnchor/properties/targetRef/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[h]:t.push(h),s++}if(m.region!==void 0){let h=m.region;if(h&&typeof h=="object"&&!Array.isArray(h)){if(h.x===void 0){let c={instancePath:a+"/anchorCatalog/"+d+"/region",schemaPath:"#/$defs/reviewAnchor/properties/region/required",keyword:"required",params:{missingProperty:"x"},message:"must have required property \'x\'"};t===null?t=[c]:t.push(c),s++}if(h.y===void 0){let c={instancePath:a+"/anchorCatalog/"+d+"/region",schemaPath:"#/$defs/reviewAnchor/properties/region/required",keyword:"required",params:{missingProperty:"y"},message:"must have required property \'y\'"};t===null?t=[c]:t.push(c),s++}if(h.width===void 0){let c={instancePath:a+"/anchorCatalog/"+d+"/region",schemaPath:"#/$defs/reviewAnchor/properties/region/required",keyword:"required",params:{missingProperty:"width"},message:"must have required property \'width\'"};t===null?t=[c]:t.push(c),s++}if(h.height===void 0){let c={instancePath:a+"/anchorCatalog/"+d+"/region",schemaPath:"#/$defs/reviewAnchor/properties/region/required",keyword:"required",params:{missingProperty:"height"},message:"must have required property \'height\'"};t===null?t=[c]:t.push(c),s++}for(let c in h)if(!(c==="x"||c==="y"||c==="width"||c==="height")){let P={instancePath:a+"/anchorCatalog/"+d+"/region",schemaPath:"#/$defs/reviewAnchor/properties/region/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:c},message:"must NOT have additional properties"};t===null?t=[P]:t.push(P),s++}if(h.x!==void 0){let c=h.x;if(typeof c=="number"){if(c>1||isNaN(c)){let P={instancePath:a+"/anchorCatalog/"+d+"/region/x",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/x/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};t===null?t=[P]:t.push(P),s++}if(c<0||isNaN(c)){let P={instancePath:a+"/anchorCatalog/"+d+"/region/x",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/x/minimum",keyword:"minimum",params:{comparison:">=",limit:0},message:"must be >= 0"};t===null?t=[P]:t.push(P),s++}}else{let P={instancePath:a+"/anchorCatalog/"+d+"/region/x",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/x/type",keyword:"type",params:{type:"number"},message:"must be number"};t===null?t=[P]:t.push(P),s++}}if(h.y!==void 0){let c=h.y;if(typeof c=="number"){if(c>1||isNaN(c)){let P={instancePath:a+"/anchorCatalog/"+d+"/region/y",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/y/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};t===null?t=[P]:t.push(P),s++}if(c<0||isNaN(c)){let P={instancePath:a+"/anchorCatalog/"+d+"/region/y",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/y/minimum",keyword:"minimum",params:{comparison:">=",limit:0},message:"must be >= 0"};t===null?t=[P]:t.push(P),s++}}else{let P={instancePath:a+"/anchorCatalog/"+d+"/region/y",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/y/type",keyword:"type",params:{type:"number"},message:"must be number"};t===null?t=[P]:t.push(P),s++}}if(h.width!==void 0){let c=h.width;if(typeof c=="number"){if(c>1||isNaN(c)){let P={instancePath:a+"/anchorCatalog/"+d+"/region/width",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/width/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};t===null?t=[P]:t.push(P),s++}if(c<=0||isNaN(c)){let P={instancePath:a+"/anchorCatalog/"+d+"/region/width",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/width/exclusiveMinimum",keyword:"exclusiveMinimum",params:{comparison:">",limit:0},message:"must be > 0"};t===null?t=[P]:t.push(P),s++}}else{let P={instancePath:a+"/anchorCatalog/"+d+"/region/width",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/width/type",keyword:"type",params:{type:"number"},message:"must be number"};t===null?t=[P]:t.push(P),s++}}if(h.height!==void 0){let c=h.height;if(typeof c=="number"){if(c>1||isNaN(c)){let P={instancePath:a+"/anchorCatalog/"+d+"/region/height",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/height/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};t===null?t=[P]:t.push(P),s++}if(c<=0||isNaN(c)){let P={instancePath:a+"/anchorCatalog/"+d+"/region/height",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/height/exclusiveMinimum",keyword:"exclusiveMinimum",params:{comparison:">",limit:0},message:"must be > 0"};t===null?t=[P]:t.push(P),s++}}else{let P={instancePath:a+"/anchorCatalog/"+d+"/region/height",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/height/type",keyword:"type",params:{type:"number"},message:"must be number"};t===null?t=[P]:t.push(P),s++}}}else{let c={instancePath:a+"/anchorCatalog/"+d+"/region",schemaPath:"#/$defs/reviewAnchor/properties/region/type",keyword:"type",params:{type:"object"},message:"must be object"};t===null?t=[c]:t.push(c),s++}}if(m.selectorHint!==void 0&&typeof m.selectorHint!="string"){let h={instancePath:a+"/anchorCatalog/"+d+"/selectorHint",schemaPath:"#/$defs/reviewAnchor/properties/selectorHint/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[h]:t.push(h),s++}if(m.fingerprint!==void 0){let h=m.fingerprint;if(typeof h=="string"){if(!Tn.test(h)){let c={instancePath:a+"/anchorCatalog/"+d+"/fingerprint",schemaPath:"#/$defs/reviewAnchor/properties/fingerprint/pattern",keyword:"pattern",params:{pattern:"^[a-f0-9]{64}$"},message:\'must match pattern "^[a-f0-9]{64}$"\'};t===null?t=[c]:t.push(c),s++}}else{let c={instancePath:a+"/anchorCatalog/"+d+"/fingerprint",schemaPath:"#/$defs/reviewAnchor/properties/fingerprint/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[c]:t.push(c),s++}}}else{let h={instancePath:a+"/anchorCatalog/"+d,schemaPath:"#/$defs/reviewAnchor/type",keyword:"type",params:{type:"object"},message:"must be object"};t===null?t=[h]:t.push(h),s++}}}else{let i={instancePath:a+"/anchorCatalog",schemaPath:"#/properties/anchorCatalog/type",keyword:"type",params:{type:"array"},message:"must be array"};t===null?t=[i]:t.push(i),s++}}if(r.exportedAt!==void 0){let o=r.exportedAt;if(typeof o=="string"){if(!Sa.validate(o)){let i={instancePath:a+"/exportedAt",schemaPath:"#/properties/exportedAt/format",keyword:"format",params:{format:"date-time"},message:\'must match format "date-time"\'};t===null?t=[i]:t.push(i),s++}}else{let i={instancePath:a+"/exportedAt",schemaPath:"#/properties/exportedAt/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[i]:t.push(i),s++}}}else{let o={instancePath:a,schemaPath:"#/type",keyword:"type",params:{type:"object"},message:"must be object"};t===null?t=[o]:t.push(o),s++}return Cu.errors=t,s===0}var em=Tu,Rn={properties:{schemaVersion:{const:"1.0"},id:{type:"string",pattern:"^event[-:][A-Za-z0-9._:-]+$",maxLength:256},reportId:{type:"string",pattern:"^report[-:][A-Za-z0-9._:-]+$",maxLength:256},sequence:{type:"integer",minimum:1},type:{enum:["viewed.changed","judgment.changed","thread.created","thread.message-added","thread.resolved","state.imported","agent-attention.changed","feedback-batch.stored","feedback-batch.claimed","feedback-batch.released","feedback-batch.answered","answer-read.changed"]},createdAt:{type:"string",format:"date-time"},anchor:{$ref:"#/$defs/reviewAnchor"},changeId:{type:"string",pattern:"^change[-:]"},viewState:{enum:["unseen","viewed","stale"]},judgmentState:{enum:["unreviewed","reviewed","follow-up","blocked","stale"]},threadId:{type:"string",pattern:"^thread[-:][A-Za-z0-9._:-]+$",maxLength:256},messageId:{type:"string",pattern:"^message[-:][A-Za-z0-9._:-]+$",maxLength:256},sourceReportId:{type:"string",pattern:"^report[-:][A-Za-z0-9._:-]+$",maxLength:256},attentionState:{enum:["none","requested","batched","submitted","acknowledged","answered","stale"]},batchId:{type:"string",pattern:"^fb[-:][A-Za-z0-9._:-]+$",maxLength:256},threadIds:{type:"array",maxItems:20,items:{type:"string",pattern:"^thread[-:][A-Za-z0-9._:-]+$",maxLength:256},uniqueItems:!0},itemIds:{type:"array",maxItems:20,items:{type:"string",pattern:"^item[-:][A-Za-z0-9._:-]+$",maxLength:256},uniqueItems:!0},itemCount:{type:"integer",minimum:1,maximum:20},deliveryMode:{enum:["direct-same-session","return-to-session","export-only"]},answerUnread:{type:"boolean"},originSessionMatched:{type:"boolean"}}},fo={properties:{type:{enum:["change","file","hunk","line-range","visual-target","visual-region","finding","verification-gap"]},ref:{type:"string",minLength:1},path:{type:"string"},side:{enum:["before","after","diff"]},startLine:{type:"integer",minimum:1},endLine:{type:"integer",minimum:1},targetRef:{type:"string"},region:{type:"object",additionalProperties:!1,required:["x","y","width","height"],properties:{x:{type:"number",minimum:0,maximum:1},y:{type:"number",minimum:0,maximum:1},width:{type:"number",exclusiveMinimum:0,maximum:1},height:{type:"number",exclusiveMinimum:0,maximum:1}}},selectorHint:{type:"string"},fingerprint:{type:"string",pattern:"^[a-f0-9]{64}$"}}},tm=new RegExp("^event[-:][A-Za-z0-9._:-]+$","u"),rm=new RegExp("^change[-:]","u"),$s=new RegExp("^thread[-:][A-Za-z0-9._:-]+$","u"),Lu=new RegExp("^message[-:][A-Za-z0-9._:-]+$","u"),ju=new RegExp("^fb[-:][A-Za-z0-9._:-]+$","u"),Ou=new RegExp("^item[-:][A-Za-z0-9._:-]+$","u");function Tu(r,{instancePath:a="",parentData:n,parentDataProperty:l,rootData:p=r}={}){let t=null,s=0,o=s,i=!0,d=s;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.type!==void 0&&r.type!=="viewed.changed"){let g={};t===null?t=[g]:t.push(g),s++}var m=d===s;if(s=o,t!==null&&(o?t.length=o:t=null),m){let g=s;if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.anchor===void 0){let x={instancePath:a,schemaPath:"#/allOf/0/then/required",keyword:"required",params:{missingProperty:"anchor"},message:"must have required property \'anchor\'"};t===null?t=[x]:t.push(x),s++}if(r.viewState===void 0){let x={instancePath:a,schemaPath:"#/allOf/0/then/required",keyword:"required",params:{missingProperty:"viewState"},message:"must have required property \'viewState\'"};t===null?t=[x]:t.push(x),s++}}var m=g===s;i=m}if(!i){let g={instancePath:a,schemaPath:"#/allOf/0/if",keyword:"if",params:{failingKeyword:"then"},message:\'must match "then" schema\'};t===null?t=[g]:t.push(g),s++}let h=s,c=!0,P=s;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.type!==void 0&&r.type!=="judgment.changed"){let g={};t===null?t=[g]:t.push(g),s++}var N=P===s;if(s=h,t!==null&&(h?t.length=h:t=null),N){let g=s;if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.changeId===void 0){let x={instancePath:a,schemaPath:"#/allOf/1/then/required",keyword:"required",params:{missingProperty:"changeId"},message:"must have required property \'changeId\'"};t===null?t=[x]:t.push(x),s++}if(r.judgmentState===void 0){let x={instancePath:a,schemaPath:"#/allOf/1/then/required",keyword:"required",params:{missingProperty:"judgmentState"},message:"must have required property \'judgmentState\'"};t===null?t=[x]:t.push(x),s++}}var N=g===s;c=N}if(!c){let g={instancePath:a,schemaPath:"#/allOf/1/if",keyword:"if",params:{failingKeyword:"then"},message:\'must match "then" schema\'};t===null?t=[g]:t.push(g),s++}let Z=s,E=!0,K=s;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.type!==void 0&&r.type!=="thread.created"){let g={};t===null?t=[g]:t.push(g),s++}var X=K===s;if(s=Z,t!==null&&(Z?t.length=Z:t=null),X){let g=s;if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.anchor===void 0){let x={instancePath:a,schemaPath:"#/allOf/2/then/required",keyword:"required",params:{missingProperty:"anchor"},message:"must have required property \'anchor\'"};t===null?t=[x]:t.push(x),s++}if(r.threadId===void 0){let x={instancePath:a,schemaPath:"#/allOf/2/then/required",keyword:"required",params:{missingProperty:"threadId"},message:"must have required property \'threadId\'"};t===null?t=[x]:t.push(x),s++}if(r.messageId===void 0){let x={instancePath:a,schemaPath:"#/allOf/2/then/required",keyword:"required",params:{missingProperty:"messageId"},message:"must have required property \'messageId\'"};t===null?t=[x]:t.push(x),s++}}var X=g===s;E=X}if(!E){let g={instancePath:a,schemaPath:"#/allOf/2/if",keyword:"if",params:{failingKeyword:"then"},message:\'must match "then" schema\'};t===null?t=[g]:t.push(g),s++}let ne=s,ee=!0,$e=s;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.type!==void 0&&r.type!=="thread.message-added"){let g={};t===null?t=[g]:t.push(g),s++}var Fe=$e===s;if(s=ne,t!==null&&(ne?t.length=ne:t=null),Fe){let g=s;if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.threadId===void 0){let x={instancePath:a,schemaPath:"#/allOf/3/then/required",keyword:"required",params:{missingProperty:"threadId"},message:"must have required property \'threadId\'"};t===null?t=[x]:t.push(x),s++}if(r.messageId===void 0){let x={instancePath:a,schemaPath:"#/allOf/3/then/required",keyword:"required",params:{missingProperty:"messageId"},message:"must have required property \'messageId\'"};t===null?t=[x]:t.push(x),s++}}var Fe=g===s;ee=Fe}if(!ee){let g={instancePath:a,schemaPath:"#/allOf/3/if",keyword:"if",params:{failingKeyword:"then"},message:\'must match "then" schema\'};t===null?t=[g]:t.push(g),s++}let ge=s,He=!0,Pt=s;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.type!==void 0&&r.type!=="thread.resolved"){let g={};t===null?t=[g]:t.push(g),s++}var Ue=Pt===s;if(s=ge,t!==null&&(ge?t.length=ge:t=null),Ue){let g=s;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.threadId===void 0){let x={instancePath:a,schemaPath:"#/allOf/4/then/required",keyword:"required",params:{missingProperty:"threadId"},message:"must have required property \'threadId\'"};t===null?t=[x]:t.push(x),s++}var Ue=g===s;He=Ue}if(!He){let g={instancePath:a,schemaPath:"#/allOf/4/if",keyword:"if",params:{failingKeyword:"then"},message:\'must match "then" schema\'};t===null?t=[g]:t.push(g),s++}let H=s,le=!0,Ne=s;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.type!==void 0&&r.type!=="state.imported"){let g={};t===null?t=[g]:t.push(g),s++}var xe=Ne===s;if(s=H,t!==null&&(H?t.length=H:t=null),xe){let g=s;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.sourceReportId===void 0){let x={instancePath:a,schemaPath:"#/allOf/5/then/required",keyword:"required",params:{missingProperty:"sourceReportId"},message:"must have required property \'sourceReportId\'"};t===null?t=[x]:t.push(x),s++}var xe=g===s;le=xe}if(!le){let g={instancePath:a,schemaPath:"#/allOf/5/if",keyword:"if",params:{failingKeyword:"then"},message:\'must match "then" schema\'};t===null?t=[g]:t.push(g),s++}let er=s,Jr=!0,oa=s;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.type!==void 0&&r.type!=="agent-attention.changed"){let g={};t===null?t=[g]:t.push(g),s++}var O=oa===s;if(s=er,t!==null&&(er?t.length=er:t=null),O){let g=s;if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.threadId===void 0){let x={instancePath:a,schemaPath:"#/allOf/6/then/required",keyword:"required",params:{missingProperty:"threadId"},message:"must have required property \'threadId\'"};t===null?t=[x]:t.push(x),s++}if(r.attentionState===void 0){let x={instancePath:a,schemaPath:"#/allOf/6/then/required",keyword:"required",params:{missingProperty:"attentionState"},message:"must have required property \'attentionState\'"};t===null?t=[x]:t.push(x),s++}}var O=g===s;Jr=O}if(!Jr){let g={instancePath:a,schemaPath:"#/allOf/6/if",keyword:"if",params:{failingKeyword:"then"},message:\'must match "then" schema\'};t===null?t=[g]:t.push(g),s++}let Gr=s,Ht=!0,ir=s;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.type!==void 0&&r.type!=="feedback-batch.stored"){let g={};t===null?t=[g]:t.push(g),s++}var kr=ir===s;if(s=Gr,t!==null&&(Gr?t.length=Gr:t=null),kr){let g=s;if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.batchId===void 0){let x={instancePath:a,schemaPath:"#/allOf/7/then/required",keyword:"required",params:{missingProperty:"batchId"},message:"must have required property \'batchId\'"};t===null?t=[x]:t.push(x),s++}if(r.threadIds===void 0){let x={instancePath:a,schemaPath:"#/allOf/7/then/required",keyword:"required",params:{missingProperty:"threadIds"},message:"must have required property \'threadIds\'"};t===null?t=[x]:t.push(x),s++}if(r.itemCount===void 0){let x={instancePath:a,schemaPath:"#/allOf/7/then/required",keyword:"required",params:{missingProperty:"itemCount"},message:"must have required property \'itemCount\'"};t===null?t=[x]:t.push(x),s++}if(r.deliveryMode===void 0){let x={instancePath:a,schemaPath:"#/allOf/7/then/required",keyword:"required",params:{missingProperty:"deliveryMode"},message:"must have required property \'deliveryMode\'"};t===null?t=[x]:t.push(x),s++}}var kr=g===s;Ht=kr}if(!Ht){let g={instancePath:a,schemaPath:"#/allOf/7/if",keyword:"if",params:{failingKeyword:"then"},message:\'must match "then" schema\'};t===null?t=[g]:t.push(g),s++}let Ca=s,xr=!0,or=s;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.type!==void 0&&r.type!=="feedback-batch.claimed"){let g={};t===null?t=[g]:t.push(g),s++}var Je=or===s;if(s=Ca,t!==null&&(Ca?t.length=Ca:t=null),Je){let g=s;if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.batchId===void 0){let x={instancePath:a,schemaPath:"#/allOf/8/then/required",keyword:"required",params:{missingProperty:"batchId"},message:"must have required property \'batchId\'"};t===null?t=[x]:t.push(x),s++}if(r.originSessionMatched===void 0){let x={instancePath:a,schemaPath:"#/allOf/8/then/required",keyword:"required",params:{missingProperty:"originSessionMatched"},message:"must have required property \'originSessionMatched\'"};t===null?t=[x]:t.push(x),s++}}var Je=g===s;xr=Je}if(!xr){let g={instancePath:a,schemaPath:"#/allOf/8/if",keyword:"if",params:{failingKeyword:"then"},message:\'must match "then" schema\'};t===null?t=[g]:t.push(g),s++}let T=s,Ar=!0,Ir=s;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.type!==void 0&&r.type!=="feedback-batch.released"){let g={};t===null?t=[g]:t.push(g),s++}var j=Ir===s;if(s=T,t!==null&&(T?t.length=T:t=null),j){let g=s;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.batchId===void 0){let x={instancePath:a,schemaPath:"#/allOf/9/then/required",keyword:"required",params:{missingProperty:"batchId"},message:"must have required property \'batchId\'"};t===null?t=[x]:t.push(x),s++}var j=g===s;Ar=j}if(!Ar){let g={instancePath:a,schemaPath:"#/allOf/9/if",keyword:"if",params:{failingKeyword:"then"},message:\'must match "then" schema\'};t===null?t=[g]:t.push(g),s++}let mn=s,Yr=!0,it=s;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.type!==void 0&&r.type!=="feedback-batch.answered"){let g={};t===null?t=[g]:t.push(g),s++}var Ga=it===s;if(s=mn,t!==null&&(mn?t.length=mn:t=null),Ga){let g=s;if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.batchId===void 0){let x={instancePath:a,schemaPath:"#/allOf/10/then/required",keyword:"required",params:{missingProperty:"batchId"},message:"must have required property \'batchId\'"};t===null?t=[x]:t.push(x),s++}if(r.itemIds===void 0){let x={instancePath:a,schemaPath:"#/allOf/10/then/required",keyword:"required",params:{missingProperty:"itemIds"},message:"must have required property \'itemIds\'"};t===null?t=[x]:t.push(x),s++}}var Ga=g===s;Yr=Ga}if(!Yr){let g={instancePath:a,schemaPath:"#/allOf/10/if",keyword:"if",params:{failingKeyword:"then"},message:\'must match "then" schema\'};t===null?t=[g]:t.push(g),s++}let Q=s,tr=!0,kt=s;if(r&&typeof r=="object"&&!Array.isArray(r)&&r.type!==void 0&&r.type!=="answer-read.changed"){let g={};t===null?t=[g]:t.push(g),s++}var $r=kt===s;if(s=Q,t!==null&&(Q?t.length=Q:t=null),$r){let g=s;if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.batchId===void 0){let x={instancePath:a,schemaPath:"#/allOf/11/then/required",keyword:"required",params:{missingProperty:"batchId"},message:"must have required property \'batchId\'"};t===null?t=[x]:t.push(x),s++}if(r.itemIds===void 0){let x={instancePath:a,schemaPath:"#/allOf/11/then/required",keyword:"required",params:{missingProperty:"itemIds"},message:"must have required property \'itemIds\'"};t===null?t=[x]:t.push(x),s++}if(r.answerUnread===void 0){let x={instancePath:a,schemaPath:"#/allOf/11/then/required",keyword:"required",params:{missingProperty:"answerUnread"},message:"must have required property \'answerUnread\'"};t===null?t=[x]:t.push(x),s++}}var $r=g===s;tr=$r}if(!tr){let g={instancePath:a,schemaPath:"#/allOf/11/if",keyword:"if",params:{failingKeyword:"then"},message:\'must match "then" schema\'};t===null?t=[g]:t.push(g),s++}if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.schemaVersion===void 0){let g={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"schemaVersion"},message:"must have required property \'schemaVersion\'"};t===null?t=[g]:t.push(g),s++}if(r.id===void 0){let g={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"id"},message:"must have required property \'id\'"};t===null?t=[g]:t.push(g),s++}if(r.reportId===void 0){let g={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"reportId"},message:"must have required property \'reportId\'"};t===null?t=[g]:t.push(g),s++}if(r.sequence===void 0){let g={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"sequence"},message:"must have required property \'sequence\'"};t===null?t=[g]:t.push(g),s++}if(r.type===void 0){let g={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"type"},message:"must have required property \'type\'"};t===null?t=[g]:t.push(g),s++}if(r.createdAt===void 0){let g={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"createdAt"},message:"must have required property \'createdAt\'"};t===null?t=[g]:t.push(g),s++}for(let g in r)if(!hn.call(Rn.properties,g)){let w={instancePath:a,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:g},message:"must NOT have additional properties"};t===null?t=[w]:t.push(w),s++}if(r.schemaVersion!==void 0&&r.schemaVersion!=="1.0"){let g={instancePath:a+"/schemaVersion",schemaPath:"#/properties/schemaVersion/const",keyword:"const",params:{allowedValue:"1.0"},message:"must be equal to constant"};t===null?t=[g]:t.push(g),s++}if(r.id!==void 0){let g=r.id;if(typeof g=="string"){if(wt(g)>256){let w={instancePath:a+"/id",schemaPath:"#/properties/id/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};t===null?t=[w]:t.push(w),s++}if(!tm.test(g)){let w={instancePath:a+"/id",schemaPath:"#/properties/id/pattern",keyword:"pattern",params:{pattern:"^event[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^event[-:][A-Za-z0-9._:-]+$"\'};t===null?t=[w]:t.push(w),s++}}else{let w={instancePath:a+"/id",schemaPath:"#/properties/id/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[w]:t.push(w),s++}}if(r.reportId!==void 0){let g=r.reportId;if(typeof g=="string"){if(wt(g)>256){let w={instancePath:a+"/reportId",schemaPath:"#/properties/reportId/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};t===null?t=[w]:t.push(w),s++}if(!Is.test(g)){let w={instancePath:a+"/reportId",schemaPath:"#/properties/reportId/pattern",keyword:"pattern",params:{pattern:"^report[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^report[-:][A-Za-z0-9._:-]+$"\'};t===null?t=[w]:t.push(w),s++}}else{let w={instancePath:a+"/reportId",schemaPath:"#/properties/reportId/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[w]:t.push(w),s++}}if(r.sequence!==void 0){let g=r.sequence;if(!(typeof g=="number"&&!(g%1)&&!isNaN(g))){let w={instancePath:a+"/sequence",schemaPath:"#/properties/sequence/type",keyword:"type",params:{type:"integer"},message:"must be integer"};t===null?t=[w]:t.push(w),s++}if(typeof g=="number"&&(g<1||isNaN(g))){let w={instancePath:a+"/sequence",schemaPath:"#/properties/sequence/minimum",keyword:"minimum",params:{comparison:">=",limit:1},message:"must be >= 1"};t===null?t=[w]:t.push(w),s++}}if(r.type!==void 0){let g=r.type;if(!(g==="viewed.changed"||g==="judgment.changed"||g==="thread.created"||g==="thread.message-added"||g==="thread.resolved"||g==="state.imported"||g==="agent-attention.changed"||g==="feedback-batch.stored"||g==="feedback-batch.claimed"||g==="feedback-batch.released"||g==="feedback-batch.answered"||g==="answer-read.changed")){let w={instancePath:a+"/type",schemaPath:"#/properties/type/enum",keyword:"enum",params:{allowedValues:Rn.properties.type.enum},message:"must be equal to one of the allowed values"};t===null?t=[w]:t.push(w),s++}}if(r.createdAt!==void 0){let g=r.createdAt;if(typeof g=="string"){if(!Sa.validate(g)){let w={instancePath:a+"/createdAt",schemaPath:"#/properties/createdAt/format",keyword:"format",params:{format:"date-time"},message:\'must match format "date-time"\'};t===null?t=[w]:t.push(w),s++}}else{let w={instancePath:a+"/createdAt",schemaPath:"#/properties/createdAt/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[w]:t.push(w),s++}}if(r.anchor!==void 0){let g=r.anchor;if(g&&typeof g=="object"&&!Array.isArray(g)){if(g.type===void 0){let w={instancePath:a+"/anchor",schemaPath:"#/$defs/reviewAnchor/required",keyword:"required",params:{missingProperty:"type"},message:"must have required property \'type\'"};t===null?t=[w]:t.push(w),s++}if(g.ref===void 0){let w={instancePath:a+"/anchor",schemaPath:"#/$defs/reviewAnchor/required",keyword:"required",params:{missingProperty:"ref"},message:"must have required property \'ref\'"};t===null?t=[w]:t.push(w),s++}if(g.fingerprint===void 0){let w={instancePath:a+"/anchor",schemaPath:"#/$defs/reviewAnchor/required",keyword:"required",params:{missingProperty:"fingerprint"},message:"must have required property \'fingerprint\'"};t===null?t=[w]:t.push(w),s++}for(let w in g)if(!hn.call(fo.properties,w)){let x={instancePath:a+"/anchor",schemaPath:"#/$defs/reviewAnchor/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:w},message:"must NOT have additional properties"};t===null?t=[x]:t.push(x),s++}if(g.type!==void 0){let w=g.type;if(!(w==="change"||w==="file"||w==="hunk"||w==="line-range"||w==="visual-target"||w==="visual-region"||w==="finding"||w==="verification-gap")){let x={instancePath:a+"/anchor/type",schemaPath:"#/$defs/reviewAnchor/properties/type/enum",keyword:"enum",params:{allowedValues:fo.properties.type.enum},message:"must be equal to one of the allowed values"};t===null?t=[x]:t.push(x),s++}}if(g.ref!==void 0){let w=g.ref;if(typeof w=="string"){if(wt(w)<1){let x={instancePath:a+"/anchor/ref",schemaPath:"#/$defs/reviewAnchor/properties/ref/minLength",keyword:"minLength",params:{limit:1},message:"must NOT have fewer than 1 characters"};t===null?t=[x]:t.push(x),s++}}else{let x={instancePath:a+"/anchor/ref",schemaPath:"#/$defs/reviewAnchor/properties/ref/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[x]:t.push(x),s++}}if(g.path!==void 0&&typeof g.path!="string"){let w={instancePath:a+"/anchor/path",schemaPath:"#/$defs/reviewAnchor/properties/path/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[w]:t.push(w),s++}if(g.side!==void 0){let w=g.side;if(!(w==="before"||w==="after"||w==="diff")){let x={instancePath:a+"/anchor/side",schemaPath:"#/$defs/reviewAnchor/properties/side/enum",keyword:"enum",params:{allowedValues:fo.properties.side.enum},message:"must be equal to one of the allowed values"};t===null?t=[x]:t.push(x),s++}}if(g.startLine!==void 0){let w=g.startLine;if(!(typeof w=="number"&&!(w%1)&&!isNaN(w))){let x={instancePath:a+"/anchor/startLine",schemaPath:"#/$defs/reviewAnchor/properties/startLine/type",keyword:"type",params:{type:"integer"},message:"must be integer"};t===null?t=[x]:t.push(x),s++}if(typeof w=="number"&&(w<1||isNaN(w))){let x={instancePath:a+"/anchor/startLine",schemaPath:"#/$defs/reviewAnchor/properties/startLine/minimum",keyword:"minimum",params:{comparison:">=",limit:1},message:"must be >= 1"};t===null?t=[x]:t.push(x),s++}}if(g.endLine!==void 0){let w=g.endLine;if(!(typeof w=="number"&&!(w%1)&&!isNaN(w))){let x={instancePath:a+"/anchor/endLine",schemaPath:"#/$defs/reviewAnchor/properties/endLine/type",keyword:"type",params:{type:"integer"},message:"must be integer"};t===null?t=[x]:t.push(x),s++}if(typeof w=="number"&&(w<1||isNaN(w))){let x={instancePath:a+"/anchor/endLine",schemaPath:"#/$defs/reviewAnchor/properties/endLine/minimum",keyword:"minimum",params:{comparison:">=",limit:1},message:"must be >= 1"};t===null?t=[x]:t.push(x),s++}}if(g.targetRef!==void 0&&typeof g.targetRef!="string"){let w={instancePath:a+"/anchor/targetRef",schemaPath:"#/$defs/reviewAnchor/properties/targetRef/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[w]:t.push(w),s++}if(g.region!==void 0){let w=g.region;if(w&&typeof w=="object"&&!Array.isArray(w)){if(w.x===void 0){let x={instancePath:a+"/anchor/region",schemaPath:"#/$defs/reviewAnchor/properties/region/required",keyword:"required",params:{missingProperty:"x"},message:"must have required property \'x\'"};t===null?t=[x]:t.push(x),s++}if(w.y===void 0){let x={instancePath:a+"/anchor/region",schemaPath:"#/$defs/reviewAnchor/properties/region/required",keyword:"required",params:{missingProperty:"y"},message:"must have required property \'y\'"};t===null?t=[x]:t.push(x),s++}if(w.width===void 0){let x={instancePath:a+"/anchor/region",schemaPath:"#/$defs/reviewAnchor/properties/region/required",keyword:"required",params:{missingProperty:"width"},message:"must have required property \'width\'"};t===null?t=[x]:t.push(x),s++}if(w.height===void 0){let x={instancePath:a+"/anchor/region",schemaPath:"#/$defs/reviewAnchor/properties/region/required",keyword:"required",params:{missingProperty:"height"},message:"must have required property \'height\'"};t===null?t=[x]:t.push(x),s++}for(let x in w)if(!(x==="x"||x==="y"||x==="width"||x==="height")){let G={instancePath:a+"/anchor/region",schemaPath:"#/$defs/reviewAnchor/properties/region/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:x},message:"must NOT have additional properties"};t===null?t=[G]:t.push(G),s++}if(w.x!==void 0){let x=w.x;if(typeof x=="number"){if(x>1||isNaN(x)){let G={instancePath:a+"/anchor/region/x",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/x/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};t===null?t=[G]:t.push(G),s++}if(x<0||isNaN(x)){let G={instancePath:a+"/anchor/region/x",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/x/minimum",keyword:"minimum",params:{comparison:">=",limit:0},message:"must be >= 0"};t===null?t=[G]:t.push(G),s++}}else{let G={instancePath:a+"/anchor/region/x",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/x/type",keyword:"type",params:{type:"number"},message:"must be number"};t===null?t=[G]:t.push(G),s++}}if(w.y!==void 0){let x=w.y;if(typeof x=="number"){if(x>1||isNaN(x)){let G={instancePath:a+"/anchor/region/y",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/y/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};t===null?t=[G]:t.push(G),s++}if(x<0||isNaN(x)){let G={instancePath:a+"/anchor/region/y",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/y/minimum",keyword:"minimum",params:{comparison:">=",limit:0},message:"must be >= 0"};t===null?t=[G]:t.push(G),s++}}else{let G={instancePath:a+"/anchor/region/y",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/y/type",keyword:"type",params:{type:"number"},message:"must be number"};t===null?t=[G]:t.push(G),s++}}if(w.width!==void 0){let x=w.width;if(typeof x=="number"){if(x>1||isNaN(x)){let G={instancePath:a+"/anchor/region/width",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/width/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};t===null?t=[G]:t.push(G),s++}if(x<=0||isNaN(x)){let G={instancePath:a+"/anchor/region/width",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/width/exclusiveMinimum",keyword:"exclusiveMinimum",params:{comparison:">",limit:0},message:"must be > 0"};t===null?t=[G]:t.push(G),s++}}else{let G={instancePath:a+"/anchor/region/width",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/width/type",keyword:"type",params:{type:"number"},message:"must be number"};t===null?t=[G]:t.push(G),s++}}if(w.height!==void 0){let x=w.height;if(typeof x=="number"){if(x>1||isNaN(x)){let G={instancePath:a+"/anchor/region/height",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/height/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};t===null?t=[G]:t.push(G),s++}if(x<=0||isNaN(x)){let G={instancePath:a+"/anchor/region/height",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/height/exclusiveMinimum",keyword:"exclusiveMinimum",params:{comparison:">",limit:0},message:"must be > 0"};t===null?t=[G]:t.push(G),s++}}else{let G={instancePath:a+"/anchor/region/height",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/height/type",keyword:"type",params:{type:"number"},message:"must be number"};t===null?t=[G]:t.push(G),s++}}}else{let x={instancePath:a+"/anchor/region",schemaPath:"#/$defs/reviewAnchor/properties/region/type",keyword:"type",params:{type:"object"},message:"must be object"};t===null?t=[x]:t.push(x),s++}}if(g.selectorHint!==void 0&&typeof g.selectorHint!="string"){let w={instancePath:a+"/anchor/selectorHint",schemaPath:"#/$defs/reviewAnchor/properties/selectorHint/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[w]:t.push(w),s++}if(g.fingerprint!==void 0){let w=g.fingerprint;if(typeof w=="string"){if(!Tn.test(w)){let x={instancePath:a+"/anchor/fingerprint",schemaPath:"#/$defs/reviewAnchor/properties/fingerprint/pattern",keyword:"pattern",params:{pattern:"^[a-f0-9]{64}$"},message:\'must match pattern "^[a-f0-9]{64}$"\'};t===null?t=[x]:t.push(x),s++}}else{let x={instancePath:a+"/anchor/fingerprint",schemaPath:"#/$defs/reviewAnchor/properties/fingerprint/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[x]:t.push(x),s++}}}else{let w={instancePath:a+"/anchor",schemaPath:"#/$defs/reviewAnchor/type",keyword:"type",params:{type:"object"},message:"must be object"};t===null?t=[w]:t.push(w),s++}}if(r.changeId!==void 0){let g=r.changeId;if(typeof g=="string"){if(!rm.test(g)){let w={instancePath:a+"/changeId",schemaPath:"#/properties/changeId/pattern",keyword:"pattern",params:{pattern:"^change[-:]"},message:\'must match pattern "^change[-:]"\'};t===null?t=[w]:t.push(w),s++}}else{let w={instancePath:a+"/changeId",schemaPath:"#/properties/changeId/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[w]:t.push(w),s++}}if(r.viewState!==void 0){let g=r.viewState;if(!(g==="unseen"||g==="viewed"||g==="stale")){let w={instancePath:a+"/viewState",schemaPath:"#/properties/viewState/enum",keyword:"enum",params:{allowedValues:Rn.properties.viewState.enum},message:"must be equal to one of the allowed values"};t===null?t=[w]:t.push(w),s++}}if(r.judgmentState!==void 0){let g=r.judgmentState;if(!(g==="unreviewed"||g==="reviewed"||g==="follow-up"||g==="blocked"||g==="stale")){let w={instancePath:a+"/judgmentState",schemaPath:"#/properties/judgmentState/enum",keyword:"enum",params:{allowedValues:Rn.properties.judgmentState.enum},message:"must be equal to one of the allowed values"};t===null?t=[w]:t.push(w),s++}}if(r.threadId!==void 0){let g=r.threadId;if(typeof g=="string"){if(wt(g)>256){let w={instancePath:a+"/threadId",schemaPath:"#/properties/threadId/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};t===null?t=[w]:t.push(w),s++}if(!$s.test(g)){let w={instancePath:a+"/threadId",schemaPath:"#/properties/threadId/pattern",keyword:"pattern",params:{pattern:"^thread[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^thread[-:][A-Za-z0-9._:-]+$"\'};t===null?t=[w]:t.push(w),s++}}else{let w={instancePath:a+"/threadId",schemaPath:"#/properties/threadId/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[w]:t.push(w),s++}}if(r.messageId!==void 0){let g=r.messageId;if(typeof g=="string"){if(wt(g)>256){let w={instancePath:a+"/messageId",schemaPath:"#/properties/messageId/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};t===null?t=[w]:t.push(w),s++}if(!Lu.test(g)){let w={instancePath:a+"/messageId",schemaPath:"#/properties/messageId/pattern",keyword:"pattern",params:{pattern:"^message[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^message[-:][A-Za-z0-9._:-]+$"\'};t===null?t=[w]:t.push(w),s++}}else{let w={instancePath:a+"/messageId",schemaPath:"#/properties/messageId/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[w]:t.push(w),s++}}if(r.sourceReportId!==void 0){let g=r.sourceReportId;if(typeof g=="string"){if(wt(g)>256){let w={instancePath:a+"/sourceReportId",schemaPath:"#/properties/sourceReportId/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};t===null?t=[w]:t.push(w),s++}if(!Is.test(g)){let w={instancePath:a+"/sourceReportId",schemaPath:"#/properties/sourceReportId/pattern",keyword:"pattern",params:{pattern:"^report[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^report[-:][A-Za-z0-9._:-]+$"\'};t===null?t=[w]:t.push(w),s++}}else{let w={instancePath:a+"/sourceReportId",schemaPath:"#/properties/sourceReportId/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[w]:t.push(w),s++}}if(r.attentionState!==void 0){let g=r.attentionState;if(!(g==="none"||g==="requested"||g==="batched"||g==="submitted"||g==="acknowledged"||g==="answered"||g==="stale")){let w={instancePath:a+"/attentionState",schemaPath:"#/properties/attentionState/enum",keyword:"enum",params:{allowedValues:Rn.properties.attentionState.enum},message:"must be equal to one of the allowed values"};t===null?t=[w]:t.push(w),s++}}if(r.batchId!==void 0){let g=r.batchId;if(typeof g=="string"){if(wt(g)>256){let w={instancePath:a+"/batchId",schemaPath:"#/properties/batchId/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};t===null?t=[w]:t.push(w),s++}if(!ju.test(g)){let w={instancePath:a+"/batchId",schemaPath:"#/properties/batchId/pattern",keyword:"pattern",params:{pattern:"^fb[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^fb[-:][A-Za-z0-9._:-]+$"\'};t===null?t=[w]:t.push(w),s++}}else{let w={instancePath:a+"/batchId",schemaPath:"#/properties/batchId/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[w]:t.push(w),s++}}if(r.threadIds!==void 0){let g=r.threadIds;if(Array.isArray(g)){if(g.length>20){let fe={instancePath:a+"/threadIds",schemaPath:"#/properties/threadIds/maxItems",keyword:"maxItems",params:{limit:20},message:"must NOT have more than 20 items"};t===null?t=[fe]:t.push(fe),s++}let w=g.length;for(let fe=0;fe<w;fe++){let te=g[fe];if(typeof te=="string"){if(wt(te)>256){let De={instancePath:a+"/threadIds/"+fe,schemaPath:"#/properties/threadIds/items/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};t===null?t=[De]:t.push(De),s++}if(!$s.test(te)){let De={instancePath:a+"/threadIds/"+fe,schemaPath:"#/properties/threadIds/items/pattern",keyword:"pattern",params:{pattern:"^thread[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^thread[-:][A-Za-z0-9._:-]+$"\'};t===null?t=[De]:t.push(De),s++}}else{let De={instancePath:a+"/threadIds/"+fe,schemaPath:"#/properties/threadIds/items/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[De]:t.push(De),s++}}let x=g.length,G;if(x>1){let fe={};for(;x--;){let te=g[x];if(typeof te=="string"){if(typeof fe[te]=="number"){G=fe[te];let De={instancePath:a+"/threadIds",schemaPath:"#/properties/threadIds/uniqueItems",keyword:"uniqueItems",params:{i:x,j:G},message:"must NOT have duplicate items (items ## "+G+" and "+x+" are identical)"};t===null?t=[De]:t.push(De),s++;break}fe[te]=x}}}}else{let w={instancePath:a+"/threadIds",schemaPath:"#/properties/threadIds/type",keyword:"type",params:{type:"array"},message:"must be array"};t===null?t=[w]:t.push(w),s++}}if(r.itemIds!==void 0){let g=r.itemIds;if(Array.isArray(g)){if(g.length>20){let fe={instancePath:a+"/itemIds",schemaPath:"#/properties/itemIds/maxItems",keyword:"maxItems",params:{limit:20},message:"must NOT have more than 20 items"};t===null?t=[fe]:t.push(fe),s++}let w=g.length;for(let fe=0;fe<w;fe++){let te=g[fe];if(typeof te=="string"){if(wt(te)>256){let De={instancePath:a+"/itemIds/"+fe,schemaPath:"#/properties/itemIds/items/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};t===null?t=[De]:t.push(De),s++}if(!Ou.test(te)){let De={instancePath:a+"/itemIds/"+fe,schemaPath:"#/properties/itemIds/items/pattern",keyword:"pattern",params:{pattern:"^item[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^item[-:][A-Za-z0-9._:-]+$"\'};t===null?t=[De]:t.push(De),s++}}else{let De={instancePath:a+"/itemIds/"+fe,schemaPath:"#/properties/itemIds/items/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[De]:t.push(De),s++}}let x=g.length,G;if(x>1){let fe={};for(;x--;){let te=g[x];if(typeof te=="string"){if(typeof fe[te]=="number"){G=fe[te];let De={instancePath:a+"/itemIds",schemaPath:"#/properties/itemIds/uniqueItems",keyword:"uniqueItems",params:{i:x,j:G},message:"must NOT have duplicate items (items ## "+G+" and "+x+" are identical)"};t===null?t=[De]:t.push(De),s++;break}fe[te]=x}}}}else{let w={instancePath:a+"/itemIds",schemaPath:"#/properties/itemIds/type",keyword:"type",params:{type:"array"},message:"must be array"};t===null?t=[w]:t.push(w),s++}}if(r.itemCount!==void 0){let g=r.itemCount;if(!(typeof g=="number"&&!(g%1)&&!isNaN(g))){let w={instancePath:a+"/itemCount",schemaPath:"#/properties/itemCount/type",keyword:"type",params:{type:"integer"},message:"must be integer"};t===null?t=[w]:t.push(w),s++}if(typeof g=="number"){if(g>20||isNaN(g)){let w={instancePath:a+"/itemCount",schemaPath:"#/properties/itemCount/maximum",keyword:"maximum",params:{comparison:"<=",limit:20},message:"must be <= 20"};t===null?t=[w]:t.push(w),s++}if(g<1||isNaN(g)){let w={instancePath:a+"/itemCount",schemaPath:"#/properties/itemCount/minimum",keyword:"minimum",params:{comparison:">=",limit:1},message:"must be >= 1"};t===null?t=[w]:t.push(w),s++}}}if(r.deliveryMode!==void 0){let g=r.deliveryMode;if(!(g==="direct-same-session"||g==="return-to-session"||g==="export-only")){let w={instancePath:a+"/deliveryMode",schemaPath:"#/properties/deliveryMode/enum",keyword:"enum",params:{allowedValues:Rn.properties.deliveryMode.enum},message:"must be equal to one of the allowed values"};t===null?t=[w]:t.push(w),s++}}if(r.answerUnread!==void 0&&typeof r.answerUnread!="boolean"){let g={instancePath:a+"/answerUnread",schemaPath:"#/properties/answerUnread/type",keyword:"type",params:{type:"boolean"},message:"must be boolean"};t===null?t=[g]:t.push(g),s++}if(r.originSessionMatched!==void 0&&typeof r.originSessionMatched!="boolean"){let g={instancePath:a+"/originSessionMatched",schemaPath:"#/properties/originSessionMatched/type",keyword:"type",params:{type:"boolean"},message:"must be boolean"};t===null?t=[g]:t.push(g),s++}}else{let g={instancePath:a,schemaPath:"#/type",keyword:"type",params:{type:"object"},message:"must be object"};t===null?t=[g]:t.push(g),s++}return Tu.errors=t,s===0}var am=Mu,mo={properties:{schemaVersion:{const:"1.3"},reportId:{type:"string",pattern:"^report[-:][A-Za-z0-9._:-]+$",maxLength:256},reportFingerprint:{type:"string",pattern:"^[a-f0-9]{64}$"},revision:{type:"integer",minimum:0},updatedAt:{type:"string",format:"date-time"},viewed:{type:"object",additionalProperties:{type:"object",additionalProperties:!1,required:["anchor","state","updatedAt"],properties:{anchor:{$ref:"#/$defs/reviewAnchor"},state:{enum:["unseen","viewed","stale"]},updatedAt:{type:"string",format:"date-time"}}}},judgments:{type:"object",additionalProperties:{type:"object",additionalProperties:!1,required:["changeId","state","updatedAt"],properties:{changeId:{type:"string"},state:{enum:["unreviewed","reviewed","follow-up","blocked","stale"]},updatedAt:{type:"string",format:"date-time"}}}},threadIds:{type:"array",items:{type:"string",pattern:"^thread[-:][A-Za-z0-9._:-]+$",maxLength:256},uniqueItems:!0},orphanedThreadIds:{type:"array",items:{type:"string",pattern:"^thread[-:][A-Za-z0-9._:-]+$",maxLength:256},uniqueItems:!0}}},vo={properties:{type:{enum:["change","file","hunk","line-range","visual-target","visual-region","finding","verification-gap"]},ref:{type:"string",minLength:1},path:{type:"string"},side:{enum:["before","after","diff"]},startLine:{type:"integer",minimum:1},endLine:{type:"integer",minimum:1},targetRef:{type:"string"},region:{$ref:"#/$defs/region"},selectorHint:{type:"string"},fingerprint:{type:"string",pattern:"^[a-f0-9]{64}$"}}};function mi(r,{instancePath:a="",parentData:n,parentDataProperty:l,rootData:p=r}={}){let t=null,s=0;if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.type===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"type"},message:"must have required property \'type\'"};t===null?t=[o]:t.push(o),s++}if(r.ref===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"ref"},message:"must have required property \'ref\'"};t===null?t=[o]:t.push(o),s++}if(r.fingerprint===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"fingerprint"},message:"must have required property \'fingerprint\'"};t===null?t=[o]:t.push(o),s++}for(let o in r)if(!hn.call(vo.properties,o)){let i={instancePath:a,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:o},message:"must NOT have additional properties"};t===null?t=[i]:t.push(i),s++}if(r.type!==void 0){let o=r.type;if(!(o==="change"||o==="file"||o==="hunk"||o==="line-range"||o==="visual-target"||o==="visual-region"||o==="finding"||o==="verification-gap")){let i={instancePath:a+"/type",schemaPath:"#/properties/type/enum",keyword:"enum",params:{allowedValues:vo.properties.type.enum},message:"must be equal to one of the allowed values"};t===null?t=[i]:t.push(i),s++}}if(r.ref!==void 0){let o=r.ref;if(typeof o=="string"){if(wt(o)<1){let i={instancePath:a+"/ref",schemaPath:"#/properties/ref/minLength",keyword:"minLength",params:{limit:1},message:"must NOT have fewer than 1 characters"};t===null?t=[i]:t.push(i),s++}}else{let i={instancePath:a+"/ref",schemaPath:"#/properties/ref/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[i]:t.push(i),s++}}if(r.path!==void 0&&typeof r.path!="string"){let o={instancePath:a+"/path",schemaPath:"#/properties/path/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[o]:t.push(o),s++}if(r.side!==void 0){let o=r.side;if(!(o==="before"||o==="after"||o==="diff")){let i={instancePath:a+"/side",schemaPath:"#/properties/side/enum",keyword:"enum",params:{allowedValues:vo.properties.side.enum},message:"must be equal to one of the allowed values"};t===null?t=[i]:t.push(i),s++}}if(r.startLine!==void 0){let o=r.startLine;if(!(typeof o=="number"&&!(o%1)&&!isNaN(o))){let i={instancePath:a+"/startLine",schemaPath:"#/properties/startLine/type",keyword:"type",params:{type:"integer"},message:"must be integer"};t===null?t=[i]:t.push(i),s++}if(typeof o=="number"&&(o<1||isNaN(o))){let i={instancePath:a+"/startLine",schemaPath:"#/properties/startLine/minimum",keyword:"minimum",params:{comparison:">=",limit:1},message:"must be >= 1"};t===null?t=[i]:t.push(i),s++}}if(r.endLine!==void 0){let o=r.endLine;if(!(typeof o=="number"&&!(o%1)&&!isNaN(o))){let i={instancePath:a+"/endLine",schemaPath:"#/properties/endLine/type",keyword:"type",params:{type:"integer"},message:"must be integer"};t===null?t=[i]:t.push(i),s++}if(typeof o=="number"&&(o<1||isNaN(o))){let i={instancePath:a+"/endLine",schemaPath:"#/properties/endLine/minimum",keyword:"minimum",params:{comparison:">=",limit:1},message:"must be >= 1"};t===null?t=[i]:t.push(i),s++}}if(r.targetRef!==void 0&&typeof r.targetRef!="string"){let o={instancePath:a+"/targetRef",schemaPath:"#/properties/targetRef/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[o]:t.push(o),s++}if(r.region!==void 0){let o=r.region;if(o&&typeof o=="object"&&!Array.isArray(o)){if(o.x===void 0){let i={instancePath:a+"/region",schemaPath:"#/$defs/region/required",keyword:"required",params:{missingProperty:"x"},message:"must have required property \'x\'"};t===null?t=[i]:t.push(i),s++}if(o.y===void 0){let i={instancePath:a+"/region",schemaPath:"#/$defs/region/required",keyword:"required",params:{missingProperty:"y"},message:"must have required property \'y\'"};t===null?t=[i]:t.push(i),s++}if(o.width===void 0){let i={instancePath:a+"/region",schemaPath:"#/$defs/region/required",keyword:"required",params:{missingProperty:"width"},message:"must have required property \'width\'"};t===null?t=[i]:t.push(i),s++}if(o.height===void 0){let i={instancePath:a+"/region",schemaPath:"#/$defs/region/required",keyword:"required",params:{missingProperty:"height"},message:"must have required property \'height\'"};t===null?t=[i]:t.push(i),s++}for(let i in o)if(!(i==="x"||i==="y"||i==="width"||i==="height")){let d={instancePath:a+"/region",schemaPath:"#/$defs/region/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:i},message:"must NOT have additional properties"};t===null?t=[d]:t.push(d),s++}if(o.x!==void 0){let i=o.x;if(typeof i=="number"){if(i>1||isNaN(i)){let d={instancePath:a+"/region/x",schemaPath:"#/$defs/region/properties/x/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};t===null?t=[d]:t.push(d),s++}if(i<0||isNaN(i)){let d={instancePath:a+"/region/x",schemaPath:"#/$defs/region/properties/x/minimum",keyword:"minimum",params:{comparison:">=",limit:0},message:"must be >= 0"};t===null?t=[d]:t.push(d),s++}}else{let d={instancePath:a+"/region/x",schemaPath:"#/$defs/region/properties/x/type",keyword:"type",params:{type:"number"},message:"must be number"};t===null?t=[d]:t.push(d),s++}}if(o.y!==void 0){let i=o.y;if(typeof i=="number"){if(i>1||isNaN(i)){let d={instancePath:a+"/region/y",schemaPath:"#/$defs/region/properties/y/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};t===null?t=[d]:t.push(d),s++}if(i<0||isNaN(i)){let d={instancePath:a+"/region/y",schemaPath:"#/$defs/region/properties/y/minimum",keyword:"minimum",params:{comparison:">=",limit:0},message:"must be >= 0"};t===null?t=[d]:t.push(d),s++}}else{let d={instancePath:a+"/region/y",schemaPath:"#/$defs/region/properties/y/type",keyword:"type",params:{type:"number"},message:"must be number"};t===null?t=[d]:t.push(d),s++}}if(o.width!==void 0){let i=o.width;if(typeof i=="number"){if(i>1||isNaN(i)){let d={instancePath:a+"/region/width",schemaPath:"#/$defs/region/properties/width/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};t===null?t=[d]:t.push(d),s++}if(i<=0||isNaN(i)){let d={instancePath:a+"/region/width",schemaPath:"#/$defs/region/properties/width/exclusiveMinimum",keyword:"exclusiveMinimum",params:{comparison:">",limit:0},message:"must be > 0"};t===null?t=[d]:t.push(d),s++}}else{let d={instancePath:a+"/region/width",schemaPath:"#/$defs/region/properties/width/type",keyword:"type",params:{type:"number"},message:"must be number"};t===null?t=[d]:t.push(d),s++}}if(o.height!==void 0){let i=o.height;if(typeof i=="number"){if(i>1||isNaN(i)){let d={instancePath:a+"/region/height",schemaPath:"#/$defs/region/properties/height/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};t===null?t=[d]:t.push(d),s++}if(i<=0||isNaN(i)){let d={instancePath:a+"/region/height",schemaPath:"#/$defs/region/properties/height/exclusiveMinimum",keyword:"exclusiveMinimum",params:{comparison:">",limit:0},message:"must be > 0"};t===null?t=[d]:t.push(d),s++}}else{let d={instancePath:a+"/region/height",schemaPath:"#/$defs/region/properties/height/type",keyword:"type",params:{type:"number"},message:"must be number"};t===null?t=[d]:t.push(d),s++}}}else{let i={instancePath:a+"/region",schemaPath:"#/$defs/region/type",keyword:"type",params:{type:"object"},message:"must be object"};t===null?t=[i]:t.push(i),s++}}if(r.selectorHint!==void 0&&typeof r.selectorHint!="string"){let o={instancePath:a+"/selectorHint",schemaPath:"#/properties/selectorHint/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[o]:t.push(o),s++}if(r.fingerprint!==void 0){let o=r.fingerprint;if(typeof o=="string"){if(!Tn.test(o)){let i={instancePath:a+"/fingerprint",schemaPath:"#/properties/fingerprint/pattern",keyword:"pattern",params:{pattern:"^[a-f0-9]{64}$"},message:\'must match pattern "^[a-f0-9]{64}$"\'};t===null?t=[i]:t.push(i),s++}}else{let i={instancePath:a+"/fingerprint",schemaPath:"#/properties/fingerprint/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[i]:t.push(i),s++}}}else{let o={instancePath:a,schemaPath:"#/type",keyword:"type",params:{type:"object"},message:"must be object"};t===null?t=[o]:t.push(o),s++}return mi.errors=t,s===0}function Mu(r,{instancePath:a="",parentData:n,parentDataProperty:l,rootData:p=r}={}){let t=null,s=0;if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.schemaVersion===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"schemaVersion"},message:"must have required property \'schemaVersion\'"};t===null?t=[o]:t.push(o),s++}if(r.reportId===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"reportId"},message:"must have required property \'reportId\'"};t===null?t=[o]:t.push(o),s++}if(r.reportFingerprint===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"reportFingerprint"},message:"must have required property \'reportFingerprint\'"};t===null?t=[o]:t.push(o),s++}if(r.revision===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"revision"},message:"must have required property \'revision\'"};t===null?t=[o]:t.push(o),s++}if(r.updatedAt===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"updatedAt"},message:"must have required property \'updatedAt\'"};t===null?t=[o]:t.push(o),s++}if(r.viewed===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"viewed"},message:"must have required property \'viewed\'"};t===null?t=[o]:t.push(o),s++}if(r.judgments===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"judgments"},message:"must have required property \'judgments\'"};t===null?t=[o]:t.push(o),s++}if(r.threadIds===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"threadIds"},message:"must have required property \'threadIds\'"};t===null?t=[o]:t.push(o),s++}if(r.orphanedThreadIds===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"orphanedThreadIds"},message:"must have required property \'orphanedThreadIds\'"};t===null?t=[o]:t.push(o),s++}for(let o in r)if(!hn.call(mo.properties,o)){let i={instancePath:a,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:o},message:"must NOT have additional properties"};t===null?t=[i]:t.push(i),s++}if(r.schemaVersion!==void 0&&r.schemaVersion!=="1.3"){let o={instancePath:a+"/schemaVersion",schemaPath:"#/properties/schemaVersion/const",keyword:"const",params:{allowedValue:"1.3"},message:"must be equal to constant"};t===null?t=[o]:t.push(o),s++}if(r.reportId!==void 0){let o=r.reportId;if(typeof o=="string"){if(wt(o)>256){let i={instancePath:a+"/reportId",schemaPath:"#/properties/reportId/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};t===null?t=[i]:t.push(i),s++}if(!Is.test(o)){let i={instancePath:a+"/reportId",schemaPath:"#/properties/reportId/pattern",keyword:"pattern",params:{pattern:"^report[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^report[-:][A-Za-z0-9._:-]+$"\'};t===null?t=[i]:t.push(i),s++}}else{let i={instancePath:a+"/reportId",schemaPath:"#/properties/reportId/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[i]:t.push(i),s++}}if(r.reportFingerprint!==void 0){let o=r.reportFingerprint;if(typeof o=="string"){if(!Tn.test(o)){let i={instancePath:a+"/reportFingerprint",schemaPath:"#/properties/reportFingerprint/pattern",keyword:"pattern",params:{pattern:"^[a-f0-9]{64}$"},message:\'must match pattern "^[a-f0-9]{64}$"\'};t===null?t=[i]:t.push(i),s++}}else{let i={instancePath:a+"/reportFingerprint",schemaPath:"#/properties/reportFingerprint/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[i]:t.push(i),s++}}if(r.revision!==void 0){let o=r.revision;if(!(typeof o=="number"&&!(o%1)&&!isNaN(o))){let i={instancePath:a+"/revision",schemaPath:"#/properties/revision/type",keyword:"type",params:{type:"integer"},message:"must be integer"};t===null?t=[i]:t.push(i),s++}if(typeof o=="number"&&(o<0||isNaN(o))){let i={instancePath:a+"/revision",schemaPath:"#/properties/revision/minimum",keyword:"minimum",params:{comparison:">=",limit:0},message:"must be >= 0"};t===null?t=[i]:t.push(i),s++}}if(r.updatedAt!==void 0){let o=r.updatedAt;if(typeof o=="string"){if(!Sa.validate(o)){let i={instancePath:a+"/updatedAt",schemaPath:"#/properties/updatedAt/format",keyword:"format",params:{format:"date-time"},message:\'must match format "date-time"\'};t===null?t=[i]:t.push(i),s++}}else{let i={instancePath:a+"/updatedAt",schemaPath:"#/properties/updatedAt/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[i]:t.push(i),s++}}if(r.viewed!==void 0){let o=r.viewed;if(o&&typeof o=="object"&&!Array.isArray(o))for(let i in o){let d=o[i];if(d&&typeof d=="object"&&!Array.isArray(d)){if(d.anchor===void 0){let m={instancePath:a+"/viewed/"+i.replace(/~/g,"~0").replace(/\\//g,"~1"),schemaPath:"#/properties/viewed/additionalProperties/required",keyword:"required",params:{missingProperty:"anchor"},message:"must have required property \'anchor\'"};t===null?t=[m]:t.push(m),s++}if(d.state===void 0){let m={instancePath:a+"/viewed/"+i.replace(/~/g,"~0").replace(/\\//g,"~1"),schemaPath:"#/properties/viewed/additionalProperties/required",keyword:"required",params:{missingProperty:"state"},message:"must have required property \'state\'"};t===null?t=[m]:t.push(m),s++}if(d.updatedAt===void 0){let m={instancePath:a+"/viewed/"+i.replace(/~/g,"~0").replace(/\\//g,"~1"),schemaPath:"#/properties/viewed/additionalProperties/required",keyword:"required",params:{missingProperty:"updatedAt"},message:"must have required property \'updatedAt\'"};t===null?t=[m]:t.push(m),s++}for(let m in d)if(!(m==="anchor"||m==="state"||m==="updatedAt")){let h={instancePath:a+"/viewed/"+i.replace(/~/g,"~0").replace(/\\//g,"~1"),schemaPath:"#/properties/viewed/additionalProperties/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:m},message:"must NOT have additional properties"};t===null?t=[h]:t.push(h),s++}if(d.anchor!==void 0&&(mi(d.anchor,{instancePath:a+"/viewed/"+i.replace(/~/g,"~0").replace(/\\//g,"~1")+"/anchor",parentData:d,parentDataProperty:"anchor",rootData:p})||(t=t===null?mi.errors:t.concat(mi.errors),s=t.length)),d.state!==void 0){let m=d.state;if(!(m==="unseen"||m==="viewed"||m==="stale")){let h={instancePath:a+"/viewed/"+i.replace(/~/g,"~0").replace(/\\//g,"~1")+"/state",schemaPath:"#/properties/viewed/additionalProperties/properties/state/enum",keyword:"enum",params:{allowedValues:mo.properties.viewed.additionalProperties.properties.state.enum},message:"must be equal to one of the allowed values"};t===null?t=[h]:t.push(h),s++}}if(d.updatedAt!==void 0){let m=d.updatedAt;if(typeof m=="string"){if(!Sa.validate(m)){let h={instancePath:a+"/viewed/"+i.replace(/~/g,"~0").replace(/\\//g,"~1")+"/updatedAt",schemaPath:"#/properties/viewed/additionalProperties/properties/updatedAt/format",keyword:"format",params:{format:"date-time"},message:\'must match format "date-time"\'};t===null?t=[h]:t.push(h),s++}}else{let h={instancePath:a+"/viewed/"+i.replace(/~/g,"~0").replace(/\\//g,"~1")+"/updatedAt",schemaPath:"#/properties/viewed/additionalProperties/properties/updatedAt/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[h]:t.push(h),s++}}}else{let m={instancePath:a+"/viewed/"+i.replace(/~/g,"~0").replace(/\\//g,"~1"),schemaPath:"#/properties/viewed/additionalProperties/type",keyword:"type",params:{type:"object"},message:"must be object"};t===null?t=[m]:t.push(m),s++}}else{let i={instancePath:a+"/viewed",schemaPath:"#/properties/viewed/type",keyword:"type",params:{type:"object"},message:"must be object"};t===null?t=[i]:t.push(i),s++}}if(r.judgments!==void 0){let o=r.judgments;if(o&&typeof o=="object"&&!Array.isArray(o))for(let i in o){let d=o[i];if(d&&typeof d=="object"&&!Array.isArray(d)){if(d.changeId===void 0){let m={instancePath:a+"/judgments/"+i.replace(/~/g,"~0").replace(/\\//g,"~1"),schemaPath:"#/properties/judgments/additionalProperties/required",keyword:"required",params:{missingProperty:"changeId"},message:"must have required property \'changeId\'"};t===null?t=[m]:t.push(m),s++}if(d.state===void 0){let m={instancePath:a+"/judgments/"+i.replace(/~/g,"~0").replace(/\\//g,"~1"),schemaPath:"#/properties/judgments/additionalProperties/required",keyword:"required",params:{missingProperty:"state"},message:"must have required property \'state\'"};t===null?t=[m]:t.push(m),s++}if(d.updatedAt===void 0){let m={instancePath:a+"/judgments/"+i.replace(/~/g,"~0").replace(/\\//g,"~1"),schemaPath:"#/properties/judgments/additionalProperties/required",keyword:"required",params:{missingProperty:"updatedAt"},message:"must have required property \'updatedAt\'"};t===null?t=[m]:t.push(m),s++}for(let m in d)if(!(m==="changeId"||m==="state"||m==="updatedAt")){let h={instancePath:a+"/judgments/"+i.replace(/~/g,"~0").replace(/\\//g,"~1"),schemaPath:"#/properties/judgments/additionalProperties/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:m},message:"must NOT have additional properties"};t===null?t=[h]:t.push(h),s++}if(d.changeId!==void 0&&typeof d.changeId!="string"){let m={instancePath:a+"/judgments/"+i.replace(/~/g,"~0").replace(/\\//g,"~1")+"/changeId",schemaPath:"#/properties/judgments/additionalProperties/properties/changeId/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[m]:t.push(m),s++}if(d.state!==void 0){let m=d.state;if(!(m==="unreviewed"||m==="reviewed"||m==="follow-up"||m==="blocked"||m==="stale")){let h={instancePath:a+"/judgments/"+i.replace(/~/g,"~0").replace(/\\//g,"~1")+"/state",schemaPath:"#/properties/judgments/additionalProperties/properties/state/enum",keyword:"enum",params:{allowedValues:mo.properties.judgments.additionalProperties.properties.state.enum},message:"must be equal to one of the allowed values"};t===null?t=[h]:t.push(h),s++}}if(d.updatedAt!==void 0){let m=d.updatedAt;if(typeof m=="string"){if(!Sa.validate(m)){let h={instancePath:a+"/judgments/"+i.replace(/~/g,"~0").replace(/\\//g,"~1")+"/updatedAt",schemaPath:"#/properties/judgments/additionalProperties/properties/updatedAt/format",keyword:"format",params:{format:"date-time"},message:\'must match format "date-time"\'};t===null?t=[h]:t.push(h),s++}}else{let h={instancePath:a+"/judgments/"+i.replace(/~/g,"~0").replace(/\\//g,"~1")+"/updatedAt",schemaPath:"#/properties/judgments/additionalProperties/properties/updatedAt/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[h]:t.push(h),s++}}}else{let m={instancePath:a+"/judgments/"+i.replace(/~/g,"~0").replace(/\\//g,"~1"),schemaPath:"#/properties/judgments/additionalProperties/type",keyword:"type",params:{type:"object"},message:"must be object"};t===null?t=[m]:t.push(m),s++}}else{let i={instancePath:a+"/judgments",schemaPath:"#/properties/judgments/type",keyword:"type",params:{type:"object"},message:"must be object"};t===null?t=[i]:t.push(i),s++}}if(r.threadIds!==void 0){let o=r.threadIds;if(Array.isArray(o)){let i=o.length;for(let h=0;h<i;h++){let c=o[h];if(typeof c=="string"){if(wt(c)>256){let P={instancePath:a+"/threadIds/"+h,schemaPath:"#/properties/threadIds/items/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};t===null?t=[P]:t.push(P),s++}if(!$s.test(c)){let P={instancePath:a+"/threadIds/"+h,schemaPath:"#/properties/threadIds/items/pattern",keyword:"pattern",params:{pattern:"^thread[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^thread[-:][A-Za-z0-9._:-]+$"\'};t===null?t=[P]:t.push(P),s++}}else{let P={instancePath:a+"/threadIds/"+h,schemaPath:"#/properties/threadIds/items/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[P]:t.push(P),s++}}let d=o.length,m;if(d>1){let h={};for(;d--;){let c=o[d];if(typeof c=="string"){if(typeof h[c]=="number"){m=h[c];let P={instancePath:a+"/threadIds",schemaPath:"#/properties/threadIds/uniqueItems",keyword:"uniqueItems",params:{i:d,j:m},message:"must NOT have duplicate items (items ## "+m+" and "+d+" are identical)"};t===null?t=[P]:t.push(P),s++;break}h[c]=d}}}}else{let i={instancePath:a+"/threadIds",schemaPath:"#/properties/threadIds/type",keyword:"type",params:{type:"array"},message:"must be array"};t===null?t=[i]:t.push(i),s++}}if(r.orphanedThreadIds!==void 0){let o=r.orphanedThreadIds;if(Array.isArray(o)){let i=o.length;for(let h=0;h<i;h++){let c=o[h];if(typeof c=="string"){if(wt(c)>256){let P={instancePath:a+"/orphanedThreadIds/"+h,schemaPath:"#/properties/orphanedThreadIds/items/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};t===null?t=[P]:t.push(P),s++}if(!$s.test(c)){let P={instancePath:a+"/orphanedThreadIds/"+h,schemaPath:"#/properties/orphanedThreadIds/items/pattern",keyword:"pattern",params:{pattern:"^thread[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^thread[-:][A-Za-z0-9._:-]+$"\'};t===null?t=[P]:t.push(P),s++}}else{let P={instancePath:a+"/orphanedThreadIds/"+h,schemaPath:"#/properties/orphanedThreadIds/items/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[P]:t.push(P),s++}}let d=o.length,m;if(d>1){let h={};for(;d--;){let c=o[d];if(typeof c=="string"){if(typeof h[c]=="number"){m=h[c];let P={instancePath:a+"/orphanedThreadIds",schemaPath:"#/properties/orphanedThreadIds/uniqueItems",keyword:"uniqueItems",params:{i:d,j:m},message:"must NOT have duplicate items (items ## "+m+" and "+d+" are identical)"};t===null?t=[P]:t.push(P),s++;break}h[c]=d}}}}else{let i={instancePath:a+"/orphanedThreadIds",schemaPath:"#/properties/orphanedThreadIds/type",keyword:"type",params:{type:"array"},message:"must be array"};t===null?t=[i]:t.push(i),s++}}}else{let o={instancePath:a,schemaPath:"#/type",keyword:"type",params:{type:"object"},message:"must be object"};t===null?t=[o]:t.push(o),s++}return Mu.errors=t,s===0}var nm=zu,li={properties:{id:{type:"string",pattern:"^thread[-:][A-Za-z0-9._:-]+$",maxLength:256},reportId:{type:"string",pattern:"^report[-:][A-Za-z0-9._:-]+$",maxLength:256},anchor:{$ref:"#/$defs/reviewAnchor"},kind:{enum:["note","question","finding","change-request"]},state:{enum:["open","answered","resolved","stale","orphaned"]},messages:{type:"array",items:{$ref:"#/$defs/message"}},agentAttention:{type:"object",additionalProperties:!1,required:["state"],properties:{state:{enum:["none","requested","batched","submitted","acknowledged","answered","stale"]},batchId:{type:"string",pattern:"^fb[-:][A-Za-z0-9._:-]+$",maxLength:256},updatedAt:{type:"string",format:"date-time"}}},createdAt:{type:"string",format:"date-time"},updatedAt:{type:"string",format:"date-time"}}},go={properties:{type:{enum:["change","file","hunk","line-range","visual-target","visual-region","finding","verification-gap"]},ref:{type:"string"},path:{type:"string"},side:{enum:["before","after","diff"]},startLine:{type:"integer",minimum:1},endLine:{type:"integer",minimum:1},targetRef:{type:"string"},region:{type:"object",additionalProperties:!1,required:["x","y","width","height"],properties:{x:{type:"number",minimum:0,maximum:1},y:{type:"number",minimum:0,maximum:1},width:{type:"number",exclusiveMinimum:0,maximum:1},height:{type:"number",exclusiveMinimum:0,maximum:1}}},selectorHint:{type:"string"},fingerprint:{type:"string",pattern:"^[a-f0-9]{64}$"}}},qd={properties:{kind:{enum:["human-note","agent-answer","system"]},author:{properties:{type:{enum:["human","agent","system"]}}}}};function zu(r,{instancePath:a="",parentData:n,parentDataProperty:l,rootData:p=r}={}){let t=null,s=0;if(r&&typeof r=="object"&&!Array.isArray(r)){if(r.id===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"id"},message:"must have required property \'id\'"};t===null?t=[o]:t.push(o),s++}if(r.reportId===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"reportId"},message:"must have required property \'reportId\'"};t===null?t=[o]:t.push(o),s++}if(r.anchor===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"anchor"},message:"must have required property \'anchor\'"};t===null?t=[o]:t.push(o),s++}if(r.kind===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"kind"},message:"must have required property \'kind\'"};t===null?t=[o]:t.push(o),s++}if(r.state===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"state"},message:"must have required property \'state\'"};t===null?t=[o]:t.push(o),s++}if(r.messages===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"messages"},message:"must have required property \'messages\'"};t===null?t=[o]:t.push(o),s++}if(r.agentAttention===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"agentAttention"},message:"must have required property \'agentAttention\'"};t===null?t=[o]:t.push(o),s++}if(r.createdAt===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"createdAt"},message:"must have required property \'createdAt\'"};t===null?t=[o]:t.push(o),s++}if(r.updatedAt===void 0){let o={instancePath:a,schemaPath:"#/required",keyword:"required",params:{missingProperty:"updatedAt"},message:"must have required property \'updatedAt\'"};t===null?t=[o]:t.push(o),s++}for(let o in r)if(!hn.call(li.properties,o)){let i={instancePath:a,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:o},message:"must NOT have additional properties"};t===null?t=[i]:t.push(i),s++}if(r.id!==void 0){let o=r.id;if(typeof o=="string"){if(wt(o)>256){let i={instancePath:a+"/id",schemaPath:"#/properties/id/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};t===null?t=[i]:t.push(i),s++}if(!$s.test(o)){let i={instancePath:a+"/id",schemaPath:"#/properties/id/pattern",keyword:"pattern",params:{pattern:"^thread[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^thread[-:][A-Za-z0-9._:-]+$"\'};t===null?t=[i]:t.push(i),s++}}else{let i={instancePath:a+"/id",schemaPath:"#/properties/id/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[i]:t.push(i),s++}}if(r.reportId!==void 0){let o=r.reportId;if(typeof o=="string"){if(wt(o)>256){let i={instancePath:a+"/reportId",schemaPath:"#/properties/reportId/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};t===null?t=[i]:t.push(i),s++}if(!Is.test(o)){let i={instancePath:a+"/reportId",schemaPath:"#/properties/reportId/pattern",keyword:"pattern",params:{pattern:"^report[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^report[-:][A-Za-z0-9._:-]+$"\'};t===null?t=[i]:t.push(i),s++}}else{let i={instancePath:a+"/reportId",schemaPath:"#/properties/reportId/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[i]:t.push(i),s++}}if(r.anchor!==void 0){let o=r.anchor;if(o&&typeof o=="object"&&!Array.isArray(o)){if(o.type===void 0){let i={instancePath:a+"/anchor",schemaPath:"#/$defs/reviewAnchor/required",keyword:"required",params:{missingProperty:"type"},message:"must have required property \'type\'"};t===null?t=[i]:t.push(i),s++}if(o.ref===void 0){let i={instancePath:a+"/anchor",schemaPath:"#/$defs/reviewAnchor/required",keyword:"required",params:{missingProperty:"ref"},message:"must have required property \'ref\'"};t===null?t=[i]:t.push(i),s++}if(o.fingerprint===void 0){let i={instancePath:a+"/anchor",schemaPath:"#/$defs/reviewAnchor/required",keyword:"required",params:{missingProperty:"fingerprint"},message:"must have required property \'fingerprint\'"};t===null?t=[i]:t.push(i),s++}for(let i in o)if(!hn.call(go.properties,i)){let d={instancePath:a+"/anchor",schemaPath:"#/$defs/reviewAnchor/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:i},message:"must NOT have additional properties"};t===null?t=[d]:t.push(d),s++}if(o.type!==void 0){let i=o.type;if(!(i==="change"||i==="file"||i==="hunk"||i==="line-range"||i==="visual-target"||i==="visual-region"||i==="finding"||i==="verification-gap")){let d={instancePath:a+"/anchor/type",schemaPath:"#/$defs/reviewAnchor/properties/type/enum",keyword:"enum",params:{allowedValues:go.properties.type.enum},message:"must be equal to one of the allowed values"};t===null?t=[d]:t.push(d),s++}}if(o.ref!==void 0&&typeof o.ref!="string"){let i={instancePath:a+"/anchor/ref",schemaPath:"#/$defs/reviewAnchor/properties/ref/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[i]:t.push(i),s++}if(o.path!==void 0&&typeof o.path!="string"){let i={instancePath:a+"/anchor/path",schemaPath:"#/$defs/reviewAnchor/properties/path/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[i]:t.push(i),s++}if(o.side!==void 0){let i=o.side;if(!(i==="before"||i==="after"||i==="diff")){let d={instancePath:a+"/anchor/side",schemaPath:"#/$defs/reviewAnchor/properties/side/enum",keyword:"enum",params:{allowedValues:go.properties.side.enum},message:"must be equal to one of the allowed values"};t===null?t=[d]:t.push(d),s++}}if(o.startLine!==void 0){let i=o.startLine;if(!(typeof i=="number"&&!(i%1)&&!isNaN(i))){let d={instancePath:a+"/anchor/startLine",schemaPath:"#/$defs/reviewAnchor/properties/startLine/type",keyword:"type",params:{type:"integer"},message:"must be integer"};t===null?t=[d]:t.push(d),s++}if(typeof i=="number"&&(i<1||isNaN(i))){let d={instancePath:a+"/anchor/startLine",schemaPath:"#/$defs/reviewAnchor/properties/startLine/minimum",keyword:"minimum",params:{comparison:">=",limit:1},message:"must be >= 1"};t===null?t=[d]:t.push(d),s++}}if(o.endLine!==void 0){let i=o.endLine;if(!(typeof i=="number"&&!(i%1)&&!isNaN(i))){let d={instancePath:a+"/anchor/endLine",schemaPath:"#/$defs/reviewAnchor/properties/endLine/type",keyword:"type",params:{type:"integer"},message:"must be integer"};t===null?t=[d]:t.push(d),s++}if(typeof i=="number"&&(i<1||isNaN(i))){let d={instancePath:a+"/anchor/endLine",schemaPath:"#/$defs/reviewAnchor/properties/endLine/minimum",keyword:"minimum",params:{comparison:">=",limit:1},message:"must be >= 1"};t===null?t=[d]:t.push(d),s++}}if(o.targetRef!==void 0&&typeof o.targetRef!="string"){let i={instancePath:a+"/anchor/targetRef",schemaPath:"#/$defs/reviewAnchor/properties/targetRef/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[i]:t.push(i),s++}if(o.region!==void 0){let i=o.region;if(i&&typeof i=="object"&&!Array.isArray(i)){if(i.x===void 0){let d={instancePath:a+"/anchor/region",schemaPath:"#/$defs/reviewAnchor/properties/region/required",keyword:"required",params:{missingProperty:"x"},message:"must have required property \'x\'"};t===null?t=[d]:t.push(d),s++}if(i.y===void 0){let d={instancePath:a+"/anchor/region",schemaPath:"#/$defs/reviewAnchor/properties/region/required",keyword:"required",params:{missingProperty:"y"},message:"must have required property \'y\'"};t===null?t=[d]:t.push(d),s++}if(i.width===void 0){let d={instancePath:a+"/anchor/region",schemaPath:"#/$defs/reviewAnchor/properties/region/required",keyword:"required",params:{missingProperty:"width"},message:"must have required property \'width\'"};t===null?t=[d]:t.push(d),s++}if(i.height===void 0){let d={instancePath:a+"/anchor/region",schemaPath:"#/$defs/reviewAnchor/properties/region/required",keyword:"required",params:{missingProperty:"height"},message:"must have required property \'height\'"};t===null?t=[d]:t.push(d),s++}for(let d in i)if(!(d==="x"||d==="y"||d==="width"||d==="height")){let m={instancePath:a+"/anchor/region",schemaPath:"#/$defs/reviewAnchor/properties/region/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:d},message:"must NOT have additional properties"};t===null?t=[m]:t.push(m),s++}if(i.x!==void 0){let d=i.x;if(typeof d=="number"){if(d>1||isNaN(d)){let m={instancePath:a+"/anchor/region/x",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/x/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};t===null?t=[m]:t.push(m),s++}if(d<0||isNaN(d)){let m={instancePath:a+"/anchor/region/x",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/x/minimum",keyword:"minimum",params:{comparison:">=",limit:0},message:"must be >= 0"};t===null?t=[m]:t.push(m),s++}}else{let m={instancePath:a+"/anchor/region/x",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/x/type",keyword:"type",params:{type:"number"},message:"must be number"};t===null?t=[m]:t.push(m),s++}}if(i.y!==void 0){let d=i.y;if(typeof d=="number"){if(d>1||isNaN(d)){let m={instancePath:a+"/anchor/region/y",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/y/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};t===null?t=[m]:t.push(m),s++}if(d<0||isNaN(d)){let m={instancePath:a+"/anchor/region/y",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/y/minimum",keyword:"minimum",params:{comparison:">=",limit:0},message:"must be >= 0"};t===null?t=[m]:t.push(m),s++}}else{let m={instancePath:a+"/anchor/region/y",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/y/type",keyword:"type",params:{type:"number"},message:"must be number"};t===null?t=[m]:t.push(m),s++}}if(i.width!==void 0){let d=i.width;if(typeof d=="number"){if(d>1||isNaN(d)){let m={instancePath:a+"/anchor/region/width",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/width/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};t===null?t=[m]:t.push(m),s++}if(d<=0||isNaN(d)){let m={instancePath:a+"/anchor/region/width",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/width/exclusiveMinimum",keyword:"exclusiveMinimum",params:{comparison:">",limit:0},message:"must be > 0"};t===null?t=[m]:t.push(m),s++}}else{let m={instancePath:a+"/anchor/region/width",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/width/type",keyword:"type",params:{type:"number"},message:"must be number"};t===null?t=[m]:t.push(m),s++}}if(i.height!==void 0){let d=i.height;if(typeof d=="number"){if(d>1||isNaN(d)){let m={instancePath:a+"/anchor/region/height",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/height/maximum",keyword:"maximum",params:{comparison:"<=",limit:1},message:"must be <= 1"};t===null?t=[m]:t.push(m),s++}if(d<=0||isNaN(d)){let m={instancePath:a+"/anchor/region/height",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/height/exclusiveMinimum",keyword:"exclusiveMinimum",params:{comparison:">",limit:0},message:"must be > 0"};t===null?t=[m]:t.push(m),s++}}else{let m={instancePath:a+"/anchor/region/height",schemaPath:"#/$defs/reviewAnchor/properties/region/properties/height/type",keyword:"type",params:{type:"number"},message:"must be number"};t===null?t=[m]:t.push(m),s++}}}else{let d={instancePath:a+"/anchor/region",schemaPath:"#/$defs/reviewAnchor/properties/region/type",keyword:"type",params:{type:"object"},message:"must be object"};t===null?t=[d]:t.push(d),s++}}if(o.selectorHint!==void 0&&typeof o.selectorHint!="string"){let i={instancePath:a+"/anchor/selectorHint",schemaPath:"#/$defs/reviewAnchor/properties/selectorHint/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[i]:t.push(i),s++}if(o.fingerprint!==void 0){let i=o.fingerprint;if(typeof i=="string"){if(!Tn.test(i)){let d={instancePath:a+"/anchor/fingerprint",schemaPath:"#/$defs/reviewAnchor/properties/fingerprint/pattern",keyword:"pattern",params:{pattern:"^[a-f0-9]{64}$"},message:\'must match pattern "^[a-f0-9]{64}$"\'};t===null?t=[d]:t.push(d),s++}}else{let d={instancePath:a+"/anchor/fingerprint",schemaPath:"#/$defs/reviewAnchor/properties/fingerprint/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[d]:t.push(d),s++}}}else{let i={instancePath:a+"/anchor",schemaPath:"#/$defs/reviewAnchor/type",keyword:"type",params:{type:"object"},message:"must be object"};t===null?t=[i]:t.push(i),s++}}if(r.kind!==void 0){let o=r.kind;if(!(o==="note"||o==="question"||o==="finding"||o==="change-request")){let i={instancePath:a+"/kind",schemaPath:"#/properties/kind/enum",keyword:"enum",params:{allowedValues:li.properties.kind.enum},message:"must be equal to one of the allowed values"};t===null?t=[i]:t.push(i),s++}}if(r.state!==void 0){let o=r.state;if(!(o==="open"||o==="answered"||o==="resolved"||o==="stale"||o==="orphaned")){let i={instancePath:a+"/state",schemaPath:"#/properties/state/enum",keyword:"enum",params:{allowedValues:li.properties.state.enum},message:"must be equal to one of the allowed values"};t===null?t=[i]:t.push(i),s++}}if(r.messages!==void 0){let o=r.messages;if(Array.isArray(o)){let i=o.length;for(let d=0;d<i;d++){let m=o[d];if(m&&typeof m=="object"&&!Array.isArray(m)){if(m.id===void 0){let h={instancePath:a+"/messages/"+d,schemaPath:"#/$defs/message/required",keyword:"required",params:{missingProperty:"id"},message:"must have required property \'id\'"};t===null?t=[h]:t.push(h),s++}if(m.kind===void 0){let h={instancePath:a+"/messages/"+d,schemaPath:"#/$defs/message/required",keyword:"required",params:{missingProperty:"kind"},message:"must have required property \'kind\'"};t===null?t=[h]:t.push(h),s++}if(m.author===void 0){let h={instancePath:a+"/messages/"+d,schemaPath:"#/$defs/message/required",keyword:"required",params:{missingProperty:"author"},message:"must have required property \'author\'"};t===null?t=[h]:t.push(h),s++}if(m.body===void 0){let h={instancePath:a+"/messages/"+d,schemaPath:"#/$defs/message/required",keyword:"required",params:{missingProperty:"body"},message:"must have required property \'body\'"};t===null?t=[h]:t.push(h),s++}if(m.createdAt===void 0){let h={instancePath:a+"/messages/"+d,schemaPath:"#/$defs/message/required",keyword:"required",params:{missingProperty:"createdAt"},message:"must have required property \'createdAt\'"};t===null?t=[h]:t.push(h),s++}for(let h in m)if(!(h==="id"||h==="kind"||h==="author"||h==="body"||h==="feedbackItemId"||h==="evidenceRefs"||h==="createdAt")){let c={instancePath:a+"/messages/"+d,schemaPath:"#/$defs/message/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:h},message:"must NOT have additional properties"};t===null?t=[c]:t.push(c),s++}if(m.id!==void 0){let h=m.id;if(typeof h=="string"){if(wt(h)>256){let c={instancePath:a+"/messages/"+d+"/id",schemaPath:"#/$defs/message/properties/id/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};t===null?t=[c]:t.push(c),s++}if(!Lu.test(h)){let c={instancePath:a+"/messages/"+d+"/id",schemaPath:"#/$defs/message/properties/id/pattern",keyword:"pattern",params:{pattern:"^message[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^message[-:][A-Za-z0-9._:-]+$"\'};t===null?t=[c]:t.push(c),s++}}else{let c={instancePath:a+"/messages/"+d+"/id",schemaPath:"#/$defs/message/properties/id/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[c]:t.push(c),s++}}if(m.kind!==void 0){let h=m.kind;if(!(h==="human-note"||h==="agent-answer"||h==="system")){let c={instancePath:a+"/messages/"+d+"/kind",schemaPath:"#/$defs/message/properties/kind/enum",keyword:"enum",params:{allowedValues:qd.properties.kind.enum},message:"must be equal to one of the allowed values"};t===null?t=[c]:t.push(c),s++}}if(m.author!==void 0){let h=m.author;if(h&&typeof h=="object"&&!Array.isArray(h)){if(h.type===void 0){let c={instancePath:a+"/messages/"+d+"/author",schemaPath:"#/$defs/message/properties/author/required",keyword:"required",params:{missingProperty:"type"},message:"must have required property \'type\'"};t===null?t=[c]:t.push(c),s++}if(h.label===void 0){let c={instancePath:a+"/messages/"+d+"/author",schemaPath:"#/$defs/message/properties/author/required",keyword:"required",params:{missingProperty:"label"},message:"must have required property \'label\'"};t===null?t=[c]:t.push(c),s++}for(let c in h)if(!(c==="type"||c==="label")){let P={instancePath:a+"/messages/"+d+"/author",schemaPath:"#/$defs/message/properties/author/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:c},message:"must NOT have additional properties"};t===null?t=[P]:t.push(P),s++}if(h.type!==void 0){let c=h.type;if(!(c==="human"||c==="agent"||c==="system")){let P={instancePath:a+"/messages/"+d+"/author/type",schemaPath:"#/$defs/message/properties/author/properties/type/enum",keyword:"enum",params:{allowedValues:qd.properties.author.properties.type.enum},message:"must be equal to one of the allowed values"};t===null?t=[P]:t.push(P),s++}}if(h.label!==void 0&&typeof h.label!="string"){let c={instancePath:a+"/messages/"+d+"/author/label",schemaPath:"#/$defs/message/properties/author/properties/label/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[c]:t.push(c),s++}}else{let c={instancePath:a+"/messages/"+d+"/author",schemaPath:"#/$defs/message/properties/author/type",keyword:"type",params:{type:"object"},message:"must be object"};t===null?t=[c]:t.push(c),s++}}if(m.body!==void 0){let h=m.body;if(typeof h=="string"){if(wt(h)>16384){let c={instancePath:a+"/messages/"+d+"/body",schemaPath:"#/$defs/message/properties/body/maxLength",keyword:"maxLength",params:{limit:16384},message:"must NOT have more than 16384 characters"};t===null?t=[c]:t.push(c),s++}if(wt(h)<1){let c={instancePath:a+"/messages/"+d+"/body",schemaPath:"#/$defs/message/properties/body/minLength",keyword:"minLength",params:{limit:1},message:"must NOT have fewer than 1 characters"};t===null?t=[c]:t.push(c),s++}}else{let c={instancePath:a+"/messages/"+d+"/body",schemaPath:"#/$defs/message/properties/body/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[c]:t.push(c),s++}}if(m.feedbackItemId!==void 0){let h=m.feedbackItemId;if(typeof h=="string"){if(wt(h)>256){let c={instancePath:a+"/messages/"+d+"/feedbackItemId",schemaPath:"#/$defs/message/properties/feedbackItemId/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};t===null?t=[c]:t.push(c),s++}if(!Ou.test(h)){let c={instancePath:a+"/messages/"+d+"/feedbackItemId",schemaPath:"#/$defs/message/properties/feedbackItemId/pattern",keyword:"pattern",params:{pattern:"^item[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^item[-:][A-Za-z0-9._:-]+$"\'};t===null?t=[c]:t.push(c),s++}}else{let c={instancePath:a+"/messages/"+d+"/feedbackItemId",schemaPath:"#/$defs/message/properties/feedbackItemId/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[c]:t.push(c),s++}}if(m.evidenceRefs!==void 0){let h=m.evidenceRefs;if(Array.isArray(h)){if(h.length>100){let Z={instancePath:a+"/messages/"+d+"/evidenceRefs",schemaPath:"#/$defs/message/properties/evidenceRefs/maxItems",keyword:"maxItems",params:{limit:100},message:"must NOT have more than 100 items"};t===null?t=[Z]:t.push(Z),s++}let c=h.length;for(let Z=0;Z<c;Z++)if(typeof h[Z]!="string"){let E={instancePath:a+"/messages/"+d+"/evidenceRefs/"+Z,schemaPath:"#/$defs/message/properties/evidenceRefs/items/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[E]:t.push(E),s++}let P=h.length,N;if(P>1){let Z={};for(;P--;){let E=h[P];if(typeof E=="string"){if(typeof Z[E]=="number"){N=Z[E];let K={instancePath:a+"/messages/"+d+"/evidenceRefs",schemaPath:"#/$defs/message/properties/evidenceRefs/uniqueItems",keyword:"uniqueItems",params:{i:P,j:N},message:"must NOT have duplicate items (items ## "+N+" and "+P+" are identical)"};t===null?t=[K]:t.push(K),s++;break}Z[E]=P}}}}else{let c={instancePath:a+"/messages/"+d+"/evidenceRefs",schemaPath:"#/$defs/message/properties/evidenceRefs/type",keyword:"type",params:{type:"array"},message:"must be array"};t===null?t=[c]:t.push(c),s++}}if(m.createdAt!==void 0){let h=m.createdAt;if(typeof h=="string"){if(!Sa.validate(h)){let c={instancePath:a+"/messages/"+d+"/createdAt",schemaPath:"#/$defs/message/properties/createdAt/format",keyword:"format",params:{format:"date-time"},message:\'must match format "date-time"\'};t===null?t=[c]:t.push(c),s++}}else{let c={instancePath:a+"/messages/"+d+"/createdAt",schemaPath:"#/$defs/message/properties/createdAt/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[c]:t.push(c),s++}}}else{let h={instancePath:a+"/messages/"+d,schemaPath:"#/$defs/message/type",keyword:"type",params:{type:"object"},message:"must be object"};t===null?t=[h]:t.push(h),s++}}}else{let i={instancePath:a+"/messages",schemaPath:"#/properties/messages/type",keyword:"type",params:{type:"array"},message:"must be array"};t===null?t=[i]:t.push(i),s++}}if(r.agentAttention!==void 0){let o=r.agentAttention;if(o&&typeof o=="object"&&!Array.isArray(o)){if(o.state===void 0){let i={instancePath:a+"/agentAttention",schemaPath:"#/properties/agentAttention/required",keyword:"required",params:{missingProperty:"state"},message:"must have required property \'state\'"};t===null?t=[i]:t.push(i),s++}for(let i in o)if(!(i==="state"||i==="batchId"||i==="updatedAt")){let d={instancePath:a+"/agentAttention",schemaPath:"#/properties/agentAttention/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:i},message:"must NOT have additional properties"};t===null?t=[d]:t.push(d),s++}if(o.state!==void 0){let i=o.state;if(!(i==="none"||i==="requested"||i==="batched"||i==="submitted"||i==="acknowledged"||i==="answered"||i==="stale")){let d={instancePath:a+"/agentAttention/state",schemaPath:"#/properties/agentAttention/properties/state/enum",keyword:"enum",params:{allowedValues:li.properties.agentAttention.properties.state.enum},message:"must be equal to one of the allowed values"};t===null?t=[d]:t.push(d),s++}}if(o.batchId!==void 0){let i=o.batchId;if(typeof i=="string"){if(wt(i)>256){let d={instancePath:a+"/agentAttention/batchId",schemaPath:"#/properties/agentAttention/properties/batchId/maxLength",keyword:"maxLength",params:{limit:256},message:"must NOT have more than 256 characters"};t===null?t=[d]:t.push(d),s++}if(!ju.test(i)){let d={instancePath:a+"/agentAttention/batchId",schemaPath:"#/properties/agentAttention/properties/batchId/pattern",keyword:"pattern",params:{pattern:"^fb[-:][A-Za-z0-9._:-]+$"},message:\'must match pattern "^fb[-:][A-Za-z0-9._:-]+$"\'};t===null?t=[d]:t.push(d),s++}}else{let d={instancePath:a+"/agentAttention/batchId",schemaPath:"#/properties/agentAttention/properties/batchId/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[d]:t.push(d),s++}}if(o.updatedAt!==void 0){let i=o.updatedAt;if(typeof i=="string"){if(!Sa.validate(i)){let d={instancePath:a+"/agentAttention/updatedAt",schemaPath:"#/properties/agentAttention/properties/updatedAt/format",keyword:"format",params:{format:"date-time"},message:\'must match format "date-time"\'};t===null?t=[d]:t.push(d),s++}}else{let d={instancePath:a+"/agentAttention/updatedAt",schemaPath:"#/properties/agentAttention/properties/updatedAt/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[d]:t.push(d),s++}}}else{let i={instancePath:a+"/agentAttention",schemaPath:"#/properties/agentAttention/type",keyword:"type",params:{type:"object"},message:"must be object"};t===null?t=[i]:t.push(i),s++}}if(r.createdAt!==void 0){let o=r.createdAt;if(typeof o=="string"){if(!Sa.validate(o)){let i={instancePath:a+"/createdAt",schemaPath:"#/properties/createdAt/format",keyword:"format",params:{format:"date-time"},message:\'must match format "date-time"\'};t===null?t=[i]:t.push(i),s++}}else{let i={instancePath:a+"/createdAt",schemaPath:"#/properties/createdAt/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[i]:t.push(i),s++}}if(r.updatedAt!==void 0){let o=r.updatedAt;if(typeof o=="string"){if(!Sa.validate(o)){let i={instancePath:a+"/updatedAt",schemaPath:"#/properties/updatedAt/format",keyword:"format",params:{format:"date-time"},message:\'must match format "date-time"\'};t===null?t=[i]:t.push(i),s++}}else{let i={instancePath:a+"/updatedAt",schemaPath:"#/properties/updatedAt/type",keyword:"type",params:{type:"string"},message:"must be string"};t===null?t=[i]:t.push(i),s++}}}else{let o={instancePath:a,schemaPath:"#/type",keyword:"type",params:{type:"object"},message:"must be object"};t===null?t=[o]:t.push(o),s++}return zu.errors=t,s===0}const sm={"review-bundle":Xf,"review-event":em,"review-state":am,"review-thread":nm};function im(r){return`${r.instancePath||"/"} ${r.message??"is invalid"}`}function xi(r){return Array.isArray(r)?`[${r.map(xi).join(",")}]`:r&&typeof r=="object"?`{${Object.entries(r).sort(([a],[n])=>a.localeCompare(n)).map(([a,n])=>`${JSON.stringify(a)}:${xi(n)}`).join(",")}}`:JSON.stringify(r)??"null"}function ws(r,a){const n=sm[r],l=n(a);return{ok:!!l,errors:l?[]:(n.errors??[]).map(im)}}function Vu(r){const a=ws("review-bundle",r);if(!a.ok)return a;const n=r,l=[],p=ws("review-state",n.state);l.push(...p.errors.map(h=>`state${h}`));for(const[h,c]of n.threads.entries()){const P=ws("review-thread",c);l.push(...P.errors.map(N=>`threads/${h}${N}`))}for(const[h,c]of n.events.entries()){const P=ws("review-event",c);l.push(...P.errors.map(N=>`events/${h}${N}`))}if(l.length>0)return{ok:!1,errors:l};n.state.reportId!==n.source.reportId&&l.push("state.reportId does not match source.reportId"),n.state.reportFingerprint!==n.source.reportFingerprint&&l.push("state.reportFingerprint does not match source.reportFingerprint");const t=n.threads.map(h=>h.id);new Set(t).size!==t.length&&l.push("threads contains duplicate IDs"),[...new Set(n.state.threadIds)].sort().join(`\n`)!==[...new Set(t)].sort().join(`\n`)&&l.push("state.threadIds does not match bundled threads");const s=new Set(n.state.orphanedThreadIds);for(const h of n.threads){h.reportId!==n.source.reportId&&l.push(`${h.id} reportId does not match source.reportId`),h.state==="orphaned"!==s.has(h.id)&&l.push(`${h.id} orphaned state is inconsistent`);for(const[c,P]of h.messages.entries()){const N=new TextEncoder().encode(P.body).byteLength;P.body.trim()||l.push(`${h.id}.messages/${c} body is empty`),N>16*1024&&l.push(`${h.id}.messages/${c} body exceeds 16 KiB`)}}for(const h of s)t.includes(h)||l.push(`orphaned thread is missing: ${h}`);const o=n.events.map(h=>h.id);new Set(o).size!==o.length&&l.push("events contains duplicate IDs");for(const[h,c]of n.events.entries())c.sequence!==h+1&&l.push(`events/${h} sequence is not contiguous`),c.reportId!==n.source.reportId&&l.push(`events/${h} reportId does not match source.reportId`);const i=n.anchorCatalog.map(h=>`${h.type}\\0${h.ref}`);new Set(i).size!==i.length&&l.push("anchorCatalog contains duplicate type/ref pairs");const d=new Map(n.anchorCatalog.map(h=>[`${h.type}\\0${h.ref}`,h])),m=(h,c)=>{const P=d.get(`${c.type}\\0${c.ref}`);(!P||xi(P)!==xi(c))&&l.push(`${h} does not match anchorCatalog`)};for(const[h,c]of Object.entries(n.state.viewed))h!==JSON.stringify([c.anchor.type,c.anchor.ref])&&l.push(`state.viewed key does not match its anchor: ${h}`),m(`state.viewed/${h}.anchor`,c.anchor);for(const[h,c]of n.threads.entries())m(`threads/${h}.anchor`,c.anchor);for(const[h,c]of n.events.entries())c.anchor&&m(`events/${h}.anchor`,c.anchor);return{ok:l.length===0,errors:l}}const Fu=4*1024*1024;function Ze(r,a){const n=new Error(a);return n.name=r,n}function Ke(r){return structuredClone(r)}function Du(r){return`utsuri:review:v1:${encodeURIComponent(r)}`}function Bu(r){if(new TextEncoder().encode(r).byteLength>Fu)throw Ze("REVIEW_BROWSER_LIMIT","Stored review state exceeds 4 MiB");const a=JSON.parse(r),n=[a];for(;n.length>0;){const l=n.pop();if(!(!l||typeof l!="object"))if(Array.isArray(l))n.push(...l);else for(const[p,t]of Object.entries(l)){if(new Set(["__proto__","constructor","prototype"]).has(p))throw Ze("REVIEW_BROWSER_KEY","Stored review state has a forbidden key");n.push(t)}}return a}function om(r){if(!r||typeof r!="object"||Array.isArray(r))return!1;const a=r;return a.schemaVersion==="1.0"&&typeof a.reportFingerprint=="string"&&!!(a.state&&typeof a.state=="object")&&Array.isArray(a.threads)&&Array.isArray(a.events)}function yo(r,a){const n=ws(r,a);if(!n.ok)throw Ze("REVIEW_BROWSER_INVALID",`${r}: ${n.errors.join("; ")}`)}function lm(r){for(const a of r)for(const n of a.messages){if(!n.body.trim())throw Ze("REVIEW_BROWSER_INVALID","Stored review comment body is empty");if(new TextEncoder().encode(n.body).byteLength>16*1024)throw Ze("REVIEW_BROWSER_INVALID","Stored review comment exceeds 16 KiB")}}function qi(r){yo("review-state",r.state);for(const p of r.threads)yo("review-thread",p);for(const p of r.events)yo("review-event",p);if(lm(r.threads),r.state.schemaVersion!=="1.3"||r.state.reportId!==r.report.reportId||r.state.reportFingerprint.length!==64||r.state.revision!==r.events.length)throw Ze("REVIEW_BROWSER_INVALID","Stored review state is inconsistent");if(new Set(r.state.threadIds).size!==r.state.threadIds.length)throw Ze("REVIEW_BROWSER_INVALID","Stored review threads are duplicated");const a=new Set(r.threads.map(p=>p.id));if(a.size!==r.threads.length||r.state.threadIds.length!==r.threads.length||r.state.threadIds.some(p=>!a.has(p)))throw Ze("REVIEW_BROWSER_INVALID","Stored review thread inventory is inconsistent");const n=new Set(r.state.orphanedThreadIds);for(const p of r.threads)if(p.reportId!==r.report.reportId||p.state==="orphaned"!==n.has(p.id))throw Ze("REVIEW_BROWSER_INVALID","Stored review thread identity is inconsistent");const l=new Set;for(const[p,t]of r.events.entries()){if(l.has(t.id)||t.sequence!==p+1||t.reportId!==r.report.reportId)throw Ze("REVIEW_BROWSER_INVALID","Stored review event sequence is invalid");l.add(t.id)}}async function Hu(r,a){const n=Bu(a);if(!om(n))throw Ze("REVIEW_BROWSER_INVALID","Stored review state has an invalid shape");if(n.reportFingerprint!==r.state.reportFingerprint||n.state.reportFingerprint!==n.reportFingerprint)throw Ze("REVIEW_BROWSER_STALE","Stored review state belongs to an older report; export it before re-anchoring");const l=Eu(n,r.anchorCatalog,await Su(r.report,br),!0);return qi({...r,state:Ke(l.state),threads:Ke(l.threads),events:Ke(l.events)}),l}function dm(){const r=globalThis.navigator?.locks;if(!r)throw Ze("REVIEW_BROWSER_LOCK_UNAVAILABLE","Concurrent-safe review storage requires utsuri serve in a browser with Web Locks support");return r}function Dn(r,a){return{...Ke(r.state),revision:r.state.revision+1,updatedAt:a}}async function Bn(r,a,n){const l=r.events.length+1,p={reportId:r.report.reportId,sequence:l,createdAt:a,...n};return{schemaVersion:"1.0",id:`event:${(await br(p)).slice(0,24)}`,...p}}async function Uu(r,a){const n=await br(r);return{report:Ke(r),state:{schemaVersion:"1.3",reportId:r.reportId,reportFingerprint:n,revision:0,updatedAt:a,viewed:{},judgments:Object.fromEntries(r.changes.map(l=>[l.id,{changeId:l.id,state:"unreviewed",updatedAt:a}])),threadIds:[],orphanedThreadIds:[]},threads:[],events:[],anchorCatalog:await Zf(r,br),sidecarFiles:{}}}async function um(r){const a=await Uu(r,new Date().toISOString()),n=localStorage.getItem(Du(r.reportId));if(!n)return a;const l=await Hu(a,n),p={...a,state:Ke(l.state),threads:Ke(l.threads),events:Ke(l.events)};return qi(p),p}async function pm(r,a=r.state.revision-1){if(qi(r),a<0||r.state.revision!==a+1)throw Ze("REVIEW_REVISION_INVALID","Review mutation must advance one revision");const n={schemaVersion:"1.0",reportFingerprint:r.state.reportFingerprint,state:Ke(r.state),threads:Ke(r.threads),events:Ke(r.events)},l=JSON.stringify(n);if(new TextEncoder().encode(l).byteLength>Fu)throw Ze("REVIEW_BROWSER_LIMIT","Review state is near browser-storage limits; export it before adding more comments");const p=Du(r.report.reportId);await dm().request(`${p}:write`,{mode:"exclusive"},async()=>{const t=localStorage.getItem(p);if((t?(await Hu(r,t)).state.revision:0)!==a)throw Ze("REVIEW_REVISION_CONFLICT","Review state changed in another tab; reload before retrying this edit");localStorage.setItem(p,l)})}async function cm(r,a,n,l=new Date().toISOString()){const p=Dn(r,l);p.viewed[Br(a)]={anchor:Ke(a),state:n,updatedAt:l};const t=await Bn(r,l,{type:"viewed.changed",anchor:Ke(a),viewState:n});return{...r,state:p,events:[...r.events,t]}}async function hm(r,a,n,l=new Date().toISOString()){if(!r.report.changes.some(s=>s.id===a))throw Ze("REVIEW_CHANGE_MISSING","Review change does not exist");const p=Dn(r,l);p.judgments[a]={changeId:a,state:n,updatedAt:l};const t=await Bn(r,l,{type:"judgment.changed",changeId:a,judgmentState:n});return{...r,state:p,events:[...r.events,t]}}async function fm(r,a,n,l,p=new Date().toISOString(),t=!1){if(a.type==="line-range"&&a.ref.includes(":range:")){const c=await Ru(r.report,a.ref,br);if(!c||qa(c)!==qa(a))throw Ze("REVIEW_RANGE_INVALID","Review line range is invalid")}const s=n.trim();if(!s)throw Ze("REVIEW_COMMENT_EMPTY","Review comments must not be empty");if(new TextEncoder().encode(s).byteLength>16*1024)throw Ze("REVIEW_COMMENT_LIMIT","Review comment exceeds 16 KiB");const o=`thread:${(await br({reportId:r.report.reportId,anchor:a,kind:l,normalized:s,createdAt:p})).slice(0,24)}`,i=`message:${(await br({threadId:o,normalized:s,createdAt:p})).slice(0,24)}`,d={id:o,reportId:r.report.reportId,anchor:Ke(a),kind:l,state:"open",messages:[{id:i,kind:"human-note",author:{type:"human",label:"Reviewer"},body:s,createdAt:p}],agentAttention:t?{state:"requested",updatedAt:p}:{state:"none"},createdAt:p,updatedAt:p},m=Dn(r,p);m.threadIds=[...m.threadIds,o];const h=await Bn(r,p,{type:"thread.created",anchor:Ke(a),threadId:o,messageId:i,attentionState:t?"requested":"none"});return{...r,state:m,threads:[...r.threads,d],events:[...r.events,h]}}async function mm(r,a,n,l=new Date().toISOString()){const p=r.threads.findIndex(m=>m.id===a);if(p===-1)throw Ze("REVIEW_THREAD_MISSING","Review thread does not exist");const t=r.threads[p];if(new Set(["stale","orphaned","resolved"]).has(t.state))throw Ze("REVIEW_THREAD_NOT_CURRENT","Stale, orphaned, or resolved comments cannot request Agent attention");const s=n?"requested":"none";if(t.agentAttention.state!=="none"&&t.agentAttention.state!=="requested")throw Ze("REVIEW_ATTENTION_SUBMITTED","Submitted Agent attention cannot be changed");if(t.agentAttention.state===s)return r;const o=Ke(r.threads);o[p]={...o[p],agentAttention:{state:s,updatedAt:l},updatedAt:l};const i=Dn(r,l),d=await Bn(r,l,{type:"agent-attention.changed",threadId:a,attentionState:s});return{...r,state:i,threads:o,events:[...r.events,d]}}async function vm(r,a,n=new Date().toISOString()){const l=r.threads.findIndex(i=>i.id===a);if(l===-1)throw Ze("REVIEW_THREAD_MISSING","Review thread does not exist");const p=r.threads[l];if(p.state==="stale"||p.state==="orphaned")throw Ze("REVIEW_THREAD_NOT_CURRENT","Stale or orphaned comments cannot be resolved");const t=Ke(r.threads);t[l]={...t[l],state:"resolved",updatedAt:n};const s=Dn(r,n),o=await Bn(r,n,{type:"thread.resolved",threadId:a});return{...r,state:s,threads:t,events:[...r.events,o]}}function gm(r){const a=new Map(r.anchorCatalog.map(n=>[Br(n),Ke(n)]));for(const n of Object.values(r.state.viewed))a.set(Br(n.anchor),Ke(n.anchor));for(const n of r.threads)a.set(Br(n.anchor),Ke(n.anchor));return[...a.values()].sort((n,l)=>Br(n).localeCompare(Br(l)))}function ym(r,a,n=new Date().toISOString()){const l={schemaVersion:"1.0",source:{reportId:r.report.reportId,reportFingerprint:r.state.reportFingerprint,base:a.base,head:a.head},state:Ke(r.state),threads:Ke(r.threads),events:Ke(r.events),anchorCatalog:gm(r),exportedAt:n},p=Vu(l);if(!p.ok)throw Ze("REVIEW_BUNDLE_INVALID",p.errors.join("; "));return l}async function _m(r,a,n={}){const l=n.importedAt??new Date().toISOString(),p=JSON.stringify(a),t=Bu(p),s=t&&typeof t=="object"&&!Array.isArray(t)&&"source"in t?t.source:null,o=!!(s&&typeof s=="object"&&!Array.isArray(s)&&"reportId"in s&&"reportFingerprint"in s&&s.reportId===r.report.reportId&&s.reportFingerprint===r.state.reportFingerprint),i=Eu(t,r.anchorCatalog,await Su(r.report,br),o),d=Vu(i);if(!d.ok)throw Ze("REVIEW_BUNDLE_INVALID",d.errors.join("; "));const m=i;if(r={...r,anchorCatalog:await Kf(r.report,r.anchorCatalog,m.threads.map(X=>X.anchor),br)},!o&&!n.reanchor)throw Ze("REVIEW_REPORT_MISMATCH","Review bundle belongs to another report; explicitly enable re-anchoring to import it");const h=[],c=[],P=Dn(r,l);for(const[X,ne]of Object.entries(m.state.viewed)){const ee=co(ne.anchor,r.anchorCatalog);c.push(ee);const $e=ee.result==="exact"?ee.candidate:ne.anchor,Fe=ee.result==="exact"?Br($e):X,ge={anchor:Ke($e),state:ee.result==="exact"?ne.state:"stale",updatedAt:l},He=P.viewed[Fe];He&&qa(He)!==qa(ge)?h.push({kind:"viewed",id:Fe,current:He,incoming:ge}):P.viewed[Fe]=ge}const N=new Map(m.anchorCatalog.filter(X=>X.type==="change").map(X=>[X.ref,X]));for(const[X,ne]of Object.entries(m.state.judgments)){const ee=N.get(X),$e=ee?co(ee,r.anchorCatalog):void 0;$e&&c.push($e);const Fe=$e?.result==="exact"?$e.candidate.ref:X,ge={changeId:Fe,state:$e?.result==="exact"?ne.state:"stale",updatedAt:l},He=P.judgments[Fe];He&&He.state!=="unreviewed"&&qa(He)!==qa(ge)?h.push({kind:"judgment",id:Fe,current:He,incoming:ge}):P.judgments[Fe]=ge}const Z=Ke(r.threads);for(const X of m.threads){const ne=co(X.anchor,r.anchorCatalog);c.push(ne);const ee={...Ke(X),reportId:r.report.reportId,anchor:ne.result==="exact"?Ke(ne.candidate):Ke(X.anchor),state:ne.result==="exact"?X.state:ne.result==="missing"?"orphaned":"stale",updatedAt:l},$e=Z.find(Fe=>Fe.id===ee.id);$e&&qa($e)!==qa(ee)?h.push({kind:"thread",id:ee.id,current:$e,incoming:ee}):$e||Z.push(ee)}P.threadIds=Z.map(X=>X.id),P.orphanedThreadIds=Z.filter(X=>X.state==="orphaned").map(X=>X.id);const E=await Bn(r,l,{type:"state.imported",sourceReportId:m.source.reportId}),K={...r,state:P,threads:Z,events:[...r.events,E]};return qi(K),{store:K,reanchored:c,conflicts:h}}const wm=512*1024;function hs(r,a,n){const l=[/\\bBearer\\s+[A-Za-z0-9._~+/=-]{8,}\\b/giu,/\\b(?:api[_-]?key|access[_-]?token|auth[_-]?token|token|password|passwd|secret)\\b\\s*[:=]\\s*[^\\s,;]+/giu,/\\bAKIA[0-9A-Z]{16}\\b/gu,/\\b(?:gh[pousr]_[A-Za-z0-9_]{20,}|github_pat_[A-Za-z0-9_]{20,}|sk-[A-Za-z0-9_-]{12,})\\b/gu];let p=r;for(const t of l)t.test(p)&&(n.push({category:"secret-pattern",ref:a}),p=p.replace(t,"[REDACTED]")),t.lastIndex=0;return p}function bm(r,a){const n=a.anchor;return n.type==="change"?r.changes.find(l=>l.id===n.ref):n.type==="hunk"||n.type==="line-range"?r.changes.find(l=>l.hunkRefs.some(p=>n.ref===p||n.ref.startsWith(`${p}:`))):n.type==="visual-target"||n.type==="visual-region"?r.changes.find(l=>l.targetRefs.includes(n.targetRef??n.ref)):n.type==="finding"?r.changes.find(l=>l.findingRefs.includes(n.ref)):r.changes.find(l=>n.ref.startsWith(`${l.id}:gap:`))}function Pm(r,a,n){return a.anchor.type==="hunk"||a.anchor.type==="line-range"?r.hunks.filter(l=>a.anchor.ref===l.id||a.anchor.ref.startsWith(`${l.id}:`)):n?r.hunks.filter(l=>n.hunkRefs.includes(l.id)):[]}function km(r,a){const n=a.anchor.targetRef??(a.anchor.type==="visual-target"?a.anchor.ref:void 0);if(!n)return[];const l=a.anchor.type==="visual-region"?a.anchor.region:void 0;return r.comparisons.filter(p=>p.targetRef===n).flatMap(p=>p.images.flatMap(t=>[{role:"before",assetRef:t.beforeRef,...l?{crop:l}:{}},{role:"after",assetRef:t.afterRef,...l?{crop:l}:{}},{role:"diff",assetRef:t.diffRef,...l?{crop:l}:{}}])).slice(0,10)}async function xm(r,a=new Date().toISOString()){const n=r.threads.filter(i=>i.agentAttention.state==="requested"&&!new Set(["stale","orphaned","resolved"]).has(i.state));if(n.length===0)throw new Error("No current comments request Agent attention");if(n.length>20)throw new Error("Feedback Batch exceeds 20 items");const l=`fb:${(await br({reportId:r.report.reportId,threads:n.map(i=>i.id),createdAt:a})).slice(0,24)}`,p=await Promise.all(n.map(async i=>{const d=[...i.messages].reverse().find(h=>h.author.type==="human");if(!d)throw new Error("Feedback thread has no human source message");const m=i.anchor.type==="visual-target"||i.anchor.type==="visual-region";return{id:`item:${(await br({batchId:l,threadId:i.id,messageId:d.id})).slice(0,24)}`,threadId:i.id,anchor:structuredClone(i.anchor),sourceMessageId:d.id,requestKind:i.kind==="question"?"explain":"freeform",question:d.body,contextSelection:{includeCodeDiff:!m,includeVisualCrop:m,includeComputedStyle:!1,includeDomAria:!1,includeRelatedTests:!1},state:"ready"}})),t=structuredClone(r.report.origin),s=[];for(const[i,d]of p.entries()){const m=n[i],h=bm(r.report,m),c=[],P=Pm(r.report,m,h),N={schemaVersion:"1.1",reportId:r.report.reportId,batchId:l,itemId:d.id,baseSha:"",headSha:"",anchor:structuredClone(d.anchor),question:hs(d.question,`item:${d.id}:question`,c),...h?{semanticChange:{id:h.id,title:hs(h.title,`change:${h.id}:title`,c),summary:hs(h.summary,`change:${h.id}:summary`,c),intent:{text:hs(h.intent.text,`change:${h.id}:intent`,c),source:h.intent.source,evidenceRefs:[...h.intent.evidenceRefs]},risk:structuredClone(h.risk)}}:{},code:d.contextSelection.includeCodeDiff?P.map(E=>({path:E.path,startLine:m.anchor.type==="line-range"?m.anchor.startLine:Math.max(1,E.newStart||E.oldStart),endLine:m.anchor.type==="line-range"?m.anchor.endLine:Math.max(1,(E.newStart||E.oldStart)+Math.max(E.newLines,E.oldLines)-1),textRef:E.id})):[],images:d.contextSelection.includeVisualCrop?km(r.report,m):[],evidenceRefs:h?[...h.intent.evidenceRefs]:[],priorThreadMessages:m.messages.map(E=>({role:E.author.type==="agent"?"agent":"human",text:hs(E.body,`message:${E.id}`,c)})),redactions:c},Z={...N,contextHash:await br(N)};if(new TextEncoder().encode(JSON.stringify(Z)).byteLength>wm)throw new Error("Context Pack exceeds 512 KiB");s.push(Z)}return{batch:{id:l,reportId:r.report.reportId,origin:t,items:p.map((i,d)=>({...i,question:s[d].question})),state:"ready",deliveryMode:"export-only",contextHash:await br(s.map(i=>i.contextHash)),createdAt:a},contexts:s,shared:{comments:p.length,codeRanges:s.reduce((i,d)=>i+d.code.length,0),imageCrops:s.reduce((i,d)=>i+d.images.length,0),evidenceReferences:s.reduce((i,d)=>i+d.evidenceRefs.length,0)},excluded:["raw DOM and ARIA artifacts","environment variables","files outside the report","related tests"],redactionCount:s.reduce((i,d)=>i+d.redactions.length,0),contextBytes:s.reduce((i,d)=>i+new TextEncoder().encode(JSON.stringify(d)).byteLength,0),warnings:["Static mode exports files; it cannot submit to an Origin Session"],destination:{host:t.host,bound:!!t.sessionRef,deliveryMode:"export-only"}}}const Wu=480*60*1e3;function Am(r,a,n){return`utsuri:interactive:${JSON.stringify([r,a,n])}`}function Im(r,a){try{const n=JSON.parse(r);return!n||Object.keys(n).sort().join(",")!=="expiresAt,token"||typeof n.token!="string"||!/^[A-Za-z0-9_-]{32,128}$/u.test(n.token)||!Number.isSafeInteger(n.expiresAt)||n.expiresAt<=a||n.expiresAt>a+Wu?null:{token:n.token,expiresAt:n.expiresAt}}catch{return null}}var Aa=F("<p> </p>"),$m=F(\'<a target="_blank" rel="noopener noreferrer"> </a><code> </code>\',1),qm=F("<li><strong> </strong> <span> </span> <p> </p> <code> </code> <dl><div><dt>SHA</dt> <dd> </dd></div> <div><dt>Exit code</dt> <dd> </dd></div> <div><dt>Passed</dt> <dd> </dd></div> <div><dt>Completed</dt> <dd> </dd></div></dl> <!> <!></li>"),_o=F("<ol></ol>"),Rm=F(\'<section class="registered-checks"><h3> </h3> <p> </p> <!></section>\'),Sm=F(\'<p class="review-message" role="alert"> </p>\'),di=F("<span> </span>"),Em=F(\'<li><a><span class="queue-index"> </span> <span class="queue-copy"><strong> </strong> <span class="badges"><span> </span> <!></span> <small class="priority-reason"> </small> <small class="human-status"> </small></span></a></li>\'),Nm=F(\'<section class="queue-section"><h3><span> </span> <span class="count"> </span></h3> <ol></ol></section>\'),Cm=F(\'<li><a><span class="queue-index"> </span> <span class="queue-copy"><strong> </strong><span> </span></span></a></li>\'),Lm=F(\'<section class="queue-section unclassified"><h3><span> </span><span class="count"> </span></h3> <ol></ol></section>\'),jm=F(\'<p class="review-overview"> </p>\'),Om=F(\'<p class="route-status"> </p> <h3> </h3> <p> </p> <button type="button"> <span aria-hidden="true">→</span></button>\',1),Tm=F(\'<li><button type="button"><span class="map-index"> </span> <span class="map-copy"><strong> </strong> <span> </span></span> <span class="map-meta"> <span aria-hidden="true">·</span> </span></button></li>\'),Mm=F(\'<li class="map-remainder"> </li>\'),zm=F(\'<section class="review-map" aria-labelledby="review-map-heading"><header><div><p class="kicker">Map / semantic</p> <h2 id="review-map-heading"> </h2></div> <p> </p></header> <ol><!> <!></ol></section>\'),Vm=F(\'<label class="viewed-control compact-control"><input type="checkbox"/> <span> </span></label>\'),Fm=F(\'<li><span class="file-status"> </span> <code> </code> <span> </span> <!></li>\'),ui=F("<option> </option>"),Dm=F(\'<div class="review-controls"><label><span> </span> <select><!><!></select></label> <label class="viewed-control"><input type="checkbox"/> <span> </span></label> <button type="button"> </button></div> <p class="local-only-note"> </p>\',1),Bm=F(\'<p class="review-message" role="status"> </p>\'),wo=F("<li> </li>"),Hm=F("<ul></ul>"),Um=F(\'<button type="button" class="inline-comment-action"> </button>\'),Wm=F("<li><span> </span> <!></li>"),Zm=F("<label><span>Target</span> <select></select></label>"),Km=F("<label><span> </span> <select></select></label>"),Jm=F(\'<label class="viewed-control visual-viewed-control"><input type="checkbox"/> <span> </span></label>\'),Gm=F(\'<div class="persistent-error" role="alert"><strong>INCOMPLETE</strong> <span> </span></div>\'),Rd=F(\'<span aria-hidden="true"> </span>\'),fs=F(\'<button class="visual-comment-pin" type="button"> </button>\'),Ym=F(\'<div class="visual-panes" data-visual-mode="side-by-side"><figure><figcaption> </figcaption> <div class="visual-scroll"><div class="image-stage"><img/></div></div></figure> <figure><figcaption> </figcaption> <div class="visual-scroll"><div class="image-stage"><img/> <!> <!></div></div></figure></div>\'),Qm=F(\'<label class="wipe-control"><span> </span> <input type="range" min="0" max="100"/></label> <figure class="single-visual"><figcaption> </figcaption> <div class="visual-scroll"><div class="image-stage"><img/> <img class="wipe-after"/> <!></div></div></figure>\',1),Xm=F(\'<figure class="single-visual"><figcaption> </figcaption> <div class="visual-scroll"><div class="image-stage"><img/> <img/> <!></div></div></figure>\'),ev=F(\'<figure class="single-visual pixel-diff-view"><figcaption> </figcaption> <div class="visual-scroll"><div class="image-stage"><img/> <!></div></div></figure>\'),tv=F(\'<figure class="single-visual"><figcaption> </figcaption> <div class="visual-scroll"><div class="image-stage"><img/> <!> <!></div></div></figure>\'),Or=F(\'<button type="button"> </button>\'),rv=F(\'<li><div class="region-actions"><button type="button"> </button> <!></div></li>\'),av=F(\'<dl class="visual-metrics"><div><dt>Pixels changed</dt> <dd> </dd></div> <div><dt>Pixel ratio</dt> <dd> </dd></div> <div><dt> </dt> <dd> </dd></div> <div><dt>Canvas</dt> <dd> </dd></div></dl> <!> <section class="region-list" aria-labelledby="region-heading"><h4 id="region-heading"> </h4> <!></section>\',1),nv=F(\'<div class="visual-selectors"><!> <!> <!> <label class="visual-slider"><span> </span> <input type="range" min="50" max="200" step="10"/></label></div> <div class="visual-mode-control" role="group"><button type="button"> </button> <button type="button"> </button> <button type="button"> </button> <button type="button"> </button> <button type="button"> </button></div> <!> <!>\',1),sv=F(\'<div class="verification-gap" role="status"><strong>UNCOVERED</strong> <span> </span></div>\'),iv=F(\'<li><article tabindex="-1"><div class="finding-badges"><span> </span><span> </span><span> </span></div> <h5> </h5> <p> </p> <!> <!></article></li>\'),ov=F("<li><span> </span><strong> </strong> <p> </p></li>"),lv=F("<li><strong> </strong> </li>"),dv=F(\'<details class="more-evidence"><summary> </summary> <ul></ul></details>\'),uv=F(\'<label class="viewed-control dark-control"><input type="checkbox"/> <span> </span></label> <button type="button"> </button>\',1),pv=F(\'<dl class="hunk-explanation"><div><dt> </dt> <dd> </dd></div> <div><dt> </dt> <dd> </dd></div></dl>\'),Sd=F(\'<button class="context-fold" type="button"> </button>\'),pi=F(\'<span class="line-number"></span>\'),Ed=F(\'<button class="line-comment" type="button">✎</button>\'),cv=F(\'<div role="group"><!> <!> <span class="line-sign" aria-hidden="true"> </span> <code></code> <!></div>\'),Nd=F("<code></code>"),hv=F(\'<div class="split-row" role="group"><div><!> <span class="line-sign" aria-hidden="true"> </span> <!></div> <div><!> <span class="line-sign" aria-hidden="true"> </span> <!></div> <!></div>\'),fv=F(\'<button class="back-link hunk-back" type="button"> </button>\'),mv=F(\'<section tabindex="-1"><header><div><p> </p> <h4> </h4></div> <div class="hunk-actions"><!> <!> <!> <button type="button" class="anchor-button">#</button></div></header> <!> <div role="region"></div> <!></section>\'),vv=F(\'<form class="comment-composer"><div><p class="kicker"> </p> <code> </code></div> <label><span>Kind</span> <select><option>Note</option><option>Question</option><option>Finding</option><option>Change request</option></select></label> <label class="comment-body"><span> </span> <textarea rows="4" maxlength="16384" required=""></textarea></label> <label class="agent-attention-control"><input type="checkbox"/> <span> </span> <small> </small></label> <p> </p> <div class="comment-actions"><button type="submit"> </button> <button type="button"> </button></div></form>\'),gv=F(\'<div class="answer-message"><p> </p> <button type="button"> </button></div>\'),yv=F(\'<label class="agent-attention-control compact-attention"><input type="checkbox"/> <span> </span></label>\'),_v=F(\'<p class="attention-state"> </p>\'),wv=F(\'<li tabindex="-1"><header><div><span> </span> <strong> </strong></div> <span> </span></header> <code> </code> <!> <!> <!></li>\'),bv=F(\'<ol class="thread-list"></ol>\'),Pv=F(\'<p class="empty-comments"> </p>\'),kv=F(\'<article class="focused-change" tabindex="-1"><button class="back-link" type="button"> </button> <header class="change-header"><div><p class="kicker"> </p> <h2> </h2></div> <div class="change-badges" aria-label="Change status"><span> </span> <span> </span> <span> </span></div></header> <p class="priority-reason"> </p> <section class="review-workspace" aria-labelledby="review-workspace-heading"><div class="review-workspace-heading"><div><p class="kicker">State / human-owned</p> <h3 id="review-workspace-heading"> </h3> <!></div> <div class="review-transfer-actions"><label><input type="checkbox"/> <span> </span></label> <button type="button"> </button> <button type="button"> </button> <input class="visually-hidden" type="file" accept="application/json,.json"/></div></div> <!> <!></section> <section class="interpretation-section" aria-labelledby="interpretation-heading"><div class="section-heading"><div><p class="kicker">Interpretation / Agent</p> <h3 id="interpretation-heading"> </h3></div></div> <div class="explanation-grid"><section><h3> </h3> <p> </p> <p class="technical"> </p></section> <section><h3> </h3> <p> </p></section> <section><h3> </h3> <!></section> <section class="risk-block"><h3> </h3> <ul></ul></section> <section class="gap-block"><h3> </h3> <ul></ul></section> <section><h3> </h3> <ul></ul></section></div></section> <section class="visual-evidence-section" aria-labelledby="measured-evidence-heading"><div class="section-heading visual-heading"><div><p class="kicker"> </p> <h3 id="measured-evidence-heading"> </h3> <h4 id="visual-evidence-heading" tabindex="-1"> </h4> <p> </p></div></div> <!> <section class="finding-list" aria-labelledby="finding-heading"><div class="section-heading"><div><p class="kicker"> </p> <h4 id="finding-heading"> </h4></div></div> <!></section></section> <section class="evidence-section" aria-labelledby="evidence-heading"><div class="section-heading"><div><p class="kicker"> </p> <h3 id="evidence-heading"> </h3></div></div> <ul class="evidence-list"></ul> <!></section> <p class="range-help"> </p> <!> <section class="diff-section" aria-labelledby="diff-heading"><div class="section-heading"><div><p class="kicker"> </p> <h3 id="diff-heading"> </h3></div> <div class="segmented-control" aria-label="Diff layout"><button type="button"> </button> <button type="button"> </button></div></div> <!></section> <section class="review-comments" aria-labelledby="review-comments-heading"><div class="section-heading"><div><p class="kicker"> </p> <h3 id="review-comments-heading"> </h3></div></div> <!> <!></section></article>\'),xv=F(\'<div class="hunk-actions"><label class="viewed-control dark-control"><input type="checkbox"/> <span> </span></label> <button type="button"> </button></div>\'),Av=F(\'<div><span class="line-number"> </span><span class="line-number"> </span><span class="line-sign"> </span><code> </code></div>\'),Iv=F(\'<section class="focused-change unclassified-focus"><button class="back-link" type="button"> </button> <p class="kicker"> </p> <h2> </h2> <section class="hunk active-hunk" tabindex="-1"><header><h3> </h3> <!></header> <div class="diff-table"></div></section></section>\'),$v=F(\'<section class="focused-change empty-focus"><h2> </h2></section>\'),qv=F(\'<li><strong> </strong> <code> </code> <span> </span> <button type="button"> </button></li>\'),Rv=F(\'<p class="feedback-warning"> </p>\'),Sv=F("<pre> </pre>"),Ev=F(\'<div class="feedback-actions"><button type="button"> </button> <!></div> <!>\',1),Nv=F(\'<section id="feedback-preview-panel" class="feedback-preview" aria-labelledby="feedback-preview-heading"><h2 id="feedback-preview-heading"> </h2> <p class="feedback-batch-state"> </p> <ol></ol> <div class="feedback-preview-grid"><section><h3> </h3> <p> </p></section> <section><h3> </h3> <p> </p></section> <section><h3> </h3> <p> </p></section></div> <!> <!></section>\'),Cv=F(\'<aside aria-live="polite"><header><div><strong> </strong> <span class="unread-badge"> </span></div> <button type="button" aria-controls="feedback-preview-panel"> </button> <!> <!></header> <!></aside>\'),Lv=F(\'<div class="report-shell"><header class="report-header"><a class="wordmark" href="#summary" aria-label="Utsuri review summary"><span aria-hidden="true">UT</span> <strong>Utsuri</strong></a> <div class="report-state"><span class="state-mark" aria-hidden="true"></span> <span> </span> <small> </small></div> <p class="report-id"> </p></header> <!> <aside class="review-rail" aria-labelledby="queue-heading"><div class="rail-heading"><p class="kicker">Focus / 01</p> <h2 id="queue-heading" tabindex="-1"> </h2></div> <label class="queue-search"><span> </span> <input type="search" autocomplete="off"/></label> <p class="priority-help"> </p> <label class="viewed-control"><input type="checkbox"/><span> </span></label> <nav><!> <!></nav></aside> <main id="main-content"><section aria-labelledby="summary-heading" class="decision-summary"><div class="brief-lead"><p class="kicker"> </p> <h1 id="summary-heading" tabindex="-1"> </h1> <!> <div class="evidence-posture"><p class="kicker"> </p> <p class="decision-statement"> </p></div></div> <aside class="review-route" aria-labelledby="review-route-heading"><p class="kicker">Next / 01</p> <h2 id="review-route-heading"> </h2> <!></aside> <!> <dl class="metrics"><div><dt> </dt> <dd> </dd></div> <div><dt> </dt> <dd class="positive"> </dd></div> <div><dt> </dt> <dd class="negative"> </dd></div> <div><dt> </dt> <dd> </dd></div> <div><dt> </dt> <dd> </dd></div></dl> <!> <section class="coverage-overview" aria-labelledby="coverage-heading"><div><p class="kicker">Coverage / structured</p> <h2 id="coverage-heading"> </h2> <p> </p></div> <dl><div><dt> </dt> <dd> </dd></div> <div><dt> </dt> <dd> </dd></div> <div><dt> </dt> <dd> </dd></div></dl></section> <details class="file-inventory"><summary> </summary> <ul></ul></details></section> <!></main> <!></div>\'),jv=F(\'<p class="loading" aria-live="polite"> </p>\');function Ov(r,a){Kd(a,!1);const n=W(),l=W(),p=W(),t=W(),s=W(),o=W(),i=(f,b=Md)=>{var q=Rm(),C=k(q),L=_(C,!0),Ae=v(C,2),Ut=_(Ae,!0),ba=v(Ae,2);{var Qr=Oa=>{var Ta=Aa(),en=_(Ta,!0);S(()=>y(en,(e(n),u(()=>e(n).noChecks)))),$(Oa,Ta)},Fi=Oa=>{var Ta=_o();we(Ta,5,b,en=>en.id,(en,pe)=>{var wn=qm(),Ms=k(wn),Di=_(Ms,!0),Qn=v(Ms),Xn=v(Qn),Bi=_(Xn),es=v(Xn,2),zs=_(es,!0),Vs=v(es,2),Fs=_(Vs,!0),ts=v(Vs,2),Ds=k(ts),Hi=v(k(Ds),2),Bs=_(Hi,!0),rs=v(Ds,2),Ui=v(k(rs),2),Wi=_(Ui,!0),as=v(rs,2),Hs=v(k(as),2),Us=_(Hs,!0),Ws=v(as,2),Zi=v(k(Ws),2),Zs=_(Zi,!0),Ks=v(ts,2);we(Ks,1,()=>(e(pe),u(()=>e(pe).warnings)),zr=>zr,(zr,tn)=>{var Ma=Aa(),ns=_(Ma,!0);S(()=>y(ns,e(tn))),$(zr,Ma)});var Js=v(Ks,2);{var Ki=zr=>{var tn=$m(),Ma=yr(tn),ns=_(Ma,!0),Ji=v(Ma),Gs=_(Ji);S(Ys=>{z(Ma,"href",Ys),y(ns,(e(n),u(()=>e(n).checkLog))),y(Gs,`SHA-256: ${e(pe),u(()=>e(pe).logSha256)??""}`)},[()=>(e(pe),u(()=>e(pe).logRef.startsWith("data:text/plain;")?e(pe).logRef:`./${e(pe).logRef}`))]),$(zr,tn)};B(Js,zr=>{e(pe),u(()=>e(pe).logRef)&&zr(Ki)})}S(zr=>{z(wn,"data-verification-kind",(e(pe),u(()=>e(pe).kind))),y(Di,(e(pe),u(()=>e(pe).kind))),y(Qn,` · ${e(pe),e(n),u(()=>e(pe).exitCode===null?e(n).checkNotRun:e(pe).exitCode===0?e(n).checkPassed:e(n).checkFailed)??""} `),y(Bi,`${e(pe),e(n),u(()=>e(pe).provenance==="log-attached"?e(n).logAttached:e(n).authorReported)??""} · ${e(pe),e(n),u(()=>e(pe).shaMatch==="match"?e(n).shaMatch:e(pe).shaMatch==="mismatch"?e(n).shaMismatch:e(n).shaUnknown)??""}`),y(zs,(e(pe),u(()=>e(pe).environment))),y(Fs,zr),y(Bs,(e(pe),u(()=>e(pe).subjectSha??"—"))),y(Wi,(e(pe),u(()=>e(pe).exitCode??"—"))),y(Us,(e(pe),u(()=>e(pe).passedCount??"—"))),y(Zs,(e(pe),u(()=>e(pe).completedAt??"—")))},[()=>(e(pe),u(()=>e(pe).command.join(" ")))]),$(en,wn)}),$(Oa,Ta)};B(ba,Oa=>{b(),u(()=>b().length===0)?Oa(Qr):Oa(Fi,-1)})}S(()=>{z(q,"aria-label",(e(n),u(()=>e(n).registeredChecks))),y(L,(e(n),u(()=>e(n).registeredChecks))),y(Ut,(e(n),u(()=>e(n).verificationHelp)))}),$(f,q)},d={critical:0,high:1,medium:2,low:3,info:4},m={"action-required":0,"needs-confirmation":1,"no-issue":2},h={en:{queue:"Review queue",autoPriority:"Automatic review priority",priorityHelp:"Priority is based on risk, verification gaps and unknown intent. Findings and human judgment are separate; completing review preserves the priority and evidence.",hideReviewed:"Hide reviewed changes",unknownIntent:"Unknown intent",verificationGaps:"Verification gaps",search:"Filter changes",action:"Priority review",confirm:"Review suggested",clear:"Routine review",unclassified:"Unclassified hunks",summary:"Review brief",reviewMap:"Change map",reviewerRoute:"Reviewer route",evidencePosture:"Evidence posture",startReview:"Start with highest attention",files:"Files",additions:"Additions",deletions:"Deletions",changes:"Change groups",lowSignal:"Low-signal files",inventory:"File inventory",backQueue:"Back to review queue",what:"What changed",why:"Why",userImpact:"User impact",noImpact:"User impact is not established.",risk:"Risk",gaps:"Not verified",verified:"Verified",evidence:"Evidence",codeDiff:"Code diff",rangeHelp:"Select a line number, then Shift-click another on the same side. Comment on the highlighted range.",rangeComment:"Comment on selected range",rangeInvalid:"Cannot comment on this range. Select up to 1,001 consecutive lines.",unified:"Unified",split:"Side by side",context:"Show {count} hidden context lines",moreEvidence:"More evidence",measured:"Measured evidence",interpretation:"Agent interpretation",hunkPurpose:"Purpose",hunkMeaning:"Meaning",visualEvidence:"Visual comparison",sideBySide:"Side by side",wipe:"Wipe",blink:"Blink",stopBlink:"Stop blink",pixelDiff:"Pixel diff",afterOnly:"After only",imageScope:"Image scope",zoom:"Zoom",wipePosition:"Wipe position",changedRegions:"Changed regions",noRegions:"No changed pixel regions",findings:"Findings",noFindings:"No linked findings",coverage:"Visual coverage",registeredChecks:"Registered verification results",verificationHelp:"Commands and outcomes are reported by the author. Attached logs are hashed assets; matching SHA identifies the subject, not independent proof of execution. Mock/local checks do not establish application E2E or external services.",noChecks:"No structured verification results registered",logAttached:"Log attached",authorReported:"Author reported",shaMatch:"SHA matches report",shaMismatch:"Different SHA",shaUnknown:"SHA match unknown",checkPassed:"Reported success",checkFailed:"Reported failure",checkNotRun:"Not run",checkLog:"Open verification log",planned:"Planned targets",captured:"Captured targets",failed:"Failed targets",viewCode:"View linked code",viewVisual:"View visual evidence",reducedMotion:"Blink unavailable because reduced motion is enabled",backChange:"Back to focused change",visualGap:"Visual verification has not run",reviewWorkspace:"Human review",reviewProgress:"Review progress",viewed:"Viewed",humanJudgment:"Human judgment",unreviewed:"Unreviewed",reviewed:"Reviewed",followUp:"Follow-up",blocked:"Blocked",comments:"Comments",comment:"Comment",commentOn:"Comment on",commentBody:"Review note",saveComment:"Save comment",cancel:"Cancel",resolve:"Resolve",resolved:"Resolved",noComments:"No comments for this change",localOnly:"Saved locally. Plain comments are never sent to an Agent.",askAgent:"Ask the current Agent",askAgentHelp:"This only saves the selection. It does not submit or create a conversation.",selectedItems:"Items for Agent review",reviewItems:"Review items",feedbackPreview:"Feedback Batch preview",feedbackUpdating:"Updating feedback…",feedbackUpdateFailed:"Review update failed",retryReviewUpdate:"Retry review update",shared:"Shared",notShared:"Not shared",delivery:"Delivery",returnConversation:"Return to current conversation",prepareRequest:"Prepare review request",copyHandoff:"Copy handoff",handoffCopied:"Handoff copied",unreadAnswers:"Unread answers",collapseFeedback:"Collapse Feedback Batch",expandFeedback:"Expand Feedback Batch",viewAnswer:"View comment and answer",markRead:"Mark as read",markUnread:"Mark as unread",answerReadHelp:"Visible answers become read after 700 ms. Marking unread pauses this until you leave and return to the answer.",exportReview:"Export review",importReview:"Import review",reviewBundleFile:"Review bundle file",reanchorImport:"Re-anchor another report",stale:"Stale",orphaned:"Orphaned",reviewUnavailable:"Review state unavailable",empty:"No semantic changes",dataUnavailable:"Review data unavailable",intentUnknown:"Intent unknown",loading:"Loading review data…"},ja:{queue:"レビューキュー",autoPriority:"自動のレビュー優先度",priorityHelp:"リスク・未検証事項・意図不明から優先度を付けます。検出事項や人の判断は別です。レビュー済みでも優先度と根拠は残ります。",hideReviewed:"レビュー済みを非表示",unknownIntent:"意図不明",verificationGaps:"未検証事項あり",search:"変更を絞り込む",action:"重点確認",confirm:"要確認",clear:"通常確認",unclassified:"未分類のハンク",summary:"レビュー要旨",reviewMap:"変更の全体像",reviewerRoute:"レビュー経路",evidencePosture:"根拠の状態",startReview:"要確認から見る",files:"ファイル",additions:"追加",deletions:"削除",changes:"変更グループ",lowSignal:"低シグナル",inventory:"ファイル一覧",backQueue:"レビューキューへ戻る",what:"変更内容",why:"変更理由",userImpact:"ユーザー影響",noImpact:"ユーザー影響は未確定です。",risk:"リスク",gaps:"未検証",verified:"検証済み",evidence:"根拠",codeDiff:"コード差分",rangeHelp:"行番号を選び、同じ側の別の行をShiftクリックすると範囲を選択できます。選択した範囲にコメントできます。",rangeComment:"選択範囲にコメント",rangeInvalid:"選択範囲にコメントできません。連続した1,001行以内の範囲を選択してください。",unified:"統合表示",split:"左右表示",context:"非表示のコンテキスト {count} 行を表示",moreEvidence:"その他の根拠",measured:"計測された根拠",interpretation:"Agent の解釈",hunkPurpose:"目的",hunkMeaning:"この差分の意味",visualEvidence:"画面比較",sideBySide:"左右比較",wipe:"ワイプ",blink:"点滅比較",stopBlink:"点滅を停止",pixelDiff:"ピクセル差分",afterOnly:"変更後のみ",imageScope:"画像の範囲",zoom:"拡大率",wipePosition:"ワイプ位置",changedRegions:"変更領域",noRegions:"変更ピクセル領域はありません",findings:"検出事項",noFindings:"関連する検出事項はありません",coverage:"画面カバレッジ",registeredChecks:"登録した検証結果",verificationHelp:"コマンドと実行結果は作者の申告です。添付ログはハッシュ付き資産として検証でき、SHA一致は対象を識別します。モックやローカル検証をアプリE2E・外部サービスの成功として扱いません。",noChecks:"構造化した検証結果は未登録です",logAttached:"ログ添付",authorReported:"作者申告",shaMatch:"レポートとSHA一致",shaMismatch:"異なるSHA",shaUnknown:"SHA一致は不明",checkPassed:"成功の申告",checkFailed:"失敗の申告",checkNotRun:"未実施",checkLog:"検証ログを開く",planned:"予定 target",captured:"取得済み target",failed:"失敗 target",viewCode:"関連コードを見る",viewVisual:"画面根拠を見る",reducedMotion:"視差低減が有効なため点滅比較は利用できません",backChange:"変更グループへ戻る",visualGap:"画面の検証は未実施です",reviewWorkspace:"人によるレビュー",reviewProgress:"レビュー進捗",viewed:"確認済み",humanJudgment:"人の判断",unreviewed:"未レビュー",reviewed:"レビュー済み",followUp:"要フォロー",blocked:"ブロック中",comments:"コメント",comment:"コメント",commentOn:"コメント対象",commentBody:"レビューメモ",saveComment:"コメントを保存",cancel:"キャンセル",resolve:"解決済みにする",resolved:"解決済み",noComments:"この変更へのコメントはありません",localOnly:"ローカルに保存します。通常コメントを Agent へ送信することはありません。",askAgent:"現在の Agent に確認を依頼",askAgentHelp:"選択状態だけを保存します。送信や新しい会話の作成は行いません。",selectedItems:"Agent 確認対象",reviewItems:"確認項目をレビュー",feedbackPreview:"Feedback Batch プレビュー",feedbackUpdating:"回答状態を更新中…",feedbackUpdateFailed:"レビュー状態を取得できませんでした",retryReviewUpdate:"レビュー状態を再取得",shared:"共有する情報",notShared:"共有しない情報",delivery:"受け渡し",returnConversation:"現在の会話へ戻す",prepareRequest:"レビュー依頼を準備",copyHandoff:"引き継ぎ文をコピー",handoffCopied:"引き継ぎ文をコピーしました",unreadAnswers:"未読回答",collapseFeedback:"Feedback Batch を折りたたむ",expandFeedback:"Feedback Batch を展開する",viewAnswer:"コメント・回答を確認",markRead:"既読にする",markUnread:"未読に戻す",answerReadHelp:"回答が画面に700ミリ秒表示されると既読になります。手動で未読に戻した回答は、一度表示領域を離れて再閲覧するまで自動既読にしません。",exportReview:"レビューを書き出す",importReview:"レビューを読み込む",reviewBundleFile:"レビューバンドルファイル",reanchorImport:"別レポートへ再アンカーする",stale:"古い状態",orphaned:"参照先なし",reviewUnavailable:"レビュー状態を利用できません",empty:"意味単位の変更はありません",dataUnavailable:"レビューデータを利用できません",intentUnknown:"変更意図は不明です",loading:"レビューデータを読み込んでいます…"}};let c=W(null),P=W(""),N=W("en"),Z=W(""),E=W(""),K=W(""),X="",ne=W("unified"),ee=W("side-by-side"),$e=W(""),Fe=W(""),ge=W(0),He=W(0),Pt=W(100),Ue=W(50),H=W(!1),le=W(!1),Ne=W(),xe=W(),er=W(),Jr=!1,oa=new Set,O=W(),Gr=W([]),Ht=W([]),ir=W([]),kr=W([]),Ca=W(!1),xr=W([]),or=W([]),Je=W(),T=W(),Ar=W([]),Ir=W(),j=W(null),mn={base:null,head:null},Yr=W(""),it=W(""),Ga=W(!1),Q=W(!1),tr=W(null),kt=W(null),$r=W(""),g=W("note"),w=W(!1),x=W(),G=W(),fe=W([]),te=W(""),De=!1,Hn="",Ri=0,Ya=W([]),ae=W(null),Cs=[],ya=W(0),vn=W(null),gn=W(!1),la=W(!1),Si=Promise.resolve();const Un=new ki;let da=W(""),Jo="",Qa=W(!1),Ls=null;function ot(f,b){return`${f}-${b.replace(/[^a-zA-Z0-9_-]/gu,"-")}`}function Wn(f){const b=f.region;return b?`left:${(b.x+b.width/2)*100}%;top:${(b.y+b.height/2)*100}%`:"display:none"}function _a(f){return f.risk.level==="critical"||f.risk.level==="high"?"action-required":f.risk.level==="medium"||f.verification.gaps.length>0||f.intent.source==="unknown"?"needs-confirmation":"no-issue"}function Ei(f){return[`${f.risk.level} risk`,...f.verification.gaps.length?[e(n).verificationGaps]:[],...f.intent.source==="unknown"?[e(n).unknownIntent]:[]].join(" · ")}function Go(f){return d[f.risk.level]*3+m[_a(f)]}function Zu(f){return e(c)?new Set(f.hunkRefs.map(b=>e(c)?.hunks.find(q=>q.id===b)?.path).filter(b=>b!==void 0)).size:0}function Ku(f,b){return/^ja(?:-|$)/iu.test(b)?`${f}ファイル`:`${f} file${f===1?"":"s"}`}function Ju(f,b){return/^ja(?:-|$)/iu.test(b)?`ほか${f}件の対応`:`${f} more change group${f===1?"":"s"}`}function Yo(f,b){return f==="reviewed"?b.reviewed:f==="follow-up"?b.followUp:f==="blocked"?b.blocked:f==="stale"?b.stale:b.unreviewed}function Zn(f,b){return f?.state.judgments[b]?.state??"unreviewed"}function La(f,b){return e(j)?Id(e(j).anchorCatalog,f,b):void 0}function Kn(f,b,q){const C=f?Id(f.anchorCatalog,b,q):void 0;return!C||!f?!1:f.state.viewed[Br(C)]?.state==="viewed"}function Qo(f,b){const q=f.lines[b];if(!q||q.kind==="no-newline")return;const C=q.kind==="addition"?"after":q.kind==="deletion"?"before":"diff",L=C==="before"?q.oldLine:q.newLine??q.oldLine;return L?La("line-range",`${f.id}:${C}:${L}:${b}`):void 0}function js(f,b,q,C){const L=e(kt);A(kt,C&&L?.hunkId===f.id&&L.side===b?{...L,end:q}:{hunkId:f.id,side:b,start:q,end:q})}function ja(f,b,q,C){return!!(C&&f?.hunkId===b&&f.side===q&&C>=Math.min(f.start,f.end)&&C<=Math.max(f.start,f.end))}async function Gu(){if(!e(kt)||!e(c))return;const{hunkId:f,side:b,start:q,end:C}=e(kt),L=await qu(e(c),f,b,Math.min(q,C),Math.max(q,C),br);if(!L){A(it,e(n).rangeInvalid);return}A(it,""),await wa(L)}function Ni(f){return f.type==="line-range"?`${f.path} · ${f.side} · ${f.startLine}–${f.endLine}`:f.path??f.ref}function Xo(f,b){return f.type==="change"?f.ref===b.id:f.type==="hunk"||f.type==="line-range"?b.hunkRefs.some(q=>f.ref===q||f.ref.startsWith(`${q}:`)):f.type==="visual-target"||f.type==="visual-region"?!!(f.targetRef&&b.targetRefs.includes(f.targetRef))||b.targetRefs.includes(f.ref):f.type==="finding"?b.findingRefs.includes(f.ref):f.type==="verification-gap"?f.ref.startsWith(`${b.id}:gap:`):!1}function Yu(){const b=new URLSearchParams(location.hash.startsWith("#")?location.hash.slice(1):"").get("token")??"";if(b){if(De=!0,!/^[A-Za-z0-9_-]{32,128}$/u.test(b)){A(Yr,"Interactive capability token is invalid"),history.replaceState(null,"",`${location.pathname}${location.search}`);return}A(Yr,""),A(te,b),Ri=Date.now()+Wu,history.replaceState(null,"",`${location.pathname}${location.search}`)}}function Ci(){return e(N)==="ja"?"対話セッションを復元できません。現在のサーバーの対話リンクを開き直してください。保存済みレビューは保持されています。":"Interactive session could not be restored. Reopen the current server\'s interactive link. Saved review data is retained."}function Li(){A(te,""),A(j,null),Ls?.abort();try{Hn&&sessionStorage.removeItem(Hn)}catch{}A(Yr,Ci())}function Qu(){if(e(c)&&(Hn=Am(location.origin,location.pathname,e(c).reportId),!De))try{const f=sessionStorage.getItem(Hn);if(!f)return;De=!0;const b=Im(f,Date.now());if(!b){Li();return}A(te,b.token),Ri=b.expiresAt}catch{A(Yr,Ci()),De=!0}}function Xu(){try{sessionStorage.setItem(Hn,JSON.stringify({token:e(te),expiresAt:Ri}))}catch{A(Yr,e(N)==="ja"?"このブラウザーではセッション保存を利用できません。再読み込み時は対話リンクを開き直してください。":"Session storage is unavailable. Reopen the interactive link after reloading.")}}async function Jn(f,b={}){if(!e(te)||!e(c))throw new Error("Interactive review capability is unavailable");const q=await fetch(`./api/v1/${f}`,{...b,credentials:"omit",headers:{authorization:`Bearer ${e(te)}`,"x-utsuri-report-id":e(c).reportId,...b.body?{"content-type":"application/json"}:{},...b.headers??{}}}),C=await q.json();if(!q.ok)throw q.status===401||q.status===403?(Li(),new Error(Ci())):new Error(C?.error?.message??`HTTP ${q.status}`);return C}function ji(f){if(!e(j)||f.state.revision<Math.max(e(j).state.revision,e(ya)))return;A(ya,f.state.revision),A(j,{...e(j),state:structuredClone(f.state),threads:structuredClone(f.threads),events:e(j).events}),A(Ya,structuredClone(f.inbox?.entries??e(Ya))),Cs=structuredClone(f.batches??Cs);const b=Cs.find(q=>q.id===e(ae)?.batch.id);e(ae)&&b&&(A(ae,{...e(ae),batch:structuredClone(b)}),b.state!=="ready"&&A(da,""))}function el(f){const b=Cs.find(q=>q.id===f.batch.id);return{...f,batch:structuredClone(b??f.batch)}}async function Oi(){const f=await Jn("review-state");ji(f)}function Xa(){return!!(e(te)&&e(j)&&e(j).state.revision<e(ya))}function tl(){return e(vn)?e(vn):Xa()?(e(gn)&&A(it,""),A(gn,!1),A(vn,(async()=>{try{for(;Xa();){const f=e(ya);if(await Oi(),Xa()&&e(ya)<=f)throw new Error(e(n).feedbackUpdateFailed)}}catch(f){A(gn,!0),A(it,f instanceof Error?f.message:String(f))}finally{A(vn,null)}})()),e(vn)):Promise.resolve()}function ep(f){try{const b=f.split(`\n`).filter(L=>L.startsWith("data:")).map(L=>L.slice(5).trimStart()).join(`\n`),q=JSON.parse(b),C=q.revision??q.sequence;if(q.reportId!==e(c)?.reportId||!Number.isSafeInteger(C)||C<=e(ya))return;A(ya,C),A(da,""),tl()}catch{}}async function yn(f){if(!e(j)||!e(c))return;const b=await Jn("review-events",{method:"POST",body:JSON.stringify({schemaVersion:"1.0",reportId:e(c).reportId,expectedRevision:e(j).state.revision,action:f})});ji(b)}async function tp(){if(!e(te)||!e(c))return;Ls?.abort();const f=new AbortController;Ls=f;try{const b=await fetch("./api/v1/events",{credentials:"omit",headers:{authorization:`Bearer ${e(te)}`,"x-utsuri-report-id":e(c).reportId},signal:f.signal});if(b.status===401||b.status===403){Li();return}if(!b.ok||!b.body)return;const q=b.body.getReader(),C=new TextDecoder;let L="";for(;!f.signal.aborted;){const{value:Ae,done:Ut}=await q.read();if(Ut)break;L+=C.decode(Ae,{stream:!0});const ba=L.split(`\n\n`);L=ba.pop()??"";for(const Qr of ba)ep(Qr)}}catch(b){f.signal.aborted||A(it,b instanceof Error?b.message:String(b))}}Rf(()=>Ls?.abort());async function _n(f){await pm(f,f.state.revision-1),A(j,f),A(it,"")}async function Gn(f,b,q){const C=La(f,b);if(!(!e(j)||!C)){A(Q,!0);try{e(te)?await yn({type:"viewed.changed",anchor:{type:C.type,ref:C.ref,fingerprint:C.fingerprint},viewState:q?"viewed":"unseen"}):await _n(await cm(e(j),C,q?"viewed":"unseen"))}catch(L){A(it,L instanceof Error?L.message:String(L))}finally{A(Q,!1)}}}async function rp(f,b){if(!(!e(j)||b==="stale")){A(Q,!0);try{e(te)?await yn({type:"judgment.changed",changeId:f,judgmentState:b}):await _n(await hm(e(j),f,b))}catch(q){A(it,q instanceof Error?q.message:String(q))}finally{A(Q,!1)}}}async function wa(f){!f||e(Q)||(A(tr,f),A($r,""),A(w,!1),await gs(),e(x)?.focus())}async function ap(){if(!(!e(j)||!e(tr))){A(Q,!0);try{e(te)?await yn({type:"thread.created",anchor:{type:e(tr).type,ref:e(tr).ref,fingerprint:e(tr).fingerprint},body:e($r),kind:e(g),requestAgentAttention:e(w)}):await _n(await fm(e(j),e(tr),e($r),e(g),new Date().toISOString(),e(w))),A(tr,null),A($r,""),A(w,!1)}catch(f){A(it,f instanceof Error?f.message:String(f))}finally{A(Q,!1)}}}async function np(f){if(e(j)){A(Q,!0);try{e(te)?await yn({type:"thread.resolved",threadId:f}):await _n(await vm(e(j),f))}catch(b){A(it,b instanceof Error?b.message:String(b))}finally{A(Q,!1)}}}async function sp(f,b){if(e(j)){A(Q,!0);try{e(te)?await yn({type:"agent-attention.changed",threadId:f,requested:b}):await _n(await mm(e(j),f,b)),A(ae,null),A(da,"")}catch(q){A(it,q instanceof Error?q.message:String(q))}finally{A(Q,!1)}}}async function ip(){if(!(!e(j)||!e(c))){A(Q,!0);try{const f=e(te)?await Jn("review/export",{method:"POST",body:JSON.stringify({schemaVersion:"1.0",reportId:e(c).reportId,expectedRevision:e(j).state.revision})}):ym(e(j),mn);rl(`${e(c)?.reportId??"utsuri"}-review.json`,f)}catch(f){A(it,f instanceof Error?f.message:String(f))}finally{A(Q,!1)}}}function rl(f,b){const q=new Blob([`${JSON.stringify(b,null,2)}\n`],{type:"application/json"}),C=URL.createObjectURL(q),L=document.createElement("a");L.href=C,L.download=f,L.click(),URL.revokeObjectURL(C)}function op(f){return`Process the pending Utsuri review items.\nReport: ${f.reportId}\nBatch: ${f.id}`}async function lp(){if(!(!e(j)||!e(c)||Xa())){A(Qa,!0);try{if(e(te)){const f=await Jn("feedback-batches/preview",{method:"POST",body:JSON.stringify({schemaVersion:"1.0",reportId:e(c).reportId,expectedRevision:e(j).state.revision,deliveryMode:"return-to-session"})});A(ae,el(f.preview))}else A(ae,await xm(e(j)));A(la,!1),Jo=`ui:${e(ae).batch.id}`,A(da,"")}catch(f){A(it,f instanceof Error?f.message:String(f))}finally{A(Qa,!1)}}}async function dp(){if(!(!e(ae)||e(ae).batch.state!=="ready"||!e(j)||!e(c)||Xa())){A(Qa,!0);try{if(e(te)){const f=await Jn("feedback-batches",{method:"POST",body:JSON.stringify({schemaVersion:"1.0",reportId:e(c).reportId,expectedRevision:e(j).state.revision,idempotencyKey:Jo,deliveryMode:"return-to-session"})});ji(f),A(ae,el(f.preview))}else rl(`${e(c).reportId}-${e(ae).batch.id.replace(":","-")}.json`,{schemaVersion:"1.0",batch:e(ae).batch,contexts:e(ae).contexts,preview:{shared:e(ae).shared,excluded:e(ae).excluded,redactionCount:e(ae).redactionCount,contextBytes:e(ae).contextBytes,destination:e(ae).destination}});A(da,e(ae).batch.state==="ready"&&!Xa()?op(e(ae).batch):"")}catch(f){A(it,f instanceof Error?f.message:String(f))}finally{A(Qa,!1)}}}function Yn(f){return e(Ya).some(b=>b.unreadAnswerItemIds.includes(f))}function al(f,b,q=!1){return q&&b&&Un.add(f),Si=Si.then(async()=>{if(!(!e(te)||Yn(f)===b))for(let C=0;C<3;C+=1)try{await yn({type:"answer-read.changed",itemId:f,unread:b});return}catch(L){if(!(L instanceof Error)||!L.message.includes("changed before this mutation")||C===2){A(it,L instanceof Error?L.message:String(L));return}await Oi()}}).catch(C=>{A(it,C instanceof Error?C.message:String(C))}),Si}function up(f,b){let q,C=!1,L=b;function Ae(){clearTimeout(q),q=void 0}function Ut(){Ae(),!(!C||document.visibilityState!=="visible"||!L.unread||Un.has(L.itemId))&&(q=setTimeout(()=>{C&&document.visibilityState==="visible"&&!Un.has(L.itemId)&&al(L.itemId,!1)},700))}const ba=new IntersectionObserver(([Qr])=>{C=!!(Qr?.isIntersecting&&Qr.intersectionRect.height>=Math.min(48,Qr.boundingClientRect.height)),C||Un.delete(L.itemId),Ut()},{threshold:[0,Math.min(1,48/Math.max(1,f.getBoundingClientRect().height)),1]});return ba.observe(f),document.addEventListener("visibilitychange",Ut),{update(Qr){L=Qr,Ut()},destroy(){Ae(),Un.delete(L.itemId),ba.disconnect(),document.removeEventListener("visibilitychange",Ut)}}}async function pp(f){const b=e(j)?.threads.find(L=>L.id===f),q=b&&e(c)?.changes.find(L=>Xo(b.anchor,L));if(!q)return;A(E,q.id),A(la,!0),await gs();const C=document.getElementById(ot("thread",f));C?.scrollIntoView({block:"center",behavior:"instant"}),C?.focus({preventScroll:!0})}async function cp(){if(!Xa()&&e(da))try{await navigator.clipboard.writeText(e(da)),A(it,e(n).handoffCopied)}catch(f){A(it,f instanceof Error?f.message:String(f))}}async function hp(f){if(!(!e(j)||!f)){if(e(te)){A(it,"Import is available only in static report mode"),md(G,e(G).value="");return}A(Q,!0);try{if(f.size>16*1024*1024)throw new Error("Review bundle exceeds 16 MiB");const b=await _m(e(j),JSON.parse(await f.text()),{reanchor:e(Ga)});await _n(b.store);const q=b.reanchored.reduce((C,L)=>(C[L.disposition]+=1,C),{matched:0,stale:0,orphaned:0});A(it,`${q.matched} matched · ${q.stale} stale · ${q.orphaned} orphaned · ${b.conflicts.length} conflicts`)}catch(b){A(it,b instanceof Error?b.message:String(b))}finally{md(G,e(G).value=""),A(Q,!1)}}}function Os(f,b){return f==="action-required"?b.action:f==="needs-confirmation"?b.confirm:b.clear}function fp(f){return e(kr).filter(b=>_a(b)===f).length}function Ti(f,b){history.pushState(null,"",`#${f}=${encodeURIComponent(b)}`)}async function hr(f){await gs(),document.getElementById(f)?.focus({preventScroll:!1})}function Ts(f,b=!0){b&&(X=ot("queue",f.id)),A(E,f.id),A(K,""),A($e,""),A(Fe,""),A(ge,0),A(He,0),A(H,!1),Ti("change",f.id),hr(ot("change",f.id))}function nl(){A(E,""),A(K,""),history.pushState(null,"","#summary"),hr("summary-heading")}function Mi(f){A(K,f),Ti("hunk",f),hr(ot("hunk",f))}function sl(){A(K,""),hr("visual-evidence-heading")}function ua(f){if(f==="blink"&&e(le)){A(ee,"side-by-side"),A(H,!1);return}A(ee,f),A(H,f==="blink"&&!e(le))}function mp(f){A($e,f),A(Fe,""),A(ge,0)}function vp(f){A(Fe,f),A(ge,0)}async function gp(f){A(ge,f),await gs(),document.getElementById(`visual-region-${f}`)?.scrollIntoView({block:"center",inline:"center",behavior:"smooth"})}function il(f,b){if(Jr||!f||!b)return;Jr=!0;const q=f.scrollHeight-f.clientHeight,C=f.scrollWidth-f.clientWidth,L=b.scrollHeight-b.clientHeight,Ae=b.scrollWidth-b.clientWidth;b.scrollTop=q>0?f.scrollTop/q*L:0,b.scrollLeft=C>0?f.scrollLeft/C*Ae:0,requestAnimationFrame(()=>Jr=!1)}function zi(f,b){const q=f.coverage.knownUsages;if(b==="ja"){const L=q===null?`${f.coverage.verifiedUsages}件の画面利用箇所を検証済み、既知の利用件数は不明`:`既知の画面利用箇所${q}件中${f.coverage.verifiedUsages}件を検証済み`;return f.coverage.unknownPossible?`${L}。ほかの利用箇所が存在する可能性があります`:L}const C=q===null?`${f.coverage.verifiedUsages} visual usages verified; known usage count unavailable`:`${f.coverage.verifiedUsages} of ${q} known visual usages verified`;return f.coverage.unknownPossible?`${C}; additional usage may exist`:C}function ol(f){const b=f.target;if(!(b?.isContentEditable||new Set(["INPUT","TEXTAREA","SELECT"]).has(b?.tagName??"")||f.metaKey||f.ctrlKey||f.altKey)){if(f.key==="b"){f.preventDefault(),nl();return}if(f.key==="/"){f.preventDefault(),e(Ne)?.focus();return}if(f.key==="1")ua("side-by-side");else if(f.key==="2")ua("wipe");else if(f.key==="3")ua("pixel-diff");else if(f.key==="4")ua("blink");else if(f.key==="5")ua("after-only");else if((f.key==="j"||f.key==="k")&&e(ir).length){const q=e(ir).findIndex(Ae=>Ae.id===e(E)),C=f.key==="j"?1:-1,L=q===-1?f.key==="j"?0:e(ir).length-1:(q+C+e(ir).length)%e(ir).length;Ts(e(ir)[L])}else if((f.key==="n"||f.key==="p")&&e(Ar).length){const q=f.key==="n"?1:-1;A(He,(e(He)+q+e(Ar).length)%e(Ar).length),hr(ot("finding",e(Ar)[e(He)].id))}else f.key==="e"&&sl()}}function yp(f){X=ot("queue-hunk",f),A(E,""),Mi(f)}function ll(){A(K,""),history.pushState(null,"","#queue"),hr(X||"queue-heading")}function _p(){A(K,""),e(O)&&(Ti("change",e(O).id),hr(ot("change",e(O).id)))}function dl(){if(!e(c))return;const f=location.hash.match(/^#(change|hunk)=(.+)$/u);if(!f){A(E,""),A(K,"");return}let b="";try{b=decodeURIComponent(f[2]??"")}catch{A(E,""),A(K,"");return}if(f[1]==="change"&&e(c).changes.some(q=>q.id===b)){A(E,b),A(K,""),hr(ot("change",b));return}f[1]==="hunk"&&e(c).hunks.some(q=>q.id===b)&&(A(E,e(c).changes.find(q=>q.hunkRefs.includes(b))?.id??""),A(K,b),hr(ot("hunk",b)))}function ul(){new URLSearchParams(location.hash.slice(1)).has("token")?pl():dl()}async function pl(){try{Yu();const f=document.querySelector("[data-utsuri-report]"),b=document.querySelector("[data-utsuri-manifest]");let q=null,C;if(f?.textContent)C=JSON.parse(f.textContent),q=b?.textContent?JSON.parse(b.textContent):null;else{const[L,Ae]=await Promise.all([fetch("./report.json",{credentials:"omit"}),fetch("./manifest.json",{credentials:"omit"})]);if(!L.ok)throw new Error(`HTTP ${L.status}`);C=await L.json(),q=Ae.ok?await Ae.json():null}A(c,C),document.querySelector("[data-static-fallback]")?.remove(),A(N,/^ja(?:-|$)/iu.test(e(c).language)?"ja":"en"),document.documentElement.lang=e(c).language,Qu(),q&&(mn={base:q.source?.base??null,head:q.source?.head??null});try{e(te)?(A(j,await Uu(e(c),new Date().toISOString())),await Oi(),Xu(),tp()):De||A(j,await um(e(c)))}catch(L){A(j,null),A(Yr,L instanceof Error?L.message:String(L))}dl()}catch(f){A(P,`${e(n).dataUnavailable}: ${f instanceof Error?f.message:String(f)}`)}}function cl(f){if(oa.has(f.id))return f.lines.map((C,L)=>({kind:"line",line:C,index:L}));const b=f.lines.map(()=>!1);f.lines.forEach((C,L)=>{if(C.kind==="addition"||C.kind==="deletion")for(let Ae=Math.max(0,L-3);Ae<=Math.min(f.lines.length-1,L+3);Ae+=1)b[Ae]=!0}),b.some(Boolean)||b.fill(!0);const q=[];for(let C=0;C<f.lines.length;)if(b[C])q.push({kind:"line",line:f.lines[C],index:C}),C+=1;else{let L=C+1;for(;L<f.lines.length&&!b[L];)L+=1;q.push({kind:"fold",count:L-C}),C=L}return q}function hl(f){oa=new Set([...oa,f])}function wp(f,b){const q=f.lines[b];if(!q||q.kind!=="addition"&&q.kind!=="deletion")return;const C=q.kind==="addition"?"deletion":"addition";for(let L=1;L<=6;L+=1)for(const Ae of[b-L,b+L]){const Ut=f.lines[Ae];if(Ut?.kind===C)return Ut;if(Ut&&Ut.kind==="context")break}}function Vi(f,b){const q=f.lines[b],C=wp(f,b);if(!C)return[{text:q.content,changed:q.kind==="addition"||q.kind==="deletion"}];let L=0;for(;L<q.content.length&&q.content[L]===C.content[L];)L+=1;let Ae=0;for(;Ae<q.content.length-L&&Ae<C.content.length-L&&q.content[q.content.length-Ae-1]===C.content[C.content.length-Ae-1];)Ae+=1;return[{text:q.content.slice(0,L),changed:!1},{text:q.content.slice(L,Ae?-Ae:void 0),changed:!0},{text:Ae?q.content.slice(-Ae):"",changed:!1}].filter(Ut=>Ut.text.length>0)}Iu(()=>(A(N,navigator.language.toLowerCase().startsWith("ja")?"ja":"en"),pl(),A(le,window.matchMedia("(prefers-reduced-motion: reduce)").matches),window.addEventListener("hashchange",ul),window.addEventListener("keydown",ol),()=>{window.removeEventListener("hashchange",ul),window.removeEventListener("keydown",ol)})),Ft(()=>e(N),()=>{A(n,h[e(N)])}),Ft(()=>(e(te),e(j),e(ya)),()=>{A(l,!!(e(te)&&e(j)&&e(j).state.revision<e(ya)))}),Ft(()=>(e(c),e(E)),()=>{A(O,e(c)?.changes.find(f=>f.id===e(E)))}),Ft(()=>(e(O),e(c)),()=>{A(Gr,e(O)?e(O).hunkRefs.map(f=>e(c)?.hunks.find(b=>b.id===f)).filter(f=>f!==void 0):[])}),Ft(()=>(e(O),e(c)),()=>{A(Ht,e(O)&&e(c)?e(c).evidence.filter(f=>e(O)?.intent.evidenceRefs.includes(f.id)||f.hunkRefs.some(b=>e(O)?.hunkRefs.includes(b))):[])}),Ft(()=>e(c),()=>{A(ir,e(c)?[...e(c).changes].sort((f,b)=>Go(f)-Go(b)):[])}),Ft(()=>(e(ir),e(Z),e(Ca),e(j)),()=>{A(kr,e(ir).filter(f=>`${f.title} ${f.summary}`.toLocaleLowerCase().includes(e(Z).toLocaleLowerCase())&&(!e(Ca)||Zn(e(j),f.id)!=="reviewed")))}),Ft(()=>e(kr),()=>{A(xr,e(kr).slice(0,5))}),Ft(()=>e(xr),()=>{A(Ir,e(xr)[0])}),Ft(()=>(e(O),e(c)),()=>{A(or,e(O)&&e(c)?e(c).comparisons.filter(f=>e(O)?.targetRefs.includes(f.targetRef)):[])}),Ft(()=>(e(or),e($e)),()=>{A(Je,e(or).find(f=>f.id===e($e))??e(or)[0])}),Ft(()=>(e(Je),e(Fe)),()=>{A(T,e(Je)?.images.find(f=>f.id===e(Fe))??e(Je)?.images[0])}),Ft(()=>(e(O),e(c)),()=>{A(Ar,e(O)&&e(c)?e(c).findings.filter(f=>e(O)?.findingRefs.includes(f.id)||(f.targetRef?e(O)?.targetRefs.includes(f.targetRef):!1)):[])}),Ft(()=>(e(O),e(j)),()=>{A(fe,e(O)&&e(j)?e(j).threads.filter(f=>Xo(f.anchor,e(O))):[])}),Ft(()=>(e(fe),e(Je),e(T)),()=>{A(p,e(fe).filter(f=>f.state!=="resolved"&&f.anchor.type==="visual-region"&&!!f.anchor.region&&!!(e(Je)&&e(T))&&f.anchor.ref.startsWith(`${e(Je).id}:${e(T).id}:`)))}),Ft(()=>e(j),()=>{A(t,e(j)?.threads.filter(f=>f.agentAttention.state==="requested").length??0)}),Ft(()=>(e(t),e(Ya)),()=>{A(s,e(t)+e(Ya).reduce((f,b)=>f+(b.state==="answered"?0:b.itemIds.length),0))}),Ft(()=>e(Ya),()=>{A(o,e(Ya).reduce((f,b)=>f+b.unreadAnswerItemIds.length,0))}),lf(),Hf();var fl=$n(),bp=yr(fl);{var Pp=f=>{var b=Lv(),q=k(b),C=k(q),L=v(C,2),Ae=v(k(L),2),Ut=_(Ae,!0),ba=v(Ae,2),Qr=_(ba,!0),Fi=v(L,2),Oa=_(Fi,!0),Ta=v(q,2);{var en=J=>{var V=Sm(),me=_(V,!0);S(()=>y(me,e(Yr))),$(J,V)};B(Ta,J=>{e(Yr)&&J(en)})}var pe=v(Ta,2),wn=k(pe),Ms=v(k(wn),2),Di=_(Ms,!0),Qn=v(wn,2),Xn=k(Qn),Bi=_(Xn,!0),es=v(Xn,2);cs(es,J=>A(Ne,J),()=>e(Ne));var zs=v(Qn,2),Vs=_(zs),Fs=v(zs,2),ts=k(Fs),Ds=v(ts),Hi=_(Ds,!0),Bs=v(Fs,2),rs=k(Bs);we(rs,0,()=>["action-required","needs-confirmation","no-issue"],J=>J,(J,V)=>{var me=Nm(),mt=k(me),St=k(mt),vt=_(St,!0),jt=v(St,2),Ot=_(jt,!0),Et=v(mt,2);we(Et,7,()=>(e(kr),u(()=>e(kr).filter(qe=>_a(qe)===V))),qe=>qe.id,(qe,ye,Be)=>{var lt=Em(),_e=k(lt),Tt=k(_e),gt=_(Tt,!0),Wt=v(Tt,2),Ge=k(Wt),pt=_(Ge,!0),Nt=v(Ge,2),xt=k(Nt),Ce=_(xt,!0),rr=v(xt,2);{var Zt=ct=>{var ar=di(),qr=_(ar);S(()=>y(qr,`${e(ye),u(()=>e(ye).verification.gaps.length)??""} gaps`)),$(ct,ar)};B(rr,ct=>{e(ye),u(()=>e(ye).verification.gaps.length>0)&&ct(Zt)})}var lr=v(Nt,2),Kt=_(lr,!0),bt=v(lr,2),Jt=_(bt);S((ct,ar,qr,za,Xr)=>{z(_e,"id",ct),z(_e,"href",ar),z(_e,"aria-current",(e(E),e(ye),u(()=>e(E)===e(ye).id?"page":void 0))),y(gt,qr),y(pt,(e(ye),u(()=>e(ye).title))),y(Ce,(e(ye),u(()=>e(ye).risk.level))),y(Kt,za),y(Jt,`${e(n),u(()=>e(n).humanJudgment)??""}: ${Xr??""}`)},[()=>(e(ye),u(()=>ot("queue",e(ye).id))),()=>(e(ye),u(()=>`#change=${encodeURIComponent(e(ye).id)}`)),()=>(et(e(Be)),u(()=>String(e(Be)+1).padStart(2,"0"))),()=>(e(ye),u(()=>Ei(e(ye)))),()=>(e(j),e(ye),e(n),u(()=>Yo(Zn(e(j),e(ye).id),e(n))))]),U("click",_e,ct=>{ct.preventDefault(),Ts(e(ye))}),$(qe,lt)}),S((qe,ye)=>{z(me,"data-queue",V),y(vt,qe),y(Ot,ye)},[()=>(e(n),u(()=>Os(V,e(n)))),()=>u(()=>fp(V))]),$(J,me)});var Ui=v(rs,2);{var Wi=J=>{var V=Lm(),me=k(V),mt=k(me),St=_(mt,!0),vt=v(mt),jt=_(vt,!0),Ot=v(me,2);we(Ot,7,()=>(e(c),u(()=>e(c).unclassifiedHunkRefs)),Et=>Et,(Et,qe,ye)=>{const Be=Ia(()=>(e(c),e(qe),u(()=>e(c).hunks.find(gt=>gt.id===e(qe)))));var lt=$n(),_e=yr(lt);{var Tt=gt=>{var Wt=Cm(),Ge=k(Wt),pt=k(Ge),Nt=_(pt),xt=v(pt,2),Ce=k(xt),rr=_(Ce,!0),Zt=v(Ce),lr=_(Zt);S((Kt,bt)=>{z(Ge,"id",Kt),z(Ge,"href",bt),y(Nt,`U${e(ye)+1}`),y(rr,(et(e(Be)),u(()=>e(Be).path))),y(lr,`@@ ${et(e(Be)),u(()=>e(Be).oldStart)??""} → ${et(e(Be)),u(()=>e(Be).newStart)??""}`)},[()=>(e(qe),u(()=>ot("queue-hunk",e(qe)))),()=>(e(qe),u(()=>`#hunk=${encodeURIComponent(e(qe))}`))]),U("click",Ge,Kt=>{Kt.preventDefault(),yp(e(qe))}),$(gt,Wt)};B(_e,gt=>{e(Be)&>(Tt)})}$(Et,lt)}),S(()=>{y(St,(e(n),u(()=>e(n).unclassified))),y(jt,(e(c),u(()=>e(c).unclassifiedHunkRefs.length)))}),$(J,V)};B(Ui,J=>{e(c),u(()=>e(c).unclassifiedHunkRefs.length>0)&&J(Wi)})}var as=v(pe,2),Hs=k(as),Us=k(Hs),Ws=k(Us),Zi=_(Ws),Zs=v(Ws,2),Ks=_(Zs,!0),Js=v(Zs,2);{var Ki=J=>{var V=jm(),me=_(V,!0);S(()=>y(me,(e(c),u(()=>e(c).summary.overview)))),$(J,V)};B(Js,J=>{e(c),u(()=>e(c).summary.overview)&&J(Ki)})}var zr=v(Js,2),tn=k(zr),Ma=_(tn,!0),ns=v(tn,2),Ji=_(ns,!0),Gs=v(Us,2),Ys=v(k(Gs),2),xp=_(Ys,!0),Ap=v(Ys,2);{var Ip=J=>{var V=Om(),me=yr(V),mt=_(me,!0),St=v(me,2),vt=_(St,!0),jt=v(St,2),Ot=_(jt,!0),Et=v(jt,2),qe=k(Et);S((ye,Be)=>{z(me,"data-queue",ye),y(mt,Be),y(vt,(e(Ir),u(()=>e(Ir).title))),y(Ot,(e(Ir),u(()=>e(Ir).summary))),y(qe,`${e(n),u(()=>e(n).startReview)??""} `)},[()=>(e(Ir),u(()=>_a(e(Ir)))),()=>(e(Ir),e(n),u(()=>Os(_a(e(Ir)),e(n))))]),U("click",Et,()=>Ts(e(Ir),!1)),$(J,V)},$p=J=>{var V=Aa(),me=_(V,!0);S(()=>y(me,(e(n),u(()=>e(n).empty)))),$(J,V)};B(Ap,J=>{e(Ir)?J(Ip):J($p,-1)})}var ml=v(Gs,2);i(ml,()=>(e(c),u(()=>e(c).verificationResults??[])));var vl=v(ml,2),gl=k(vl),yl=k(gl),qp=_(yl,!0),Rp=v(yl,2),Sp=_(Rp,!0),_l=v(gl,2),wl=k(_l),Ep=_(wl,!0),Np=v(wl,2),Cp=_(Np),bl=v(_l,2),Pl=k(bl),Lp=_(Pl,!0),jp=v(Pl,2),Op=_(jp),kl=v(bl,2),xl=k(kl),Tp=_(xl,!0),Mp=v(xl,2),zp=_(Mp,!0),Vp=v(kl,2),Al=k(Vp),Fp=_(Al,!0),Dp=v(Al,2),Bp=_(Dp,!0),Il=v(vl,2);{var Hp=J=>{var V=zm(),me=k(V),mt=k(me),St=v(k(mt),2),vt=_(St,!0),jt=v(mt,2),Ot=_(jt),Et=v(me,2),qe=k(Et);we(qe,3,()=>e(xr),lt=>lt.id,(lt,_e,Tt)=>{var gt=Tm(),Wt=k(gt),Ge=k(Wt),pt=_(Ge,!0),Nt=v(Ge,2),xt=k(Nt),Ce=_(xt,!0),rr=v(xt,2),Zt=_(rr,!0),lr=v(Nt,2),Kt=k(lr),bt=v(Kt,2);S((Jt,ct,ar,qr)=>{z(gt,"data-queue",Jt),y(pt,ct),y(Ce,(e(_e),u(()=>e(_e).title))),y(Zt,(e(_e),u(()=>e(_e).summary))),y(Kt,`${ar??""} `),y(bt,` ${qr??""}`)},[()=>(e(_e),u(()=>_a(e(_e)))),()=>(et(e(Tt)),u(()=>String(e(Tt)+1).padStart(2,"0"))),()=>(e(_e),e(n),u(()=>Os(_a(e(_e)),e(n)))),()=>(e(_e),e(c),u(()=>Ku(Zu(e(_e)),e(c).language)))]),U("click",Wt,()=>Ts(e(_e),!1)),$(lt,gt)});var ye=v(qe,2);{var Be=lt=>{var _e=Mm(),Tt=_(_e,!0);S(gt=>y(Tt,gt),[()=>(e(c),e(xr),u(()=>Ju(e(c).changes.length-e(xr).length,e(c).language)))]),$(lt,_e)};B(ye,lt=>{e(c),e(xr),u(()=>e(c).changes.length>e(xr).length)&<(Be)})}S(lt=>{y(vt,(e(n),u(()=>e(n).reviewMap))),y(Ot,`${e(c),u(()=>e(c).changes.length)??""} ${lt??""}`)},[()=>(e(n),u(()=>e(n).changes.toLocaleLowerCase()))]),$(J,V)};B(Il,J=>{e(xr),u(()=>e(xr).length>0)&&J(Hp)})}var $l=v(Il,2),ql=k($l),Rl=v(k(ql),2),Up=_(Rl,!0),Wp=v(Rl,2),Zp=_(Wp,!0),Kp=v(ql,2),Sl=k(Kp),El=k(Sl),Jp=_(El,!0),Gp=v(El,2),Yp=_(Gp,!0),Nl=v(Sl,2),Cl=k(Nl),Qp=_(Cl,!0),Xp=v(Cl,2),ec=_(Xp,!0),tc=v(Nl,2),Ll=k(tc),rc=_(Ll,!0),ac=v(Ll,2),nc=_(ac,!0),sc=v($l,2),jl=k(sc),ic=_(jl,!0),oc=v(jl,2);we(oc,5,()=>(e(c),u(()=>e(c).files)),J=>J.id,(J,V)=>{var me=Fm(),mt=k(me),St=_(mt,!0),vt=v(mt,2),jt=_(vt,!0),Ot=v(vt,2),Et=_(Ot,!0),qe=v(Ot,2);{var ye=Be=>{var lt=Vm(),_e=k(lt),Tt=v(_e,2),gt=_(Tt,!0);S(Wt=>{qn(_e,Wt),_e.disabled=e(Q),y(gt,(e(n),u(()=>e(n).viewed)))},[()=>(e(j),e(V),u(()=>Kn(e(j),"file",e(V).id)))]),U("change",_e,Wt=>{Gn("file",e(V).id,Wt.currentTarget.checked)}),$(Be,lt)};B(qe,Be=>{e(j)&&Be(ye)})}S(()=>{y(St,(e(V),u(()=>e(V).status))),y(jt,(e(V),u(()=>e(V).oldPath&&e(V).newPath&&e(V).oldPath!==e(V).newPath?`${e(V).oldPath} → ${e(V).newPath}`:e(V).newPath??e(V).oldPath))),y(Et,(e(V),u(()=>e(V).binary?"binary":`+${e(V).additions??0} / −${e(V).deletions??0}`)))}),$(J,me)});var lc=v(Hs,2);{var dc=J=>{var V=kv(),me=k(V),mt=_(me),St=v(me,2),vt=k(St),jt=k(vt),Ot=_(jt),Et=v(jt,2),qe=_(Et,!0),ye=v(vt,2),Be=k(ye),lt=_(Be),_e=v(Be,2),Tt=_(_e),gt=v(_e,2),Wt=_(gt,!0),Ge=v(St,2),pt=_(Ge),Nt=v(Ge,2),xt=k(Nt),Ce=k(xt),rr=v(k(Ce),2),Zt=_(rr,!0),lr=v(rr,2);{var Kt=D=>{var I=Aa(),Y=_(I);S((M,Te,Me)=>y(Y,`${e(n),u(()=>e(n).reviewProgress)??""}: ${M??""}\n ${Te??""} ·\n ${e(j),u(()=>e(j).threads.length)??""}\n ${Me??""}`),[()=>(e(j),u(()=>Object.values(e(j).state.viewed).filter(M=>M.state==="viewed").length)),()=>(e(n),u(()=>e(n).viewed.toLocaleLowerCase())),()=>(e(n),u(()=>e(n).comments.toLocaleLowerCase()))]),$(D,I)},bt=D=>{var I=Aa(),Y=_(I,!0);S(()=>y(Y,(e(n),u(()=>e(n).reviewUnavailable)))),$(D,I)};B(lr,D=>{e(j)?D(Kt):D(bt,-1)})}var Jt=v(Ce,2),ct=k(Jt),ar=k(ct),qr=v(ar,2),za=_(qr,!0),Xr=v(ct,2),ss=_(Xr,!0),Va=v(Xr,2),is=_(Va,!0),bn=v(Va,2);cs(bn,D=>A(G,D),()=>e(G));var Qs=v(xt,2);{var Gi=D=>{var I=Dm(),Y=yr(I),M=k(Y),Te=k(M),Me=_(Te,!0),Re=v(Te,2),rt=k(Re);we(rt,0,()=>["unreviewed","reviewed","follow-up","blocked"],nt=>nt,(nt,ce)=>{var re=ui(),ze=_(re,!0),ht={};S(de=>{y(ze,de),ht!==(ht=ce)&&(re.value=(re.__value=ht)??"")},[()=>(e(n),u(()=>Yo(ce,e(n))))]),$(nt,re)});var at=v(rt);{var dt=nt=>{var ce=ui(),re=_(ce,!0);ce.value=ce.__value="stale",S(()=>y(re,(e(n),u(()=>e(n).stale)))),$(nt,ce)},Mt=Zh(()=>(e(j),e(O),u(()=>Zn(e(j),e(O).id)==="stale")));B(at,nt=>{e(Mt)&&nt(dt)})}var Gt;ii(Re);var fr=v(M,2),zt=k(fr),sr=v(zt,2),Rr=_(sr,!0),At=v(fr,2),Sr=_(At,!0),Ct=v(Y,2),mr=_(Ct,!0);S((nt,ce,re)=>{y(Me,(e(n),u(()=>e(n).humanJudgment))),Re.disabled=nt,Gt!==(Gt=ce)&&(Re.value=(Re.__value=Gt)??"",ks(Re,Gt)),qn(zt,re),zt.disabled=e(Q),y(Rr,(e(n),u(()=>e(n).viewed))),At.disabled=e(Q),y(Sr,(e(n),u(()=>e(n).comment))),y(mr,(e(n),u(()=>e(n).localOnly)))},[()=>(e(Q),e(j),e(O),u(()=>e(Q)||Zn(e(j),e(O).id)==="stale")),()=>(e(j),e(O),u(()=>Zn(e(j),e(O).id))),()=>(e(j),e(O),u(()=>Kn(e(j),"change",e(O).id)))]),U("change",Re,nt=>{rp(e(O).id,nt.currentTarget.value)}),U("change",zt,nt=>{Gn("change",e(O).id,nt.currentTarget.checked)}),U("click",At,()=>{wa(La("change",e(O).id))}),$(D,I)};B(Qs,D=>{e(j)&&D(Gi)})}var Yi=v(Qs,2);{var Xs=D=>{var I=Bm(),Y=_(I,!0);S(()=>y(Y,e(it))),$(D,I)};B(Yi,D=>{e(it)&&D(Xs)})}var ei=v(Nt,2),ti=k(ei),dr=k(ti),nr=v(k(dr),2),pa=_(nr,!0),ea=v(ti,2),Pn=k(ea),rn=k(Pn),os=_(rn,!0),an=v(rn,2),ls=_(an,!0),Vr=v(an,2),ta=_(Vr,!0),Fa=v(Pn,2),Ol=k(Fa),fc=_(Ol,!0),mc=v(Ol,2),vc=_(mc,!0),Tl=v(Fa,2),Ml=k(Tl),gc=_(Ml,!0),yc=v(Ml,2);{var _c=D=>{var I=Hm();we(I,5,()=>(e(O),u(()=>e(O).userImpact)),xa,(Y,M)=>{var Te=wo(),Me=_(Te,!0);S(()=>y(Me,e(M))),$(Y,Te)}),$(D,I)},wc=D=>{var I=Aa(),Y=_(I,!0);S(()=>y(Y,(e(n),u(()=>e(n).noImpact)))),$(D,I)};B(yc,D=>{e(O),u(()=>e(O).userImpact.length>0)?D(_c):D(wc,-1)})}var zl=v(Tl,2),Vl=k(zl),bc=_(Vl,!0),Pc=v(Vl,2);we(Pc,5,()=>(e(O),u(()=>e(O).risk.reasons)),xa,(D,I)=>{var Y=wo(),M=_(Y,!0);S(()=>y(M,e(I))),$(D,Y)});var Fl=v(zl,2),Dl=k(Fl),kc=_(Dl,!0),xc=v(Dl,2);we(xc,5,()=>(e(O),u(()=>e(O).verification.gaps)),xa,(D,I,Y)=>{var M=Wm(),Te=k(M),Me=_(Te,!0),Re=v(Te,2);{var rt=at=>{var dt=Um(),Mt=_(dt,!0);S(()=>{dt.disabled=e(Q),y(Mt,(e(n),u(()=>e(n).comment)))}),U("click",dt,()=>{wa(La("verification-gap",`${e(O).id}:gap:${Y}`))}),$(at,dt)};B(Re,at=>{e(j)&&at(rt)})}S(()=>y(Me,e(I))),$(D,M)});var Ac=v(Fl,2),Bl=k(Ac),Ic=_(Bl,!0),$c=v(Bl,2);we($c,5,()=>(e(O),u(()=>e(O).verification.verified)),xa,(D,I)=>{var Y=wo(),M=_(Y,!0);S(()=>y(M,e(I))),$(D,Y)});var Hl=v(ei,2),Ul=k(Hl),qc=k(Ul),Wl=k(qc),Rc=_(Wl),Zl=v(Wl,2),Sc=_(Zl,!0),Kl=v(Zl,2),Ec=_(Kl,!0),Nc=v(Kl,2),Cc=_(Nc,!0),Jl=v(Ul,2);{var Lc=D=>{var I=nv(),Y=yr(I),M=k(Y);{var Te=se=>{var We=Zm(),ue=v(k(We),2);we(ue,5,()=>e(or),Pe=>Pe.id,(Pe,ie)=>{const Se=Ia(()=>(e(c),e(ie),u(()=>e(c).targets.find(Nr=>Nr.id===e(ie).targetRef))));var yt=ui(),ur=_(yt),Er={};S(()=>{y(ur,`${et(e(Se)),e(ie),u(()=>e(Se)?.routeOrStory??e(ie).targetRef)??""} · ${et(e(Se)),u(()=>e(Se)?.viewport)??""} · ${et(e(Se)),u(()=>e(Se)?.state)??""}`),Er!==(Er=(e(ie),u(()=>e(ie).id)))&&(yt.value=(yt.__value=Er)??"")}),$(Pe,yt)});var Qe;ii(ue),S(()=>{Qe!==(Qe=(e(Je),u(()=>e(Je)?.id)))&&(ue.value=(ue.__value=Qe)??"",ks(ue,Qe))}),U("change",ue,Pe=>mp(Pe.currentTarget.value)),$(se,We)};B(M,se=>{e(or),u(()=>e(or).length>1)&&se(Te)})}var Me=v(M,2);{var Re=se=>{var We=Km(),ue=k(We),Qe=_(ue,!0),Pe=v(ue,2);we(Pe,5,()=>(e(Je),u(()=>e(Je).images)),Se=>Se.id,(Se,yt)=>{var ur=ui(),Er=_(ur,!0),Nr={};S(()=>{y(Er,(e(yt),u(()=>e(yt).label))),Nr!==(Nr=(e(yt),u(()=>e(yt).id)))&&(ur.value=(ur.__value=Nr)??"")}),$(Se,ur)});var ie;ii(Pe),S(()=>{y(Qe,(e(n),u(()=>e(n).imageScope))),ie!==(ie=(e(T),u(()=>e(T)?.id)))&&(Pe.value=(Pe.__value=ie)??"",ks(Pe,ie))}),U("change",Pe,Se=>vp(Se.currentTarget.value)),$(se,We)};B(Me,se=>{e(Je),u(()=>e(Je)&&e(Je).images.length>1)&&se(Re)})}var rt=v(Me,2);{var at=se=>{var We=Jm(),ue=k(We),Qe=v(ue,2),Pe=_(Qe,!0);S(ie=>{qn(ue,ie),ue.disabled=e(Q),y(Pe,(e(n),u(()=>e(n).viewed)))},[()=>(e(j),e(Je),u(()=>Kn(e(j),"visual-target",e(Je).targetRef)))]),U("change",ue,ie=>{Gn("visual-target",e(Je).targetRef,ie.currentTarget.checked)}),$(se,We)};B(rt,se=>{e(Je)&&e(j)&&se(at)})}var dt=v(rt,2),Mt=k(dt),Gt=_(Mt),fr=v(Mt,2),zt=v(Y,2),sr=k(zt),Rr=_(sr,!0),At=v(sr,2),Sr=_(At,!0),Ct=v(At,2),mr=_(Ct,!0),nt=v(Ct,2),ce=_(nt,!0),re=v(nt,2),ze=_(re,!0),ht=v(zt,2);{var de=se=>{var We=Gm(),ue=v(k(We),2),Qe=_(ue,!0);S(Pe=>y(Qe,Pe),[()=>(e(Je),u(()=>e(Je).incompleteReasons.join(", ")))]),$(se,We)};B(ht,se=>{e(Je),u(()=>e(Je)?.status==="incomplete")&&se(de)})}var R=v(ht,2);{var Ye=se=>{var We=av(),ue=yr(We),Qe=k(ue),Pe=v(k(Qe),2),ie=_(Pe,!0),Se=v(Qe,2),yt=v(k(Se),2),ur=_(yt),Er=v(Se,2),Nr=k(Er),ds=_(Nr,!0),kn=v(Nr,2),xn=_(kn,!0),us=v(Er,2),An=v(k(us),2),nn=_(An),sn=v(ue,2);{var ut=ke=>{var Ee=Ym(),ve=k(Ee),Ie=k(ve),Yt=_(Ie),Qt=v(Ie,2),Vt=k(Qt),It=_(Vt);cs(Qt,pr=>A(xe,pr),()=>e(xe));var vr=v(ve,2),_t=k(vr),st=_(_t),Oe=v(_t,2),Ve=k(Oe),$t=k(Ve),gr=v($t,2);we(gr,3,()=>(e(T),u(()=>e(T).regions)),pr=>pr.id,(pr,Xt,ka)=>{var jr=Rd();let ni;var to=_(jr,!0);S(()=>{z(jr,"id",`visual-region-${e(ka)}`),ni=Dt(jr,1,"region-marker",null,ni,{"active-region":e(ge)===e(ka)}),_r(jr,(e(Xt),e(T),u(()=>`left:${e(Xt).x/e(T).width*100}%;top:${e(Xt).y/e(T).height*100}%;width:${e(Xt).width/e(T).width*100}%;height:${e(Xt).height/e(T).height*100}%`))),y(to,e(ka)+1)}),$(pr,jr)});var Pa=v(gr,2);we(Pa,3,()=>e(p),pr=>pr.id,(pr,Xt,ka)=>{var jr=fs(),ni=_(jr,!0);S(to=>{_r(jr,to),z(jr,"aria-label",(e(n),et(e(ka)),e(Xt),u(()=>`${e(n).comment} pin ${e(ka)+1}: ${e(Xt).state}`))),y(ni,e(ka)+1)},[()=>(e(Xt),u(()=>Wn(e(Xt).anchor)))]),U("click",jr,()=>{hr(ot("thread",e(Xt).id))}),$(pr,jr)}),cs(Oe,pr=>A(er,pr),()=>e(er)),S(()=>{y(Yt,`Before · ${e(T),u(()=>e(T).label)??""}`),_r(Vt,`width: ${e(Pt)}%`),z(It,"src",(e(T),u(()=>`./${e(T).beforeRef}`))),z(It,"alt",(e(T),u(()=>`Before capture for ${e(T).label}`))),y(st,`After · ${e(T),u(()=>e(T).label)??""}`),_r(Ve,`width: ${e(Pt)}%`),z($t,"src",(e(T),u(()=>`./${e(T).afterRef}`))),z($t,"alt",(e(T),u(()=>`After capture for ${e(T).label}`)))}),no("scroll",Qt,()=>il(e(xe),e(er))),no("scroll",Oe,()=>il(e(er),e(xe))),$(ke,Ee)},Le=ke=>{var Ee=Qm(),ve=yr(Ee),Ie=k(ve),Yt=_(Ie),Qt=v(Ie,2),Vt=v(ve,2),It=k(Vt),vr=_(It),_t=v(It,2),st=k(_t),Oe=k(st),Ve=v(Oe,2),$t=v(Ve,2);we($t,3,()=>e(p),gr=>gr.id,(gr,Pa,pr)=>{var Xt=fs(),ka=_(Xt,!0);S(jr=>{_r(Xt,jr),z(Xt,"aria-label",(e(n),et(e(pr)),e(Pa),u(()=>`${e(n).comment} pin ${e(pr)+1}: ${e(Pa).state}`))),y(ka,e(pr)+1)},[()=>(e(Pa),u(()=>Wn(e(Pa).anchor)))]),U("click",Xt,()=>{hr(ot("thread",e(Pa).id))}),$(gr,Xt)}),S(()=>{y(Yt,`${e(n),u(()=>e(n).wipePosition)??""}: ${e(Ue)??""}%`),y(vr,`Before / after wipe · ${e(T),u(()=>e(T).label)??""}`),_r(st,`width: ${e(Pt)}%`),z(Oe,"src",(e(T),u(()=>`./${e(T).beforeRef}`))),z(Oe,"alt",(e(T),u(()=>`Before capture for ${e(T).label}`))),_r(Ve,`clip-path: inset(0 ${100-e(Ue)}% 0 0)`),z(Ve,"src",(e(T),u(()=>`./${e(T).afterRef}`))),z(Ve,"alt",`After capture revealed to ${e(Ue)}%`)}),oi(Qt,()=>e(Ue),gr=>A(Ue,gr)),$(ke,Ee)},Cr=ke=>{var Ee=Xm(),ve=k(Ee),Ie=_(ve),Yt=v(ve,2),Qt=k(Yt),Vt=k(Qt),It=v(Vt,2);let vr;var _t=v(It,2);we(_t,3,()=>e(p),st=>st.id,(st,Oe,Ve)=>{var $t=fs(),gr=_($t,!0);S(Pa=>{_r($t,Pa),z($t,"aria-label",(e(n),et(e(Ve)),e(Oe),u(()=>`${e(n).comment} pin ${e(Ve)+1}: ${e(Oe).state}`))),y(gr,e(Ve)+1)},[()=>(e(Oe),u(()=>Wn(e(Oe).anchor)))]),U("click",$t,()=>{hr(ot("thread",e(Oe).id))}),$(st,$t)}),S(()=>{y(Ie,`${e(H)?"Blink running; use Stop blink to pause":"Blink paused"} ·\n ${e(T),u(()=>e(T).label)??""}`),_r(Qt,`width: ${e(Pt)}%`),z(Vt,"src",(e(T),u(()=>`./${e(T).beforeRef}`))),z(Vt,"alt",(e(T),u(()=>`Before capture for ${e(T).label}`))),vr=Dt(It,1,"blink-after",null,vr,{"blink-running":e(H)}),z(It,"src",(e(T),u(()=>`./${e(T).afterRef}`))),z(It,"alt",(e(T),u(()=>`After capture for ${e(T).label}`)))}),$(ke,Ee)},ra=ke=>{var Ee=ev(),ve=k(Ee),Ie=_(ve),Yt=v(ve,2),Qt=k(Yt),Vt=k(Qt),It=v(Vt,2);we(It,3,()=>e(p),vr=>vr.id,(vr,_t,st)=>{var Oe=fs(),Ve=_(Oe,!0);S($t=>{_r(Oe,$t),z(Oe,"aria-label",(e(n),et(e(st)),e(_t),u(()=>`${e(n).comment} pin ${e(st)+1}: ${e(_t).state}`))),y(Ve,e(st)+1)},[()=>(e(_t),u(()=>Wn(e(_t).anchor)))]),U("click",Oe,()=>{hr(ot("thread",e(_t).id))}),$(vr,Oe)}),S(()=>{y(Ie,`${e(n),u(()=>e(n).pixelDiff)??""} · ${e(T),u(()=>e(T).label)??""}`),_r(Qt,`width: ${e(Pt)}%`),z(Vt,"src",(e(T),u(()=>`./${e(T).diffRef}`))),z(Vt,"alt",(e(T),u(()=>`Pixel difference bitmap with ${e(T).diffPixelCount} changed pixels`)))}),$(ke,Ee)},Lr=ke=>{var Ee=tv(),ve=k(Ee),Ie=_(ve),Yt=v(ve,2),Qt=k(Yt),Vt=k(Qt),It=v(Vt,2);we(It,3,()=>(e(T),u(()=>e(T).regions)),_t=>_t.id,(_t,st,Oe)=>{var Ve=Rd();let $t;var gr=_(Ve,!0);S(()=>{z(Ve,"id",`visual-region-${e(Oe)}`),$t=Dt(Ve,1,"region-marker",null,$t,{"active-region":e(ge)===e(Oe)}),_r(Ve,(e(st),e(T),u(()=>`left:${e(st).x/e(T).width*100}%;top:${e(st).y/e(T).height*100}%;width:${e(st).width/e(T).width*100}%;height:${e(st).height/e(T).height*100}%`))),y(gr,e(Oe)+1)}),$(_t,Ve)});var vr=v(It,2);we(vr,3,()=>e(p),_t=>_t.id,(_t,st,Oe)=>{var Ve=fs(),$t=_(Ve,!0);S(gr=>{_r(Ve,gr),z(Ve,"aria-label",(e(n),et(e(Oe)),e(st),u(()=>`${e(n).comment} pin ${e(Oe)+1}: ${e(st).state}`))),y($t,e(Oe)+1)},[()=>(e(st),u(()=>Wn(e(st).anchor)))]),U("click",Ve,()=>{hr(ot("thread",e(st).id))}),$(_t,Ve)}),S(()=>{y(Ie,`${e(n),u(()=>e(n).afterOnly)??""} · ${e(T),u(()=>e(T).label)??""}`),_r(Qt,`width: ${e(Pt)}%`),z(Vt,"src",(e(T),u(()=>`./${e(T).afterRef}`))),z(Vt,"alt",(e(T),u(()=>`After capture for ${e(T).label}`)))}),$(ke,Ee)};B(sn,ke=>{e(ee)==="side-by-side"?ke(ut):e(ee)==="wipe"?ke(Le,1):e(ee)==="blink"?ke(Cr,2):e(ee)==="pixel-diff"?ke(ra,3):ke(Lr,-1)})}var on=v(sn,2),ai=k(on),Xi=_(ai,!0),eo=v(ai,2);{var Xe=ke=>{var Ee=_o();we(Ee,7,()=>(e(T),u(()=>e(T).regions)),ve=>ve.id,(ve,Ie,Yt)=>{var Qt=rv(),Vt=k(Qt),It=k(Vt),vr=_(It),_t=v(It,2);{var st=Oe=>{var Ve=Or(),$t=_(Ve,!0);S(()=>{Ve.disabled=e(Q),y($t,(e(n),u(()=>e(n).comment)))}),U("click",Ve,()=>{wa(La("visual-region",`${e(Je).id}:${e(T).id}:${e(Ie).id}`))}),$(Oe,Ve)};B(_t,Oe=>{e(j)&&Oe(st)})}S(()=>{z(It,"aria-current",e(ge)===e(Yt)?"true":void 0),y(vr,`Region ${e(Yt)+1} · ${e(Ie),u(()=>e(Ie).pixels)??""} px · (${e(Ie),u(()=>e(Ie).x)??""}, ${e(Ie),u(()=>e(Ie).y)??""}) ${e(Ie),u(()=>e(Ie).width)??""}\n × ${e(Ie),u(()=>e(Ie).height)??""}`)}),U("click",It,()=>{gp(e(Yt))}),$(ve,Qt)}),$(ke,Ee)},je=ke=>{var Ee=Aa(),ve=_(Ee,!0);S(()=>y(ve,(e(n),u(()=>e(n).noRegions)))),$(ke,Ee)};B(eo,ke=>{e(T),u(()=>e(T).regions.length>0)?ke(Xe):ke(je,-1)})}S(ke=>{y(ie,(e(T),u(()=>e(T).diffPixelCount))),y(ur,`${ke??""}%`),y(ds,(e(n),u(()=>e(n).changedRegions))),y(xn,(e(T),u(()=>e(T).regions.length))),y(nn,`${e(T),u(()=>e(T).width)??""} × ${e(T),u(()=>e(T).height)??""}`),y(Xi,(e(n),u(()=>e(n).changedRegions)))},[()=>(e(T),u(()=>(e(T).diffRatio*100).toFixed(3)))]),$(se,We)};B(R,se=>{e(T)&&se(Ye)})}S(()=>{y(Gt,`${e(n),u(()=>e(n).zoom)??""}: ${e(Pt)??""}%`),z(zt,"aria-label",(e(n),u(()=>e(n).visualEvidence))),z(sr,"aria-pressed",e(ee)==="side-by-side"),y(Rr,(e(n),u(()=>e(n).sideBySide))),z(At,"aria-pressed",e(ee)==="wipe"),y(Sr,(e(n),u(()=>e(n).wipe))),z(Ct,"aria-pressed",e(ee)==="blink"),Ct.disabled=e(le),z(Ct,"title",(e(le),e(n),u(()=>e(le)?e(n).reducedMotion:void 0))),y(mr,(e(ee),e(H),e(n),u(()=>e(ee)==="blink"&&e(H)?e(n).stopBlink:e(n).blink))),z(nt,"aria-pressed",e(ee)==="pixel-diff"),y(ce,(e(n),u(()=>e(n).pixelDiff))),z(re,"aria-pressed",e(ee)==="after-only"),y(ze,(e(n),u(()=>e(n).afterOnly)))}),oi(fr,()=>e(Pt),se=>A(Pt,se)),U("click",sr,()=>ua("side-by-side")),U("click",At,()=>ua("wipe")),U("click",Ct,()=>{e(ee)==="blink"?A(H,!e(H)):ua("blink")}),U("click",nt,()=>ua("pixel-diff")),U("click",re,()=>ua("after-only")),$(D,I)},jc=D=>{var I=sv(),Y=v(k(I),2),M=_(Y,!0);S(()=>y(M,(e(n),u(()=>e(n).visualGap)))),$(D,I)};B(Jl,D=>{e(or),u(()=>e(or).length>0)?D(Lc):D(jc,-1)})}var Oc=v(Jl,2),Gl=k(Oc),Tc=k(Gl),Yl=k(Tc),Mc=_(Yl),zc=v(Yl,2),Vc=_(zc,!0),Fc=v(Gl,2);{var Dc=D=>{var I=_o();we(I,7,()=>e(Ar),Y=>Y.id,(Y,M,Te)=>{var Me=iv(),Re=k(Me);let rt;var at=k(Re),dt=k(at),Mt=_(dt,!0),Gt=v(dt),fr=_(Gt,!0),zt=v(Gt),sr=_(zt,!0),Rr=v(at,2),At=_(Rr,!0),Sr=v(Rr,2),Ct=_(Sr,!0),mr=v(Sr,2);{var nt=ze=>{var ht=Or(),de=_(ht,!0);S(()=>y(de,(e(n),u(()=>e(n).viewCode)))),U("click",ht,()=>Mi(e(M).hunkRefs[0])),$(ze,ht)};B(mr,ze=>{e(M),u(()=>e(M).hunkRefs[0])&&ze(nt)})}var ce=v(mr,2);{var re=ze=>{var ht=Or(),de=_(ht,!0);S(()=>{ht.disabled=e(Q),y(de,(e(n),u(()=>e(n).comment)))}),U("click",ht,()=>{wa(La("finding",e(M).id))}),$(ze,ht)};B(ce,ze=>{e(j)&&ze(re)})}S(ze=>{z(Re,"id",ze),rt=Dt(Re,1,"",null,rt,{"active-finding":e(He)===e(Te)}),y(Mt,(e(M),u(()=>e(M).state))),y(fr,(e(M),u(()=>e(M).severity))),y(sr,(e(M),u(()=>e(M).category))),y(At,(e(M),u(()=>e(M).title))),y(Ct,(e(M),u(()=>e(M).description)))},[()=>(e(M),u(()=>ot("finding",e(M).id)))]),$(Y,Me)}),$(D,I)},Bc=D=>{var I=Aa(),Y=_(I,!0);S(()=>y(Y,(e(n),u(()=>e(n).noFindings)))),$(D,I)};B(Fc,D=>{e(Ar),u(()=>e(Ar).length>0)?D(Dc):D(Bc,-1)})}var Ql=v(Hl,2),Xl=k(Ql),Hc=k(Xl),ed=k(Hc),Uc=_(ed),Wc=v(ed,2),Zc=_(Wc,!0),td=v(Xl,2);we(td,5,()=>(e(Ht),u(()=>e(Ht).slice(0,3))),D=>D.id,(D,I)=>{var Y=ov(),M=k(Y),Te=_(M,!0),Me=v(M),Re=_(Me,!0),rt=v(Me,2),at=_(rt,!0);S(()=>{y(Te,(e(I),u(()=>e(I).type))),y(Re,(e(I),u(()=>e(I).path))),y(at,(e(I),u(()=>e(I).summary)))}),$(D,Y)});var Kc=v(td,2);{var Jc=D=>{var I=dv(),Y=k(I),M=_(Y),Te=v(Y,2);we(Te,5,()=>(e(Ht),u(()=>e(Ht).slice(3))),Me=>Me.id,(Me,Re)=>{var rt=lv(),at=k(rt),dt=_(at,!0),Mt=v(at);S(()=>{y(dt,(e(Re),u(()=>e(Re).path))),y(Mt,` — ${e(Re),u(()=>e(Re).summary)??""}`)}),$(Me,rt)}),S(()=>y(M,`${e(n),u(()=>e(n).moreEvidence)??""} (${e(Ht),u(()=>e(Ht).length-3)??""})`)),$(D,I)};B(Kc,D=>{e(Ht),u(()=>e(Ht).length>3)&&D(Jc)})}var rd=v(Ql,2),Gc=_(rd,!0),ad=v(rd,2);{let D=Ia(()=>(e(c),e(O),u(()=>(e(c).verificationResults??[]).filter(I=>I.changeRefs.length===0||I.changeRefs.includes(e(O).id)))));i(ad,()=>e(D))}var nd=v(ad,2),sd=k(nd),id=k(sd),od=k(id),Yc=_(od),Qc=v(od,2),Xc=_(Qc,!0),eh=v(id,2),ri=k(eh),th=_(ri,!0),Qi=v(ri,2),rh=_(Qi,!0),ah=v(sd,2);we(ah,1,()=>e(Gr),D=>D.id,(D,I)=>{const Y=Ia(()=>(e(O),e(I),u(()=>e(O).hunkExplanations?.find(({hunkRef:de})=>de===e(I).id))));var M=mv();let Te;var Me=k(M),Re=k(Me),rt=k(Re),at=_(rt,!0),dt=v(rt,2),Mt=_(dt),Gt=v(Re,2),fr=k(Gt);{var zt=de=>{var R=uv(),Ye=yr(R),se=k(Ye),We=v(se,2),ue=_(We,!0),Qe=v(Ye,2),Pe=_(Qe,!0);S(ie=>{qn(se,ie),se.disabled=e(Q),y(ue,(e(n),u(()=>e(n).viewed))),Qe.disabled=e(Q),y(Pe,(e(n),u(()=>e(n).comment)))},[()=>(e(j),e(I),u(()=>Kn(e(j),"hunk",e(I).id)))]),U("change",se,ie=>{Gn("hunk",e(I).id,ie.currentTarget.checked)}),U("click",Qe,()=>{wa(La("hunk",e(I).id))}),$(de,R)};B(fr,de=>{e(j)&&de(zt)})}var sr=v(fr,2);{var Rr=de=>{var R=Or(),Ye=_(R,!0);S(()=>{R.disabled=e(Q),y(Ye,(e(n),u(()=>e(n).rangeComment)))}),U("click",R,()=>{Gu()}),$(de,R)};B(sr,de=>{e(kt),e(I),u(()=>e(kt)?.hunkId===e(I).id)&&de(Rr)})}var At=v(sr,2);{var Sr=de=>{var R=Or(),Ye=_(R,!0);S(()=>y(Ye,(e(n),u(()=>e(n).viewVisual)))),U("click",R,sl),$(de,R)};B(At,de=>{e(or),u(()=>e(or).length>0)&&de(Sr)})}var Ct=v(At,2),mr=v(Me,2);{var nt=de=>{var R=pv(),Ye=k(R),se=k(Ye),We=_(se,!0),ue=v(se,2),Qe=_(ue,!0),Pe=v(Ye,2),ie=k(Pe),Se=_(ie,!0),yt=v(ie,2),ur=_(yt,!0);S(()=>{z(R,"aria-label",(e(n),u(()=>e(n).interpretation))),y(We,(e(n),u(()=>e(n).hunkPurpose))),y(Qe,(et(e(Y)),u(()=>e(Y).purpose))),y(Se,(e(n),u(()=>e(n).hunkMeaning))),y(ur,(et(e(Y)),u(()=>e(Y).meaning)))}),$(de,R)};B(mr,de=>{e(Y)&&de(nt)})}var ce=v(mr,2);let re;we(ce,5,()=>(e(I),u(()=>cl(e(I)))),xa,(de,R)=>{var Ye=$n(),se=yr(Ye);{var We=Pe=>{var ie=Sd(),Se=_(ie,!0);S(yt=>y(Se,yt),[()=>(e(n),e(R),u(()=>e(n).context.replace("{count}",String(e(R).count))))]),U("click",ie,()=>hl(e(I).id)),$(Pe,ie)},ue=Pe=>{const ie=Ia(()=>(e(I),e(R),u(()=>Qo(e(I),e(R).index))));var Se=cv(),yt=k(Se);{var ur=ut=>{var Le=Or();let Cr;var ra=_(Le,!0);S((Lr,on)=>{Cr=Dt(Le,1,"line-number range-line",null,Cr,{"range-selected":Lr}),z(Le,"aria-label",(e(R),e(I),u(()=>`Select before line ${e(R).line.oldLine} in ${e(I).path}`))),z(Le,"aria-pressed",on),y(ra,(e(R),u(()=>e(R).line.oldLine)))},[()=>ja(e(kt),e(I).id,"before",e(R).line.oldLine),()=>(e(kt),e(I),e(R),u(()=>ja(e(kt),e(I).id,"before",e(R).line.oldLine)))]),U("click",Le,Lr=>js(e(I),"before",e(R).line.oldLine,Lr.shiftKey)),$(ut,Le)},Er=ut=>{var Le=pi();$(ut,Le)};B(yt,ut=>{e(R),u(()=>e(R).line.oldLine)?ut(ur):ut(Er,-1)})}var Nr=v(yt,2);{var ds=ut=>{var Le=Or();let Cr;var ra=_(Le,!0);S((Lr,on)=>{Cr=Dt(Le,1,"line-number range-line",null,Cr,{"range-selected":Lr}),z(Le,"aria-label",(e(R),e(I),u(()=>`Select after line ${e(R).line.newLine} in ${e(I).path}`))),z(Le,"aria-pressed",on),y(ra,(e(R),u(()=>e(R).line.newLine)))},[()=>ja(e(kt),e(I).id,"after",e(R).line.newLine),()=>(e(kt),e(I),e(R),u(()=>ja(e(kt),e(I).id,"after",e(R).line.newLine)))]),U("click",Le,Lr=>js(e(I),"after",e(R).line.newLine,Lr.shiftKey)),$(ut,Le)},kn=ut=>{var Le=pi();$(ut,Le)};B(Nr,ut=>{e(R),u(()=>e(R).line.newLine)?ut(ds):ut(kn,-1)})}var xn=v(Nr,2),us=_(xn,!0),An=v(xn,2);we(An,5,()=>(e(I),e(R),u(()=>Vi(e(I),e(R).index))),xa,(ut,Le)=>{var Cr=di();let ra;var Lr=_(Cr,!0);S(()=>{ra=Dt(Cr,1,"",null,ra,{"word-change":e(Le).changed}),y(Lr,(e(Le),u(()=>e(Le).text)))}),$(ut,Cr)});var nn=v(An,2);{var sn=ut=>{var Le=Ed();S(()=>{Le.disabled=e(Q),z(Le,"aria-label",(e(n),e(I),et(e(ie)),u(()=>`${e(n).commentOn} ${e(I).path}:${e(ie).startLine}`))),z(Le,"title",(e(n),u(()=>e(n).comment)))}),U("click",Le,()=>{wa(e(ie))}),$(ut,Le)};B(nn,ut=>{e(j)&&e(ie)&&ut(sn)})}S(()=>{Dt(Se,1,(e(R),u(()=>`diff-line ${e(R).line.kind}`))),z(Se,"aria-label",(e(R),u(()=>`${e(R).line.kind}, old line ${e(R).line.oldLine??"none"}, new line ${e(R).line.newLine??"none"}`))),y(us,(e(R),u(()=>e(R).line.kind==="addition"?"+":e(R).line.kind==="deletion"?"−":" ")))}),$(Pe,Se)},Qe=Pe=>{const ie=Ia(()=>(e(I),e(R),u(()=>Qo(e(I),e(R).index))));var Se=hv(),yt=k(Se);let ur;var Er=k(yt);{var Nr=Xe=>{var je=Or();let ke;var Ee=_(je,!0);S((ve,Ie)=>{ke=Dt(je,1,"line-number range-line",null,ke,{"range-selected":ve}),z(je,"aria-label",(e(R),e(I),u(()=>`Select before line ${e(R).line.oldLine} in ${e(I).path}`))),z(je,"aria-pressed",Ie),y(Ee,(e(R),u(()=>e(R).line.oldLine)))},[()=>ja(e(kt),e(I).id,"before",e(R).line.oldLine),()=>(e(kt),e(I),e(R),u(()=>ja(e(kt),e(I).id,"before",e(R).line.oldLine)))]),U("click",je,ve=>js(e(I),"before",e(R).line.oldLine,ve.shiftKey)),$(Xe,je)},ds=Xe=>{var je=pi();$(Xe,je)};B(Er,Xe=>{e(R),u(()=>e(R).line.oldLine)?Xe(Nr):Xe(ds,-1)})}var kn=v(Er,2),xn=_(kn,!0),us=v(kn,2);{var An=Xe=>{var je=Nd();we(je,5,()=>(e(I),e(R),u(()=>Vi(e(I),e(R).index))),xa,(ke,Ee)=>{var ve=di();let Ie;var Yt=_(ve,!0);S(()=>{Ie=Dt(ve,1,"",null,Ie,{"word-change":e(Ee).changed}),y(Yt,(e(Ee),u(()=>e(Ee).text)))}),$(ke,ve)}),$(Xe,je)};B(us,Xe=>{e(R),u(()=>e(R).line.kind!=="addition")&&Xe(An)})}var nn=v(yt,2);let sn;var ut=k(nn);{var Le=Xe=>{var je=Or();let ke;var Ee=_(je,!0);S((ve,Ie)=>{ke=Dt(je,1,"line-number range-line",null,ke,{"range-selected":ve}),z(je,"aria-label",(e(R),e(I),u(()=>`Select after line ${e(R).line.newLine} in ${e(I).path}`))),z(je,"aria-pressed",Ie),y(Ee,(e(R),u(()=>e(R).line.newLine)))},[()=>ja(e(kt),e(I).id,"after",e(R).line.newLine),()=>(e(kt),e(I),e(R),u(()=>ja(e(kt),e(I).id,"after",e(R).line.newLine)))]),U("click",je,ve=>js(e(I),"after",e(R).line.newLine,ve.shiftKey)),$(Xe,je)},Cr=Xe=>{var je=pi();$(Xe,je)};B(ut,Xe=>{e(R),u(()=>e(R).line.newLine)?Xe(Le):Xe(Cr,-1)})}var ra=v(ut,2),Lr=_(ra,!0),on=v(ra,2);{var ai=Xe=>{var je=Nd();we(je,5,()=>(e(I),e(R),u(()=>Vi(e(I),e(R).index))),xa,(ke,Ee)=>{var ve=di();let Ie;var Yt=_(ve,!0);S(()=>{Ie=Dt(ve,1,"",null,Ie,{"word-change":e(Ee).changed}),y(Yt,(e(Ee),u(()=>e(Ee).text)))}),$(ke,ve)}),$(Xe,je)};B(on,Xe=>{e(R),u(()=>e(R).line.kind!=="deletion")&&Xe(ai)})}var Xi=v(nn,2);{var eo=Xe=>{var je=Ed();S(()=>{je.disabled=e(Q),z(je,"aria-label",(e(n),e(I),et(e(ie)),u(()=>`${e(n).commentOn} ${e(I).path}:${e(ie).startLine}`))),z(je,"title",(e(n),u(()=>e(n).comment)))}),U("click",je,()=>{wa(e(ie))}),$(Xe,je)};B(Xi,Xe=>{e(j)&&e(ie)&&Xe(eo)})}S(()=>{z(Se,"aria-label",(e(R),u(()=>`${e(R).line.kind}, old line ${e(R).line.oldLine??"none"}, new line ${e(R).line.newLine??"none"}`))),ur=Dt(yt,1,(e(R),u(()=>`diff-line ${e(R).line.kind==="addition"?"empty":e(R).line.kind}`)),null,ur,{"empty-side":e(R).line.kind==="addition"}),y(xn,(e(R),u(()=>e(R).line.kind==="deletion"?"−":" "))),sn=Dt(nn,1,(e(R),u(()=>`diff-line ${e(R).line.kind==="deletion"?"empty":e(R).line.kind}`)),null,sn,{"empty-side":e(R).line.kind==="deletion"}),y(Lr,(e(R),u(()=>e(R).line.kind==="addition"?"+":" ")))}),$(Pe,Se)};B(se,Pe=>{e(R),u(()=>e(R).kind==="fold")?Pe(We):e(ne)==="unified"?Pe(ue,1):Pe(Qe,-1)})}$(de,Ye)});var ze=v(ce,2);{var ht=de=>{var R=fv(),Ye=_(R);S(()=>y(Ye,`← ${e(n),u(()=>e(n).backChange)??""}`)),U("click",R,_p),$(de,R)};B(ze,de=>{e(K),e(I),u(()=>e(K)===e(I).id)&&de(ht)})}S((de,R,Ye)=>{Te=Dt(M,1,"hunk",null,Te,{"active-hunk":e(K)===e(I).id}),z(M,"id",de),z(M,"aria-labelledby",R),y(at,(e(I),u(()=>e(I).path))),z(dt,"id",Ye),y(Mt,`@@ −${e(I),u(()=>e(I).oldStart)??""},${e(I),u(()=>e(I).oldLines)??""} +${e(I),u(()=>e(I).newStart)??""},${e(I),u(()=>e(I).newLines)??""} @@ ${e(I),u(()=>e(I).heading)??""}`),z(Ct,"aria-label",(e(I),u(()=>`Link to hunk in ${e(I).path}`))),re=Dt(ce,1,"diff-table",null,re,{"split-diff":e(ne)==="split"}),z(ce,"aria-label",(e(I),u(()=>`Diff for ${e(I).path}`)))},[()=>(e(I),u(()=>ot("hunk",e(I).id))),()=>(e(I),u(()=>ot("hunk-title",e(I).id))),()=>(e(I),u(()=>ot("hunk-title",e(I).id)))]),U("click",Ct,()=>Mi(e(I).id)),$(D,M)});var nh=v(nd,2),ld=k(nh),sh=k(ld),dd=k(sh),ih=_(dd),oh=v(dd,2),lh=_(oh,!0),ud=v(ld,2);{var dh=D=>{var I=vv(),Y=k(I),M=k(Y),Te=_(M),Me=v(M,2),Re=_(Me,!0),rt=v(Y,2),at=v(k(rt),2),dt=k(at);dt.value=dt.__value="note";var Mt=v(dt);Mt.value=Mt.__value="question";var Gt=v(Mt);Gt.value=Gt.__value="finding";var fr=v(Gt);fr.value=fr.__value="change-request",ii(at);var zt=v(rt,2),sr=k(zt),Rr=_(sr,!0),At=v(sr,2);cs(At,ue=>A(x,ue),()=>e(x));var Sr=v(zt,2),Ct=k(Sr),mr=v(Ct,2),nt=_(mr,!0),ce=v(mr,2),re=_(ce,!0),ze=v(Sr,2),ht=_(ze,!0),de=v(ze,2),R=k(de),Ye=_(R,!0),se=v(R,2),We=_(se,!0);S((ue,Qe)=>{y(Te,`${e(n),u(()=>e(n).commentOn)??""} / ${e(tr),u(()=>e(tr).type)??""}`),y(Re,ue),at.disabled=e(Q),y(Rr,(e(n),u(()=>e(n).commentBody))),At.disabled=e(Q),Ct.disabled=e(Q),y(nt,(e(n),u(()=>e(n).askAgent))),y(re,(e(n),u(()=>e(n).askAgentHelp))),y(ht,(e(n),u(()=>e(n).localOnly))),R.disabled=Qe,y(Ye,(e(n),u(()=>e(n).saveComment))),se.disabled=e(Q),y(We,(e(n),u(()=>e(n).cancel)))},[()=>(e(tr),u(()=>Ni(e(tr)))),()=>(e(Q),e($r),u(()=>e(Q)||!e($r).trim()))]),no("submit",I,ue=>{ue.preventDefault(),ap()}),zf(at,()=>e(g),ue=>A(g,ue)),oi(At,()=>e($r),ue=>A($r,ue)),oo(Ct,()=>e(w),ue=>A(w,ue)),U("click",se,()=>{A(tr,null),A($r,""),A(w,!1)}),$(D,I)};B(ud,D=>{e(tr)&&D(dh)})}var uh=v(ud,2);{var ph=D=>{var I=bv();we(I,5,()=>e(fe),Y=>Y.id,(Y,M)=>{var Te=wv(),Me=k(Te),Re=k(Me),rt=k(Re),at=_(rt,!0),dt=v(rt,2),Mt=_(dt,!0),Gt=v(Re,2),fr=_(Gt,!0),zt=v(Me,2),sr=_(zt,!0),Rr=v(zt,2);we(Rr,1,()=>(e(M),u(()=>e(M).messages)),ce=>ce.id,(ce,re)=>{var ze=$n(),ht=yr(ze);{var de=Ye=>{var se=gv(),We=k(se),ue=_(We,!0);Lf(We,(ie,Se)=>up?.(ie,Se),()=>({itemId:e(re).feedbackItemId,unread:Yn(e(re).feedbackItemId)}));var Qe=v(We,2),Pe=_(Qe,!0);S((ie,Se)=>{z(se,"data-unread",ie),y(ue,(e(re),u(()=>e(re).body))),z(Qe,"title",(e(n),u(()=>e(n).answerReadHelp))),y(Pe,Se)},[()=>(e(re),u(()=>Yn(e(re).feedbackItemId))),()=>(e(re),e(n),u(()=>Yn(e(re).feedbackItemId)?e(n).markRead:e(n).markUnread))]),U("click",Qe,()=>{al(e(re).feedbackItemId,!Yn(e(re).feedbackItemId),!0)}),$(Ye,se)},R=Ye=>{var se=Aa(),We=_(se,!0);S(()=>y(We,(e(re),u(()=>e(re).body)))),$(Ye,se)};B(ht,Ye=>{e(te),e(re),u(()=>e(te)&&e(re).kind==="agent-answer"&&e(re).feedbackItemId)?Ye(de):Ye(R,-1)})}$(ce,ze)});var At=v(Rr,2);{var Sr=ce=>{var re=yv(),ze=k(re),ht=v(ze,2),de=_(ht,!0);S(()=>{qn(ze,(e(M),u(()=>e(M).agentAttention.state==="requested"))),ze.disabled=(e(Q),e(M),u(()=>e(Q)||e(M).state!=="open")),y(de,(e(n),u(()=>e(n).askAgent)))}),U("change",ze,R=>{sp(e(M).id,R.currentTarget.checked)}),$(ce,re)},Ct=ce=>{var re=_v(),ze=_(re);S(()=>y(ze,`Agent attention: ${e(M),u(()=>e(M).agentAttention.state)??""}`)),$(ce,re)};B(At,ce=>{e(M),u(()=>e(M).agentAttention.state==="none"||e(M).agentAttention.state==="requested")?ce(Sr):ce(Ct,-1)})}var mr=v(At,2);{var nt=ce=>{var re=Or(),ze=_(re,!0);S(()=>{re.disabled=e(Q),y(ze,(e(n),u(()=>e(n).resolve)))}),U("click",re,()=>{np(e(M).id)}),$(ce,re)};B(mr,ce=>{e(M),u(()=>e(M).state==="open")&&ce(nt)})}S((ce,re)=>{z(Te,"id",ce),z(Te,"data-thread-state",(e(M),u(()=>e(M).state))),y(at,(e(M),u(()=>e(M).kind))),y(Mt,(e(M),u(()=>e(M).anchor.type))),y(fr,(e(M),e(n),u(()=>e(M).state==="resolved"?e(n).resolved:e(M).state))),y(sr,re)},[()=>(e(M),u(()=>ot("thread",e(M).id))),()=>(e(M),u(()=>Ni(e(M).anchor)))]),$(Y,Te)}),$(D,I)},ch=D=>{var I=Pv(),Y=_(I,!0);S(()=>y(Y,(e(n),u(()=>e(n).noComments)))),$(D,I)};B(uh,D=>{e(fe),u(()=>e(fe).length>0)?D(ph):D(ch,-1)})}S((D,I,Y,M,Te,Me,Re,rt,at,dt)=>{z(V,"id",D),z(V,"aria-labelledby",I),y(mt,`← ${e(n),u(()=>e(n).backQueue)??""}`),y(Ot,`Focused change / ${e(O),u(()=>e(O).kind)??""}`),z(Et,"id",Y),y(qe,(e(O),u(()=>e(O).title))),z(Be,"title",M),z(Be,"data-queue",Te),y(lt,`${e(n),u(()=>e(n).autoPriority)??""}: ${Me??""}`),y(Tt,`${e(O),u(()=>e(O).risk.level)??""} risk`),y(Wt,(e(O),u(()=>e(O).intent.source))),y(pt,`${e(n),u(()=>e(n).autoPriority)??""}: ${Re??""}`),y(Zt,(e(n),u(()=>e(n).reviewWorkspace))),ar.disabled=rt,y(za,(e(n),u(()=>e(n).reanchorImport))),Xr.disabled=!e(j)||e(Q),y(ss,(e(n),u(()=>e(n).exportReview))),Va.disabled=at,y(is,(e(n),u(()=>e(n).importReview))),z(bn,"aria-label",(e(n),u(()=>e(n).reviewBundleFile))),y(pa,(e(n),u(()=>e(n).interpretation))),y(os,(e(n),u(()=>e(n).what))),y(ls,(e(O),u(()=>e(O).summary))),y(ta,(e(O),u(()=>e(O).implementation))),y(fc,(e(n),u(()=>e(n).why))),y(vc,(e(O),e(n),u(()=>e(O).intent.text||e(n).intentUnknown))),y(gc,(e(n),u(()=>e(n).userImpact))),y(bc,(e(n),u(()=>e(n).risk))),y(kc,(e(n),u(()=>e(n).gaps))),y(Ic,(e(n),u(()=>e(n).verified))),y(Rc,`Evidence / ${e(or),u(()=>e(or).length)??""}`),y(Sc,(e(n),u(()=>e(n).measured))),y(Ec,(e(n),u(()=>e(n).visualEvidence))),y(Cc,dt),y(Mc,`Finding states / ${e(Ar),u(()=>e(Ar).length)??""}`),y(Vc,(e(n),u(()=>e(n).findings))),y(Uc,`Evidence / ${e(Ht),u(()=>e(Ht).length)??""}`),y(Zc,(e(n),u(()=>e(n).evidence))),y(Gc,(e(n),u(()=>e(n).rangeHelp))),y(Yc,`Structured patch / ${e(Gr),u(()=>e(Gr).length)??""}`),y(Xc,(e(n),u(()=>e(n).codeDiff))),z(ri,"aria-pressed",e(ne)==="unified"),y(th,(e(n),u(()=>e(n).unified))),z(Qi,"aria-pressed",e(ne)==="split"),y(rh,(e(n),u(()=>e(n).split))),y(ih,`Notes / ${e(fe),u(()=>e(fe).length)??""}`),y(lh,(e(n),u(()=>e(n).comments)))},[()=>(e(O),u(()=>ot("change",e(O).id))),()=>(e(O),u(()=>ot("title",e(O).id))),()=>(e(O),u(()=>ot("title",e(O).id))),()=>(e(O),u(()=>Ei(e(O)))),()=>(e(O),u(()=>_a(e(O)))),()=>(e(O),e(n),u(()=>Os(_a(e(O)),e(n)))),()=>(e(O),u(()=>Ei(e(O)))),()=>(e(Q),e(te),u(()=>e(Q)||!!e(te))),()=>(e(j),e(Q),e(te),u(()=>!e(j)||e(Q)||!!e(te))),()=>(e(c),e(N),u(()=>zi(e(c),e(N))))]),U("click",me,ll),oo(ar,()=>e(Ga),D=>A(Ga,D)),U("click",Xr,()=>{ip()}),U("click",Va,()=>e(G)?.click()),U("change",bn,D=>{hp(D.currentTarget.files?.[0])}),U("click",ri,()=>A(ne,"unified")),U("click",Qi,()=>A(ne,"split")),$(J,V)},uc=J=>{const V=Ia(()=>(e(c),e(K),u(()=>e(c).hunks.find(vt=>vt.id===e(K)))));var me=$n(),mt=yr(me);{var St=vt=>{var jt=Iv(),Ot=k(jt),Et=_(Ot),qe=v(Ot,2),ye=_(qe,!0),Be=v(qe,2),lt=_(Be,!0),_e=v(Be,2),Tt=k(_e),gt=k(Tt),Wt=_(gt),Ge=v(gt,2);{var pt=xt=>{var Ce=xv(),rr=k(Ce),Zt=k(rr),lr=v(Zt,2),Kt=_(lr,!0),bt=v(rr,2),Jt=_(bt,!0);S(ct=>{qn(Zt,ct),Zt.disabled=e(Q),y(Kt,(e(n),u(()=>e(n).viewed))),bt.disabled=e(Q),y(Jt,(e(n),u(()=>e(n).comment)))},[()=>(e(j),et(e(V)),u(()=>Kn(e(j),"hunk",e(V).id)))]),U("change",Zt,ct=>{Gn("hunk",e(V).id,ct.currentTarget.checked)}),U("click",bt,()=>{wa(La("hunk",e(V).id))}),$(xt,Ce)};B(Ge,xt=>{e(j)&&xt(pt)})}var Nt=v(Tt,2);we(Nt,5,()=>(et(e(V)),u(()=>cl(e(V)))),xa,(xt,Ce)=>{var rr=$n(),Zt=yr(rr);{var lr=bt=>{var Jt=Sd(),ct=_(Jt,!0);S(ar=>y(ct,ar),[()=>(e(n),e(Ce),u(()=>e(n).context.replace("{count}",String(e(Ce).count))))]),U("click",Jt,()=>hl(e(V).id)),$(bt,Jt)},Kt=bt=>{var Jt=Av(),ct=k(Jt),ar=_(ct,!0),qr=v(ct),za=_(qr,!0),Xr=v(qr),ss=_(Xr,!0),Va=v(Xr),is=_(Va,!0);S(()=>{Dt(Jt,1,(e(Ce),u(()=>`diff-line ${e(Ce).line.kind}`))),y(ar,(e(Ce),u(()=>e(Ce).line.oldLine??""))),y(za,(e(Ce),u(()=>e(Ce).line.newLine??""))),y(ss,(e(Ce),u(()=>e(Ce).line.kind==="addition"?"+":e(Ce).line.kind==="deletion"?"−":" "))),y(is,(e(Ce),u(()=>e(Ce).line.content)))}),$(bt,Jt)};B(Zt,bt=>{e(Ce),u(()=>e(Ce).kind==="fold")?bt(lr):bt(Kt,-1)})}$(xt,rr)}),S(xt=>{y(Et,`← ${e(n),u(()=>e(n).backQueue)??""}`),y(ye,(e(n),u(()=>e(n).unclassified))),y(lt,(et(e(V)),u(()=>e(V).path))),z(_e,"id",xt),y(Wt,`@@ −${et(e(V)),u(()=>e(V).oldStart)??""},${et(e(V)),u(()=>e(V).oldLines)??""} +${et(e(V)),u(()=>e(V).newStart)??""},${et(e(V)),u(()=>e(V).newLines)??""} @@`)},[()=>(et(e(V)),u(()=>ot("hunk",e(V).id)))]),U("click",Ot,ll),$(vt,jt)};B(mt,vt=>{e(V)&&vt(St)})}$(J,me)},pc=J=>{var V=$v(),me=k(V),mt=_(me,!0);S(()=>y(mt,(e(n),u(()=>e(n).empty)))),$(J,V)};B(lc,J=>{e(O)?J(dc):e(K)?J(uc,1):(e(c),u(()=>e(c).changes.length===0)&&J(pc,2))})}var cc=v(as,2);{var hc=J=>{var V=Cv();let me;var mt=k(V),St=k(mt),vt=k(St),jt=_(vt),Ot=v(vt,2),Et=_(Ot),qe=v(St,2),ye=_(qe,!0),Be=v(qe,2);{var lt=Ge=>{var pt=Or(),Nt=_(pt,!0);S(()=>{pt.disabled=e(Qa)||e(Q)||e(l),y(Nt,(e(n),u(()=>e(n).reviewItems)))}),U("click",pt,()=>{lp()}),$(Ge,pt)};B(Be,Ge=>{e(t)>0&&!e(la)&&Ge(lt)})}var _e=v(Be,2);{var Tt=Ge=>{var pt=Or(),Nt=_(pt,!0);S(()=>{pt.disabled=e(vn)!==null,y(Nt,(e(n),u(()=>e(n).retryReviewUpdate)))}),U("click",pt,()=>{tl()}),$(Ge,pt)};B(_e,Ge=>{e(l)&&e(gn)&&Ge(Tt)})}var gt=v(mt,2);{var Wt=Ge=>{var pt=Nv(),Nt=k(pt),xt=_(Nt,!0),Ce=v(Nt,2),rr=_(Ce,!0),Zt=v(Ce,2);we(Zt,5,()=>(e(ae),u(()=>e(ae).batch.items)),dr=>dr.id,(dr,nr)=>{var pa=qv(),ea=k(pa),Pn=_(ea,!0),rn=v(ea,2),os=_(rn),an=v(rn,2),ls=_(an,!0),Vr=v(an,2),ta=_(Vr,!0);S(Fa=>{y(Pn,(e(nr),u(()=>e(nr).question))),y(os,`${e(nr),u(()=>e(nr).anchor.type)??""}: ${Fa??""}`),y(ls,(e(l),e(n),e(nr),u(()=>e(l)?e(n).feedbackUpdating:e(nr).state))),y(ta,(e(n),u(()=>e(n).viewAnswer)))},[()=>(e(nr),u(()=>Ni(e(nr).anchor)))]),U("click",Vr,()=>{pp(e(nr).threadId)}),$(dr,pa)});var lr=v(Zt,2),Kt=k(lr),bt=k(Kt),Jt=_(bt,!0),ct=v(bt,2),ar=_(ct),qr=v(Kt,2),za=k(qr),Xr=_(za,!0),ss=v(za,2),Va=_(ss,!0),is=v(qr,2),bn=k(is),Qs=_(bn,!0),Gi=v(bn,2),Yi=_(Gi),Xs=v(lr,2);we(Xs,1,()=>(e(ae),u(()=>e(ae).warnings)),dr=>dr,(dr,nr)=>{var pa=Rv(),ea=_(pa,!0);S(()=>y(ea,e(nr))),$(dr,pa)});var ei=v(Xs,2);{var ti=dr=>{var nr=Ev(),pa=yr(nr),ea=k(pa),Pn=_(ea,!0),rn=v(ea,2);{var os=Vr=>{var ta=Or(),Fa=_(ta,!0);S(()=>{ta.disabled=e(Qa),y(Fa,(e(n),u(()=>e(n).copyHandoff)))}),U("click",ta,()=>{cp()}),$(Vr,ta)};B(rn,Vr=>{e(da)&&Vr(os)})}var an=v(pa,2);{var ls=Vr=>{var ta=Sv(),Fa=_(ta,!0);S(()=>y(Fa,e(da))),$(Vr,ta)};B(an,Vr=>{e(da)&&Vr(ls)})}S(()=>{ea.disabled=e(Qa),y(Pn,(e(te),e(n),u(()=>e(te)?e(n).returnConversation:e(n).prepareRequest)))}),U("click",ea,()=>{dp()}),$(dr,nr)};B(ei,dr=>{e(ae),e(l),u(()=>e(ae).batch.state==="ready"&&!e(l))&&dr(ti)})}S(dr=>{y(xt,(e(n),u(()=>e(n).feedbackPreview))),y(rr,(e(l),e(gn),e(n),e(ae),u(()=>e(l)?e(gn)?e(n).feedbackUpdateFailed:e(n).feedbackUpdating:e(ae).batch.state))),y(Jt,(e(n),u(()=>e(n).shared))),y(ar,`${e(ae),u(()=>e(ae).shared.comments)??""} comments · ${e(ae),u(()=>e(ae).shared.codeRanges)??""}\n code ranges · ${e(ae),u(()=>e(ae).shared.imageCrops)??""} image crops ·\n ${e(ae),u(()=>e(ae).shared.evidenceReferences)??""} evidence refs`),y(Xr,(e(n),u(()=>e(n).notShared))),y(Va,dr),y(Qs,(e(n),u(()=>e(n).delivery))),y(Yi,`${e(ae),u(()=>e(ae).destination.deliveryMode)??""} · ${e(ae),u(()=>e(ae).contextBytes)??""} bytes ·\n ${e(ae),u(()=>e(ae).redactionCount)??""} redactions`)},[()=>(e(ae),u(()=>e(ae).excluded.join(" · ")))]),$(Ge,pt)};B(gt,Ge=>{e(ae)&&!e(la)&&Ge(Wt)})}S(()=>{me=Dt(V,1,"feedback-dock",null,me,{collapsed:e(la)}),z(V,"aria-label",(e(n),u(()=>e(n).selectedItems))),y(jt,`${e(n),u(()=>e(n).selectedItems)??""}: ${(e(l)?"…":e(s))??""}`),y(Et,`${e(n),u(()=>e(n).unreadAnswers)??""}: ${(e(l)?"…":e(o))??""}`),z(qe,"aria-expanded",!e(la)),y(ye,(e(la),e(n),u(()=>e(la)?e(n).expandFeedback:e(n).collapseFeedback)))}),U("click",qe,()=>{A(la,!e(la))}),$(J,V)};B(cc,J=>{e(j)&&(e(s)>0||e(o)>0||e(ae))&&J(hc)})}S((J,V,me)=>{z(L,"data-status",(e(c),u(()=>e(c).status))),y(Ut,(e(c),u(()=>e(c).status))),y(Qr,J),y(Oa,(e(c),u(()=>e(c).reportId))),y(Di,(e(n),u(()=>e(n).queue))),y(Bi,(e(n),u(()=>e(n).search))),y(Vs,`${e(n),u(()=>e(n).autoPriority)??""}: ${e(n),u(()=>e(n).priorityHelp)??""}`),y(Hi,(e(n),u(()=>e(n).hideReviewed))),z(Bs,"aria-label",(e(n),u(()=>e(n).queue))),y(Zi,`Brief / ${e(c),u(()=>e(c).status)??""}`),y(Ks,(e(n),u(()=>e(n).summary))),z(zr,"data-status",(e(c),u(()=>e(c).status))),y(Ma,(e(n),u(()=>e(n).evidencePosture))),y(Ji,(e(c),u(()=>e(c).summary.statement))),y(xp,(e(n),u(()=>e(n).reviewerRoute))),y(qp,(e(n),u(()=>e(n).files))),y(Sp,(e(c),u(()=>e(c).summary.filesChanged))),y(Ep,(e(n),u(()=>e(n).additions))),y(Cp,`+${e(c),u(()=>e(c).summary.additions)??""}`),y(Lp,(e(n),u(()=>e(n).deletions))),y(Op,`−${e(c),u(()=>e(c).summary.deletions)??""}`),y(Tp,(e(n),u(()=>e(n).changes))),y(zp,(e(c),u(()=>e(c).changes.length))),y(Fp,(e(n),u(()=>e(n).lowSignal))),y(Bp,V),y(Up,(e(n),u(()=>e(n).coverage))),y(Zp,me),y(Jp,(e(n),u(()=>e(n).planned))),y(Yp,(e(c),u(()=>e(c).coverage.planned))),y(Qp,(e(n),u(()=>e(n).captured))),y(ec,(e(c),u(()=>e(c).coverage.succeeded))),y(rc,(e(n),u(()=>e(n).failed))),y(nc,(e(c),u(()=>e(c).coverage.failed))),y(ic,(e(n),u(()=>e(n).inventory)))},[()=>(e(c),e(N),u(()=>zi(e(c),e(N)))),()=>(e(c),u(()=>e(c).files.filter(J=>J.lowSignal).length)),()=>(e(c),e(N),u(()=>zi(e(c),e(N))))]),U("click",C,J=>{J.preventDefault(),nl()}),oi(es,()=>e(Z),J=>A(Z,J)),oo(ts,()=>e(Ca),J=>A(Ca,J)),$(f,b)},kp=f=>{var b=jv(),q=_(b,!0);S(()=>{z(b,"role",e(P)?"alert":"status"),y(q,(e(P),u(()=>e(P)||h.en.loading)))}),$(f,b)};B(bp,f=>{e(c)?f(Pp):f(kp,-1)})}$(r,fl),Jd()}mf(["click","change"]);const Cd=document.querySelector("[data-utsuri-app]");Cd&&Af(Ov,{target:Cd});\n';
|
|
220255
|
+
var reportUiCss = ':root{color-scheme:light dark;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Hiragino Sans,Yu Gothic UI,sans-serif;font-size:16px;--paper: #f2efe7;--paper-raised: #fffdf7;--ink: #171a1f;--ink-muted: #61656d;--line: #c9c4b8;--line-strong: #7c7b77;--rail: #e4e0d6;--blue: #1558d6;--blue-soft: #dce7ff;--coral: #b73f2d;--coral-soft: #fae1db;--green: #176948;--green-soft: #d8eee3;--amber: #805400;--amber-soft: #f5e7bf;--focus: #0066ff;--code-bg: #20242b;--code-text: #f5f2e9;--code-muted: #a9afb9;--addition: #123d2e;--deletion: #4d2524;--word-addition: #297553;--word-deletion: #9c4139;--radius: .25rem;--shadow: 0 1px 0 rgb(23 26 31 / 8%), 0 12px 34px rgb(23 26 31 / 7%)}@media(prefers-color-scheme:dark){:root{--paper: #15171a;--paper-raised: #1e2126;--ink: #f4f0e7;--ink-muted: #b3b5ba;--line: #3b3f45;--line-strong: #71757c;--rail: #1a1d21;--blue: #80a9ff;--blue-soft: #25395f;--coral: #ff9b89;--coral-soft: #542e2a;--green: #76d4ac;--green-soft: #1c4637;--amber: #f0c66c;--amber-soft: #4b3b1c;--focus: #8ab4ff;--code-bg: #0c0e11}}*{box-sizing:border-box}html{background:var(--paper);color:var(--ink);scroll-behavior:smooth}body{margin:0;min-width:320px;background-image:linear-gradient(rgb(23 26 31 / 3%) 1px,transparent 1px);background-size:100% 2rem}button,input,select{font:inherit}button,a,summary{-webkit-tap-highlight-color:transparent}a{color:inherit}:focus-visible{outline:3px solid var(--focus);outline-offset:3px}.skip-link{position:fixed;inset:0 auto auto 0;z-index:100;transform:translateY(-120%);padding:.75rem 1rem;background:var(--paper-raised);color:var(--ink)}.skip-link:focus{transform:translateY(0)}.report-shell{display:grid;grid-template-columns:clamp(17rem,23vw,22rem) minmax(0,1fr);grid-template-rows:4.5rem minmax(calc(100vh - 4.5rem),auto);min-height:100vh}.report-header{position:sticky;top:0;z-index:20;grid-column:1 / -1;display:grid;grid-template-columns:clamp(17rem,23vw,22rem) 1fr auto;align-items:stretch;min-height:4.5rem;border-bottom:1px solid var(--line-strong);background:color-mix(in srgb,var(--paper-raised) 94%,transparent);-webkit-backdrop-filter:blur(14px);backdrop-filter:blur(14px)}.wordmark{display:flex;align-items:center;gap:.8rem;padding:0 1.25rem;border-right:1px solid var(--line-strong);text-decoration:none}.wordmark>span{display:grid;width:2rem;height:2rem;place-items:center;border-radius:50%;background:var(--ink);color:var(--paper-raised);font-size:.68rem;font-weight:800;letter-spacing:-.08em}.wordmark strong{font-size:1.05rem;letter-spacing:-.025em}.report-state{display:flex;align-items:center;gap:.65rem;padding:0 1.5rem;font-size:.78rem;font-weight:760;letter-spacing:.075em}.report-state small{color:var(--ink-muted);font-size:.75rem;font-weight:500;letter-spacing:0}.state-mark{width:.72rem;height:.72rem;border:2px solid currentColor;transform:rotate(45deg)}.report-state[data-status=UNCOVERED],.report-state[data-status=INCOMPLETE]{color:var(--amber)}.report-state[data-status=REGRESSION]{color:var(--coral)}.report-state[data-status=PASS]{color:var(--green)}.report-state[data-status=CHANGED]{color:var(--blue)}.report-id{align-self:center;margin:0;padding:0 1.25rem;color:var(--ink-muted);font:.7rem/1.2 ui-monospace,SFMono-Regular,Menlo,monospace}.review-rail{position:sticky;top:4.5rem;align-self:start;height:calc(100vh - 4.5rem);overflow-y:auto;border-right:1px solid var(--line-strong);background:color-mix(in srgb,var(--rail) 96%,transparent)}.rail-heading,.queue-search,.queue-section h3{padding-right:1.25rem;padding-left:1.25rem}.rail-heading{padding-top:1.6rem;padding-bottom:1rem}.kicker{margin:0 0 .55rem;color:var(--ink-muted);font-size:.69rem;font-weight:750;letter-spacing:.12em;text-transform:uppercase}.rail-heading h2,.decision-summary h1,.focused-change h2,.section-heading h3{margin:0;letter-spacing:-.04em}.rail-heading h2{font-size:1.55rem}.queue-search{display:grid;gap:.42rem;padding-bottom:1.4rem;color:var(--ink-muted);font-size:.72rem;font-weight:650}.queue-search input{width:100%;border:1px solid var(--line-strong);border-radius:var(--radius);padding:.72rem .8rem;background:var(--paper-raised);color:var(--ink)}.queue-section{border-top:1px solid var(--line)}.queue-section h3{display:flex;align-items:center;justify-content:space-between;margin:0;padding-top:.75rem;padding-bottom:.75rem;color:var(--ink-muted);font-size:.7rem;letter-spacing:.055em;text-transform:uppercase}.count{min-width:1.7rem;border:1px solid var(--line);border-radius:1rem;padding:.12rem .38rem;text-align:center}.queue-section ol{margin:0;padding:0;list-style:none}.queue-section a{display:grid;grid-template-columns:2rem minmax(0,1fr);gap:.65rem;padding:.9rem 1.25rem;border-top:1px solid color-mix(in srgb,var(--line) 70%,transparent);text-decoration:none}.queue-section a:hover,.queue-section a[aria-current=page]{background:var(--paper-raised)}.queue-section a[aria-current=page]{box-shadow:inset .24rem 0 var(--blue)}.queue-index{padding-top:.08rem;color:var(--ink-muted);font:.68rem/1.2 ui-monospace,SFMono-Regular,Menlo,monospace}.queue-copy{min-width:0}.queue-copy strong{display:block;overflow:hidden;font-size:.84rem;line-height:1.35;text-overflow:ellipsis}.queue-copy>span:not(.badges){color:var(--ink-muted);font-size:.7rem}.badges{display:flex;flex-wrap:wrap;gap:.35rem;margin-top:.48rem}.badges span,.change-badges span{border:1px solid var(--line);border-radius:99px;padding:.16rem .45rem;color:var(--ink-muted);font-size:.63rem;font-weight:700}main{min-width:0;padding:clamp(1.25rem,3vw,3rem)}.decision-summary,.focused-change{width:min(100%,90rem);margin:0 auto;border:1px solid var(--line-strong);background:var(--paper-raised);box-shadow:var(--shadow)}.decision-summary{display:grid;grid-template-columns:minmax(0,1.45fr) minmax(18rem,.55fr);gap:clamp(1.5rem,4vw,4rem);padding:clamp(1.4rem,3vw,2.6rem)}.decision-summary h1{font-size:clamp(1.9rem,4vw,3.6rem);line-height:.98}.review-overview{max-width:54rem;margin:1.4rem 0 0;font-size:clamp(1.25rem,2.25vw,2rem);font-weight:680;letter-spacing:-.028em;line-height:1.34}.evidence-posture{max-width:48rem;margin-top:2rem;border-left:.24rem solid var(--amber);padding:.15rem 0 .15rem 1rem}.evidence-posture .kicker{margin-bottom:.3rem}.decision-statement{margin:0;color:var(--ink-muted);font-size:.9rem;line-height:1.55}.review-route{position:relative;display:flex;min-width:0;flex-direction:column;align-items:flex-start;overflow:hidden;border-left:1px solid var(--line-strong);padding-left:clamp(1.25rem,3vw,2.4rem)}.review-route:before{position:absolute;top:-1.25rem;right:-.3rem;content:"01";color:color-mix(in srgb,var(--ink) 8%,transparent);font:800 clamp(5rem,9vw,8rem)/1 ui-monospace,SFMono-Regular,Menlo,monospace;letter-spacing:-.12em;pointer-events:none}.review-route h2,.review-route h3,.review-route>p{position:relative;margin:0}.review-route h2{font-size:.9rem;letter-spacing:.06em;text-transform:uppercase}.review-route h3{max-width:min(100%,28rem);overflow-wrap:anywhere;margin-top:1.25rem;font-size:clamp(1.25rem,2vw,1.75rem);letter-spacing:-.035em;line-height:1.12}.review-route>p:not(.kicker,.route-status){max-width:30rem;margin-top:.8rem;color:var(--ink-muted);font-size:.82rem;line-height:1.5}.route-status{margin-top:1.5rem!important;border:1px solid currentColor;padding:.28rem .48rem;color:var(--amber);font-size:.65rem;font-weight:760;letter-spacing:.065em;text-transform:uppercase}.route-status[data-queue=action-required]{color:var(--coral)}.route-status[data-queue=no-issue]{color:var(--green)}.review-route button{position:relative;width:100%;margin-top:auto;border:0;border-top:1px solid var(--line-strong);border-bottom:1px solid var(--line-strong);padding:.8rem 0;background:transparent;color:var(--ink);font-size:.78rem;font-weight:760;text-align:left;cursor:pointer}.review-route button span{float:right;transition:transform .14s ease}.review-route button:hover span{transform:translate(.3rem)}.metrics{grid-column:1 / -1;display:grid;grid-template-columns:repeat(5,minmax(0,1fr));align-self:end;margin:0;border-top:1px solid var(--line-strong);border-bottom:1px solid var(--line-strong)}.metrics div{min-width:0;padding:.85rem .65rem;border-right:1px solid var(--line)}.metrics div:last-child{border-right:0}.metrics dt{min-height:2.2em;color:var(--ink-muted);font-size:.65rem}.metrics dd{margin:.35rem 0 0;font:700 clamp(1.25rem,2vw,1.8rem)/1 ui-monospace,SFMono-Regular,Menlo,monospace}.positive{color:var(--green)}.negative{color:var(--coral)}.review-map{grid-column:1 / -1;border-top:1px solid var(--line);padding-top:1.15rem}.review-map header{display:flex;align-items:end;justify-content:space-between;gap:1rem;padding-bottom:.9rem}.review-map h2,.review-map header p{margin:0}.review-map h2{font-size:clamp(1.15rem,2vw,1.55rem);letter-spacing:-.03em}.review-map header>p{color:var(--ink-muted);font:.68rem/1.2 ui-monospace,SFMono-Regular,Menlo,monospace}.review-map ol{margin:0;border-top:1px solid var(--line-strong);padding:0;list-style:none}.review-map li{animation:brief-row-enter .32s ease-out both}.review-map li:nth-child(2){animation-delay:45ms}.review-map li:nth-child(3){animation-delay:90ms}.review-map li:nth-child(4){animation-delay:135ms}.review-map li:nth-child(5){animation-delay:.18s}.review-map button{display:grid;width:100%;grid-template-columns:2.5rem minmax(0,1fr) auto;gap:1rem;align-items:center;border:0;border-bottom:1px solid var(--line);padding:1rem .75rem;background:transparent;color:var(--ink);text-align:left;cursor:pointer}.review-map button:hover{background:color-mix(in srgb,var(--amber-soft) 58%,transparent)}.review-map li[data-queue=action-required] button{box-shadow:inset .22rem 0 var(--coral)}.review-map li[data-queue=needs-confirmation] button{box-shadow:inset .22rem 0 var(--amber)}.review-map li[data-queue=no-issue] button{box-shadow:inset .22rem 0 var(--green)}.map-index{color:var(--ink-muted);font:.7rem/1 ui-monospace,SFMono-Regular,Menlo,monospace}.map-copy{min-width:0}.map-copy strong,.map-copy>span{display:block}.map-copy strong{overflow-wrap:anywhere;font-size:.92rem;line-height:1.3}.map-copy>span{overflow:hidden;margin-top:.25rem;color:var(--ink-muted);font-size:.74rem;line-height:1.4;text-overflow:ellipsis;white-space:nowrap}.map-meta{display:flex;gap:.4rem;color:var(--ink-muted);font-size:.68rem;white-space:nowrap}.map-remainder{border-bottom:1px solid var(--line);padding:.7rem .75rem .7rem 3.25rem;color:var(--ink-muted);font-size:.72rem}@keyframes brief-row-enter{0%{transform:translateY(.4rem)}to{transform:translateY(0)}}.file-inventory{grid-column:1 / -1;border-top:1px solid var(--line);padding-top:1rem}.coverage-overview{grid-column:1 / -1;display:grid;grid-template-columns:minmax(0,1fr) auto;gap:2rem;align-items:end;border-top:1px solid var(--line);padding-top:1rem}.coverage-overview h2,.coverage-overview p{margin:0}.coverage-overview h2{font-size:1rem}.coverage-overview p{margin-top:.35rem;color:var(--ink-muted);font-size:.82rem}.coverage-overview dl{display:grid;grid-template-columns:repeat(3,minmax(6rem,1fr));margin:0}.coverage-overview dl div{border-left:1px solid var(--line);padding-left:1rem}.coverage-overview dt{color:var(--ink-muted);font-size:.65rem}.coverage-overview dd{margin:.25rem 0 0;font:700 1.2rem/1 ui-monospace,SFMono-Regular,Menlo,monospace}.file-inventory summary,.more-evidence summary{cursor:pointer;font-size:.78rem;font-weight:720}.file-inventory ul{display:grid;gap:0;margin:.8rem 0 0;padding:0;list-style:none}.file-inventory li{display:grid;grid-template-columns:6rem minmax(0,1fr) auto auto;gap:1rem;padding:.48rem 0;border-top:1px solid var(--line);color:var(--ink-muted);font-size:.72rem}.file-inventory code{overflow-wrap:anywhere;color:var(--ink)}.file-status{font-weight:750;text-transform:uppercase}.focused-change{margin-top:1.4rem;padding:clamp(1.4rem,3vw,2.6rem)}.back-link,.anchor-button{border:0;padding:0;background:transparent;color:var(--blue);cursor:pointer;font-size:.75rem;font-weight:720}.change-header{display:flex;align-items:end;justify-content:space-between;gap:2rem;margin-top:1.8rem;padding-bottom:1.5rem;border-bottom:2px solid var(--ink)}.change-header h2{max-width:50rem;overflow-wrap:anywhere;font-size:clamp(1.8rem,4vw,3.25rem);line-height:1.04}.change-header>div,.finding-list li,.finding-list article{min-width:0}.change-badges{display:flex;flex-wrap:wrap;justify-content:end;gap:.4rem}.change-badges span[data-queue=action-required]{border-color:var(--coral);background:var(--coral-soft);color:var(--coral)}.change-badges span[data-queue=needs-confirmation]{border-color:var(--amber);background:var(--amber-soft);color:var(--amber)}.change-badges span[data-queue=no-issue]{border-color:var(--green);background:var(--green-soft);color:var(--green)}.review-workspace{margin-top:1rem;border:1px solid var(--line-strong);border-left:.35rem solid var(--blue);padding:1rem 1.1rem;background:linear-gradient(90deg,color-mix(in srgb,var(--blue-soft) 48%,transparent),transparent 54%),var(--paper)}.review-workspace-heading{display:flex;align-items:end;justify-content:space-between;gap:1rem}.review-workspace h3,.review-workspace p{margin:0}.review-workspace h3{font-size:1.05rem}.review-workspace-heading p:not(.kicker),.local-only-note,.review-message{margin-top:.35rem;color:var(--ink-muted);font-size:.74rem}.review-transfer-actions,.review-controls,.comment-actions{display:flex;flex-wrap:wrap;gap:.45rem;align-items:center}.review-controls{margin-top:.9rem;border-top:1px solid var(--line);padding-top:.9rem}.review-transfer-actions button,.review-controls button,.comment-actions button,.thread-list button,.feedback-dock button,.inline-comment-action{min-height:2.25rem;border:1px solid var(--line-strong);border-radius:var(--radius);padding:.45rem .7rem;background:var(--paper-raised);color:var(--ink);cursor:pointer;font-size:.7rem;font-weight:720}.review-transfer-actions button:disabled,.review-controls button:disabled,.comment-actions button:disabled,.thread-list button:disabled,.feedback-dock button:disabled{cursor:not-allowed;opacity:.55}.review-controls>label:not(.viewed-control),.comment-composer label{display:grid;gap:.28rem;color:var(--ink-muted);font-size:.68rem;font-weight:700}.review-controls select,.comment-composer select,.comment-composer textarea{border:1px solid var(--line-strong);border-radius:var(--radius);padding:.5rem .65rem;background:var(--paper-raised);color:var(--ink)}.viewed-control{display:inline-flex;gap:.4rem;align-items:center;min-height:2.25rem;color:var(--ink-muted);font-size:.7rem;font-weight:720}.viewed-control input{width:1rem;height:1rem;accent-color:var(--blue)}.compact-control{min-height:auto;justify-self:end}.dark-control{color:#d8e3ff}.visual-viewed-control{align-self:end}.visually-hidden{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;clip-path:inset(50%)}.review-message{border-left:.2rem solid var(--amber);padding:.45rem .6rem;background:var(--amber-soft);color:var(--amber)}.explanation-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));border-bottom:1px solid var(--line-strong)}.explanation-grid section{min-width:0;padding:1.5rem 1.5rem 1.5rem 0;border-bottom:1px solid var(--line)}.explanation-grid section:nth-child(2n){padding-right:0;padding-left:1.5rem;border-left:1px solid var(--line)}.explanation-grid h3{margin:0 0 .7rem;font-size:.74rem;letter-spacing:.08em;text-transform:uppercase}.explanation-grid p,.explanation-grid li{font-size:.9rem;line-height:1.62}.explanation-grid ul{margin:0;padding-left:1.1rem}.technical{color:var(--ink-muted)}.risk-block{box-shadow:inset .22rem 0 var(--coral);padding-left:1.2rem!important}.gap-block{background:var(--amber-soft);box-shadow:inset .22rem 0 var(--amber)}.gap-block li{display:flex;gap:.6rem;align-items:start;justify-content:space-between}.inline-comment-action{min-height:1.7rem;flex:none;padding:.18rem .45rem;background:transparent}.interpretation-section,.visual-evidence-section{padding-top:2.2rem}.interpretation-section>.section-heading{margin-bottom:0}.visual-evidence-section{border-top:2px solid var(--ink)}.visual-heading p:not(.kicker){max-width:42rem;margin:.5rem 0 0;color:var(--ink-muted);font-size:.82rem}.visual-heading h4{margin:.35rem 0 0;font-size:1rem}.visual-selectors{display:flex;flex-wrap:wrap;gap:.8rem;align-items:end;margin-bottom:.8rem}.visual-selectors label,.wipe-control{display:grid;gap:.35rem;min-width:min(100%,13rem);color:var(--ink-muted);font-size:.7rem;font-weight:680}.visual-selectors select,.visual-selectors input,.wipe-control input{min-height:2.5rem}.visual-selectors select{max-width:24rem;border:1px solid var(--line-strong);border-radius:var(--radius);padding:.5rem .65rem;background:var(--paper-raised);color:var(--ink)}.visual-slider{margin-left:auto}.visual-mode-control{display:flex;flex-wrap:wrap;gap:.35rem;margin-bottom:1rem}.visual-mode-control button,.region-list button,.finding-list button,.hunk-actions button{min-height:2rem;border:1px solid var(--line-strong);border-radius:var(--radius);padding:.42rem .65rem;background:transparent;color:var(--ink);cursor:pointer;font-size:.7rem;font-weight:700}.visual-mode-control button[aria-pressed=true]{background:var(--ink);color:var(--paper-raised)}.visual-mode-control button:disabled{cursor:not-allowed;opacity:.55}.persistent-error,.verification-gap{display:flex;gap:.7rem;align-items:baseline;margin:0 0 1rem;border-left:.3rem solid var(--amber);padding:.85rem 1rem;background:var(--amber-soft);color:var(--amber);font-size:.8rem}.persistent-error strong,.verification-gap strong{letter-spacing:.08em}.visual-metrics{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));margin:0 0 .8rem;border:1px solid var(--line)}.visual-metrics div{padding:.65rem .8rem;border-right:1px solid var(--line)}.visual-metrics div:last-child{border-right:0}.visual-metrics dt{color:var(--ink-muted);font-size:.64rem}.visual-metrics dd{margin:.25rem 0 0;font:700 .82rem/1.2 ui-monospace,SFMono-Regular,Menlo,monospace}.visual-panes{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.8rem}.visual-panes figure,.single-visual{min-width:0;margin:0}.visual-panes figcaption,.single-visual figcaption{border:1px solid var(--line-strong);border-bottom:0;padding:.5rem .7rem;background:var(--rail);color:var(--ink);font-size:.7rem;font-weight:720}.visual-scroll{overflow:auto;max-height:32rem;min-height:12rem;border:1px solid var(--line-strong);background:linear-gradient(45deg,color-mix(in srgb,var(--line) 25%,transparent) 25%,transparent 25%) 0 0 / 1rem 1rem,linear-gradient(45deg,transparent 75%,color-mix(in srgb,var(--line) 25%,transparent) 75%) 0 0 / 1rem 1rem,var(--paper-raised);overscroll-behavior:contain}.image-stage{position:relative;min-width:20rem}.image-stage img{display:block;width:100%;height:auto}.wipe-after,.blink-after{position:absolute;inset:0}.blink-after{opacity:0}.blink-after.blink-running{animation:utsuri-blink 1s steps(1,end) infinite}@keyframes utsuri-blink{0%,49%{opacity:0}50%,to{opacity:1}}.pixel-diff-view .visual-scroll{background-color:#16191e}.region-marker{position:absolute;display:grid;min-width:1.5rem;min-height:1.5rem;place-items:center;border:2px solid #fff;border-radius:0;padding:0;background:#b73f2d4d;box-shadow:0 0 0 2px var(--coral);color:#fff;font-size:.65rem;font-weight:800;pointer-events:none}.region-marker.active-region{border-width:4px;background:#b73f2d7f}.visual-comment-pin{position:absolute;z-index:4;display:grid;width:2rem;height:2rem;place-items:center;transform:translate(-50%,-50%);border:2px solid #fff;border-radius:50%;padding:0;background:var(--blue);box-shadow:0 0 0 3px #0e1117a6;color:#fff;font-size:.72rem;font-weight:820}.visual-comment-pin:hover{background:var(--coral)}.wipe-control{width:min(100%,28rem);margin:0 0 .75rem}.region-list,.finding-list{margin-top:1rem;border-top:1px solid var(--line);padding-top:1rem}.region-list h4,.finding-list h4{margin:0 0 .65rem;font-size:.82rem}.region-list ol,.finding-list ol{display:grid;gap:.5rem;margin:0;padding:0;list-style:none}.region-list ol{grid-template-columns:repeat(auto-fit,minmax(14rem,1fr))}.region-list button{width:100%;text-align:left}.region-actions{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:.35rem}.region-list button[aria-current=true]{border-color:var(--coral);box-shadow:inset .22rem 0 var(--coral)}.finding-list article{border:1px solid var(--line);padding:1rem;background:color-mix(in srgb,var(--paper) 55%,var(--paper-raised))}.finding-list article.active-finding{border-color:var(--blue)}.finding-list h5{margin:.65rem 0 .35rem;overflow-wrap:anywhere;font-size:.95rem}.finding-list p{margin:0 0 .8rem;color:var(--ink-muted);font-size:.82rem;line-height:1.5}.finding-badges{display:flex;flex-wrap:wrap;gap:.35rem}.finding-badges span{border:1px solid var(--line-strong);border-radius:99px;padding:.15rem .45rem;font-size:.63rem;font-weight:720;text-transform:uppercase}.hunk-actions{display:flex;flex-shrink:0;gap:.5rem;align-items:center}.hunk-actions button{border-color:#707987;color:#d8e3ff}.evidence-section,.diff-section{padding-top:2.2rem}.section-heading{display:flex;align-items:end;justify-content:space-between;gap:1.5rem;margin-bottom:1rem}.section-heading h3{font-size:clamp(1.35rem,2.5vw,2rem)}.evidence-list{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:.75rem;margin:0;padding:0;list-style:none}.evidence-list li{min-width:0;border:1px solid var(--line);padding:1rem;background:color-mix(in srgb,var(--blue-soft) 35%,transparent)}.evidence-list span{display:block;color:var(--blue);font-size:.64rem;font-weight:780;letter-spacing:.08em;text-transform:uppercase}.evidence-list strong{display:block;overflow-wrap:anywhere;margin-top:.55rem;font:.77rem/1.4 ui-monospace,SFMono-Regular,Menlo,monospace}.evidence-list p{margin:.55rem 0 0;color:var(--ink-muted);font-size:.78rem;line-height:1.45}.more-evidence{margin-top:.8rem}.segmented-control{display:inline-flex;border:1px solid var(--line-strong);border-radius:var(--radius);overflow:hidden}.segmented-control button{border:0;border-right:1px solid var(--line-strong);padding:.48rem .72rem;background:transparent;color:var(--ink-muted);cursor:pointer;font-size:.7rem;font-weight:700}.segmented-control button:last-child{border-right:0}.segmented-control button[aria-pressed=true]{background:var(--ink);color:var(--paper-raised)}.hunk{overflow:hidden;margin-top:1rem;border:1px solid #555c66;border-radius:var(--radius);background:var(--code-bg);color:var(--code-text)}.hunk.active-hunk{box-shadow:0 0 0 4px var(--focus)}.hunk>header{display:flex;align-items:center;justify-content:space-between;gap:1rem;padding:.75rem 1rem;border-bottom:1px solid #555c66;background:#292e36}.hunk>header p,.hunk>header h4,.hunk>header h3{margin:0;overflow-wrap:anywhere;font:.72rem/1.45 ui-monospace,SFMono-Regular,Menlo,monospace}.hunk>header p{color:#d6d9de;font-weight:760}.hunk>header h4{color:var(--code-muted);font-weight:500}.anchor-button{min-width:2rem;min-height:2rem;color:#9bbaff;font:700 1rem/1 ui-monospace,SFMono-Regular,Menlo,monospace}.hunk-explanation{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));margin:0;border-bottom:1px solid #555c66;background:#20262e}.hunk-explanation div{padding:.85rem 1rem .95rem}.hunk-explanation div+div{border-left:1px solid #555c66}.hunk-explanation dt{margin-bottom:.3rem;color:#a9bce9;font-size:.68rem;font-weight:800;letter-spacing:.08em;text-transform:uppercase}.hunk-explanation dd{margin:0;color:#f2f5fb;font-size:.84rem;line-height:1.55;overflow-wrap:anywhere}.diff-table{overflow-x:auto;font:.76rem/1.55 ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;font-variant-ligatures:none}.diff-line{display:grid;grid-template-columns:3.4rem 3.4rem 1.4rem minmax(max-content,1fr) 2.2rem;min-height:1.55rem}.diff-line.addition{background:var(--addition)}.diff-line.deletion{background:var(--deletion)}.diff-line.no-newline{color:var(--code-muted);font-style:italic}.line-number{padding:0 .65rem;border-right:1px solid rgb(255 255 255 / 8%);color:var(--code-muted);text-align:right;-webkit-user-select:none;user-select:none}.line-sign{color:var(--code-muted);text-align:center;-webkit-user-select:none;user-select:none}.diff-line code{padding:0 .75rem 0 0;white-space:pre}.word-change{border-radius:.12rem;background:var(--word-addition);box-shadow:0 0 0 .08rem var(--word-addition)}.deletion .word-change{background:var(--word-deletion);box-shadow:0 0 0 .08rem var(--word-deletion)}.context-fold{width:100%;border:0;border-top:1px solid #3a4049;border-bottom:1px solid #3a4049;padding:.4rem;background:#252a31;color:#a9c0ef;cursor:pointer;font:inherit;text-align:center}.split-row{display:grid;grid-template-columns:repeat(2,minmax(max-content,1fr)) 2.2rem;border-bottom:1px solid rgb(255 255 255 / 5%)}.split-row .diff-line{grid-template-columns:3.4rem 1.4rem minmax(max-content,1fr)}.split-row .diff-line:first-child{border-right:1px solid #555c66}.empty-side{background:#171a1f!important}.line-comment{position:sticky;right:0;min-width:2.2rem;border:0;border-left:1px solid rgb(255 255 255 / 14%);background:#292e36;color:#b8ccff;cursor:pointer;font:700 .82rem/1 ui-monospace,SFMono-Regular,Menlo,monospace}.line-comment:hover{background:#384252;color:#fff}.review-comments{margin-top:2.2rem;border-top:2px solid var(--ink);padding-top:2.2rem}.comment-composer{display:grid;grid-template-columns:minmax(0,1fr) 11rem;gap:.9rem 1rem;margin-bottom:1rem;border:1px solid var(--line-strong);border-left:.35rem solid var(--blue);padding:1rem;background:var(--paper)}.comment-composer code{overflow-wrap:anywhere;font-size:.74rem}.comment-body,.agent-attention-control,.comment-composer>p,.comment-actions{grid-column:1 / -1}.comment-composer textarea{width:100%;resize:vertical;line-height:1.5}.comment-composer>p,.empty-comments{margin:0;color:var(--ink-muted);font-size:.75rem}.agent-attention-control{grid-template-columns:1.15rem minmax(0,1fr);align-items:center;border:1px solid var(--line);border-radius:var(--radius);padding:.65rem .75rem;background:var(--blue-soft);color:var(--ink);font-size:.78rem;font-weight:720}.agent-attention-control small{grid-column:2;color:var(--ink-muted);font-size:.68rem;font-weight:500}.compact-attention{display:inline-grid;margin-top:.4rem;padding:.45rem .55rem}.attention-state{color:var(--blue);font-size:.72rem!important;font-weight:720}.feedback-dock{position:fixed;z-index:20;right:1rem;bottom:1rem;width:min(44rem,calc(100vw - 22rem));max-height:min(70vh,42rem);overflow:auto;border:1px solid var(--line-strong);border-top:.35rem solid var(--blue);border-radius:var(--radius);padding:.9rem 1rem;background:var(--paper-raised);box-shadow:0 1.1rem 3rem #141e2d33}.feedback-dock>header,.feedback-dock>header>div,.feedback-actions{display:flex;flex-wrap:wrap;gap:.55rem;align-items:center}.feedback-dock>header{justify-content:space-between}.unread-badge{border-radius:999px;padding:.25rem .5rem;background:var(--blue);color:#fff;font-size:.68rem;font-weight:750}.feedback-preview{margin-top:.8rem;border-top:1px solid var(--line);padding-top:.8rem}.feedback-preview h2,.feedback-preview h3,.feedback-preview p{margin:0}.feedback-preview h2{font-size:.95rem}.feedback-preview ol{display:grid;gap:.35rem;margin:.65rem 0;padding-left:1.3rem}.feedback-preview li{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:.2rem .7rem;font-size:.75rem}.feedback-preview li code{overflow-wrap:anywhere;color:var(--ink-muted);font-size:.66rem}.feedback-preview li span{grid-row:1 / 3;grid-column:2;color:var(--ink-muted);font-size:.64rem;text-transform:uppercase}.feedback-preview-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:.55rem}.feedback-preview-grid section{border:1px solid var(--line);padding:.6rem;background:var(--paper)}.feedback-preview-grid h3{margin-bottom:.25rem;font-size:.7rem}.feedback-preview-grid p,.feedback-warning{color:var(--ink-muted);font-size:.66rem;line-height:1.45}.feedback-warning{margin-top:.55rem!important;color:var(--amber)}.feedback-actions{margin-top:.65rem}.feedback-preview pre{overflow:auto;margin:.65rem 0 0;border:1px solid var(--line);padding:.65rem;background:var(--paper);white-space:pre-wrap;font-size:.67rem}.thread-list{display:grid;gap:.65rem;margin:0;padding:0;list-style:none}.thread-list li{border:1px solid var(--line);padding:.9rem 1rem;background:color-mix(in srgb,var(--paper) 60%,var(--paper-raised))}.thread-list li[data-thread-state=stale],.thread-list li[data-thread-state=orphaned]{border-left:.35rem solid var(--amber);background:var(--amber-soft)}.thread-list header{display:flex;justify-content:space-between;gap:1rem;color:var(--ink-muted);font-size:.66rem;text-transform:uppercase}.thread-list header div{display:flex;gap:.45rem}.thread-list code{display:block;overflow-wrap:anywhere;margin-top:.5rem;color:var(--ink-muted);font-size:.68rem}.thread-list p{margin:.65rem 0;white-space:pre-wrap;font-size:.86rem;line-height:1.55}.hunk-back{margin:.75rem 1rem;color:#9bbaff}.loading{margin:3rem;color:var(--ink-muted)}.empty-focus{min-height:12rem}@media(max-width:1100px){.report-shell{grid-template-columns:16rem minmax(0,1fr)}.report-header{grid-template-columns:16rem 1fr}.report-id{display:none}.decision-summary{grid-template-columns:1fr}.review-route{border-top:1px solid var(--line-strong);border-left:0;padding-top:1.25rem;padding-left:0}.review-route button{margin-top:1.5rem}.coverage-overview{grid-template-columns:1fr}.metrics{grid-template-columns:repeat(5,minmax(5rem,1fr));overflow-x:auto}.evidence-list{grid-template-columns:1fr}}@media(max-width:760px){.report-shell{display:block}.report-header{position:sticky;display:flex;min-height:3.75rem}.wordmark{border-right:0}.report-state{margin-left:auto;padding-right:1rem}.report-state small{display:none}.review-rail{position:static;width:100%;height:auto;max-height:26rem;border-right:0;border-bottom:1px solid var(--line-strong)}main{padding:.8rem}.feedback-dock{right:.5rem;bottom:.5rem;left:.5rem;width:auto}.feedback-preview-grid{grid-template-columns:1fr}.decision-summary,.focused-change{box-shadow:none}.change-header{display:block}.change-badges{justify-content:start;margin-top:1rem}.review-map button{grid-template-columns:2rem minmax(0,1fr);gap:.7rem}.map-meta{grid-column:2;flex-wrap:wrap;white-space:normal}.explanation-grid{display:block}.explanation-grid section,.explanation-grid section:nth-child(2n){padding:1.15rem 0;border-left:0}.risk-block,.gap-block{padding-left:1rem!important}.section-heading{display:block}.coverage-overview dl,.visual-metrics{grid-template-columns:repeat(2,minmax(0,1fr))}.coverage-overview dl div:nth-child(3),.visual-metrics div:nth-child(3){border-top:1px solid var(--line)}.visual-panes{grid-template-columns:1fr}.visual-slider{margin-left:0}.visual-mode-control button{flex:1 1 8rem}.segmented-control{margin-top:.8rem}.hunk-explanation{grid-template-columns:1fr}.hunk-explanation div+div{border-top:1px solid #555c66;border-left:0}.file-inventory li{grid-template-columns:1fr;gap:.25rem}.review-workspace-heading,.comment-composer{display:block}.review-transfer-actions,.review-controls,.comment-composer label,.comment-actions{margin-top:.75rem}.region-actions{grid-template-columns:1fr}}@media(prefers-reduced-motion:reduce){*,*:before,*:after{scroll-behavior:auto!important;transition-duration:.01ms!important;animation-duration:.01ms!important}.blink-after.blink-running{animation:none!important;opacity:1}}@media print{.review-rail,.segmented-control,.back-link,.anchor-button,.visual-mode-control,.visual-selectors,.wipe-control,.region-list,.review-transfer-actions,.review-controls,.comment-composer,.line-comment{display:none!important}.report-shell,.report-header{display:block}main{padding:0}.decision-summary,.focused-change{border:0;box-shadow:none}}.feedback-dock.collapsed{width:min(24rem,calc(100vw - 2rem));max-height:9rem;padding:.55rem .75rem}.answer-message[data-unread=true]{border-left:.2rem solid var(--blue);padding-left:.6rem}.priority-help,.priority-reason,.human-status{font-size:.75rem;line-height:1.5;color:var(--ink-muted)}.priority-help{margin:.7rem 0}.range-line{border:0;border-radius:0;background:transparent;color:inherit;cursor:pointer;font:inherit;padding:0}.range-line.range-selected{background:#386ee5;color:#fff}.range-help{font-size:.8rem;color:var(--ink-muted)}.registered-checks{margin:1rem 0;border:1px solid var(--line);border-radius:var(--radius);padding:1rem}.registered-checks>p{font-size:.8rem;color:var(--ink-muted)}.registered-checks ol{padding-left:1.2rem}.registered-checks li{padding:.6rem 0}.registered-checks span,.registered-checks code{display:block;overflow-wrap:anywhere;font-size:.75rem}.registered-checks dl{display:flex;flex-wrap:wrap;gap:.7rem;font-size:.75rem}.registered-checks dd{margin:0;overflow-wrap:anywhere}\n';
|
|
220033
220256
|
|
|
220034
220257
|
// packages/report-builder/src/native-publish.ts
|
|
220035
220258
|
import { spawn as spawn6 } from "node:child_process";
|
|
@@ -220190,10 +220413,10 @@ function reportText(language, english, japanese) {
|
|
|
220190
220413
|
}
|
|
220191
220414
|
var generatedPreComparisonGaps = {
|
|
220192
220415
|
"Visual behavior was not captured.": true,
|
|
220193
|
-
"
|
|
220416
|
+
"Application E2E and external integrations are not established by browser evidence.": true,
|
|
220194
220417
|
"Captured evidence has not been compared or mapped to this change.": true,
|
|
220195
220418
|
"画面上の挙動は取得されていません。": true,
|
|
220196
|
-
"
|
|
220419
|
+
"アプリのE2E・外部連携はブラウザ根拠による検証がありません。": true,
|
|
220197
220420
|
"取得済みの根拠は、この変更との比較または対応付けが完了していません。": true
|
|
220198
220421
|
};
|
|
220199
220422
|
function indexHtml(report) {
|
|
@@ -220445,7 +220668,7 @@ function createCandidateChanges(diff2, plan, language) {
|
|
|
220445
220668
|
] : [
|
|
220446
220669
|
reportText(
|
|
220447
220670
|
language,
|
|
220448
|
-
"
|
|
220671
|
+
"Application behavior, external integrations and visual effects have no browser verification.",
|
|
220449
220672
|
"実行時および画面上の影響は検証されていません。"
|
|
220450
220673
|
)
|
|
220451
220674
|
]
|
|
@@ -220469,8 +220692,8 @@ function createCandidateChanges(diff2, plan, language) {
|
|
|
220469
220692
|
),
|
|
220470
220693
|
reportText(
|
|
220471
220694
|
language,
|
|
220472
|
-
"
|
|
220473
|
-
"
|
|
220695
|
+
"Application E2E and external integrations are not established by browser evidence.",
|
|
220696
|
+
"アプリのE2E・外部連携はブラウザ根拠による検証がありません。"
|
|
220474
220697
|
)
|
|
220475
220698
|
]
|
|
220476
220699
|
}
|
|
@@ -220924,6 +221147,7 @@ function reportArtifactReferences(report) {
|
|
|
220924
221147
|
const references = [
|
|
220925
221148
|
...captureReferences,
|
|
220926
221149
|
...rasterReferences,
|
|
221150
|
+
...(report.verificationResults ?? []).map((result2) => result2.logRef),
|
|
220927
221151
|
...report.evidence.filter((evidence) => evidence.type !== "visual").map((evidence) => evidence.path).filter(
|
|
220928
221152
|
(reference) => reference.startsWith("capture/") || reference.startsWith("comparison/")
|
|
220929
221153
|
)
|
|
@@ -220931,6 +221155,7 @@ function reportArtifactReferences(report) {
|
|
|
220931
221155
|
for (const reference of references) {
|
|
220932
221156
|
try {
|
|
220933
221157
|
if (rasterReferences.includes(reference)) assertRasterImageReference(reference);
|
|
221158
|
+
else if (reference.startsWith("verification/")) assertVerificationLogReference(reference);
|
|
220934
221159
|
else assertSafeReportAssetReference(reference);
|
|
220935
221160
|
} catch (error) {
|
|
220936
221161
|
throw new UtsuriError(
|
|
@@ -221259,8 +221484,8 @@ function createCodeOnlyReport(input, diff2, evidenceIndex, plan, annotations, ca
|
|
|
221259
221484
|
),
|
|
221260
221485
|
reportText(
|
|
221261
221486
|
language,
|
|
221262
|
-
"
|
|
221263
|
-
"
|
|
221487
|
+
"Application E2E and external integrations are not established by browser evidence.",
|
|
221488
|
+
"アプリのE2E・外部連携はブラウザ根拠による検証がありません。"
|
|
221264
221489
|
)
|
|
221265
221490
|
])
|
|
221266
221491
|
]
|
|
@@ -221286,8 +221511,8 @@ function createCodeOnlyReport(input, diff2, evidenceIndex, plan, annotations, ca
|
|
|
221286
221511
|
"コード変更を収集しましたが、ブラウザ根拠は未完了です。"
|
|
221287
221512
|
) : reportText(
|
|
221288
221513
|
language,
|
|
221289
|
-
"Code changes were collected and grouped. Visual and
|
|
221290
|
-
"
|
|
221514
|
+
"Code changes were collected and grouped. Visual comparison, application E2E and external integrations have no browser verification. Registered checks are shown separately.",
|
|
221515
|
+
"コード変更を収集してグループ化しました。画面比較・アプリのE2E・外部連携はブラウザ根拠による検証がありません。登録した検証結果は別に表示します。"
|
|
221291
221516
|
),
|
|
221292
221517
|
filesChanged: diff2.summary.filesChanged,
|
|
221293
221518
|
additions: diff2.summary.additions,
|
|
@@ -221338,6 +221563,50 @@ function createCodeOnlyReport(input, diff2, evidenceIndex, plan, annotations, ca
|
|
|
221338
221563
|
}
|
|
221339
221564
|
};
|
|
221340
221565
|
}
|
|
221566
|
+
async function integrateVerificationResults(runDirectory, report, input, annotations, artifactDigests2) {
|
|
221567
|
+
if (!annotations?.verificationResults) return { report, artifactDigests: artifactDigests2 };
|
|
221568
|
+
const ids = /* @__PURE__ */ new Set();
|
|
221569
|
+
const digests = { ...artifactDigests2 };
|
|
221570
|
+
const results = [];
|
|
221571
|
+
const subject = isRecord6(input) && typeof input.head === "string" && /^[a-f0-9]{40}(?:[a-f0-9]{24})?$/u.test(input.head) ? input.head : null;
|
|
221572
|
+
for (const result2 of annotations.verificationResults) {
|
|
221573
|
+
if (ids.has(result2.id) || result2.changeRefs.some((ref) => !report.changes.some((change) => change.id === ref)) || result2.exitCode !== null && result2.completedAt === null) {
|
|
221574
|
+
throw new UtsuriError(
|
|
221575
|
+
"VERIFICATION_RESULT_INVALID",
|
|
221576
|
+
"Verification result identity, scope or completion is invalid",
|
|
221577
|
+
ExitCode.Artifact
|
|
221578
|
+
);
|
|
221579
|
+
}
|
|
221580
|
+
ids.add(result2.id);
|
|
221581
|
+
if (result2.logRef) {
|
|
221582
|
+
assertVerificationLogReference(result2.logRef);
|
|
221583
|
+
const bytes = await readRegularBytes(await resolveContainedPath(runDirectory, result2.logRef));
|
|
221584
|
+
let validUtf8 = true;
|
|
221585
|
+
try {
|
|
221586
|
+
new TextDecoder("utf-8", { fatal: true }).decode(bytes);
|
|
221587
|
+
} catch {
|
|
221588
|
+
validUtf8 = false;
|
|
221589
|
+
}
|
|
221590
|
+
if (!validUtf8 || bytes.includes(0) || sha2563(bytes) !== result2.logSha256) {
|
|
221591
|
+
throw new UtsuriError(
|
|
221592
|
+
"VERIFICATION_LOG_INVALID",
|
|
221593
|
+
"Verification log is not text or its SHA-256 differs",
|
|
221594
|
+
ExitCode.Artifact
|
|
221595
|
+
);
|
|
221596
|
+
}
|
|
221597
|
+
digests[result2.logRef] = result2.logSha256;
|
|
221598
|
+
}
|
|
221599
|
+
results.push({
|
|
221600
|
+
...result2,
|
|
221601
|
+
provenance: result2.logRef ? "log-attached" : "reported",
|
|
221602
|
+
shaMatch: subject && result2.subjectSha ? subject === result2.subjectSha ? "match" : "mismatch" : "unknown"
|
|
221603
|
+
});
|
|
221604
|
+
}
|
|
221605
|
+
return {
|
|
221606
|
+
report: { ...report, verificationSubjectSha: subject, verificationResults: results },
|
|
221607
|
+
artifactDigests: immutableJsonSnapshot(digests)
|
|
221608
|
+
};
|
|
221609
|
+
}
|
|
221341
221610
|
async function reconstructReportFromSourceSnapshot(runDirectory, source12, annotations) {
|
|
221342
221611
|
const input = source12.values["input.json"];
|
|
221343
221612
|
const diffValue = source12.values["diff.json"];
|
|
@@ -221395,7 +221664,16 @@ async function reconstructReportFromSourceSnapshot(runDirectory, source12, annot
|
|
|
221395
221664
|
discovery
|
|
221396
221665
|
);
|
|
221397
221666
|
assertReferenceResult("REPORT_REFERENCE_INVALID", validateReportReferences(report2));
|
|
221398
|
-
return {
|
|
221667
|
+
return {
|
|
221668
|
+
...await integrateVerificationResults(
|
|
221669
|
+
runDirectory,
|
|
221670
|
+
report2,
|
|
221671
|
+
input,
|
|
221672
|
+
annotations,
|
|
221673
|
+
artifactDigests2
|
|
221674
|
+
),
|
|
221675
|
+
sourceSnapshotHash
|
|
221676
|
+
};
|
|
221399
221677
|
}
|
|
221400
221678
|
if (annotations?.changes.length) {
|
|
221401
221679
|
throw new UtsuriError(
|
|
@@ -221424,6 +221702,7 @@ async function reconstructReportFromSourceSnapshot(runDirectory, source12, annot
|
|
|
221424
221702
|
const reportId = `report-${stableHash({
|
|
221425
221703
|
input,
|
|
221426
221704
|
...annotations ? { language } : {},
|
|
221705
|
+
...annotations?.verificationResults ? { verificationResults: annotations.verificationResults } : {},
|
|
221427
221706
|
...capture ? { capture } : {}
|
|
221428
221707
|
}).slice(0, 16)}`;
|
|
221429
221708
|
const report = {
|
|
@@ -221478,7 +221757,16 @@ async function reconstructReportFromSourceSnapshot(runDirectory, source12, annot
|
|
|
221478
221757
|
}
|
|
221479
221758
|
};
|
|
221480
221759
|
assertReferenceResult("REPORT_REFERENCE_INVALID", validateReportReferences(report));
|
|
221481
|
-
return {
|
|
221760
|
+
return {
|
|
221761
|
+
...await integrateVerificationResults(
|
|
221762
|
+
runDirectory,
|
|
221763
|
+
report,
|
|
221764
|
+
input,
|
|
221765
|
+
annotations,
|
|
221766
|
+
artifactDigests2
|
|
221767
|
+
),
|
|
221768
|
+
sourceSnapshotHash
|
|
221769
|
+
};
|
|
221482
221770
|
}
|
|
221483
221771
|
async function createInitialReport(runDirectory, annotationsValue = null) {
|
|
221484
221772
|
let annotations = null;
|
|
@@ -222017,6 +222305,16 @@ async function validateReportDirectory(input, options2 = {}) {
|
|
|
222017
222305
|
}
|
|
222018
222306
|
}
|
|
222019
222307
|
if (report) {
|
|
222308
|
+
for (const result2 of report.verificationResults ?? []) {
|
|
222309
|
+
const subject = report.verificationSubjectSha;
|
|
222310
|
+
const expectedMatch = subject && result2.subjectSha ? subject === result2.subjectSha ? "match" : "mismatch" : "unknown";
|
|
222311
|
+
if (result2.shaMatch !== expectedMatch)
|
|
222312
|
+
errors2.push(`Verification SHA classification mismatch: ${result2.id}`);
|
|
222313
|
+
if (result2.provenance !== (result2.logRef ? "log-attached" : "reported"))
|
|
222314
|
+
errors2.push(`Verification provenance mismatch: ${result2.id}`);
|
|
222315
|
+
if (result2.logRef && result2.logSha256 !== manifest.assetHashes[result2.logRef])
|
|
222316
|
+
errors2.push(`Verification log hash mismatch: ${result2.id}`);
|
|
222317
|
+
}
|
|
222020
222318
|
if (manifest.reportId !== report.reportId) errors2.push("Manifest reportId mismatch");
|
|
222021
222319
|
if (manifest.semanticHash !== stableHash({
|
|
222022
222320
|
report,
|
|
@@ -222191,6 +222489,51 @@ async function buildAnchorCatalog(report, digest) {
|
|
|
222191
222489
|
(left, right) => `${left.type}\0${left.ref}`.localeCompare(`${right.type}\0${right.ref}`)
|
|
222192
222490
|
);
|
|
222193
222491
|
}
|
|
222492
|
+
async function buildLineRangeAnchor(report, hunkId2, side, startLine, endLine, digest) {
|
|
222493
|
+
const hunk = report.hunks.find((entry) => entry.id === hunkId2);
|
|
222494
|
+
if (!hunk || side !== "before" && side !== "after" || !Number.isSafeInteger(startLine) || !Number.isSafeInteger(endLine) || startLine < 1 || endLine < startLine || endLine - startLine > 1e3)
|
|
222495
|
+
return void 0;
|
|
222496
|
+
const lines = hunk.lines.filter((line) => {
|
|
222497
|
+
const number = side === "before" ? line.oldLine : line.newLine;
|
|
222498
|
+
return line.kind !== "no-newline" && number !== null && number !== void 0 && number >= startLine && number <= endLine;
|
|
222499
|
+
});
|
|
222500
|
+
if (lines.length !== endLine - startLine + 1 || lines.some(
|
|
222501
|
+
(line, index) => (side === "before" ? line.oldLine : line.newLine) !== startLine + index
|
|
222502
|
+
))
|
|
222503
|
+
return void 0;
|
|
222504
|
+
return anchor(
|
|
222505
|
+
digest,
|
|
222506
|
+
{
|
|
222507
|
+
type: "line-range",
|
|
222508
|
+
ref: `${hunk.id}:range:${side}:${startLine}:${endLine}`,
|
|
222509
|
+
path: hunk.path,
|
|
222510
|
+
side,
|
|
222511
|
+
startLine,
|
|
222512
|
+
endLine
|
|
222513
|
+
},
|
|
222514
|
+
{ path: hunk.path, side, startLine, endLine, lines: lines.map((line) => line.content) }
|
|
222515
|
+
);
|
|
222516
|
+
}
|
|
222517
|
+
async function resolveLineRangeAnchor(report, ref, digest) {
|
|
222518
|
+
const match = ref.match(/^(.*):range:(before|after):(\d+):(\d+)$/u);
|
|
222519
|
+
return match ? buildLineRangeAnchor(
|
|
222520
|
+
report,
|
|
222521
|
+
match[1],
|
|
222522
|
+
match[2],
|
|
222523
|
+
Number(match[3]),
|
|
222524
|
+
Number(match[4]),
|
|
222525
|
+
digest
|
|
222526
|
+
) : void 0;
|
|
222527
|
+
}
|
|
222528
|
+
async function includeLineRangeAnchors(report, catalog, sources, digest) {
|
|
222529
|
+
const result2 = new Map(catalog.map((entry) => [anchorKey(entry), entry]));
|
|
222530
|
+
for (const source12 of sources) {
|
|
222531
|
+
if (source12.type !== "line-range") continue;
|
|
222532
|
+
const current = await resolveLineRangeAnchor(report, source12.ref, digest);
|
|
222533
|
+
if (current) result2.set(anchorKey(current), current);
|
|
222534
|
+
}
|
|
222535
|
+
return [...result2.values()];
|
|
222536
|
+
}
|
|
222194
222537
|
async function buildLegacyVisualAnchorCatalog(report, digest) {
|
|
222195
222538
|
const pending = [];
|
|
222196
222539
|
for (const comparison of report.comparisons) {
|
|
@@ -222435,6 +222778,15 @@ async function setJudgment(store, changeId, judgmentState, updatedAt, digest = n
|
|
|
222435
222778
|
return { ...store, state, events: [...store.events, event] };
|
|
222436
222779
|
}
|
|
222437
222780
|
async function createHumanComment(store, anchor2, body, kind, createdAt, digest = nodeReviewDigest, requestAgentAttention = false) {
|
|
222781
|
+
if (anchor2.type === "line-range" && anchor2.ref.includes(":range:")) {
|
|
222782
|
+
const canonical = await resolveLineRangeAnchor(store.report, anchor2.ref, digest);
|
|
222783
|
+
if (!canonical || canonicalReviewJson(canonical) !== canonicalReviewJson(anchor2))
|
|
222784
|
+
throw new UtsuriError(
|
|
222785
|
+
"REVIEW_RANGE_INVALID",
|
|
222786
|
+
"Review line range is invalid",
|
|
222787
|
+
ExitCode.Artifact
|
|
222788
|
+
);
|
|
222789
|
+
}
|
|
222438
222790
|
requireIsoDate(createdAt);
|
|
222439
222791
|
const normalizedBody = requireCommentBody(body);
|
|
222440
222792
|
const identity = { reportId: store.report.reportId, anchor: anchor2, kind, normalizedBody, createdAt };
|
|
@@ -222603,6 +222955,15 @@ async function importReviewBundle(current, bundle, options2) {
|
|
|
222603
222955
|
throw new UtsuriError("REVIEW_BUNDLE_INVALID", validation.errors.join("; "), ExitCode.Artifact);
|
|
222604
222956
|
}
|
|
222605
222957
|
const sourceBundle = migratedBundle;
|
|
222958
|
+
current = {
|
|
222959
|
+
...current,
|
|
222960
|
+
anchorCatalog: await includeLineRangeAnchors(
|
|
222961
|
+
current.report,
|
|
222962
|
+
current.anchorCatalog,
|
|
222963
|
+
sourceBundle.threads.map((thread) => thread.anchor),
|
|
222964
|
+
digest
|
|
222965
|
+
)
|
|
222966
|
+
};
|
|
222606
222967
|
if (!exactReport && !options2.reanchor) {
|
|
222607
222968
|
throw new UtsuriError(
|
|
222608
222969
|
"REVIEW_REPORT_MISMATCH",
|
|
@@ -223288,8 +223649,8 @@ async function buildContextPack(input) {
|
|
|
223288
223649
|
...semanticChange ? { semanticChange } : {},
|
|
223289
223650
|
code: hunks.map((hunk) => ({
|
|
223290
223651
|
path: assertReportPath(hunk.path),
|
|
223291
|
-
startLine: Math.max(1, hunk.newStart || hunk.oldStart),
|
|
223292
|
-
endLine: Math.max(
|
|
223652
|
+
startLine: item.anchor.type === "line-range" ? item.anchor.startLine : Math.max(1, hunk.newStart || hunk.oldStart),
|
|
223653
|
+
endLine: item.anchor.type === "line-range" ? item.anchor.endLine : Math.max(
|
|
223293
223654
|
1,
|
|
223294
223655
|
(hunk.newStart || hunk.oldStart) + Math.max(hunk.newLines, hunk.oldLines) - 1
|
|
223295
223656
|
),
|
|
@@ -223366,7 +223727,7 @@ function assertInbox(value2, reportId) {
|
|
|
223366
223727
|
const itemIds = raw.itemIds;
|
|
223367
223728
|
if (typeof raw.batchId !== "string" || !/^fb[-:]/u.test(raw.batchId) || batchIds.has(raw.batchId) || raw.batchFile !== sidecarPath("batches", raw.batchId) || !Array.isArray(itemIds) || itemIds.length < 1 || itemIds.length > 20 || itemIds.some((id) => typeof id !== "string" || !/^item[-:]/u.test(id)) || new Set(itemIds).size !== itemIds.length || !(/* @__PURE__ */ new Set(["draft", "ready", "submitted", "consumed", "answered", "stale"])).has(
|
|
223368
223729
|
String(raw.state)
|
|
223369
|
-
) || typeof raw.createdAt !== "string" || !Number.isFinite(Date.parse(raw.createdAt)) || typeof raw.updatedAt !== "string" || !Number.isFinite(Date.parse(raw.updatedAt)) || raw.claimedBySessionRef !== void 0 && (typeof raw.claimedBySessionRef !== "string" || !/^session:[a-f0-9]{64}$/u.test(raw.claimedBySessionRef)) || !Array.isArray(raw.unreadAnswerItemIds) || raw.unreadAnswerItemIds.some((id) => typeof id !== "string" || !itemIds.includes(id)) || new Set(raw.unreadAnswerItemIds).size !== raw.unreadAnswerItemIds.length || (raw.state === "consumed" || raw.state === "answered") !== (raw.claimedBySessionRef !== void 0) ||
|
|
223730
|
+
) || typeof raw.createdAt !== "string" || !Number.isFinite(Date.parse(raw.createdAt)) || typeof raw.updatedAt !== "string" || !Number.isFinite(Date.parse(raw.updatedAt)) || raw.claimedBySessionRef !== void 0 && (typeof raw.claimedBySessionRef !== "string" || !/^session:[a-f0-9]{64}$/u.test(raw.claimedBySessionRef)) || !Array.isArray(raw.unreadAnswerItemIds) || raw.unreadAnswerItemIds.some((id) => typeof id !== "string" || !itemIds.includes(id)) || new Set(raw.unreadAnswerItemIds).size !== raw.unreadAnswerItemIds.length || (raw.state === "consumed" || raw.state === "answered") !== (raw.claimedBySessionRef !== void 0) || raw.state !== "answered" && raw.unreadAnswerItemIds.length !== 0) {
|
|
223370
223731
|
inboxError("REVIEW_INBOX_INVALID", "Review Inbox entry fields are invalid");
|
|
223371
223732
|
}
|
|
223372
223733
|
batchIds.add(raw.batchId);
|
|
@@ -223898,6 +224259,39 @@ async function postFeedbackAnswers(store, batchId, answers, current, answeredAt,
|
|
|
223898
224259
|
digest
|
|
223899
224260
|
);
|
|
223900
224261
|
}
|
|
224262
|
+
async function setFeedbackAnswerUnread(store, itemId, unread, updatedAt) {
|
|
224263
|
+
const inbox = readReviewInbox(store);
|
|
224264
|
+
const entries = inbox.entries.filter((entry2) => entry2.itemIds.includes(itemId));
|
|
224265
|
+
const entry = entries[0];
|
|
224266
|
+
if (entries.length !== 1 || !entry || entry.state !== "answered") {
|
|
224267
|
+
inboxError("FEEDBACK_ANSWER_MISSING", "Only a saved answer can change read state");
|
|
224268
|
+
}
|
|
224269
|
+
const batch = readBatch(store, entry.batchId, entry);
|
|
224270
|
+
if (!batch.items.some((item) => item.id === itemId && item.state === "answered")) {
|
|
224271
|
+
inboxError("FEEDBACK_ANSWER_MISSING", "Feedback item has no saved answer");
|
|
224272
|
+
}
|
|
224273
|
+
const content = store.sidecarFiles[sidecarPath("answers", itemId)];
|
|
224274
|
+
if (!content) inboxError("FEEDBACK_ANSWER_MISSING", "Feedback answer is missing");
|
|
224275
|
+
const answer = parseBoundedJson(content, { label: "review answer", maximumBytes: 1024 * 1024 });
|
|
224276
|
+
assertArtifact("review-answer", answer);
|
|
224277
|
+
if (answer.itemId !== itemId || answer.batchId !== batch.id) {
|
|
224278
|
+
inboxError("FEEDBACK_ANSWER_BINDING", "Feedback answer belongs to another item");
|
|
224279
|
+
}
|
|
224280
|
+
if (entry.unreadAnswerItemIds.includes(itemId) === unread) return store;
|
|
224281
|
+
entry.unreadAnswerItemIds = unread ? entry.itemIds.filter((id) => id === itemId || entry.unreadAnswerItemIds.includes(id)) : entry.unreadAnswerItemIds.filter((id) => id !== itemId);
|
|
224282
|
+
entry.updatedAt = updatedAt;
|
|
224283
|
+
return appendReviewEvent(
|
|
224284
|
+
store,
|
|
224285
|
+
{
|
|
224286
|
+
type: "answer-read.changed",
|
|
224287
|
+
batchId: batch.id,
|
|
224288
|
+
itemIds: [itemId],
|
|
224289
|
+
answerUnread: unread
|
|
224290
|
+
},
|
|
224291
|
+
updatedAt,
|
|
224292
|
+
{ sidecarFiles: replaceInbox(store.sidecarFiles, inbox) }
|
|
224293
|
+
);
|
|
224294
|
+
}
|
|
223901
224295
|
|
|
223902
224296
|
// packages/review-mcp-server/src/run-registry.ts
|
|
223903
224297
|
import { createHash as createHash8, randomUUID as randomUUID5 } from "node:crypto";
|
|
@@ -224474,7 +224868,7 @@ function exactArguments(value2, required, optional = []) {
|
|
|
224474
224868
|
var ReviewMcpService = class {
|
|
224475
224869
|
toolDefinitions = toolDefinitions;
|
|
224476
224870
|
structuredToolErrors = false;
|
|
224477
|
-
serverInfo = { name: "utsu-ri-review", version: "0.3.
|
|
224871
|
+
serverInfo = { name: "utsu-ri-review", version: "0.3.6" };
|
|
224478
224872
|
#runDirectory;
|
|
224479
224873
|
#report;
|
|
224480
224874
|
#currentSession;
|
|
@@ -224673,7 +225067,7 @@ async function runReviewMcpStdio(service, streams = {}) {
|
|
|
224673
225067
|
result2 = {
|
|
224674
225068
|
protocolVersion: "2025-06-18",
|
|
224675
225069
|
capabilities: { tools: { listChanged: false } },
|
|
224676
|
-
serverInfo: service.serverInfo ?? { name: "utsu-ri-review", version: "0.3.
|
|
225070
|
+
serverInfo: service.serverInfo ?? { name: "utsu-ri-review", version: "0.3.6" }
|
|
224677
225071
|
};
|
|
224678
225072
|
} else if (request3.method === "ping") result2 = {};
|
|
224679
225073
|
else if (request3.method === "tools/list")
|
|
@@ -226018,7 +226412,8 @@ async function loadConfig2(cwd, configValue) {
|
|
|
226018
226412
|
return value2;
|
|
226019
226413
|
}
|
|
226020
226414
|
function dataUri(filename, bytes) {
|
|
226021
|
-
const
|
|
226415
|
+
const extension = path24.extname(filename).toLowerCase();
|
|
226416
|
+
const contentType = extension === ".png" ? "image/png" : [".txt", ".log", ".ndjson"].includes(extension) ? "text/plain;charset=utf-8" : null;
|
|
226022
226417
|
if (!contentType) throw new Error(`Unsupported embedded asset: ${filename}`);
|
|
226023
226418
|
return `data:${contentType};base64,${bytes.toString("base64")}`;
|
|
226024
226419
|
}
|
|
@@ -226053,7 +226448,7 @@ function singleFileDocument(loaded) {
|
|
|
226053
226448
|
}
|
|
226054
226449
|
const replacements = /* @__PURE__ */ new Map();
|
|
226055
226450
|
for (const [name, bytes] of loaded.files) {
|
|
226056
|
-
if (/^(?:capture|comparison)\/.+\.png$/u.test(name)) {
|
|
226451
|
+
if (/^(?:capture|comparison)\/.+\.png$/u.test(name) || /^verification\/.+\.(?:txt|log|ndjson)$/u.test(name)) {
|
|
226057
226452
|
replacements.set(name, dataUri(name, bytes));
|
|
226058
226453
|
}
|
|
226059
226454
|
}
|
|
@@ -226421,6 +226816,9 @@ var contentTypes = /* @__PURE__ */ new Map([
|
|
|
226421
226816
|
[".html", "text/html; charset=utf-8"],
|
|
226422
226817
|
[".js", "text/javascript; charset=utf-8"],
|
|
226423
226818
|
[".json", "application/json; charset=utf-8"],
|
|
226819
|
+
[".txt", "text/plain; charset=utf-8"],
|
|
226820
|
+
[".log", "text/plain; charset=utf-8"],
|
|
226821
|
+
[".ndjson", "text/plain; charset=utf-8"],
|
|
226424
226822
|
[".png", "image/png"]
|
|
226425
226823
|
]);
|
|
226426
226824
|
function serverError(id, message) {
|
|
@@ -226643,12 +227041,12 @@ function requireInteractiveBoundary(request3, expectedOrigin, reportId, capabili
|
|
|
226643
227041
|
);
|
|
226644
227042
|
}
|
|
226645
227043
|
}
|
|
226646
|
-
function anchorFromAction(store, action) {
|
|
227044
|
+
async function anchorFromAction(store, action) {
|
|
226647
227045
|
const input = action.anchor;
|
|
226648
227046
|
if (!isRecord10(input) || !hasExactKeys2(input, ["type", "ref", "fingerprint"]) || typeof input.type !== "string" || typeof input.ref !== "string" || typeof input.fingerprint !== "string") {
|
|
226649
227047
|
throw serverError("INTERACTIVE_ANCHOR_INVALID", "Interactive review anchor is invalid");
|
|
226650
227048
|
}
|
|
226651
|
-
const anchor2 = findAnchor(store.anchorCatalog, input.type, input.ref);
|
|
227049
|
+
const anchor2 = findAnchor(store.anchorCatalog, input.type, input.ref) ?? (input.type === "line-range" ? await resolveLineRangeAnchor(store.report, input.ref, nodeReviewDigest) : void 0);
|
|
226652
227050
|
if (!anchor2 || anchor2.fingerprint !== input.fingerprint) {
|
|
226653
227051
|
throw serverError("INTERACTIVE_ANCHOR_STALE", "Interactive review anchor is stale");
|
|
226654
227052
|
}
|
|
@@ -226665,7 +227063,7 @@ async function applyReviewMutation(store, body, updatedAt) {
|
|
|
226665
227063
|
}
|
|
226666
227064
|
return setViewed(
|
|
226667
227065
|
store,
|
|
226668
|
-
anchorFromAction(store, action),
|
|
227066
|
+
await anchorFromAction(store, action),
|
|
226669
227067
|
action.viewState,
|
|
226670
227068
|
updatedAt
|
|
226671
227069
|
);
|
|
@@ -226687,7 +227085,7 @@ async function applyReviewMutation(store, body, updatedAt) {
|
|
|
226687
227085
|
}
|
|
226688
227086
|
return createHumanComment(
|
|
226689
227087
|
store,
|
|
226690
|
-
anchorFromAction(store, action),
|
|
227088
|
+
await anchorFromAction(store, action),
|
|
226691
227089
|
action.body,
|
|
226692
227090
|
action.kind,
|
|
226693
227091
|
updatedAt,
|
|
@@ -226695,6 +227093,12 @@ async function applyReviewMutation(store, body, updatedAt) {
|
|
|
226695
227093
|
action.requestAgentAttention === true
|
|
226696
227094
|
);
|
|
226697
227095
|
}
|
|
227096
|
+
if (action.type === "answer-read.changed") {
|
|
227097
|
+
if (!hasExactKeys2(action, ["type", "itemId", "unread"]) || typeof action.itemId !== "string" || typeof action.unread !== "boolean") {
|
|
227098
|
+
throw serverError("INTERACTIVE_ACTION_INVALID", "Answer read action is invalid");
|
|
227099
|
+
}
|
|
227100
|
+
return setFeedbackAnswerUnread(store, action.itemId, action.unread, updatedAt);
|
|
227101
|
+
}
|
|
226698
227102
|
if (action.type === "agent-attention.changed") {
|
|
226699
227103
|
if (!hasExactKeys2(action, ["type", "threadId", "requested"]) || typeof action.threadId !== "string" || typeof action.requested !== "boolean") {
|
|
226700
227104
|
throw serverError("INTERACTIVE_ACTION_INVALID", "Agent attention action is invalid");
|
|
@@ -226855,7 +227259,8 @@ async function startInteractiveReportServer(reportDirectory, options2) {
|
|
|
226855
227259
|
reportId: report.reportId,
|
|
226856
227260
|
state: store.state,
|
|
226857
227261
|
threads: store.threads,
|
|
226858
|
-
inbox: readReviewInbox(store)
|
|
227262
|
+
inbox: readReviewInbox(store),
|
|
227263
|
+
batches: listFeedbackBatches(store)
|
|
226859
227264
|
});
|
|
226860
227265
|
return;
|
|
226861
227266
|
}
|
|
@@ -226886,6 +227291,7 @@ async function startInteractiveReportServer(reportDirectory, options2) {
|
|
|
226886
227291
|
state: next.state,
|
|
226887
227292
|
threads: next.threads,
|
|
226888
227293
|
inbox: readReviewInbox(next),
|
|
227294
|
+
batches: listFeedbackBatches(next),
|
|
226889
227295
|
event: next.events.at(-1) ?? null
|
|
226890
227296
|
});
|
|
226891
227297
|
return;
|
|
@@ -226961,7 +227367,8 @@ async function startInteractiveReportServer(reportDirectory, options2) {
|
|
|
226961
227367
|
preview: stored.preview,
|
|
226962
227368
|
state: stored.store.state,
|
|
226963
227369
|
threads: stored.store.threads,
|
|
226964
|
-
inbox: readReviewInbox(stored.store)
|
|
227370
|
+
inbox: readReviewInbox(stored.store),
|
|
227371
|
+
batches: listFeedbackBatches(stored.store)
|
|
226965
227372
|
});
|
|
226966
227373
|
return;
|
|
226967
227374
|
}
|
|
@@ -227487,7 +227894,7 @@ async function readPublishedOrigin(runDirectory) {
|
|
|
227487
227894
|
assertArtifact("report", report);
|
|
227488
227895
|
return structuredClone(report.origin);
|
|
227489
227896
|
}
|
|
227490
|
-
var help = `Utsuri 0.3.
|
|
227897
|
+
var help = `Utsuri 0.3.6
|
|
227491
227898
|
|
|
227492
227899
|
Usage: utsuri <command> [options]
|
|
227493
227900
|
|
|
@@ -227529,10 +227936,10 @@ async function executeCli(argv2, cwd = process.cwd(), environment = process.env)
|
|
|
227529
227936
|
ok: true,
|
|
227530
227937
|
command: "version",
|
|
227531
227938
|
package: "@utsu-ri/cli",
|
|
227532
|
-
version: "0.3.
|
|
227939
|
+
version: "0.3.6",
|
|
227533
227940
|
protocolVersion: "1.1"
|
|
227534
227941
|
},
|
|
227535
|
-
human: "0.3.
|
|
227942
|
+
human: "0.3.6",
|
|
227536
227943
|
json
|
|
227537
227944
|
};
|
|
227538
227945
|
}
|
|
@@ -227616,7 +228023,7 @@ async function executeCli(argv2, cwd = process.cwd(), environment = process.env)
|
|
|
227616
228023
|
publishedOrigin
|
|
227617
228024
|
);
|
|
227618
228025
|
const built = await buildReport(runDirectory, report, {
|
|
227619
|
-
toolVersion: "0.3.
|
|
228026
|
+
toolVersion: "0.3.6",
|
|
227620
228027
|
annotations,
|
|
227621
228028
|
...report.origin.bindingMode === "unbound" ? {} : { origin: report.origin }
|
|
227622
228029
|
});
|
|
@@ -228021,7 +228428,7 @@ function sameRegistration(left, right) {
|
|
|
228021
228428
|
var PluginBrokerMcpService = class {
|
|
228022
228429
|
toolDefinitions = brokerMcpToolDefinitions;
|
|
228023
228430
|
structuredToolErrors = true;
|
|
228024
|
-
serverInfo = { name: "utsu-ri-plugin-broker", version: "0.3.
|
|
228431
|
+
serverInfo = { name: "utsu-ri-plugin-broker", version: "0.3.6" };
|
|
228025
228432
|
#projectRoot;
|
|
228026
228433
|
#environment;
|
|
228027
228434
|
#readRegistrations;
|