diffprism 1.0.0 → 1.2.0

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 CHANGED
@@ -130,6 +130,8 @@ diffprism hook install # Add the gate to this repo's pre-commit hoo
130
130
  diffprism hook uninstall # Remove it
131
131
  ```
132
132
 
133
+ If you ask the agent something while the commit waits, the commit stops and prints each question with the command that answers it (`diffprism reply --session <id> <annotation-id> "…"`). The agent answers, commits again, and the review picks up where it left off — no MCP server needed.
134
+
133
135
  It reviews **staged** changes only, where every other entry point defaults to the whole
134
136
  working copy: a commit contains exactly the index, so unstaged edits aren't part of what
135
137
  is being approved. By default a staged diff of **120+ changed lines** opens a review; anything smaller
@@ -187,6 +189,7 @@ diffprism server status # Check server status
187
189
  diffprism server stop # Stop the server
188
190
  diffprism hook install # Gate commits on a review
189
191
  diffprism hook uninstall # Remove the gate
192
+ diffprism reply --session <id> <annotation-id> "…" # Answer a reviewer's question, as the agent
190
193
  diffprism feedback # Share feedback as a prefilled GitHub issue
191
194
  diffprism feedback --bug # Report a bug, including the last error
192
195
  diffprism teardown # Remove configuration
package/dist/bin.js CHANGED
@@ -5,7 +5,7 @@ import {
5
5
  } from "./chunk-EPU4F7WT.js";
6
6
  import {
7
7
  demo
8
- } from "./chunk-CJ6LV2XV.js";
8
+ } from "./chunk-FONA4U6B.js";
9
9
  import {
10
10
  COMMIT_GATE_DIFF_REF,
11
11
  DEFAULT_DIFF_REF,
@@ -26,7 +26,7 @@ import {
26
26
  recordError,
27
27
  startGlobalServer,
28
28
  submitReviewToServer
29
- } from "./chunk-CU2BAL6Q.js";
29
+ } from "./chunk-F6O5YP3I.js";
30
30
  import {
31
31
  getDiff
32
32
  } from "./chunk-3GMPE2ZR.js";
@@ -40,6 +40,52 @@ import { Command } from "commander";
40
40
  import { execFileSync } from "child_process";
41
41
  import fs from "fs";
42
42
  import path from "path";
43
+
44
+ // cli/src/commands/reply.ts
45
+ function replyCommandFor(sessionId, annotationId) {
46
+ return `diffprism reply --session ${sessionId} ${annotationId} "<your answer>"`;
47
+ }
48
+ async function reply(annotationId, words, flags) {
49
+ const body = words.join(" ").trim();
50
+ if (!body) {
51
+ fail("Nothing to say: pass the reply after the annotation id.");
52
+ return;
53
+ }
54
+ const serverInfo = await isServerAlive();
55
+ if (!serverInfo) {
56
+ fail("No DiffPrism server is running, so there is no open review to reply on.");
57
+ return;
58
+ }
59
+ let response;
60
+ try {
61
+ response = await fetch(
62
+ `http://localhost:${serverInfo.httpPort}/api/reviews/${flags.session}/annotations/${annotationId}/replies`,
63
+ {
64
+ method: "POST",
65
+ headers: { "Content-Type": "application/json" },
66
+ body: JSON.stringify({ author: "agent", agent: flags.agent ?? "agent", body })
67
+ }
68
+ );
69
+ } catch (err) {
70
+ recordError("reply", err);
71
+ fail(`Could not reach the DiffPrism server: ${err instanceof Error ? err.message : String(err)}
72
+ ${REPORT_HINT}`);
73
+ return;
74
+ }
75
+ const data = await response.json().catch(() => ({}));
76
+ if (!response.ok) {
77
+ fail(`Reply not posted: ${data.error ?? `server returned ${response.status}`}`);
78
+ return;
79
+ }
80
+ const where = data.annotation ? ` on ${data.annotation.file}:${data.annotation.line}` : "";
81
+ console.log(`Replied${where}. It shows in the review now.`);
82
+ }
83
+ function fail(message2) {
84
+ console.error(message2);
85
+ process.exit(1);
86
+ }
87
+
88
+ // cli/src/commands/hook.ts
43
89
  var DEFAULT_MIN_LINES = 120;
44
90
  var RETRY_ADVICE = "The review stays open in DiffPrism \u2014 once the reviewer decides, run git commit again to pick up the decision. Don't open another review or change the staged files meanwhile.";
45
91
  var MARKER_START = "# >>> diffprism >>>";
@@ -57,7 +103,7 @@ async function preCommitHook(flags = {}) {
57
103
  );
58
104
  } catch (err) {
59
105
  recordError("hook pre-commit", err);
60
- fail(`Could not read the staged diff: ${message(err)}
106
+ fail2(`Could not read the staged diff: ${message(err)}
61
107
  ${REPORT_HINT}`);
62
108
  return;
63
109
  }
@@ -88,18 +134,18 @@ ${REPORT_HINT}`);
88
134
  } catch (err) {
89
135
  stopWaiting();
90
136
  if (err instanceof ReviewerAskedError) {
91
- printQuestions(err.threads);
92
- fail(
93
- `Commit blocked: the reviewer asked you something before deciding. Answer each question with the DiffPrism reply tool (session_id: ${err.sessionId}, annotation_id as listed), then run git commit again \u2014 the review stays open and the decision still comes.`
137
+ printQuestions(err.sessionId, err.threads);
138
+ fail2(
139
+ "Commit blocked: the reviewer asked you something before deciding. Answer each question with the command under it \u2014 change the code too if that's what they asked for \u2014 then run git commit again. The review stays open and the decision still comes."
94
140
  );
95
141
  return;
96
142
  }
97
143
  if (err instanceof ReviewTimeoutError) {
98
- fail(`Commit blocked: no decision after ${Math.round(err.waitedMs / 1e3)}s. ${RETRY_ADVICE}`);
144
+ fail2(`Commit blocked: no decision after ${Math.round(err.waitedMs / 1e3)}s. ${RETRY_ADVICE}`);
99
145
  return;
100
146
  }
101
147
  recordError("hook pre-commit", err);
102
- fail(`DiffPrism could not run the review: ${message(err)}
148
+ fail2(`DiffPrism could not run the review: ${message(err)}
103
149
  ${REPORT_HINT}`);
104
150
  return;
105
151
  }
@@ -116,27 +162,28 @@ ${REPORT_HINT}`);
116
162
  }
117
163
  if (decision === "changes_requested") {
118
164
  printFeedback(review2);
119
- fail("Commit blocked: the review requested changes.");
165
+ fail2("Commit blocked: the review requested changes.");
120
166
  return;
121
167
  }
122
168
  if (decision === "dismissed") {
123
- fail("Commit blocked: the review was dismissed without a decision.");
169
+ fail2("Commit blocked: the review was dismissed without a decision.");
124
170
  return;
125
171
  }
126
- fail(
172
+ fail2(
127
173
  `Commit blocked: no review decision was returned (got ${String(decision)}).`
128
174
  );
129
175
  }
130
- function printQuestions(threads) {
176
+ function printQuestions(sessionId, threads) {
131
177
  console.error("");
132
178
  for (const t of threads) {
133
179
  const last = t.replies?.at(-1)?.body ?? t.body;
134
- console.error(` ${t.file}:${t.line} (annotation_id: ${t.id})`);
180
+ console.error(` ${t.file}:${t.line}`);
135
181
  for (const line of last.split("\n")) {
136
182
  console.error(` ${line}`);
137
183
  }
184
+ console.error(` Answer: ${replyCommandFor(sessionId, t.id)}`);
185
+ console.error("");
138
186
  }
139
- console.error("");
140
187
  }
141
188
  function printFeedback(review2) {
142
189
  const summary = review2?.summary?.trim();
@@ -277,7 +324,7 @@ function ensureTrailingNewline(text) {
277
324
  function message(err) {
278
325
  return err instanceof Error ? err.message : String(err);
279
326
  }
280
- function fail(text) {
327
+ function fail2(text) {
281
328
  console.error(text);
282
329
  process.exit(1);
283
330
  }
@@ -320,9 +367,9 @@ async function reviewLocalFlow(diffRef, flags) {
320
367
  }));
321
368
  } catch (err) {
322
369
  if (err instanceof ReviewerAskedError) {
323
- printQuestions(err.threads);
370
+ printQuestions(err.sessionId, err.threads);
324
371
  console.error(
325
- `The reviewer asked something before deciding. Answer each question with the DiffPrism reply tool (session_id: ${err.sessionId}, annotation_id as listed), then run diffprism review again \u2014 the review stays open.`
372
+ "The reviewer asked something before deciding. Answer each question with the command under it, then run diffprism review again \u2014 the review stays open."
326
373
  );
327
374
  process.exit(1);
328
375
  }
@@ -449,7 +496,7 @@ If the repo has the DiffPrism pre-commit gate installed (\`diffprism hook instal
449
496
  - Run \`git commit\` with a shell timeout long enough for someone to read the change \u2014 up to 600000 ms \u2014 not the short default.
450
497
  - If the commit is interrupted, or reports no decision, the review is still open. Once the reviewer decides, run the **same** \`git commit\` again: their decision is picked up immediately. Don't change the staged files first \u2014 that makes it a new question.
451
498
  - If it's blocked with changes requested, the reviewer's summary and comments are printed. Address them, stage, and commit again.
452
- - If it's blocked because the reviewer asked something, their questions are printed with an \`annotation_id\` each. Answer each with \`mcp__diffprism__reply\`, then run the same \`git commit\` again \u2014 the review is still open.
499
+ - If it's blocked because the reviewer asked something, each question is printed with the command that answers it \u2014 \`diffprism reply --session <id> <annotation-id> "<your answer>"\`. Run it for each, then run the same \`git commit\` again \u2014 the review is still open.
453
500
 
454
501
  ## Workflow 3: PR Review
455
502
 
@@ -669,7 +716,7 @@ async function setupInteractive(flags) {
669
716
  }
670
717
  async function runDemo(dev) {
671
718
  console.log("");
672
- const { demo: demo2 } = await import("./demo-X5LWQDVU.js");
719
+ const { demo: demo2 } = await import("./demo-VNWYEDZ3.js");
673
720
  await demo2({ dev });
674
721
  }
675
722
  async function setupBatch(flags) {
@@ -1184,6 +1231,7 @@ hookCmd.command("uninstall").description("Remove the diffprism gate from this re
1184
1231
  uninstallHook();
1185
1232
  });
1186
1233
  program.command("feedback").description("Open a prefilled GitHub issue to share feedback or report a bug \u2014 you review it before anything is sent").option("--bug", "Report a bug, including the last error DiffPrism hit").option("-m, --message <text>", "Start the issue with this text").option("--print", "Print the issue URL instead of opening a browser").action((flags) => feedback(flags));
1234
+ program.command("reply <annotation-id> <message...>").description("Answer a reviewer's question on an open review, as the agent").requiredOption("--session <id>", "The review the question is on").option("--agent <name>", "Name shown on the reply", "agent").action((annotationId, message2, flags) => reply(annotationId, message2, flags));
1187
1235
  program.command("serve").description("Start the MCP server for Claude Code integration").action(serve);
1188
1236
  program.command("setup").description("Configure DiffPrism for Claude Code integration").option("--global", "Configure globally (skill + permissions, no git repo required)").option("--force", "Overwrite existing configuration files").option("--dev", "Use Vite dev server").option("--no-demo", "Skip the demo review after setup").action((flags) => {
1189
1237
  setup(flags);
@@ -119,7 +119,7 @@ import path3 from "path";
119
119
  var ISSUES_NEW_URL = "https://github.com/CodeJonesW/diffprism/issues/new";
120
120
  var MAX_ERROR_CHARS = 1500;
121
121
  function currentVersion() {
122
- return true ? "1.0.0" : "0.0.0-dev";
122
+ return true ? "1.2.0" : "0.0.0-dev";
123
123
  }
124
124
  function describeEnvironment() {
125
125
  return {
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  ensureServer,
3
3
  submitReviewToServer
4
- } from "./chunk-CU2BAL6Q.js";
4
+ } from "./chunk-F6O5YP3I.js";
5
5
  import {
6
6
  parseDiff
7
7
  } from "./chunk-3GMPE2ZR.js";
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  demo
3
- } from "./chunk-CJ6LV2XV.js";
4
- import "./chunk-CU2BAL6Q.js";
3
+ } from "./chunk-FONA4U6B.js";
4
+ import "./chunk-F6O5YP3I.js";
5
5
  import "./chunk-3GMPE2ZR.js";
6
6
  import "./chunk-DHCVZGHE.js";
7
7
  import "./chunk-JSBRDJBE.js";
@@ -14,7 +14,7 @@ import {
14
14
  recordError,
15
15
  submitReviewToServer,
16
16
  waitForDecision
17
- } from "./chunk-CU2BAL6Q.js";
17
+ } from "./chunk-F6O5YP3I.js";
18
18
  import {
19
19
  getDiff
20
20
  } from "./chunk-3GMPE2ZR.js";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "diffprism",
3
- "version": "1.0.0",
3
+ "version": "1.2.0",
4
4
  "type": "module",
5
5
  "description": "Local-first code review tool for agent-generated code changes",
6
6
  "bin": {
@@ -341,5 +341,5 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
341
341
  `],o=0;o<this.diffs.length;o++){switch(this.diffs[o][0]){case 1:r="+";break;case-1:r="-";break;case 0:r=" "}s[o+1]=r+encodeURI(this.diffs[o][1])+`
342
342
  `}return s.join("").replace(/%20/g," ")},l.exports=i,l.exports.diff_match_patch=i,l.exports.DIFF_DELETE=-1,l.exports.DIFF_INSERT=1,l.exports.DIFF_EQUAL=0}));Lo.DIFF_EQUAL;Lo.DIFF_DELETE;Lo.DIFF_INSERT;var DS=["enhancers"],zS=function(l){var i,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},s=r.enhancers,o=s===void 0?[]:s,d=rt(AS(l,na(r,DS)),2),h=d[0],m=d[1],g=[tp(h),tp(m)],y=(i=[g[0],g[1]],o.reduce((function(C,_){return _(C)}),i)),b=rt(y,2),x=b[0],S=b[1],E=[x.map(np),S.map(np)],A=E[1];return{old:E[0].map((function(C){var _;return(_=C.children)!==null&&_!==void 0?_:[]})),new:A.map((function(C){var _;return(_=C.children)!==null&&_!==void 0?_:[]}))}};sn.displayName="clike";sn.aliases=[];function sn(l){l.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/,boolean:/\b(?:false|true)\b/,function:/\b\w+(?=\()/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/}}Mr.displayName="c";Mr.aliases=[];function Mr(l){l.register(sn),l.languages.c=l.languages.extend("clike",{comment:{pattern:/\/\/(?:[^\r\n\\]|\\(?:\r\n?|\n|(?![\r\n])))*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},string:{pattern:/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},"class-name":{pattern:/(\b(?:enum|struct)\s+(?:__attribute__\s*\(\([\s\S]*?\)\)\s*)?)\w+|\b[a-z]\w*_t\b/,lookbehind:!0},keyword:/\b(?:_Alignas|_Alignof|_Atomic|_Bool|_Complex|_Generic|_Imaginary|_Noreturn|_Static_assert|_Thread_local|__attribute__|asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|inline|int|long|register|return|short|signed|sizeof|static|struct|switch|typedef|typeof|union|unsigned|void|volatile|while)\b/,function:/\b[a-z_]\w*(?=\s*\()/i,number:/(?:\b0x(?:[\da-f]+(?:\.[\da-f]*)?|\.[\da-f]+)(?:p[+-]?\d+)?|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?)[ful]{0,4}/i,operator:/>>=?|<<=?|->|([-+&|:])\1|[?:~]|[-+*/%&|^!=<>]=?/}),l.languages.insertBefore("c","string",{char:{pattern:/'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n]){0,32}'/,greedy:!0}}),l.languages.insertBefore("c","string",{macro:{pattern:/(^[\t ]*)#\s*[a-z](?:[^\r\n\\/]|\/(?!\*)|\/\*(?:[^*]|\*(?!\/))*\*\/|\\(?:\r\n|[\s\S]))*/im,lookbehind:!0,greedy:!0,alias:"property",inside:{string:[{pattern:/^(#\s*include\s*)<[^>]+>/,lookbehind:!0},l.languages.c.string],char:l.languages.c.char,comment:l.languages.c.comment,"macro-name":[{pattern:/(^#\s*define\s+)\w+\b(?!\()/i,lookbehind:!0},{pattern:/(^#\s*define\s+)\w+\b(?=\()/i,lookbehind:!0,alias:"function"}],directive:{pattern:/^(#\s*)[a-z]+/,lookbehind:!0,alias:"keyword"},"directive-hash":/^#/,punctuation:/##|\\(?=[\r\n])/,expression:{pattern:/\S[\s\S]*/,inside:l.languages.c}}}}),l.languages.insertBefore("c","function",{constant:/\b(?:EOF|NULL|SEEK_CUR|SEEK_END|SEEK_SET|__DATE__|__FILE__|__LINE__|__TIMESTAMP__|__TIME__|__func__|stderr|stdin|stdout)\b/}),delete l.languages.c.boolean}ws.displayName="cpp";ws.aliases=[];function ws(l){l.register(Mr),(function(i){var r=/\b(?:alignas|alignof|asm|auto|bool|break|case|catch|char|char16_t|char32_t|char8_t|class|co_await|co_return|co_yield|compl|concept|const|const_cast|consteval|constexpr|constinit|continue|decltype|default|delete|do|double|dynamic_cast|else|enum|explicit|export|extern|final|float|for|friend|goto|if|import|inline|int|int16_t|int32_t|int64_t|int8_t|long|module|mutable|namespace|new|noexcept|nullptr|operator|override|private|protected|public|register|reinterpret_cast|requires|return|short|signed|sizeof|static|static_assert|static_cast|struct|switch|template|this|thread_local|throw|try|typedef|typeid|typename|uint16_t|uint32_t|uint64_t|uint8_t|union|unsigned|using|virtual|void|volatile|wchar_t|while)\b/,s=/\b(?!<keyword>)\w+(?:\s*\.\s*\w+)*\b/.source.replace(/<keyword>/g,function(){return r.source});i.languages.cpp=i.languages.extend("c",{"class-name":[{pattern:RegExp(/(\b(?:class|concept|enum|struct|typename)\s+)(?!<keyword>)\w+/.source.replace(/<keyword>/g,function(){return r.source})),lookbehind:!0},/\b[A-Z]\w*(?=\s*::\s*\w+\s*\()/,/\b[A-Z_]\w*(?=\s*::\s*~\w+\s*\()/i,/\b\w+(?=\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>\s*::\s*\w+\s*\()/],keyword:r,number:{pattern:/(?:\b0b[01']+|\b0x(?:[\da-f']+(?:\.[\da-f']*)?|\.[\da-f']+)(?:p[+-]?[\d']+)?|(?:\b[\d']+(?:\.[\d']*)?|\B\.[\d']+)(?:e[+-]?[\d']+)?)[ful]{0,4}/i,greedy:!0},operator:/>>=?|<<=?|->|--|\+\+|&&|\|\||[?:~]|<=>|[-+*/%&|^!=<>]=?|\b(?:and|and_eq|bitand|bitor|not|not_eq|or|or_eq|xor|xor_eq)\b/,boolean:/\b(?:false|true)\b/}),i.languages.insertBefore("cpp","string",{module:{pattern:RegExp(/(\b(?:import|module)\s+)/.source+"(?:"+/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|<[^<>\r\n]*>/.source+"|"+/<mod-name>(?:\s*:\s*<mod-name>)?|:\s*<mod-name>/.source.replace(/<mod-name>/g,function(){return s})+")"),lookbehind:!0,greedy:!0,inside:{string:/^[<"][\s\S]+/,operator:/:/,punctuation:/\./}},"raw-string":{pattern:/R"([^()\\ ]{0,16})\([\s\S]*?\)\1"/,alias:"string",greedy:!0}}),i.languages.insertBefore("cpp","keyword",{"generic-function":{pattern:/\b(?!operator\b)[a-z_]\w*\s*<(?:[^<>]|<[^<>]*>)*>(?=\s*\()/i,inside:{function:/^\w+/,generic:{pattern:/<[\s\S]+/,alias:"class-name",inside:i.languages.cpp}}}}),i.languages.insertBefore("cpp","operator",{"double-colon":{pattern:/::/,alias:"punctuation"}}),i.languages.insertBefore("cpp","class-name",{"base-clause":{pattern:/(\b(?:class|struct)\s+\w+\s*:\s*)[^;{}"'\s]+(?:\s+[^;{}"'\s]+)*(?=\s*[;{])/,lookbehind:!0,greedy:!0,inside:i.languages.extend("cpp",{})}}),i.languages.insertBefore("inside","double-colon",{"class-name":/\b[a-z_]\w*\b(?!\s*::)/i},i.languages.cpp["base-clause"])})(l)}Uo.displayName="arduino";Uo.aliases=["ino"];function Uo(l){l.register(ws),l.languages.arduino=l.languages.extend("cpp",{keyword:/\b(?:String|array|bool|boolean|break|byte|case|catch|continue|default|do|double|else|finally|for|function|goto|if|in|instanceof|int|integer|long|loop|new|null|return|setup|string|switch|throw|try|void|while|word)\b/,constant:/\b(?:ANALOG_MESSAGE|DEFAULT|DIGITAL_MESSAGE|EXTERNAL|FIRMATA_STRING|HIGH|INPUT|INPUT_PULLUP|INTERNAL|INTERNAL1V1|INTERNAL2V56|LED_BUILTIN|LOW|OUTPUT|REPORT_ANALOG|REPORT_DIGITAL|SET_PIN_MODE|SYSEX_START|SYSTEM_RESET)\b/,builtin:/\b(?:Audio|BSSID|Bridge|Client|Console|EEPROM|Esplora|EsploraTFT|Ethernet|EthernetClient|EthernetServer|EthernetUDP|File|FileIO|FileSystem|Firmata|GPRS|GSM|GSMBand|GSMClient|GSMModem|GSMPIN|GSMScanner|GSMServer|GSMVoiceCall|GSM_SMS|HttpClient|IPAddress|IRread|Keyboard|KeyboardController|LiquidCrystal|LiquidCrystal_I2C|Mailbox|Mouse|MouseController|PImage|Process|RSSI|RobotControl|RobotMotor|SD|SPI|SSID|Scheduler|Serial|Server|Servo|SoftwareSerial|Stepper|Stream|TFT|Task|USBHost|WiFi|WiFiClient|WiFiServer|WiFiUDP|Wire|YunClient|YunServer|abs|addParameter|analogRead|analogReadResolution|analogReference|analogWrite|analogWriteResolution|answerCall|attach|attachGPRS|attachInterrupt|attached|autoscroll|available|background|beep|begin|beginPacket|beginSD|beginSMS|beginSpeaker|beginTFT|beginTransmission|beginWrite|bit|bitClear|bitRead|bitSet|bitWrite|blink|blinkVersion|buffer|changePIN|checkPIN|checkPUK|checkReg|circle|cityNameRead|cityNameWrite|clear|clearScreen|click|close|compassRead|config|connect|connected|constrain|cos|countryNameRead|countryNameWrite|createChar|cursor|debugPrint|delay|delayMicroseconds|detach|detachInterrupt|digitalRead|digitalWrite|disconnect|display|displayLogos|drawBMP|drawCompass|encryptionType|end|endPacket|endSMS|endTransmission|endWrite|exists|exitValue|fill|find|findUntil|flush|gatewayIP|get|getAsynchronously|getBand|getButton|getCurrentCarrier|getIMEI|getKey|getModifiers|getOemKey|getPINUsed|getResult|getSignalStrength|getSocket|getVoiceCallStatus|getXChange|getYChange|hangCall|height|highByte|home|image|interrupts|isActionDone|isDirectory|isListening|isPIN|isPressed|isValid|keyPressed|keyReleased|keyboardRead|knobRead|leftToRight|line|lineFollowConfig|listen|listenOnLocalhost|loadImage|localIP|lowByte|macAddress|maintain|map|max|messageAvailable|micros|millis|min|mkdir|motorsStop|motorsWrite|mouseDragged|mouseMoved|mousePressed|mouseReleased|move|noAutoscroll|noBlink|noBuffer|noCursor|noDisplay|noFill|noInterrupts|noListenOnLocalhost|noStroke|noTone|onReceive|onRequest|open|openNextFile|overflow|parseCommand|parseFloat|parseInt|parsePacket|pauseMode|peek|pinMode|playFile|playMelody|point|pointTo|position|pow|prepare|press|print|printFirmwareVersion|printVersion|println|process|processInput|pulseIn|put|random|randomSeed|read|readAccelerometer|readBlue|readButton|readBytes|readBytesUntil|readGreen|readJoystickButton|readJoystickSwitch|readJoystickX|readJoystickY|readLightSensor|readMessage|readMicrophone|readNetworks|readRed|readSlider|readString|readStringUntil|readTemperature|ready|rect|release|releaseAll|remoteIP|remoteNumber|remotePort|remove|requestFrom|retrieveCallingNumber|rewindDirectory|rightToLeft|rmdir|robotNameRead|robotNameWrite|run|runAsynchronously|runShellCommand|runShellCommandAsynchronously|running|scanNetworks|scrollDisplayLeft|scrollDisplayRight|seek|sendAnalog|sendDigitalPortPair|sendDigitalPorts|sendString|sendSysex|serialEvent|setBand|setBitOrder|setClockDivider|setCursor|setDNS|setDataMode|setFirmwareVersion|setMode|setPINUsed|setSpeed|setTextSize|setTimeout|shiftIn|shiftOut|shutdown|sin|size|sqrt|startLoop|step|stop|stroke|subnetMask|switchPIN|tan|tempoWrite|text|tone|transfer|tuneWrite|turn|updateIR|userNameRead|userNameWrite|voiceCall|waitContinue|width|write|writeBlue|writeGreen|writeJSON|writeMessage|writeMicroseconds|writeRGB|writeRed|yield)\b/}),l.languages.ino=l.languages.arduino}Bo.displayName="bash";Bo.aliases=["sh","shell"];function Bo(l){(function(i){var r="\\b(?:BASH|BASHOPTS|BASH_ALIASES|BASH_ARGC|BASH_ARGV|BASH_CMDS|BASH_COMPLETION_COMPAT_DIR|BASH_LINENO|BASH_REMATCH|BASH_SOURCE|BASH_VERSINFO|BASH_VERSION|COLORTERM|COLUMNS|COMP_WORDBREAKS|DBUS_SESSION_BUS_ADDRESS|DEFAULTS_PATH|DESKTOP_SESSION|DIRSTACK|DISPLAY|EUID|GDMSESSION|GDM_LANG|GNOME_KEYRING_CONTROL|GNOME_KEYRING_PID|GPG_AGENT_INFO|GROUPS|HISTCONTROL|HISTFILE|HISTFILESIZE|HISTSIZE|HOME|HOSTNAME|HOSTTYPE|IFS|INSTANCE|JOB|LANG|LANGUAGE|LC_ADDRESS|LC_ALL|LC_IDENTIFICATION|LC_MEASUREMENT|LC_MONETARY|LC_NAME|LC_NUMERIC|LC_PAPER|LC_TELEPHONE|LC_TIME|LESSCLOSE|LESSOPEN|LINES|LOGNAME|LS_COLORS|MACHTYPE|MAILCHECK|MANDATORY_PATH|NO_AT_BRIDGE|OLDPWD|OPTERR|OPTIND|ORBIT_SOCKETDIR|OSTYPE|PAPERSIZE|PATH|PIPESTATUS|PPID|PS1|PS2|PS3|PS4|PWD|RANDOM|REPLY|SECONDS|SELINUX_INIT|SESSION|SESSIONTYPE|SESSION_MANAGER|SHELL|SHELLOPTS|SHLVL|SSH_AUTH_SOCK|TERM|UID|UPSTART_EVENTS|UPSTART_INSTANCE|UPSTART_JOB|UPSTART_SESSION|USER|WINDOWID|XAUTHORITY|XDG_CONFIG_DIRS|XDG_CURRENT_DESKTOP|XDG_DATA_DIRS|XDG_GREETER_DATA_DIR|XDG_MENU_PREFIX|XDG_RUNTIME_DIR|XDG_SEAT|XDG_SEAT_PATH|XDG_SESSION_DESKTOP|XDG_SESSION_ID|XDG_SESSION_PATH|XDG_SESSION_TYPE|XDG_VTNR|XMODIFIERS)\\b",s={pattern:/(^(["']?)\w+\2)[ \t]+\S.*/,lookbehind:!0,alias:"punctuation",inside:null},o={bash:s,environment:{pattern:RegExp("\\$"+r),alias:"constant"},variable:[{pattern:/\$?\(\([\s\S]+?\)\)/,greedy:!0,inside:{variable:[{pattern:/(^\$\(\([\s\S]+)\)\)/,lookbehind:!0},/^\$\(\(/],number:/\b0x[\dA-Fa-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[Ee]-?\d+)?/,operator:/--|\+\+|\*\*=?|<<=?|>>=?|&&|\|\||[=!+\-*/%<>^&|]=?|[?~:]/,punctuation:/\(\(?|\)\)?|,|;/}},{pattern:/\$\((?:\([^)]+\)|[^()])+\)|`[^`]+`/,greedy:!0,inside:{variable:/^\$\(|^`|\)$|`$/}},{pattern:/\$\{[^}]+\}/,greedy:!0,inside:{operator:/:[-=?+]?|[!\/]|##?|%%?|\^\^?|,,?/,punctuation:/[\[\]]/,environment:{pattern:RegExp("(\\{)"+r),lookbehind:!0,alias:"constant"}}},/\$(?:\w+|[#?*!@$])/],entity:/\\(?:[abceEfnrtv\\"]|O?[0-7]{1,3}|U[0-9a-fA-F]{8}|u[0-9a-fA-F]{4}|x[0-9a-fA-F]{1,2})/};i.languages.bash={shebang:{pattern:/^#!\s*\/.*/,alias:"important"},comment:{pattern:/(^|[^"{\\$])#.*/,lookbehind:!0},"function-name":[{pattern:/(\bfunction\s+)[\w-]+(?=(?:\s*\(?:\s*\))?\s*\{)/,lookbehind:!0,alias:"function"},{pattern:/\b[\w-]+(?=\s*\(\s*\)\s*\{)/,alias:"function"}],"for-or-select":{pattern:/(\b(?:for|select)\s+)\w+(?=\s+in\s)/,alias:"variable",lookbehind:!0},"assign-left":{pattern:/(^|[\s;|&]|[<>]\()\w+(?:\.\w+)*(?=\+?=)/,inside:{environment:{pattern:RegExp("(^|[\\s;|&]|[<>]\\()"+r),lookbehind:!0,alias:"constant"}},alias:"variable",lookbehind:!0},parameter:{pattern:/(^|\s)-{1,2}(?:\w+:[+-]?)?\w+(?:\.\w+)*(?=[=\s]|$)/,alias:"variable",lookbehind:!0},string:[{pattern:/((?:^|[^<])<<-?\s*)(\w+)\s[\s\S]*?(?:\r?\n|\r)\2/,lookbehind:!0,greedy:!0,inside:o},{pattern:/((?:^|[^<])<<-?\s*)(["'])(\w+)\2\s[\s\S]*?(?:\r?\n|\r)\3/,lookbehind:!0,greedy:!0,inside:{bash:s}},{pattern:/(^|[^\\](?:\\\\)*)"(?:\\[\s\S]|\$\([^)]+\)|\$(?!\()|`[^`]+`|[^"\\`$])*"/,lookbehind:!0,greedy:!0,inside:o},{pattern:/(^|[^$\\])'[^']*'/,lookbehind:!0,greedy:!0},{pattern:/\$'(?:[^'\\]|\\[\s\S])*'/,greedy:!0,inside:{entity:o.entity}}],environment:{pattern:RegExp("\\$?"+r),alias:"constant"},variable:o.variable,function:{pattern:/(^|[\s;|&]|[<>]\()(?:add|apropos|apt|apt-cache|apt-get|aptitude|aspell|automysqlbackup|awk|basename|bash|bc|bconsole|bg|bzip2|cal|cargo|cat|cfdisk|chgrp|chkconfig|chmod|chown|chroot|cksum|clear|cmp|column|comm|composer|cp|cron|crontab|csplit|curl|cut|date|dc|dd|ddrescue|debootstrap|df|diff|diff3|dig|dir|dircolors|dirname|dirs|dmesg|docker|docker-compose|du|egrep|eject|env|ethtool|expand|expect|expr|fdformat|fdisk|fg|fgrep|file|find|fmt|fold|format|free|fsck|ftp|fuser|gawk|git|gparted|grep|groupadd|groupdel|groupmod|groups|grub-mkconfig|gzip|halt|head|hg|history|host|hostname|htop|iconv|id|ifconfig|ifdown|ifup|import|install|ip|java|jobs|join|kill|killall|less|link|ln|locate|logname|logrotate|look|lpc|lpr|lprint|lprintd|lprintq|lprm|ls|lsof|lynx|make|man|mc|mdadm|mkconfig|mkdir|mke2fs|mkfifo|mkfs|mkisofs|mknod|mkswap|mmv|more|most|mount|mtools|mtr|mutt|mv|nano|nc|netstat|nice|nl|node|nohup|notify-send|npm|nslookup|op|open|parted|passwd|paste|pathchk|ping|pkill|pnpm|podman|podman-compose|popd|pr|printcap|printenv|ps|pushd|pv|quota|quotacheck|quotactl|ram|rar|rcp|reboot|remsync|rename|renice|rev|rm|rmdir|rpm|rsync|scp|screen|sdiff|sed|sendmail|seq|service|sftp|sh|shellcheck|shuf|shutdown|sleep|slocate|sort|split|ssh|stat|strace|su|sudo|sum|suspend|swapon|sync|sysctl|tac|tail|tar|tee|time|timeout|top|touch|tr|traceroute|tsort|tty|umount|uname|unexpand|uniq|units|unrar|unshar|unzip|update-grub|uptime|useradd|userdel|usermod|users|uudecode|uuencode|v|vcpkg|vdir|vi|vim|virsh|vmstat|wait|watch|wc|wget|whereis|which|who|whoami|write|xargs|xdg-open|yarn|yes|zenity|zip|zsh|zypper)(?=$|[)\s;|&])/,lookbehind:!0},keyword:{pattern:/(^|[\s;|&]|[<>]\()(?:case|do|done|elif|else|esac|fi|for|function|if|in|select|then|until|while)(?=$|[)\s;|&])/,lookbehind:!0},builtin:{pattern:/(^|[\s;|&]|[<>]\()(?:\.|:|alias|bind|break|builtin|caller|cd|command|continue|declare|echo|enable|eval|exec|exit|export|getopts|hash|help|let|local|logout|mapfile|printf|pwd|read|readarray|readonly|return|set|shift|shopt|source|test|times|trap|type|typeset|ulimit|umask|unalias|unset)(?=$|[)\s;|&])/,lookbehind:!0,alias:"class-name"},boolean:{pattern:/(^|[\s;|&]|[<>]\()(?:false|true)(?=$|[)\s;|&])/,lookbehind:!0},"file-descriptor":{pattern:/\B&\d\b/,alias:"important"},operator:{pattern:/\d?<>|>\||\+=|=[=~]?|!=?|<<[<-]?|[&\d]?>>|\d[<>]&?|[<>][&=]?|&[>&]?|\|[&|]?/,inside:{"file-descriptor":{pattern:/^\d/,alias:"important"}}},punctuation:/\$?\(\(?|\)\)?|\.\.|[{}[\];\\]/,number:{pattern:/(^|\s)(?:[1-9]\d*|0)(?:[.,]\d+)?\b/,lookbehind:!0}},s.inside=i.languages.bash;for(var d=["comment","function-name","for-or-select","assign-left","parameter","string","environment","function","keyword","builtin","boolean","file-descriptor","operator","punctuation","number"],h=o.variable[1].inside,m=0;m<d.length;m++)h[d[m]]=i.languages.bash[d[m]];i.languages.sh=i.languages.bash,i.languages.shell=i.languages.bash})(l)}Ho.displayName="csharp";Ho.aliases=["cs","dotnet"];function Ho(l){l.register(sn),(function(i){function r(oe,w){return oe.replace(/<<(\d+)>>/g,function(I,P){return"(?:"+w[+P]+")"})}function s(oe,w,I){return RegExp(r(oe,w),"")}function o(oe,w){for(var I=0;I<w;I++)oe=oe.replace(/<<self>>/g,function(){return"(?:"+oe+")"});return oe.replace(/<<self>>/g,"[^\\s\\S]")}var d={type:"bool byte char decimal double dynamic float int long object sbyte short string uint ulong ushort var void",typeDeclaration:"class enum interface record struct",contextual:"add alias and ascending async await by descending from(?=\\s*(?:\\w|$)) get global group into init(?=\\s*;) join let nameof not notnull on or orderby partial remove select set unmanaged value when where with(?=\\s*{)",other:"abstract as base break case catch checked const continue default delegate do else event explicit extern finally fixed for foreach goto if implicit in internal is lock namespace new null operator out override params private protected public readonly ref return sealed sizeof stackalloc static switch this throw try typeof unchecked unsafe using virtual volatile while yield"};function h(oe){return"\\b(?:"+oe.trim().replace(/ /g,"|")+")\\b"}var m=h(d.typeDeclaration),g=RegExp(h(d.type+" "+d.typeDeclaration+" "+d.contextual+" "+d.other)),y=h(d.typeDeclaration+" "+d.contextual+" "+d.other),b=h(d.type+" "+d.typeDeclaration+" "+d.other),x=o(/<(?:[^<>;=+\-*/%&|^]|<<self>>)*>/.source,2),S=o(/\((?:[^()]|<<self>>)*\)/.source,2),E=/@?\b[A-Za-z_]\w*\b/.source,A=r(/<<0>>(?:\s*<<1>>)?/.source,[E,x]),C=r(/(?!<<0>>)<<1>>(?:\s*\.\s*<<1>>)*/.source,[y,A]),_=/\[\s*(?:,\s*)*\]/.source,B=r(/<<0>>(?:\s*(?:\?\s*)?<<1>>)*(?:\s*\?)?/.source,[C,_]),q=r(/[^,()<>[\];=+\-*/%&|^]|<<0>>|<<1>>|<<2>>/.source,[x,S,_]),R=r(/\(<<0>>+(?:,<<0>>+)+\)/.source,[q]),Z=r(/(?:<<0>>|<<1>>)(?:\s*(?:\?\s*)?<<2>>)*(?:\s*\?)?/.source,[R,C,_]),Y={keyword:g,punctuation:/[<>()?,.:[\]]/},F=/'(?:[^\r\n'\\]|\\.|\\[Uux][\da-fA-F]{1,8})'/.source,H=/"(?:\\.|[^\\"\r\n])*"/.source,j=/@"(?:""|\\[\s\S]|[^\\"])*"(?!")/.source;i.languages.csharp=i.languages.extend("clike",{string:[{pattern:s(/(^|[^$\\])<<0>>/.source,[j]),lookbehind:!0,greedy:!0},{pattern:s(/(^|[^@$\\])<<0>>/.source,[H]),lookbehind:!0,greedy:!0}],"class-name":[{pattern:s(/(\busing\s+static\s+)<<0>>(?=\s*;)/.source,[C]),lookbehind:!0,inside:Y},{pattern:s(/(\busing\s+<<0>>\s*=\s*)<<1>>(?=\s*;)/.source,[E,Z]),lookbehind:!0,inside:Y},{pattern:s(/(\busing\s+)<<0>>(?=\s*=)/.source,[E]),lookbehind:!0},{pattern:s(/(\b<<0>>\s+)<<1>>/.source,[m,A]),lookbehind:!0,inside:Y},{pattern:s(/(\bcatch\s*\(\s*)<<0>>/.source,[C]),lookbehind:!0,inside:Y},{pattern:s(/(\bwhere\s+)<<0>>/.source,[E]),lookbehind:!0},{pattern:s(/(\b(?:is(?:\s+not)?|as)\s+)<<0>>/.source,[B]),lookbehind:!0,inside:Y},{pattern:s(/\b<<0>>(?=\s+(?!<<1>>|with\s*\{)<<2>>(?:\s*[=,;:{)\]]|\s+(?:in|when)\b))/.source,[Z,b,E]),inside:Y}],keyword:g,number:/(?:\b0(?:x[\da-f_]*[\da-f]|b[01_]*[01])|(?:\B\.\d+(?:_+\d+)*|\b\d+(?:_+\d+)*(?:\.\d+(?:_+\d+)*)?)(?:e[-+]?\d+(?:_+\d+)*)?)(?:[dflmu]|lu|ul)?\b/i,operator:/>>=?|<<=?|[-=]>|([-+&|])\1|~|\?\?=?|[-+*/%&|^!=<>]=?/,punctuation:/\?\.?|::|[{}[\];(),.:]/}),i.languages.insertBefore("csharp","number",{range:{pattern:/\.\./,alias:"operator"}}),i.languages.insertBefore("csharp","punctuation",{"named-parameter":{pattern:s(/([(,]\s*)<<0>>(?=\s*:)/.source,[E]),lookbehind:!0,alias:"punctuation"}}),i.languages.insertBefore("csharp","class-name",{namespace:{pattern:s(/(\b(?:namespace|using)\s+)<<0>>(?:\s*\.\s*<<0>>)*(?=\s*[;{])/.source,[E]),lookbehind:!0,inside:{punctuation:/\./}},"type-expression":{pattern:s(/(\b(?:default|sizeof|typeof)\s*\(\s*(?!\s))(?:[^()\s]|\s(?!\s)|<<0>>)*(?=\s*\))/.source,[S]),lookbehind:!0,alias:"class-name",inside:Y},"return-type":{pattern:s(/<<0>>(?=\s+(?:<<1>>\s*(?:=>|[({]|\.\s*this\s*\[)|this\s*\[))/.source,[Z,C]),inside:Y,alias:"class-name"},"constructor-invocation":{pattern:s(/(\bnew\s+)<<0>>(?=\s*[[({])/.source,[Z]),lookbehind:!0,inside:Y,alias:"class-name"},"generic-method":{pattern:s(/<<0>>\s*<<1>>(?=\s*\()/.source,[E,x]),inside:{function:s(/^<<0>>/.source,[E]),generic:{pattern:RegExp(x),alias:"class-name",inside:Y}}},"type-list":{pattern:s(/\b((?:<<0>>\s+<<1>>|record\s+<<1>>\s*<<5>>|where\s+<<2>>)\s*:\s*)(?:<<3>>|<<4>>|<<1>>\s*<<5>>|<<6>>)(?:\s*,\s*(?:<<3>>|<<4>>|<<6>>))*(?=\s*(?:where|[{;]|=>|$))/.source,[m,A,E,Z,g.source,S,/\bnew\s*\(\s*\)/.source]),lookbehind:!0,inside:{"record-arguments":{pattern:s(/(^(?!new\s*\()<<0>>\s*)<<1>>/.source,[A,S]),lookbehind:!0,greedy:!0,inside:i.languages.csharp},keyword:g,"class-name":{pattern:RegExp(Z),greedy:!0,inside:Y},punctuation:/[,()]/}},preprocessor:{pattern:/(^[\t ]*)#.*/m,lookbehind:!0,alias:"property",inside:{directive:{pattern:/(#)\b(?:define|elif|else|endif|endregion|error|if|line|nullable|pragma|region|undef|warning)\b/,lookbehind:!0,alias:"keyword"}}}});var ae=H+"|"+F,ee=r(/\/(?![*/])|\/\/[^\r\n]*[\r\n]|\/\*(?:[^*]|\*(?!\/))*\*\/|<<0>>/.source,[ae]),re=o(r(/[^"'/()]|<<0>>|\(<<self>>*\)/.source,[ee]),2),ce=/\b(?:assembly|event|field|method|module|param|property|return|type)\b/.source,te=r(/<<0>>(?:\s*\(<<1>>*\))?/.source,[C,re]);i.languages.insertBefore("csharp","class-name",{attribute:{pattern:s(/((?:^|[^\s\w>)?])\s*\[\s*)(?:<<0>>\s*:\s*)?<<1>>(?:\s*,\s*<<1>>)*(?=\s*\])/.source,[ce,te]),lookbehind:!0,greedy:!0,inside:{target:{pattern:s(/^<<0>>(?=\s*:)/.source,[ce]),alias:"keyword"},"attribute-arguments":{pattern:s(/\(<<0>>*\)/.source,[re]),inside:i.languages.csharp},"class-name":{pattern:RegExp(C),inside:{punctuation:/\./}},punctuation:/[:,]/}}});var J=/:[^}\r\n]+/.source,Q=o(r(/[^"'/()]|<<0>>|\(<<self>>*\)/.source,[ee]),2),M=r(/\{(?!\{)(?:(?![}:])<<0>>)*<<1>>?\}/.source,[Q,J]),O=o(r(/[^"'/()]|\/(?!\*)|\/\*(?:[^*]|\*(?!\/))*\*\/|<<0>>|\(<<self>>*\)/.source,[ae]),2),le=r(/\{(?!\{)(?:(?![}:])<<0>>)*<<1>>?\}/.source,[O,J]);function ye(oe,w){return{interpolation:{pattern:s(/((?:^|[^{])(?:\{\{)*)<<0>>/.source,[oe]),lookbehind:!0,inside:{"format-string":{pattern:s(/(^\{(?:(?![}:])<<0>>)*)<<1>>(?=\}$)/.source,[w,J]),lookbehind:!0,inside:{punctuation:/^:/}},punctuation:/^\{|\}$/,expression:{pattern:/[\s\S]+/,alias:"language-csharp",inside:i.languages.csharp}}},string:/[\s\S]+/}}i.languages.insertBefore("csharp","string",{"interpolation-string":[{pattern:s(/(^|[^\\])(?:\$@|@\$)"(?:""|\\[\s\S]|\{\{|<<0>>|[^\\{"])*"/.source,[M]),lookbehind:!0,greedy:!0,inside:ye(M,Q)},{pattern:s(/(^|[^@\\])\$"(?:\\.|\{\{|<<0>>|[^\\"{])*"/.source,[le]),lookbehind:!0,greedy:!0,inside:ye(le,O)}],char:{pattern:RegExp(F),greedy:!0}}),i.languages.dotnet=i.languages.cs=i.languages.csharp})(l)}Dr.displayName="markup";Dr.aliases=["atom","html","mathml","rss","ssml","svg","xml"];function Dr(l){l.languages.markup={comment:{pattern:/<!--(?:(?!<!--)[\s\S])*?-->/,greedy:!0},prolog:{pattern:/<\?[\s\S]+?\?>/,greedy:!0},doctype:{pattern:/<!DOCTYPE(?:[^>"'[\]]|"[^"]*"|'[^']*')+(?:\[(?:[^<"'\]]|"[^"]*"|'[^']*'|<(?!!--)|<!--(?:[^-]|-(?!->))*-->)*\]\s*)?>/i,greedy:!0,inside:{"internal-subset":{pattern:/(^[^\[]*\[)[\s\S]+(?=\]>$)/,lookbehind:!0,greedy:!0,inside:null},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},punctuation:/^<!|>$|[[\]]/,"doctype-tag":/^DOCTYPE/i,name:/[^\s<>'"]+/}},cdata:{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,greedy:!0},tag:{pattern:/<\/?(?!\d)[^\s>\/=$<%]+(?:\s(?:\s*[^\s>\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?\s*\/?>/,greedy:!0,inside:{tag:{pattern:/^<\/?[^\s>\/]+/,inside:{punctuation:/^<\/?/,namespace:/^[^\s>\/:]+:/}},"special-attr":[],"attr-value":{pattern:/=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+)/,inside:{punctuation:[{pattern:/^=/,alias:"attr-equals"},{pattern:/^(\s*)["']|["']$/,lookbehind:!0}]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:"named-entity"},/&#x?[\da-f]{1,8};/i]},l.languages.markup.tag.inside["attr-value"].inside.entity=l.languages.markup.entity,l.languages.markup.doctype.inside["internal-subset"].inside=l.languages.markup,l.hooks.add("wrap",function(i){i.type==="entity"&&(i.attributes.title=i.content.value.replace(/&amp;/,"&"))}),Object.defineProperty(l.languages.markup.tag,"addInlined",{value:function(r,s){var o={};o["language-"+s]={pattern:/(^<!\[CDATA\[)[\s\S]+?(?=\]\]>$)/i,lookbehind:!0,inside:l.languages[s]},o.cdata=/^<!\[CDATA\[|\]\]>$/i;var d={"included-cdata":{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,inside:o}};d["language-"+s]={pattern:/[\s\S]+/,inside:l.languages[s]};var h={};h[r]={pattern:RegExp(/(<__[^>]*>)(?:<!\[CDATA\[(?:[^\]]|\](?!\]>))*\]\]>|(?!<!\[CDATA\[)[\s\S])*?(?=<\/__>)/.source.replace(/__/g,function(){return r}),"i"),lookbehind:!0,greedy:!0,inside:d},l.languages.insertBefore("markup","cdata",h)}}),Object.defineProperty(l.languages.markup.tag,"addAttribute",{value:function(i,r){l.languages.markup.tag.inside["special-attr"].push({pattern:RegExp(/(^|["'\s])/.source+"(?:"+i+")"+/\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))/.source,"i"),lookbehind:!0,inside:{"attr-name":/^[^\s=]+/,"attr-value":{pattern:/=[\s\S]+/,inside:{value:{pattern:/(^=\s*(["']|(?!["'])))\S[\s\S]*(?=\2$)/,lookbehind:!0,alias:[r,"language-"+r],inside:l.languages[r]},punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}}}})}}),l.languages.html=l.languages.markup,l.languages.mathml=l.languages.markup,l.languages.svg=l.languages.markup,l.languages.xml=l.languages.extend("markup",{}),l.languages.ssml=l.languages.xml,l.languages.atom=l.languages.xml,l.languages.rss=l.languages.xml}Tl.displayName="css";Tl.aliases=[];function Tl(l){(function(i){var r=/(?:"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n])*')/;i.languages.css={comment:/\/\*[\s\S]*?\*\//,atrule:{pattern:RegExp("@[\\w-](?:"+/[^;{\s"']|\s+(?!\s)/.source+"|"+r.source+")*?"+/(?:;|(?=\s*\{))/.source),inside:{rule:/^@[\w-]+/,"selector-function-argument":{pattern:/(\bselector\s*\(\s*(?![\s)]))(?:[^()\s]|\s+(?![\s)])|\((?:[^()]|\([^()]*\))*\))+(?=\s*\))/,lookbehind:!0,alias:"selector"},keyword:{pattern:/(^|[^\w-])(?:and|not|only|or)(?![\w-])/,lookbehind:!0}}},url:{pattern:RegExp("\\burl\\((?:"+r.source+"|"+/(?:[^\\\r\n()"']|\\[\s\S])*/.source+")\\)","i"),greedy:!0,inside:{function:/^url/i,punctuation:/^\(|\)$/,string:{pattern:RegExp("^"+r.source+"$"),alias:"url"}}},selector:{pattern:RegExp(`(^|[{}\\s])[^{}\\s](?:[^{};"'\\s]|\\s+(?![\\s{])|`+r.source+")*(?=\\s*\\{)"),lookbehind:!0},string:{pattern:r,greedy:!0},property:{pattern:/(^|[^-\w\xA0-\uFFFF])(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*(?=\s*:)/i,lookbehind:!0},important:/!important\b/i,function:{pattern:/(^|[^-a-z0-9])[-a-z0-9]+(?=\()/i,lookbehind:!0},punctuation:/[(){};:,]/},i.languages.css.atrule.inside.rest=i.languages.css;var s=i.languages.markup;s&&(s.tag.addInlined("style","css"),s.tag.addAttribute("style","css"))})(l)}Go.displayName="diff";Go.aliases=[];function Go(l){(function(i){i.languages.diff={coord:[/^(?:\*{3}|-{3}|\+{3}).*$/m,/^@@.*@@$/m,/^\d.*$/m]};var r={"deleted-sign":"-","deleted-arrow":"<","inserted-sign":"+","inserted-arrow":">",unchanged:" ",diff:"!"};Object.keys(r).forEach(function(s){var o=r[s],d=[];/^\w+$/.test(s)||d.push(/\w+/.exec(s)[0]),s==="diff"&&d.push("bold"),i.languages.diff[s]={pattern:RegExp("^(?:["+o+`].*(?:\r
343
343
  ?|
344
- |(?![\\s\\S])))+`,"m"),alias:d,inside:{line:{pattern:/(.)(?=[\s\S]).*(?:\r\n?|\n)?/,lookbehind:!0},prefix:{pattern:/[\s\S]/,alias:/\w+/.exec(s)[0]}}}}),Object.defineProperty(i.languages.diff,"PREFIXES",{value:r})})(l)}Yo.displayName="go";Yo.aliases=[];function Yo(l){l.register(sn),l.languages.go=l.languages.extend("clike",{string:{pattern:/(^|[^\\])"(?:\\.|[^"\\\r\n])*"|`[^`]*`/,lookbehind:!0,greedy:!0},keyword:/\b(?:break|case|chan|const|continue|default|defer|else|fallthrough|for|func|go(?:to)?|if|import|interface|map|package|range|return|select|struct|switch|type|var)\b/,boolean:/\b(?:_|false|iota|nil|true)\b/,number:[/\b0(?:b[01_]+|o[0-7_]+)i?\b/i,/\b0x(?:[a-f\d_]+(?:\.[a-f\d_]*)?|\.[a-f\d_]+)(?:p[+-]?\d+(?:_\d+)*)?i?(?!\w)/i,/(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?[\d_]+)?i?(?!\w)/i],operator:/[*\/%^!=]=?|\+[=+]?|-[=-]?|\|[=|]?|&(?:=|&|\^=?)?|>(?:>=?|=)?|<(?:<=?|=|-)?|:=|\.\.\./,builtin:/\b(?:append|bool|byte|cap|close|complex|complex(?:64|128)|copy|delete|error|float(?:32|64)|u?int(?:8|16|32|64)?|imag|len|make|new|panic|print(?:ln)?|real|recover|rune|string|uintptr)\b/}),l.languages.insertBefore("go","string",{char:{pattern:/'(?:\\.|[^'\\\r\n]){0,10}'/,greedy:!0}}),delete l.languages.go["class-name"]}qo.displayName="ini";qo.aliases=[];function qo(l){l.languages.ini={comment:{pattern:/(^[ \f\t\v]*)[#;][^\n\r]*/m,lookbehind:!0},section:{pattern:/(^[ \f\t\v]*)\[[^\n\r\]]*\]?/m,lookbehind:!0,inside:{"section-name":{pattern:/(^\[[ \f\t\v]*)[^ \f\t\v\]]+(?:[ \f\t\v]+[^ \f\t\v\]]+)*/,lookbehind:!0,alias:"selector"},punctuation:/\[|\]/}},key:{pattern:/(^[ \f\t\v]*)[^ \f\n\r\t\v=]+(?:[ \f\t\v]+[^ \f\n\r\t\v=]+)*(?=[ \f\t\v]*=)/m,lookbehind:!0,alias:"attr-name"},value:{pattern:/(=[ \f\t\v]*)[^ \f\n\r\t\v]+(?:[ \f\t\v]+[^ \f\n\r\t\v]+)*/,lookbehind:!0,alias:"attr-value",inside:{"inner-value":{pattern:/^("|').+(?=\1$)/,lookbehind:!0}}},punctuation:/=/}}Io.displayName="java";Io.aliases=[];function Io(l){l.register(sn),(function(i){var r=/\b(?:abstract|assert|boolean|break|byte|case|catch|char|class|const|continue|default|do|double|else|enum|exports|extends|final|finally|float|for|goto|if|implements|import|instanceof|int|interface|long|module|native|new|non-sealed|null|open|opens|package|permits|private|protected|provides|public|record(?!\s*[(){}[\]<>=%~.:,;?+\-*/&|^])|requires|return|sealed|short|static|strictfp|super|switch|synchronized|this|throw|throws|to|transient|transitive|try|uses|var|void|volatile|while|with|yield)\b/,s=/(?:[a-z]\w*\s*\.\s*)*(?:[A-Z]\w*\s*\.\s*)*/.source,o={pattern:RegExp(/(^|[^\w.])/.source+s+/[A-Z](?:[\d_A-Z]*[a-z]\w*)?\b/.source),lookbehind:!0,inside:{namespace:{pattern:/^[a-z]\w*(?:\s*\.\s*[a-z]\w*)*(?:\s*\.)?/,inside:{punctuation:/\./}},punctuation:/\./}};i.languages.java=i.languages.extend("clike",{string:{pattern:/(^|[^\\])"(?:\\.|[^"\\\r\n])*"/,lookbehind:!0,greedy:!0},"class-name":[o,{pattern:RegExp(/(^|[^\w.])/.source+s+/[A-Z]\w*(?=\s+\w+\s*[;,=()]|\s*(?:\[[\s,]*\]\s*)?::\s*new\b)/.source),lookbehind:!0,inside:o.inside},{pattern:RegExp(/(\b(?:class|enum|extends|implements|instanceof|interface|new|record|throws)\s+)/.source+s+/[A-Z]\w*\b/.source),lookbehind:!0,inside:o.inside}],keyword:r,function:[i.languages.clike.function,{pattern:/(::\s*)[a-z_]\w*/,lookbehind:!0}],number:/\b0b[01][01_]*L?\b|\b0x(?:\.[\da-f_p+-]+|[\da-f_]+(?:\.[\da-f_p+-]+)?)\b|(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?\d[\d_]*)?[dfl]?/i,operator:{pattern:/(^|[^.])(?:<<=?|>>>?=?|->|--|\+\+|&&|\|\||::|[?:~]|[-+*/%&|^!=<>]=?)/m,lookbehind:!0},constant:/\b[A-Z][A-Z_\d]+\b/}),i.languages.insertBefore("java","string",{"triple-quoted-string":{pattern:/"""[ \t]*[\r\n](?:(?:"|"")?(?:\\.|[^"\\]))*"""/,greedy:!0,alias:"string"},char:{pattern:/'(?:\\.|[^'\\\r\n]){1,6}'/,greedy:!0}}),i.languages.insertBefore("java","class-name",{annotation:{pattern:/(^|[^.])@\w+(?:\s*\.\s*\w+)*/,lookbehind:!0,alias:"punctuation"},generics:{pattern:/<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&))*>)*>)*>)*>/,inside:{"class-name":o,keyword:r,punctuation:/[<>(),.:]/,operator:/[?&|]/}},import:[{pattern:RegExp(/(\bimport\s+)/.source+s+/(?:[A-Z]\w*|\*)(?=\s*;)/.source),lookbehind:!0,inside:{namespace:o.inside.namespace,punctuation:/\./,operator:/\*/,"class-name":/\w+/}},{pattern:RegExp(/(\bimport\s+static\s+)/.source+s+/(?:\w+|\*)(?=\s*;)/.source),lookbehind:!0,alias:"static",inside:{namespace:o.inside.namespace,static:/\b\w+$/,punctuation:/\./,operator:/\*/,"class-name":/\w+/}}],namespace:{pattern:RegExp(/(\b(?:exports|import(?:\s+static)?|module|open|opens|package|provides|requires|to|transitive|uses|with)\s+)(?!<keyword>)[a-z]\w*(?:\.[a-z]\w*)*\.?/.source.replace(/<keyword>/g,function(){return r.source})),lookbehind:!0,inside:{punctuation:/\./}}})})(l)}Xo.displayName="regex";Xo.aliases=[];function Xo(l){(function(i){var r={pattern:/\\[\\(){}[\]^$+*?|.]/,alias:"escape"},s=/\\(?:x[\da-fA-F]{2}|u[\da-fA-F]{4}|u\{[\da-fA-F]+\}|0[0-7]{0,2}|[123][0-7]{2}|c[a-zA-Z]|.)/,o={pattern:/\.|\\[wsd]|\\p\{[^{}]+\}/i,alias:"class-name"},d={pattern:/\\[wsd]|\\p\{[^{}]+\}/i,alias:"class-name"},h="(?:[^\\\\-]|"+s.source+")",m=RegExp(h+"-"+h),g={pattern:/(<|')[^<>']+(?=[>']$)/,lookbehind:!0,alias:"variable"};i.languages.regex={"char-class":{pattern:/((?:^|[^\\])(?:\\\\)*)\[(?:[^\\\]]|\\[\s\S])*\]/,lookbehind:!0,inside:{"char-class-negation":{pattern:/(^\[)\^/,lookbehind:!0,alias:"operator"},"char-class-punctuation":{pattern:/^\[|\]$/,alias:"punctuation"},range:{pattern:m,inside:{escape:s,"range-punctuation":{pattern:/-/,alias:"operator"}}},"special-escape":r,"char-set":d,escape:s}},"special-escape":r,"char-set":o,backreference:[{pattern:/\\(?![123][0-7]{2})[1-9]/,alias:"keyword"},{pattern:/\\k<[^<>']+>/,alias:"keyword",inside:{"group-name":g}}],anchor:{pattern:/[$^]|\\[ABbGZz]/,alias:"function"},escape:s,group:[{pattern:/\((?:\?(?:<[^<>']+>|'[^<>']+'|[>:]|<?[=!]|[idmnsuxU]+(?:-[idmnsuxU]+)?:?))?/,alias:"punctuation",inside:{"group-name":g}},{pattern:/\)/,alias:"punctuation"}],quantifier:{pattern:/(?:[+*?]|\{\d+(?:,\d*)?\})[?+]?/,alias:"number"},alternation:{pattern:/\|/,alias:"keyword"}}})(l)}As.displayName="javascript";As.aliases=["js"];function As(l){l.register(sn),l.languages.javascript=l.languages.extend("clike",{"class-name":[l.languages.clike["class-name"],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(/(^|[^\w$])/.source+"(?:"+(/NaN|Infinity/.source+"|"+/0[bB][01]+(?:_[01]+)*n?/.source+"|"+/0[oO][0-7]+(?:_[0-7]+)*n?/.source+"|"+/0[xX][\dA-Fa-f]+(?:_[\dA-Fa-f]+)*n?/.source+"|"+/\d+(?:_\d+)*n/.source+"|"+/(?:\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[Ee][+-]?\d+(?:_\d+)*)?/.source)+")"+/(?![\w$])/.source),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),l.languages.javascript["class-name"][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,l.languages.insertBefore("javascript","keyword",{regex:{pattern:RegExp(/((?:^|[^$\w\xA0-\uFFFF."'\])\s]|\b(?:return|yield))\s*)/.source+/\//.source+"(?:"+/(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}/.source+"|"+/(?:\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.)*\])*\])*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}v[dgimyus]{0,7}/.source+")"+/(?=(?:\s|\/\*(?:[^*]|\*(?!\/))*\*\/)*(?:$|[\r\n,.;:})\]]|\/\/))/.source),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:"language-regex",inside:l.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:"function"},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:l.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:l.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:l.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:l.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),l.languages.insertBefore("javascript","string",{hashbang:{pattern:/^#!.*/,greedy:!0,alias:"comment"},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:l.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:"property"}}),l.languages.insertBefore("javascript","operator",{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:"property"}}),l.languages.markup&&(l.languages.markup.tag.addInlined("script","javascript"),l.languages.markup.tag.addAttribute(/on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)/.source,"javascript")),l.languages.js=l.languages.javascript}Fo.displayName="json";Fo.aliases=["webmanifest"];function Fo(l){l.languages.json={property:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?=\s*:)/,lookbehind:!0,greedy:!0},string:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?!\s*:)/,lookbehind:!0,greedy:!0},comment:{pattern:/\/\/.*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},number:/-?\b\d+(?:\.\d+)?(?:e[+-]?\d+)?\b/i,punctuation:/[{}[\],]/,operator:/:/,boolean:/\b(?:false|true)\b/,null:{pattern:/\bnull\b/,alias:"keyword"}},l.languages.webmanifest=l.languages.json}Zo.displayName="kotlin";Zo.aliases=["kt","kts"];function Zo(l){l.register(sn),(function(i){i.languages.kotlin=i.languages.extend("clike",{keyword:{pattern:/(^|[^.])\b(?:abstract|actual|annotation|as|break|by|catch|class|companion|const|constructor|continue|crossinline|data|do|dynamic|else|enum|expect|external|final|finally|for|fun|get|if|import|in|infix|init|inline|inner|interface|internal|is|lateinit|noinline|null|object|open|operator|out|override|package|private|protected|public|reified|return|sealed|set|super|suspend|tailrec|this|throw|to|try|typealias|val|var|vararg|when|where|while)\b/,lookbehind:!0},function:[{pattern:/(?:`[^\r\n`]+`|\b\w+)(?=\s*\()/,greedy:!0},{pattern:/(\.)(?:`[^\r\n`]+`|\w+)(?=\s*\{)/,lookbehind:!0,greedy:!0}],number:/\b(?:0[xX][\da-fA-F]+(?:_[\da-fA-F]+)*|0[bB][01]+(?:_[01]+)*|\d+(?:_\d+)*(?:\.\d+(?:_\d+)*)?(?:[eE][+-]?\d+(?:_\d+)*)?[fFL]?)\b/,operator:/\+[+=]?|-[-=>]?|==?=?|!(?:!|==?)?|[\/*%<>]=?|[?:]:?|\.\.|&&|\|\||\b(?:and|inv|or|shl|shr|ushr|xor)\b/}),delete i.languages.kotlin["class-name"];var r={"interpolation-punctuation":{pattern:/^\$\{?|\}$/,alias:"punctuation"},expression:{pattern:/[\s\S]+/,inside:i.languages.kotlin}};i.languages.insertBefore("kotlin","string",{"string-literal":[{pattern:/"""(?:[^$]|\$(?:(?!\{)|\{[^{}]*\}))*?"""/,alias:"multiline",inside:{interpolation:{pattern:/\$(?:[a-z_]\w*|\{[^{}]*\})/i,inside:r},string:/[\s\S]+/}},{pattern:/"(?:[^"\\\r\n$]|\\.|\$(?:(?!\{)|\{[^{}]*\}))*"/,alias:"singleline",inside:{interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$(?:[a-z_]\w*|\{[^{}]*\})/i,lookbehind:!0,inside:r},string:/[\s\S]+/}}],char:{pattern:/'(?:[^'\\\r\n]|\\(?:.|u[a-fA-F0-9]{0,4}))'/,greedy:!0}}),delete i.languages.kotlin.string,i.languages.insertBefore("kotlin","keyword",{annotation:{pattern:/\B@(?:\w+:)?(?:[A-Z]\w*|\[[^\]]+\])/,alias:"builtin"}}),i.languages.insertBefore("kotlin","function",{label:{pattern:/\b\w+@|@\w+\b/,alias:"symbol"}}),i.languages.kt=i.languages.kotlin,i.languages.kts=i.languages.kotlin})(l)}$o.displayName="less";$o.aliases=[];function $o(l){l.register(Tl),l.languages.less=l.languages.extend("css",{comment:[/\/\*[\s\S]*?\*\//,{pattern:/(^|[^\\])\/\/.*/,lookbehind:!0}],atrule:{pattern:/@[\w-](?:\((?:[^(){}]|\([^(){}]*\))*\)|[^(){};\s]|\s+(?!\s))*?(?=\s*\{)/,inside:{punctuation:/[:()]/}},selector:{pattern:/(?:@\{[\w-]+\}|[^{};\s@])(?:@\{[\w-]+\}|\((?:[^(){}]|\([^(){}]*\))*\)|[^(){};@\s]|\s+(?!\s))*?(?=\s*\{)/,inside:{variable:/@+[\w-]+/}},property:/(?:@\{[\w-]+\}|[\w-])+(?:\+_?)?(?=\s*:)/,operator:/[+\-*\/]/}),l.languages.insertBefore("less","property",{variable:[{pattern:/@[\w-]+\s*:/,inside:{punctuation:/:/}},/@@?[\w-]+/],"mixin-usage":{pattern:/([{;]\s*)[.#](?!\d)[\w-].*?(?=[(;])/,lookbehind:!0,alias:"function"}})}Vo.displayName="lua";Vo.aliases=[];function Vo(l){l.languages.lua={comment:/^#!.+|--(?:\[(=*)\[[\s\S]*?\]\1\]|.*)/m,string:{pattern:/(["'])(?:(?!\1)[^\\\r\n]|\\z(?:\r\n|\s)|\\(?:\r\n|[^z]))*\1|\[(=*)\[[\s\S]*?\]\2\]/,greedy:!0},number:/\b0x[a-f\d]+(?:\.[a-f\d]*)?(?:p[+-]?\d+)?\b|\b\d+(?:\.\B|(?:\.\d*)?(?:e[+-]?\d+)?\b)|\B\.\d+(?:e[+-]?\d+)?\b/i,keyword:/\b(?:and|break|do|else|elseif|end|false|for|function|goto|if|in|local|nil|not|or|repeat|return|then|true|until|while)\b/,function:/(?!\d)\w+(?=\s*(?:[({]))/,operator:[/[-+*%^&|#]|\/\/?|<[<=]?|>[>=]?|[=~]=?/,{pattern:/(^|[^.])\.\.(?!\.)/,lookbehind:!0}],punctuation:/[\[\](){},;]|\.+|:+/}}Ko.displayName="makefile";Ko.aliases=[];function Ko(l){l.languages.makefile={comment:{pattern:/(^|[^\\])#(?:\\(?:\r\n|[\s\S])|[^\\\r\n])*/,lookbehind:!0},string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"builtin-target":{pattern:/\.[A-Z][^:#=\s]+(?=\s*:(?!=))/,alias:"builtin"},target:{pattern:/^(?:[^:=\s]|[ \t]+(?![\s:]))+(?=\s*:(?!=))/m,alias:"symbol",inside:{variable:/\$+(?:(?!\$)[^(){}:#=\s]+|(?=[({]))/}},variable:/\$+(?:(?!\$)[^(){}:#=\s]+|\([@*%<^+?][DF]\)|(?=[({]))/,keyword:/-include\b|\b(?:define|else|endef|endif|export|ifn?def|ifn?eq|include|override|private|sinclude|undefine|unexport|vpath)\b/,function:{pattern:/(\()(?:abspath|addsuffix|and|basename|call|dir|error|eval|file|filter(?:-out)?|findstring|firstword|flavor|foreach|guile|if|info|join|lastword|load|notdir|or|origin|patsubst|realpath|shell|sort|strip|subst|suffix|value|warning|wildcard|word(?:list|s)?)(?=[ \t])/,lookbehind:!0},operator:/(?:::|[?:+!])?=|[|@]/,punctuation:/[:;(){}]/}}Qo.displayName="yaml";Qo.aliases=["yml"];function Qo(l){(function(i){var r=/[*&][^\s[\]{},]+/,s=/!(?:<[\w\-%#;/?:@&=+$,.!~*'()[\]]+>|(?:[a-zA-Z\d-]*!)?[\w\-%#;/?:@&=+$.~*'()]+)?/,o="(?:"+s.source+"(?:[ ]+"+r.source+")?|"+r.source+"(?:[ ]+"+s.source+")?)",d=/(?:[^\s\x00-\x08\x0e-\x1f!"#%&'*,\-:>?@[\]`{|}\x7f-\x84\x86-\x9f\ud800-\udfff\ufffe\uffff]|[?:-]<PLAIN>)(?:[ \t]*(?:(?![#:])<PLAIN>|:<PLAIN>))*/.source.replace(/<PLAIN>/g,function(){return/[^\s\x00-\x08\x0e-\x1f,[\]{}\x7f-\x84\x86-\x9f\ud800-\udfff\ufffe\uffff]/.source}),h=/"(?:[^"\\\r\n]|\\.)*"|'(?:[^'\\\r\n]|\\.)*'/.source;function m(g,y){y=(y||"").replace(/m/g,"")+"m";var b=/([:\-,[{]\s*(?:\s<<prop>>[ \t]+)?)(?:<<value>>)(?=[ \t]*(?:$|,|\]|\}|(?:[\r\n]\s*)?#))/.source.replace(/<<prop>>/g,function(){return o}).replace(/<<value>>/g,function(){return g});return RegExp(b,y)}i.languages.yaml={scalar:{pattern:RegExp(/([\-:]\s*(?:\s<<prop>>[ \t]+)?[|>])[ \t]*(?:((?:\r?\n|\r)[ \t]+)\S[^\r\n]*(?:\2[^\r\n]+)*)/.source.replace(/<<prop>>/g,function(){return o})),lookbehind:!0,alias:"string"},comment:/#.*/,key:{pattern:RegExp(/((?:^|[:\-,[{\r\n?])[ \t]*(?:<<prop>>[ \t]+)?)<<key>>(?=\s*:\s)/.source.replace(/<<prop>>/g,function(){return o}).replace(/<<key>>/g,function(){return"(?:"+d+"|"+h+")"})),lookbehind:!0,greedy:!0,alias:"atrule"},directive:{pattern:/(^[ \t]*)%.+/m,lookbehind:!0,alias:"important"},datetime:{pattern:m(/\d{4}-\d\d?-\d\d?(?:[tT]|[ \t]+)\d\d?:\d{2}:\d{2}(?:\.\d*)?(?:[ \t]*(?:Z|[-+]\d\d?(?::\d{2})?))?|\d{4}-\d{2}-\d{2}|\d\d?:\d{2}(?::\d{2}(?:\.\d*)?)?/.source),lookbehind:!0,alias:"number"},boolean:{pattern:m(/false|true/.source,"i"),lookbehind:!0,alias:"important"},null:{pattern:m(/null|~/.source,"i"),lookbehind:!0,alias:"important"},string:{pattern:m(h),lookbehind:!0,greedy:!0},number:{pattern:m(/[+-]?(?:0x[\da-f]+|0o[0-7]+|(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?|\.inf|\.nan)/.source,"i"),lookbehind:!0},tag:s,important:r,punctuation:/---|[:[\]{}\-,|>?]|\.\.\./},i.languages.yml=i.languages.yaml})(l)}Jo.displayName="markdown";Jo.aliases=["md"];function Jo(l){l.register(Dr),(function(i){var r=/(?:\\.|[^\\\n\r]|(?:\n|\r\n?)(?![\r\n]))/.source;function s(m){return m=m.replace(/<inner>/g,function(){return r}),RegExp(/((?:^|[^\\])(?:\\{2})*)/.source+"(?:"+m+")")}var o=/(?:\\.|``(?:[^`\r\n]|`(?!`))+``|`[^`\r\n]+`|[^\\|\r\n`])+/.source,d=/\|?__(?:\|__)+\|?(?:(?:\n|\r\n?)|(?![\s\S]))/.source.replace(/__/g,function(){return o}),h=/\|?[ \t]*:?-{3,}:?[ \t]*(?:\|[ \t]*:?-{3,}:?[ \t]*)+\|?(?:\n|\r\n?)/.source;i.languages.markdown=i.languages.extend("markup",{}),i.languages.insertBefore("markdown","prolog",{"front-matter-block":{pattern:/(^(?:\s*[\r\n])?)---(?!.)[\s\S]*?[\r\n]---(?!.)/,lookbehind:!0,greedy:!0,inside:{punctuation:/^---|---$/,"front-matter":{pattern:/\S+(?:\s+\S+)*/,alias:["yaml","language-yaml"],inside:i.languages.yaml}}},blockquote:{pattern:/^>(?:[\t ]*>)*/m,alias:"punctuation"},table:{pattern:RegExp("^"+d+h+"(?:"+d+")*","m"),inside:{"table-data-rows":{pattern:RegExp("^("+d+h+")(?:"+d+")*$"),lookbehind:!0,inside:{"table-data":{pattern:RegExp(o),inside:i.languages.markdown},punctuation:/\|/}},"table-line":{pattern:RegExp("^("+d+")"+h+"$"),lookbehind:!0,inside:{punctuation:/\||:?-{3,}:?/}},"table-header-row":{pattern:RegExp("^"+d+"$"),inside:{"table-header":{pattern:RegExp(o),alias:"important",inside:i.languages.markdown},punctuation:/\|/}}}},code:[{pattern:/((?:^|\n)[ \t]*\n|(?:^|\r\n?)[ \t]*\r\n?)(?: {4}|\t).+(?:(?:\n|\r\n?)(?: {4}|\t).+)*/,lookbehind:!0,alias:"keyword"},{pattern:/^```[\s\S]*?^```$/m,greedy:!0,inside:{"code-block":{pattern:/^(```.*(?:\n|\r\n?))[\s\S]+?(?=(?:\n|\r\n?)^```$)/m,lookbehind:!0},"code-language":{pattern:/^(```).+/,lookbehind:!0},punctuation:/```/}}],title:[{pattern:/\S.*(?:\n|\r\n?)(?:==+|--+)(?=[ \t]*$)/m,alias:"important",inside:{punctuation:/==+$|--+$/}},{pattern:/(^\s*)#.+/m,lookbehind:!0,alias:"important",inside:{punctuation:/^#+|#+$/}}],hr:{pattern:/(^\s*)([*-])(?:[\t ]*\2){2,}(?=\s*$)/m,lookbehind:!0,alias:"punctuation"},list:{pattern:/(^\s*)(?:[*+-]|\d+\.)(?=[\t ].)/m,lookbehind:!0,alias:"punctuation"},"url-reference":{pattern:/!?\[[^\]]+\]:[\t ]+(?:\S+|<(?:\\.|[^>\\])+>)(?:[\t ]+(?:"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\((?:\\.|[^)\\])*\)))?/,inside:{variable:{pattern:/^(!?\[)[^\]]+/,lookbehind:!0},string:/(?:"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\((?:\\.|[^)\\])*\))$/,punctuation:/^[\[\]!:]|[<>]/},alias:"url"},bold:{pattern:s(/\b__(?:(?!_)<inner>|_(?:(?!_)<inner>)+_)+__\b|\*\*(?:(?!\*)<inner>|\*(?:(?!\*)<inner>)+\*)+\*\*/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^..)[\s\S]+(?=..$)/,lookbehind:!0,inside:{}},punctuation:/\*\*|__/}},italic:{pattern:s(/\b_(?:(?!_)<inner>|__(?:(?!_)<inner>)+__)+_\b|\*(?:(?!\*)<inner>|\*\*(?:(?!\*)<inner>)+\*\*)+\*/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^.)[\s\S]+(?=.$)/,lookbehind:!0,inside:{}},punctuation:/[*_]/}},strike:{pattern:s(/(~~?)(?:(?!~)<inner>)+\2/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^~~?)[\s\S]+(?=\1$)/,lookbehind:!0,inside:{}},punctuation:/~~?/}},"code-snippet":{pattern:/(^|[^\\`])(?:``[^`\r\n]+(?:`[^`\r\n]+)*``(?!`)|`[^`\r\n]+`(?!`))/,lookbehind:!0,greedy:!0,alias:["code","keyword"]},url:{pattern:s(/!?\[(?:(?!\])<inner>)+\](?:\([^\s)]+(?:[\t ]+"(?:\\.|[^"\\])*")?\)|[ \t]?\[(?:(?!\])<inner>)+\])/.source),lookbehind:!0,greedy:!0,inside:{operator:/^!/,content:{pattern:/(^\[)[^\]]+(?=\])/,lookbehind:!0,inside:{}},variable:{pattern:/(^\][ \t]?\[)[^\]]+(?=\]$)/,lookbehind:!0},url:{pattern:/(^\]\()[^\s)]+/,lookbehind:!0},string:{pattern:/(^[ \t]+)"(?:\\.|[^"\\])*"(?=\)$)/,lookbehind:!0}}}}),["url","bold","italic","strike"].forEach(function(m){["url","bold","italic","strike","code-snippet"].forEach(function(g){m!==g&&(i.languages.markdown[m].inside.content.inside[g]=i.languages.markdown[g])})}),i.hooks.add("after-tokenize",function(m){if(m.language!=="markdown"&&m.language!=="md")return;function g(y){if(!(!y||typeof y=="string"))for(var b=0,x=y.length;b<x;b++){var S=y[b];if(S.type!=="code"){g(S.content);continue}var E=S.content[1],A=S.content[3];if(E&&A&&E.type==="code-language"&&A.type==="code-block"&&typeof E.content=="string"){var C=E.content.replace(/\b#/g,"sharp").replace(/\b\+\+/g,"pp");C=(/[a-z][\w-]*/i.exec(C)||[""])[0].toLowerCase();var _="language-"+C;A.alias?typeof A.alias=="string"?A.alias=[A.alias,_]:A.alias.push(_):A.alias=[_]}}}g(m.tokens)}),i.hooks.add("wrap",function(m){if(m.type==="code-block"){for(var g="",y=0,b=m.classes.length;y<b;y++){var x=m.classes[y],S=/language-(.+)/.exec(x);if(S){g=S[1];break}}var E=i.languages[g];if(E)m.content=i.highlight(m.content.value,E,g);else if(g&&g!=="none"&&i.plugins.autoloader){var A="md-"+new Date().valueOf()+"-"+Math.floor(Math.random()*1e16);m.attributes.id=A,i.plugins.autoloader.loadLanguages(g,function(){var C=document.getElementById(A);C&&(C.innerHTML=i.highlight(C.textContent,i.languages[g],g))})}}}),RegExp(i.languages.markup.tag.pattern.source,"gi"),i.languages.md=i.languages.markdown})(l)}Wo.displayName="objectivec";Wo.aliases=["objc"];function Wo(l){l.register(Mr),l.languages.objectivec=l.languages.extend("c",{string:{pattern:/@?"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},keyword:/\b(?:asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|in|inline|int|long|register|return|self|short|signed|sizeof|static|struct|super|switch|typedef|typeof|union|unsigned|void|volatile|while)\b|(?:@interface|@end|@implementation|@protocol|@class|@public|@protected|@private|@property|@try|@catch|@finally|@throw|@synthesize|@dynamic|@selector)\b/,operator:/-[->]?|\+\+?|!=?|<<?=?|>>?=?|==?|&&?|\|\|?|[~^%?*\/@]/}),delete l.languages.objectivec["class-name"],l.languages.objc=l.languages.objectivec}Po.displayName="perl";Po.aliases=[];function Po(l){(function(i){var r=/(?:\((?:[^()\\]|\\[\s\S])*\)|\{(?:[^{}\\]|\\[\s\S])*\}|\[(?:[^[\]\\]|\\[\s\S])*\]|<(?:[^<>\\]|\\[\s\S])*>)/.source;i.languages.perl={comment:[{pattern:/(^\s*)=\w[\s\S]*?=cut.*/m,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\$])#.*/,lookbehind:!0,greedy:!0}],string:[{pattern:RegExp(/\b(?:q|qq|qw|qx)(?![a-zA-Z0-9])\s*/.source+"(?:"+[/([^a-zA-Z0-9\s{(\[<])(?:(?!\1)[^\\]|\\[\s\S])*\1/.source,/([a-zA-Z0-9])(?:(?!\2)[^\\]|\\[\s\S])*\2/.source,r].join("|")+")"),greedy:!0},{pattern:/("|`)(?:(?!\1)[^\\]|\\[\s\S])*\1/,greedy:!0},{pattern:/'(?:[^'\\\r\n]|\\.)*'/,greedy:!0}],regex:[{pattern:RegExp(/\b(?:m|qr)(?![a-zA-Z0-9])\s*/.source+"(?:"+[/([^a-zA-Z0-9\s{(\[<])(?:(?!\1)[^\\]|\\[\s\S])*\1/.source,/([a-zA-Z0-9])(?:(?!\2)[^\\]|\\[\s\S])*\2/.source,r].join("|")+")"+/[msixpodualngc]*/.source),greedy:!0},{pattern:RegExp(/(^|[^-])\b(?:s|tr|y)(?![a-zA-Z0-9])\s*/.source+"(?:"+[/([^a-zA-Z0-9\s{(\[<])(?:(?!\2)[^\\]|\\[\s\S])*\2(?:(?!\2)[^\\]|\\[\s\S])*\2/.source,/([a-zA-Z0-9])(?:(?!\3)[^\\]|\\[\s\S])*\3(?:(?!\3)[^\\]|\\[\s\S])*\3/.source,r+/\s*/.source+r].join("|")+")"+/[msixpodualngcer]*/.source),lookbehind:!0,greedy:!0},{pattern:/\/(?:[^\/\\\r\n]|\\.)*\/[msixpodualngc]*(?=\s*(?:$|[\r\n,.;})&|\-+*~<>!?^]|(?:and|cmp|eq|ge|gt|le|lt|ne|not|or|x|xor)\b))/,greedy:!0}],variable:[/[&*$@%]\{\^[A-Z]+\}/,/[&*$@%]\^[A-Z_]/,/[&*$@%]#?(?=\{)/,/[&*$@%]#?(?:(?:::)*'?(?!\d)[\w$]+(?![\w$]))+(?:::)*/,/[&*$@%]\d+/,/(?!%=)[$@%][!"#$%&'()*+,\-.\/:;<=>?@[\\\]^_`{|}~]/],filehandle:{pattern:/<(?![<=])\S*?>|\b_\b/,alias:"symbol"},"v-string":{pattern:/v\d+(?:\.\d+)*|\d+(?:\.\d+){2,}/,alias:"string"},function:{pattern:/(\bsub[ \t]+)\w+/,lookbehind:!0},keyword:/\b(?:any|break|continue|default|delete|die|do|else|elsif|eval|for|foreach|given|goto|if|last|local|my|next|our|package|print|redo|require|return|say|state|sub|switch|undef|unless|until|use|when|while)\b/,number:/\b(?:0x[\dA-Fa-f](?:_?[\dA-Fa-f])*|0b[01](?:_?[01])*|(?:(?:\d(?:_?\d)*)?\.)?\d(?:_?\d)*(?:[Ee][+-]?\d+)?)\b/,operator:/-[rwxoRWXOezsfdlpSbctugkTBMAC]\b|\+[+=]?|-[-=>]?|\*\*?=?|\/\/?=?|=[=~>]?|~[~=]?|\|\|?=?|&&?=?|<(?:=>?|<=?)?|>>?=?|![~=]?|[%^]=?|\.(?:=|\.\.?)?|[\\?]|\bx(?:=|\b)|\b(?:and|cmp|eq|ge|gt|le|lt|ne|not|or|xor)\b/,punctuation:/[{}[\];(),:]/}})(l)}Ts.displayName="markup-templating";Ts.aliases=[];function Ts(l){l.register(Dr),(function(i){function r(s,o){return"___"+s.toUpperCase()+o+"___"}Object.defineProperties(i.languages["markup-templating"]={},{buildPlaceholders:{value:function(s,o,d,h){if(s.language===o){var m=s.tokenStack=[];s.code=s.code.replace(d,function(g){if(typeof h=="function"&&!h(g))return g;for(var y=m.length,b;s.code.indexOf(b=r(o,y))!==-1;)++y;return m[y]=g,b}),s.grammar=i.languages.markup}}},tokenizePlaceholders:{value:function(s,o){if(s.language!==o||!s.tokenStack)return;s.grammar=i.languages[o];var d=0,h=Object.keys(s.tokenStack);function m(g){for(var y=0;y<g.length&&!(d>=h.length);y++){var b=g[y];if(typeof b=="string"||b.content&&typeof b.content=="string"){var x=h[d],S=s.tokenStack[x],E=typeof b=="string"?b:b.content,A=r(o,x),C=E.indexOf(A);if(C>-1){++d;var _=E.substring(0,C),B=new i.Token(o,i.tokenize(S,s.grammar),"language-"+o,S),q=E.substring(C+A.length),R=[];_&&R.push.apply(R,m([_])),R.push(B),q&&R.push.apply(R,m([q])),typeof b=="string"?g.splice.apply(g,[y,1].concat(R)):b.content=R}}else b.content&&m(b.content)}return g}m(s.tokens)}}})})(l)}ef.displayName="php";ef.aliases=[];function ef(l){l.register(Ts),(function(i){var r=/\/\*[\s\S]*?\*\/|\/\/.*|#(?!\[).*/,s=[{pattern:/\b(?:false|true)\b/i,alias:"boolean"},{pattern:/(::\s*)\b[a-z_]\w*\b(?!\s*\()/i,greedy:!0,lookbehind:!0},{pattern:/(\b(?:case|const)\s+)\b[a-z_]\w*(?=\s*[;=])/i,greedy:!0,lookbehind:!0},/\b(?:null)\b/i,/\b[A-Z_][A-Z0-9_]*\b(?!\s*\()/],o=/\b0b[01]+(?:_[01]+)*\b|\b0o[0-7]+(?:_[0-7]+)*\b|\b0x[\da-f]+(?:_[\da-f]+)*\b|(?:\b\d+(?:_\d+)*\.?(?:\d+(?:_\d+)*)?|\B\.\d+)(?:e[+-]?\d+)?/i,d=/<?=>|\?\?=?|\.{3}|\??->|[!=]=?=?|::|\*\*=?|--|\+\+|&&|\|\||<<|>>|[?~]|[/^|%*&<>.+-]=?/,h=/[{}\[\](),:;]/;i.languages.php={delimiter:{pattern:/\?>$|^<\?(?:php(?=\s)|=)?/i,alias:"important"},comment:r,variable:/\$+(?:\w+\b|(?=\{))/,package:{pattern:/(namespace\s+|use\s+(?:function\s+)?)(?:\\?\b[a-z_]\w*)+\b(?!\\)/i,lookbehind:!0,inside:{punctuation:/\\/}},"class-name-definition":{pattern:/(\b(?:class|enum|interface|trait)\s+)\b[a-z_]\w*(?!\\)\b/i,lookbehind:!0,alias:"class-name"},"function-definition":{pattern:/(\bfunction\s+)[a-z_]\w*(?=\s*\()/i,lookbehind:!0,alias:"function"},keyword:[{pattern:/(\(\s*)\b(?:array|bool|boolean|float|int|integer|object|string)\b(?=\s*\))/i,alias:"type-casting",greedy:!0,lookbehind:!0},{pattern:/([(,?]\s*)\b(?:array(?!\s*\()|bool|callable|(?:false|null)(?=\s*\|)|float|int|iterable|mixed|object|self|static|string)\b(?=\s*\$)/i,alias:"type-hint",greedy:!0,lookbehind:!0},{pattern:/(\)\s*:\s*(?:\?\s*)?)\b(?:array(?!\s*\()|bool|callable|(?:false|null)(?=\s*\|)|float|int|iterable|mixed|never|object|self|static|string|void)\b/i,alias:"return-type",greedy:!0,lookbehind:!0},{pattern:/\b(?:array(?!\s*\()|bool|float|int|iterable|mixed|object|string|void)\b/i,alias:"type-declaration",greedy:!0},{pattern:/(\|\s*)(?:false|null)\b|\b(?:false|null)(?=\s*\|)/i,alias:"type-declaration",greedy:!0,lookbehind:!0},{pattern:/\b(?:parent|self|static)(?=\s*::)/i,alias:"static-context",greedy:!0},{pattern:/(\byield\s+)from\b/i,lookbehind:!0},/\bclass\b/i,{pattern:/((?:^|[^\s>:]|(?:^|[^-])>|(?:^|[^:]):)\s*)\b(?:abstract|and|array|as|break|callable|case|catch|clone|const|continue|declare|default|die|do|echo|else|elseif|empty|enddeclare|endfor|endforeach|endif|endswitch|endwhile|enum|eval|exit|extends|final|finally|fn|for|foreach|function|global|goto|if|implements|include|include_once|instanceof|insteadof|interface|isset|list|match|namespace|never|new|or|parent|print|private|protected|public|readonly|require|require_once|return|self|static|switch|throw|trait|try|unset|use|var|while|xor|yield|__halt_compiler)\b/i,lookbehind:!0}],"argument-name":{pattern:/([(,]\s*)\b[a-z_]\w*(?=\s*:(?!:))/i,lookbehind:!0},"class-name":[{pattern:/(\b(?:extends|implements|instanceof|new(?!\s+self|\s+static))\s+|\bcatch\s*\()\b[a-z_]\w*(?!\\)\b/i,greedy:!0,lookbehind:!0},{pattern:/(\|\s*)\b[a-z_]\w*(?!\\)\b/i,greedy:!0,lookbehind:!0},{pattern:/\b[a-z_]\w*(?!\\)\b(?=\s*\|)/i,greedy:!0},{pattern:/(\|\s*)(?:\\?\b[a-z_]\w*)+\b/i,alias:"class-name-fully-qualified",greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}},{pattern:/(?:\\?\b[a-z_]\w*)+\b(?=\s*\|)/i,alias:"class-name-fully-qualified",greedy:!0,inside:{punctuation:/\\/}},{pattern:/(\b(?:extends|implements|instanceof|new(?!\s+self\b|\s+static\b))\s+|\bcatch\s*\()(?:\\?\b[a-z_]\w*)+\b(?!\\)/i,alias:"class-name-fully-qualified",greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}},{pattern:/\b[a-z_]\w*(?=\s*\$)/i,alias:"type-declaration",greedy:!0},{pattern:/(?:\\?\b[a-z_]\w*)+(?=\s*\$)/i,alias:["class-name-fully-qualified","type-declaration"],greedy:!0,inside:{punctuation:/\\/}},{pattern:/\b[a-z_]\w*(?=\s*::)/i,alias:"static-context",greedy:!0},{pattern:/(?:\\?\b[a-z_]\w*)+(?=\s*::)/i,alias:["class-name-fully-qualified","static-context"],greedy:!0,inside:{punctuation:/\\/}},{pattern:/([(,?]\s*)[a-z_]\w*(?=\s*\$)/i,alias:"type-hint",greedy:!0,lookbehind:!0},{pattern:/([(,?]\s*)(?:\\?\b[a-z_]\w*)+(?=\s*\$)/i,alias:["class-name-fully-qualified","type-hint"],greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}},{pattern:/(\)\s*:\s*(?:\?\s*)?)\b[a-z_]\w*(?!\\)\b/i,alias:"return-type",greedy:!0,lookbehind:!0},{pattern:/(\)\s*:\s*(?:\?\s*)?)(?:\\?\b[a-z_]\w*)+\b(?!\\)/i,alias:["class-name-fully-qualified","return-type"],greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}}],constant:s,function:{pattern:/(^|[^\\\w])\\?[a-z_](?:[\w\\]*\w)?(?=\s*\()/i,lookbehind:!0,inside:{punctuation:/\\/}},property:{pattern:/(->\s*)\w+/,lookbehind:!0},number:o,operator:d,punctuation:h};var m={pattern:/\{\$(?:\{(?:\{[^{}]+\}|[^{}]+)\}|[^{}])+\}|(^|[^\\{])\$+(?:\w+(?:\[[^\r\n\[\]]+\]|->\w+)?)/,lookbehind:!0,inside:i.languages.php},g=[{pattern:/<<<'([^']+)'[\r\n](?:.*[\r\n])*?\1;/,alias:"nowdoc-string",greedy:!0,inside:{delimiter:{pattern:/^<<<'[^']+'|[a-z_]\w*;$/i,alias:"symbol",inside:{punctuation:/^<<<'?|[';]$/}}}},{pattern:/<<<(?:"([^"]+)"[\r\n](?:.*[\r\n])*?\1;|([a-z_]\w*)[\r\n](?:.*[\r\n])*?\2;)/i,alias:"heredoc-string",greedy:!0,inside:{delimiter:{pattern:/^<<<(?:"[^"]+"|[a-z_]\w*)|[a-z_]\w*;$/i,alias:"symbol",inside:{punctuation:/^<<<"?|[";]$/}},interpolation:m}},{pattern:/`(?:\\[\s\S]|[^\\`])*`/,alias:"backtick-quoted-string",greedy:!0},{pattern:/'(?:\\[\s\S]|[^\\'])*'/,alias:"single-quoted-string",greedy:!0},{pattern:/"(?:\\[\s\S]|[^\\"])*"/,alias:"double-quoted-string",greedy:!0,inside:{interpolation:m}}];i.languages.insertBefore("php","variable",{string:g,attribute:{pattern:/#\[(?:[^"'\/#]|\/(?![*/])|\/\/.*$|#(?!\[).*$|\/\*(?:[^*]|\*(?!\/))*\*\/|"(?:\\[\s\S]|[^\\"])*"|'(?:\\[\s\S]|[^\\'])*')+\](?=\s*[a-z$#])/im,greedy:!0,inside:{"attribute-content":{pattern:/^(#\[)[\s\S]+(?=\]$)/,lookbehind:!0,inside:{comment:r,string:g,"attribute-class-name":[{pattern:/([^:]|^)\b[a-z_]\w*(?!\\)\b/i,alias:"class-name",greedy:!0,lookbehind:!0},{pattern:/([^:]|^)(?:\\?\b[a-z_]\w*)+/i,alias:["class-name","class-name-fully-qualified"],greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}}],constant:s,number:o,operator:d,punctuation:h}},delimiter:{pattern:/^#\[|\]$/,alias:"punctuation"}}}}),i.hooks.add("before-tokenize",function(y){if(/<\?/.test(y.code)){var b=/<\?(?:[^"'/#]|\/(?![*/])|("|')(?:\\[\s\S]|(?!\1)[^\\])*\1|(?:\/\/|#(?!\[))(?:[^?\n\r]|\?(?!>))*(?=$|\?>|[\r\n])|#\[|\/\*(?:[^*]|\*(?!\/))*(?:\*\/|$))*?(?:\?>|$)/g;i.languages["markup-templating"].buildPlaceholders(y,"php",b)}}),i.hooks.add("after-tokenize",function(y){i.languages["markup-templating"].tokenizePlaceholders(y,"php")})})(l)}tf.displayName="python";tf.aliases=["py"];function tf(l){l.languages.python={comment:{pattern:/(^|[^\\])#.*/,lookbehind:!0,greedy:!0},"string-interpolation":{pattern:/(?:f|fr|rf)(?:("""|''')[\s\S]*?\1|("|')(?:\\.|(?!\2)[^\\\r\n])*\2)/i,greedy:!0,inside:{interpolation:{pattern:/((?:^|[^{])(?:\{\{)*)\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}])+\})+\})+\}/,lookbehind:!0,inside:{"format-spec":{pattern:/(:)[^:(){}]+(?=\}$)/,lookbehind:!0},"conversion-option":{pattern:/![sra](?=[:}]$)/,alias:"punctuation"},rest:null}},string:/[\s\S]+/}},"triple-quoted-string":{pattern:/(?:[rub]|br|rb)?("""|''')[\s\S]*?\1/i,greedy:!0,alias:"string"},string:{pattern:/(?:[rub]|br|rb)?("|')(?:\\.|(?!\1)[^\\\r\n])*\1/i,greedy:!0},function:{pattern:/((?:^|\s)def[ \t]+)[a-zA-Z_]\w*(?=\s*\()/g,lookbehind:!0},"class-name":{pattern:/(\bclass\s+)\w+/i,lookbehind:!0},decorator:{pattern:/(^[\t ]*)@\w+(?:\.\w+)*/m,lookbehind:!0,alias:["annotation","punctuation"],inside:{punctuation:/\./}},keyword:/\b(?:_(?=\s*:)|and|as|assert|async|await|break|case|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|match|nonlocal|not|or|pass|print|raise|return|try|while|with|yield)\b/,builtin:/\b(?:__import__|abs|all|any|apply|ascii|basestring|bin|bool|buffer|bytearray|bytes|callable|chr|classmethod|cmp|coerce|compile|complex|delattr|dict|dir|divmod|enumerate|eval|execfile|file|filter|float|format|frozenset|getattr|globals|hasattr|hash|help|hex|id|input|int|intern|isinstance|issubclass|iter|len|list|locals|long|map|max|memoryview|min|next|object|oct|open|ord|pow|property|range|raw_input|reduce|reload|repr|reversed|round|set|setattr|slice|sorted|staticmethod|str|sum|super|tuple|type|unichr|unicode|vars|xrange|zip)\b/,boolean:/\b(?:False|None|True)\b/,number:/\b0(?:b(?:_?[01])+|o(?:_?[0-7])+|x(?:_?[a-f0-9])+)\b|(?:\b\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\B\.\d+(?:_\d+)*)(?:e[+-]?\d+(?:_\d+)*)?j?(?!\w)/i,operator:/[-+%=]=?|!=|:=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,punctuation:/[{}[\];(),.:]/},l.languages.python["string-interpolation"].inside.interpolation.inside.rest=l.languages.python,l.languages.py=l.languages.python}nf.displayName="r";nf.aliases=[];function nf(l){l.languages.r={comment:/#.*/,string:{pattern:/(['"])(?:\\.|(?!\1)[^\\\r\n])*\1/,greedy:!0},"percent-operator":{pattern:/%[^%\s]*%/,alias:"operator"},boolean:/\b(?:FALSE|TRUE)\b/,ellipsis:/\.\.(?:\.|\d+)/,number:[/\b(?:Inf|NaN)\b/,/(?:\b0x[\dA-Fa-f]+(?:\.\d*)?|\b\d+(?:\.\d*)?|\B\.\d+)(?:[EePp][+-]?\d+)?[iL]?/],keyword:/\b(?:NA|NA_character_|NA_complex_|NA_integer_|NA_real_|NULL|break|else|for|function|if|in|next|repeat|while)\b/,operator:/->?>?|<(?:=|<?-)?|[>=!]=?|::?|&&?|\|\|?|[+*\/^$@~]/,punctuation:/[(){}\[\],;]/}}af.displayName="ruby";af.aliases=["rb"];function af(l){l.register(sn),(function(i){i.languages.ruby=i.languages.extend("clike",{comment:{pattern:/#.*|^=begin\s[\s\S]*?^=end/m,greedy:!0},"class-name":{pattern:/(\b(?:class|module)\s+|\bcatch\s+\()[\w.\\]+|\b[A-Z_]\w*(?=\s*\.\s*new\b)/,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:BEGIN|END|alias|and|begin|break|case|class|def|define_method|defined|do|each|else|elsif|end|ensure|extend|for|if|in|include|module|new|next|nil|not|or|prepend|private|protected|public|raise|redo|require|rescue|retry|return|self|super|then|throw|undef|unless|until|when|while|yield)\b/,operator:/\.{2,3}|&\.|===|<?=>|[!=]?~|(?:&&|\|\||<<|>>|\*\*|[+\-*/%<>!^&|=])=?|[?:]/,punctuation:/[(){}[\].,;]/}),i.languages.insertBefore("ruby","operator",{"double-colon":{pattern:/::/,alias:"punctuation"}});var r={pattern:/((?:^|[^\\])(?:\\{2})*)#\{(?:[^{}]|\{[^{}]*\})*\}/,lookbehind:!0,inside:{content:{pattern:/^(#\{)[\s\S]+(?=\}$)/,lookbehind:!0,inside:i.languages.ruby},delimiter:{pattern:/^#\{|\}$/,alias:"punctuation"}}};delete i.languages.ruby.function;var s="(?:"+[/([^a-zA-Z0-9\s{(\[<=])(?:(?!\1)[^\\]|\\[\s\S])*\1/.source,/\((?:[^()\\]|\\[\s\S]|\((?:[^()\\]|\\[\s\S])*\))*\)/.source,/\{(?:[^{}\\]|\\[\s\S]|\{(?:[^{}\\]|\\[\s\S])*\})*\}/.source,/\[(?:[^\[\]\\]|\\[\s\S]|\[(?:[^\[\]\\]|\\[\s\S])*\])*\]/.source,/<(?:[^<>\\]|\\[\s\S]|<(?:[^<>\\]|\\[\s\S])*>)*>/.source].join("|")+")",o=/(?:"(?:\\.|[^"\\\r\n])*"|(?:\b[a-zA-Z_]\w*|[^\s\0-\x7F]+)[?!]?|\$.)/.source;i.languages.insertBefore("ruby","keyword",{"regex-literal":[{pattern:RegExp(/%r/.source+s+/[egimnosux]{0,6}/.source),greedy:!0,inside:{interpolation:r,regex:/[\s\S]+/}},{pattern:/(^|[^/])\/(?!\/)(?:\[[^\r\n\]]+\]|\\.|[^[/\\\r\n])+\/[egimnosux]{0,6}(?=\s*(?:$|[\r\n,.;})#]))/,lookbehind:!0,greedy:!0,inside:{interpolation:r,regex:/[\s\S]+/}}],variable:/[@$]+[a-zA-Z_]\w*(?:[?!]|\b)/,symbol:[{pattern:RegExp(/(^|[^:]):/.source+o),lookbehind:!0,greedy:!0},{pattern:RegExp(/([\r\n{(,][ \t]*)/.source+o+/(?=:(?!:))/.source),lookbehind:!0,greedy:!0}],"method-definition":{pattern:/(\bdef\s+)\w+(?:\s*\.\s*\w+)?/,lookbehind:!0,inside:{function:/\b\w+$/,keyword:/^self\b/,"class-name":/^\w+/,punctuation:/\./}}}),i.languages.insertBefore("ruby","string",{"string-literal":[{pattern:RegExp(/%[qQiIwWs]?/.source+s),greedy:!0,inside:{interpolation:r,string:/[\s\S]+/}},{pattern:/("|')(?:#\{[^}]+\}|#(?!\{)|\\(?:\r\n|[\s\S])|(?!\1)[^\\#\r\n])*\1/,greedy:!0,inside:{interpolation:r,string:/[\s\S]+/}},{pattern:/<<[-~]?([a-z_]\w*)[\r\n](?:.*[\r\n])*?[\t ]*\1/i,alias:"heredoc-string",greedy:!0,inside:{delimiter:{pattern:/^<<[-~]?[a-z_]\w*|\b[a-z_]\w*$/i,inside:{symbol:/\b\w+/,punctuation:/^<<[-~]?/}},interpolation:r,string:/[\s\S]+/}},{pattern:/<<[-~]?'([a-z_]\w*)'[\r\n](?:.*[\r\n])*?[\t ]*\1/i,alias:"heredoc-string",greedy:!0,inside:{delimiter:{pattern:/^<<[-~]?'[a-z_]\w*'|\b[a-z_]\w*$/i,inside:{symbol:/\b\w+/,punctuation:/^<<[-~]?'|'$/}},string:/[\s\S]+/}}],"command-literal":[{pattern:RegExp(/%x/.source+s),greedy:!0,inside:{interpolation:r,command:{pattern:/[\s\S]+/,alias:"string"}}},{pattern:/`(?:#\{[^}]+\}|#(?!\{)|\\(?:\r\n|[\s\S])|[^\\`#\r\n])*`/,greedy:!0,inside:{interpolation:r,command:{pattern:/[\s\S]+/,alias:"string"}}}]}),delete i.languages.ruby.string,i.languages.insertBefore("ruby","number",{builtin:/\b(?:Array|Bignum|Binding|Class|Continuation|Dir|Exception|FalseClass|File|Fixnum|Float|Hash|IO|Integer|MatchData|Method|Module|NilClass|Numeric|Object|Proc|Range|Regexp|Stat|String|Struct|Symbol|TMS|Thread|ThreadGroup|Time|TrueClass)\b/,constant:/\b[A-Z][A-Z0-9_]*(?:[?!]|\b)/}),i.languages.rb=i.languages.ruby})(l)}lf.displayName="rust";lf.aliases=[];function lf(l){(function(i){for(var r=/\/\*(?:[^*/]|\*(?!\/)|\/(?!\*)|<self>)*\*\//.source,s=0;s<2;s++)r=r.replace(/<self>/g,function(){return r});r=r.replace(/<self>/g,function(){return/[^\s\S]/.source}),i.languages.rust={comment:[{pattern:RegExp(/(^|[^\\])/.source+r),lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/b?"(?:\\[\s\S]|[^\\"])*"|b?r(#*)"(?:[^"]|"(?!\1))*"\1/,greedy:!0},char:{pattern:/b?'(?:\\(?:x[0-7][\da-fA-F]|u\{(?:[\da-fA-F]_*){1,6}\}|.)|[^\\\r\n\t'])'/,greedy:!0},attribute:{pattern:/#!?\[(?:[^\[\]"]|"(?:\\[\s\S]|[^\\"])*")*\]/,greedy:!0,alias:"attr-name",inside:{string:null}},"closure-params":{pattern:/([=(,:]\s*|\bmove\s*)\|[^|]*\||\|[^|]*\|(?=\s*(?:\{|->))/,lookbehind:!0,greedy:!0,inside:{"closure-punctuation":{pattern:/^\||\|$/,alias:"punctuation"},rest:null}},"lifetime-annotation":{pattern:/'\w+/,alias:"symbol"},"fragment-specifier":{pattern:/(\$\w+:)[a-z]+/,lookbehind:!0,alias:"punctuation"},variable:/\$\w+/,"function-definition":{pattern:/(\bfn\s+)\w+/,lookbehind:!0,alias:"function"},"type-definition":{pattern:/(\b(?:enum|struct|trait|type|union)\s+)\w+/,lookbehind:!0,alias:"class-name"},"module-declaration":[{pattern:/(\b(?:crate|mod)\s+)[a-z][a-z_\d]*/,lookbehind:!0,alias:"namespace"},{pattern:/(\b(?:crate|self|super)\s*)::\s*[a-z][a-z_\d]*\b(?:\s*::(?:\s*[a-z][a-z_\d]*\s*::)*)?/,lookbehind:!0,alias:"namespace",inside:{punctuation:/::/}}],keyword:[/\b(?:Self|abstract|as|async|await|become|box|break|const|continue|crate|do|dyn|else|enum|extern|final|fn|for|if|impl|in|let|loop|macro|match|mod|move|mut|override|priv|pub|ref|return|self|static|struct|super|trait|try|type|typeof|union|unsafe|unsized|use|virtual|where|while|yield)\b/,/\b(?:bool|char|f(?:32|64)|[ui](?:8|16|32|64|128|size)|str)\b/],function:/\b[a-z_]\w*(?=\s*(?:::\s*<|\())/,macro:{pattern:/\b\w+!/,alias:"property"},constant:/\b[A-Z_][A-Z_\d]+\b/,"class-name":/\b[A-Z]\w*\b/,namespace:{pattern:/(?:\b[a-z][a-z_\d]*\s*::\s*)*\b[a-z][a-z_\d]*\s*::(?!\s*<)/,inside:{punctuation:/::/}},number:/\b(?:0x[\dA-Fa-f](?:_?[\dA-Fa-f])*|0o[0-7](?:_?[0-7])*|0b[01](?:_?[01])*|(?:(?:\d(?:_?\d)*)?\.)?\d(?:_?\d)*(?:[Ee][+-]?\d+)?)(?:_?(?:f32|f64|[iu](?:8|16|32|64|size)?))?\b/,boolean:/\b(?:false|true)\b/,punctuation:/->|\.\.=|\.{1,3}|::|[{}[\];(),:]/,operator:/[-+*\/%!^]=?|=[=>]?|&[&=]?|\|[|=]?|<<?=?|>>?=?|[@?]/},i.languages.rust["closure-params"].inside.rest=i.languages.rust,i.languages.rust.attribute.inside.string=i.languages.rust.string})(l)}rf.displayName="sass";rf.aliases=[];function rf(l){l.register(Tl),(function(i){i.languages.sass=i.languages.extend("css",{comment:{pattern:/^([ \t]*)\/[\/*].*(?:(?:\r?\n|\r)\1[ \t].+)*/m,lookbehind:!0,greedy:!0}}),i.languages.insertBefore("sass","atrule",{"atrule-line":{pattern:/^(?:[ \t]*)[@+=].+/m,greedy:!0,inside:{atrule:/(?:@[\w-]+|[+=])/}}}),delete i.languages.sass.atrule;var r=/\$[-\w]+|#\{\$[-\w]+\}/,s=[/[+*\/%]|[=!]=|<=?|>=?|\b(?:and|not|or)\b/,{pattern:/(\s)-(?=\s)/,lookbehind:!0}];i.languages.insertBefore("sass","property",{"variable-line":{pattern:/^[ \t]*\$.+/m,greedy:!0,inside:{punctuation:/:/,variable:r,operator:s}},"property-line":{pattern:/^[ \t]*(?:[^:\s]+ *:.*|:[^:\s].*)/m,greedy:!0,inside:{property:[/[^:\s]+(?=\s*:)/,{pattern:/(:)[^:\s]+/,lookbehind:!0}],punctuation:/:/,variable:r,operator:s,important:i.languages.sass.important}}}),delete i.languages.sass.property,delete i.languages.sass.important,i.languages.insertBefore("sass","punctuation",{selector:{pattern:/^([ \t]*)\S(?:,[^,\r\n]+|[^,\r\n]*)(?:,[^,\r\n]+)*(?:,(?:\r?\n|\r)\1[ \t]+\S(?:,[^,\r\n]+|[^,\r\n]*)(?:,[^,\r\n]+)*)*/m,lookbehind:!0,greedy:!0}})})(l)}sf.displayName="scss";sf.aliases=[];function sf(l){l.register(Tl),l.languages.scss=l.languages.extend("css",{comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|\/\/.*)/,lookbehind:!0},atrule:{pattern:/@[\w-](?:\([^()]+\)|[^()\s]|\s+(?!\s))*?(?=\s+[{;])/,inside:{rule:/@[\w-]+/}},url:/(?:[-a-z]+-)?url(?=\()/i,selector:{pattern:/(?=\S)[^@;{}()]?(?:[^@;{}()\s]|\s+(?!\s)|#\{\$[-\w]+\})+(?=\s*\{(?:\}|\s|[^}][^:{}]*[:{][^}]))/,inside:{parent:{pattern:/&/,alias:"important"},placeholder:/%[-\w]+/,variable:/\$[-\w]+|#\{\$[-\w]+\}/}},property:{pattern:/(?:[-\w]|\$[-\w]|#\{\$[-\w]+\})+(?=\s*:)/,inside:{variable:/\$[-\w]+|#\{\$[-\w]+\}/}}}),l.languages.insertBefore("scss","atrule",{keyword:[/@(?:content|debug|each|else(?: if)?|extend|for|forward|function|if|import|include|mixin|return|use|warn|while)\b/i,{pattern:/( )(?:from|through)(?= )/,lookbehind:!0}]}),l.languages.insertBefore("scss","important",{variable:/\$[-\w]+|#\{\$[-\w]+\}/}),l.languages.insertBefore("scss","function",{"module-modifier":{pattern:/\b(?:as|hide|show|with)\b/i,alias:"keyword"},placeholder:{pattern:/%[-\w]+/,alias:"selector"},statement:{pattern:/\B!(?:default|optional)\b/i,alias:"keyword"},boolean:/\b(?:false|true)\b/,null:{pattern:/\bnull\b/,alias:"keyword"},operator:{pattern:/(\s)(?:[-+*\/%]|[=!]=|<=?|>=?|and|not|or)(?=\s)/,lookbehind:!0}}),l.languages.scss.atrule.inside.rest=l.languages.scss}uf.displayName="sql";uf.aliases=[];function uf(l){l.languages.sql={comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|(?:--|\/\/|#).*)/,lookbehind:!0},variable:[{pattern:/@(["'`])(?:\\[\s\S]|(?!\1)[^\\])+\1/,greedy:!0},/@[\w.$]+/],string:{pattern:/(^|[^@\\])("|')(?:\\[\s\S]|(?!\2)[^\\]|\2\2)*\2/,greedy:!0,lookbehind:!0},identifier:{pattern:/(^|[^@\\])`(?:\\[\s\S]|[^`\\]|``)*`/,greedy:!0,lookbehind:!0,inside:{punctuation:/^`|`$/}},function:/\b(?:AVG|COUNT|FIRST|FORMAT|LAST|LCASE|LEN|MAX|MID|MIN|MOD|NOW|ROUND|SUM|UCASE)(?=\s*\()/i,keyword:/\b(?:ACTION|ADD|AFTER|ALGORITHM|ALL|ALTER|ANALYZE|ANY|APPLY|AS|ASC|AUTHORIZATION|AUTO_INCREMENT|BACKUP|BDB|BEGIN|BERKELEYDB|BIGINT|BINARY|BIT|BLOB|BOOL|BOOLEAN|BREAK|BROWSE|BTREE|BULK|BY|CALL|CASCADED?|CASE|CHAIN|CHAR(?:ACTER|SET)?|CHECK(?:POINT)?|CLOSE|CLUSTERED|COALESCE|COLLATE|COLUMNS?|COMMENT|COMMIT(?:TED)?|COMPUTE|CONNECT|CONSISTENT|CONSTRAINT|CONTAINS(?:TABLE)?|CONTINUE|CONVERT|CREATE|CROSS|CURRENT(?:_DATE|_TIME|_TIMESTAMP|_USER)?|CURSOR|CYCLE|DATA(?:BASES?)?|DATE(?:TIME)?|DAY|DBCC|DEALLOCATE|DEC|DECIMAL|DECLARE|DEFAULT|DEFINER|DELAYED|DELETE|DELIMITERS?|DENY|DESC|DESCRIBE|DETERMINISTIC|DISABLE|DISCARD|DISK|DISTINCT|DISTINCTROW|DISTRIBUTED|DO|DOUBLE|DROP|DUMMY|DUMP(?:FILE)?|DUPLICATE|ELSE(?:IF)?|ENABLE|ENCLOSED|END|ENGINE|ENUM|ERRLVL|ERRORS|ESCAPED?|EXCEPT|EXEC(?:UTE)?|EXISTS|EXIT|EXPLAIN|EXTENDED|FETCH|FIELDS|FILE|FILLFACTOR|FIRST|FIXED|FLOAT|FOLLOWING|FOR(?: EACH ROW)?|FORCE|FOREIGN|FREETEXT(?:TABLE)?|FROM|FULL|FUNCTION|GEOMETRY(?:COLLECTION)?|GLOBAL|GOTO|GRANT|GROUP|HANDLER|HASH|HAVING|HOLDLOCK|HOUR|IDENTITY(?:COL|_INSERT)?|IF|IGNORE|IMPORT|INDEX|INFILE|INNER|INNODB|INOUT|INSERT|INT|INTEGER|INTERSECT|INTERVAL|INTO|INVOKER|ISOLATION|ITERATE|JOIN|KEYS?|KILL|LANGUAGE|LAST|LEAVE|LEFT|LEVEL|LIMIT|LINENO|LINES|LINESTRING|LOAD|LOCAL|LOCK|LONG(?:BLOB|TEXT)|LOOP|MATCH(?:ED)?|MEDIUM(?:BLOB|INT|TEXT)|MERGE|MIDDLEINT|MINUTE|MODE|MODIFIES|MODIFY|MONTH|MULTI(?:LINESTRING|POINT|POLYGON)|NATIONAL|NATURAL|NCHAR|NEXT|NO|NONCLUSTERED|NULLIF|NUMERIC|OFF?|OFFSETS?|ON|OPEN(?:DATASOURCE|QUERY|ROWSET)?|OPTIMIZE|OPTION(?:ALLY)?|ORDER|OUT(?:ER|FILE)?|OVER|PARTIAL|PARTITION|PERCENT|PIVOT|PLAN|POINT|POLYGON|PRECEDING|PRECISION|PREPARE|PREV|PRIMARY|PRINT|PRIVILEGES|PROC(?:EDURE)?|PUBLIC|PURGE|QUICK|RAISERROR|READS?|REAL|RECONFIGURE|REFERENCES|RELEASE|RENAME|REPEAT(?:ABLE)?|REPLACE|REPLICATION|REQUIRE|RESIGNAL|RESTORE|RESTRICT|RETURN(?:ING|S)?|REVOKE|RIGHT|ROLLBACK|ROUTINE|ROW(?:COUNT|GUIDCOL|S)?|RTREE|RULE|SAVE(?:POINT)?|SCHEMA|SECOND|SELECT|SERIAL(?:IZABLE)?|SESSION(?:_USER)?|SET(?:USER)?|SHARE|SHOW|SHUTDOWN|SIMPLE|SMALLINT|SNAPSHOT|SOME|SONAME|SQL|START(?:ING)?|STATISTICS|STATUS|STRIPED|SYSTEM_USER|TABLES?|TABLESPACE|TEMP(?:ORARY|TABLE)?|TERMINATED|TEXT(?:SIZE)?|THEN|TIME(?:STAMP)?|TINY(?:BLOB|INT|TEXT)|TOP?|TRAN(?:SACTIONS?)?|TRIGGER|TRUNCATE|TSEQUAL|TYPES?|UNBOUNDED|UNCOMMITTED|UNDEFINED|UNION|UNIQUE|UNLOCK|UNPIVOT|UNSIGNED|UPDATE(?:TEXT)?|USAGE|USE|USER|USING|VALUES?|VAR(?:BINARY|CHAR|CHARACTER|YING)|VIEW|WAITFOR|WARNINGS|WHEN|WHERE|WHILE|WITH(?: ROLLUP|IN)?|WORK|WRITE(?:TEXT)?|YEAR)\b/i,boolean:/\b(?:FALSE|NULL|TRUE)\b/i,number:/\b0x[\da-f]+\b|\b\d+(?:\.\d*)?|\B\.\d+\b/i,operator:/[-+*\/=%^~]|&&?|\|\|?|!=?|<(?:=>?|<|>)?|>[>=]?|\b(?:AND|BETWEEN|DIV|ILIKE|IN|IS|LIKE|NOT|OR|REGEXP|RLIKE|SOUNDS LIKE|XOR)\b/i,punctuation:/[;[\]()`,.]/}}cf.displayName="swift";cf.aliases=[];function cf(l){l.languages.swift={comment:{pattern:/(^|[^\\:])(?:\/\/.*|\/\*(?:[^/*]|\/(?!\*)|\*(?!\/)|\/\*(?:[^*]|\*(?!\/))*\*\/)*\*\/)/,lookbehind:!0,greedy:!0},"string-literal":[{pattern:RegExp(/(^|[^"#])/.source+"(?:"+/"(?:\\(?:\((?:[^()]|\([^()]*\))*\)|\r\n|[^(])|[^\\\r\n"])*"/.source+"|"+/"""(?:\\(?:\((?:[^()]|\([^()]*\))*\)|[^(])|[^\\"]|"(?!""))*"""/.source+")"+/(?!["#])/.source),lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:/(\\\()(?:[^()]|\([^()]*\))*(?=\))/,lookbehind:!0,inside:null},"interpolation-punctuation":{pattern:/^\)|\\\($/,alias:"punctuation"},punctuation:/\\(?=[\r\n])/,string:/[\s\S]+/}},{pattern:RegExp(/(^|[^"#])(#+)/.source+"(?:"+/"(?:\\(?:#+\((?:[^()]|\([^()]*\))*\)|\r\n|[^#])|[^\\\r\n])*?"/.source+"|"+/"""(?:\\(?:#+\((?:[^()]|\([^()]*\))*\)|[^#])|[^\\])*?"""/.source+")\\2"),lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:/(\\#+\()(?:[^()]|\([^()]*\))*(?=\))/,lookbehind:!0,inside:null},"interpolation-punctuation":{pattern:/^\)|\\#+\($/,alias:"punctuation"},string:/[\s\S]+/}}],directive:{pattern:RegExp(/#/.source+"(?:"+(/(?:elseif|if)\b/.source+"(?:[ ]*"+/(?:![ \t]*)?(?:\b\w+\b(?:[ \t]*\((?:[^()]|\([^()]*\))*\))?|\((?:[^()]|\([^()]*\))*\))(?:[ \t]*(?:&&|\|\|))?/.source+")+")+"|"+/(?:else|endif)\b/.source+")"),alias:"property",inside:{"directive-name":/^#\w+/,boolean:/\b(?:false|true)\b/,number:/\b\d+(?:\.\d+)*\b/,operator:/!|&&|\|\||[<>]=?/,punctuation:/[(),]/}},literal:{pattern:/#(?:colorLiteral|column|dsohandle|file(?:ID|Literal|Path)?|function|imageLiteral|line)\b/,alias:"constant"},"other-directive":{pattern:/#\w+\b/,alias:"property"},attribute:{pattern:/@\w+/,alias:"atrule"},"function-definition":{pattern:/(\bfunc\s+)\w+/,lookbehind:!0,alias:"function"},label:{pattern:/\b(break|continue)\s+\w+|\b[a-zA-Z_]\w*(?=\s*:\s*(?:for|repeat|while)\b)/,lookbehind:!0,alias:"important"},keyword:/\b(?:Any|Protocol|Self|Type|actor|as|assignment|associatedtype|associativity|async|await|break|case|catch|class|continue|convenience|default|defer|deinit|didSet|do|dynamic|else|enum|extension|fallthrough|fileprivate|final|for|func|get|guard|higherThan|if|import|in|indirect|infix|init|inout|internal|is|isolated|lazy|left|let|lowerThan|mutating|none|nonisolated|nonmutating|open|operator|optional|override|postfix|precedencegroup|prefix|private|protocol|public|repeat|required|rethrows|return|right|safe|self|set|some|static|struct|subscript|super|switch|throw|throws|try|typealias|unowned|unsafe|var|weak|where|while|willSet)\b/,boolean:/\b(?:false|true)\b/,nil:{pattern:/\bnil\b/,alias:"constant"},"short-argument":/\$\d+\b/,omit:{pattern:/\b_\b/,alias:"keyword"},number:/\b(?:[\d_]+(?:\.[\de_]+)?|0x[a-f0-9_]+(?:\.[a-f0-9p_]+)?|0b[01_]+|0o[0-7_]+)\b/i,"class-name":/\b[A-Z](?:[A-Z_\d]*[a-z]\w*)?\b/,function:/\b[a-z_]\w*(?=\s*\()/i,constant:/\b(?:[A-Z_]{2,}|k[A-Z][A-Za-z_]+)\b/,operator:/[-+*/%=!<>&|^~?]+|\.[.\-+*/%=!<>&|^~?]+/,punctuation:/[{}[\]();,.:\\]/},l.languages.swift["string-literal"].forEach(function(i){i.inside.interpolation.inside=l.languages.swift})}of.displayName="typescript";of.aliases=["ts"];function of(l){l.register(As),(function(i){i.languages.typescript=i.languages.extend("javascript",{"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|type)\s+)(?!keyof\b)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?:\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>)?/,lookbehind:!0,greedy:!0,inside:null},builtin:/\b(?:Array|Function|Promise|any|boolean|console|never|number|string|symbol|unknown)\b/}),i.languages.typescript.keyword.push(/\b(?:abstract|declare|is|keyof|readonly|require)\b/,/\b(?:asserts|infer|interface|module|namespace|type)\b(?=\s*(?:[{_$a-zA-Z\xA0-\uFFFF]|$))/,/\btype\b(?=\s*(?:[\{*]|$))/),delete i.languages.typescript.parameter,delete i.languages.typescript["literal-property"];var r=i.languages.extend("typescript",{});delete r["class-name"],i.languages.typescript["class-name"].inside=r,i.languages.insertBefore("typescript","function",{decorator:{pattern:/@[$\w\xA0-\uFFFF]+/,inside:{at:{pattern:/^@/,alias:"operator"},function:/^[\s\S]+/}},"generic-function":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>(?=\s*\()/,greedy:!0,inside:{function:/^#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*/,generic:{pattern:/<[\s\S]+/,alias:"class-name",inside:r}}}}),i.languages.ts=i.languages.typescript})(l)}Cs.displayName="basic";Cs.aliases=[];function Cs(l){l.languages.basic={comment:{pattern:/(?:!|REM\b).+/i,inside:{keyword:/^REM/i}},string:{pattern:/"(?:""|[!#$%&'()*,\/:;<=>?^\w +\-.])*"/,greedy:!0},number:/(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:E[+-]?\d+)?/i,keyword:/\b(?:AS|BEEP|BLOAD|BSAVE|CALL(?: ABSOLUTE)?|CASE|CHAIN|CHDIR|CLEAR|CLOSE|CLS|COM|COMMON|CONST|DATA|DECLARE|DEF(?: FN| SEG|DBL|INT|LNG|SNG|STR)|DIM|DO|DOUBLE|ELSE|ELSEIF|END|ENVIRON|ERASE|ERROR|EXIT|FIELD|FILES|FOR|FUNCTION|GET|GOSUB|GOTO|IF|INPUT|INTEGER|IOCTL|KEY|KILL|LINE INPUT|LOCATE|LOCK|LONG|LOOP|LSET|MKDIR|NAME|NEXT|OFF|ON(?: COM| ERROR| KEY| TIMER)?|OPEN|OPTION BASE|OUT|POKE|PUT|READ|REDIM|REM|RESTORE|RESUME|RETURN|RMDIR|RSET|RUN|SELECT CASE|SHARED|SHELL|SINGLE|SLEEP|STATIC|STEP|STOP|STRING|SUB|SWAP|SYSTEM|THEN|TIMER|TO|TROFF|TRON|TYPE|UNLOCK|UNTIL|USING|VIEW PRINT|WAIT|WEND|WHILE|WRITE)(?:\$|\b)/i,function:/\b(?:ABS|ACCESS|ACOS|ANGLE|AREA|ARITHMETIC|ARRAY|ASIN|ASK|AT|ATN|BASE|BEGIN|BREAK|CAUSE|CEIL|CHR|CLIP|COLLATE|COLOR|CON|COS|COSH|COT|CSC|DATE|DATUM|DEBUG|DECIMAL|DEF|DEG|DEGREES|DELETE|DET|DEVICE|DISPLAY|DOT|ELAPSED|EPS|ERASABLE|EXLINE|EXP|EXTERNAL|EXTYPE|FILETYPE|FIXED|FP|GO|GRAPH|HANDLER|IDN|IMAGE|IN|INT|INTERNAL|IP|IS|KEYED|LBOUND|LCASE|LEFT|LEN|LENGTH|LET|LINE|LINES|LOG|LOG10|LOG2|LTRIM|MARGIN|MAT|MAX|MAXNUM|MID|MIN|MISSING|MOD|NATIVE|NUL|NUMERIC|OF|OPTION|ORD|ORGANIZATION|OUTIN|OUTPUT|PI|POINT|POINTER|POINTS|POS|PRINT|PROGRAM|PROMPT|RAD|RADIANS|RANDOMIZE|RECORD|RECSIZE|RECTYPE|RELATIVE|REMAINDER|REPEAT|REST|RETRY|REWRITE|RIGHT|RND|ROUND|RTRIM|SAME|SEC|SELECT|SEQUENTIAL|SET|SETTER|SGN|SIN|SINH|SIZE|SKIP|SQR|STANDARD|STATUS|STR|STREAM|STYLE|TAB|TAN|TANH|TEMPLATE|TEXT|THERE|TIME|TIMEOUT|TRACE|TRANSFORM|TRUNCATE|UBOUND|UCASE|USE|VAL|VARIABLE|VIEWPORT|WHEN|WINDOW|WITH|ZER|ZONEWIDTH)(?:\$|\b)/i,operator:/<[=>]?|>=?|[+\-*\/^=&]|\b(?:AND|EQV|IMP|NOT|OR|XOR)\b/i,punctuation:/[,;:()]/}}ff.displayName="vbnet";ff.aliases=[];function ff(l){l.register(Cs),l.languages.vbnet=l.languages.extend("basic",{comment:[{pattern:/(?:!|REM\b).+/i,inside:{keyword:/^REM/i}},{pattern:/(^|[^\\:])'.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(^|[^"])"(?:""|[^"])*"(?!")/,lookbehind:!0,greedy:!0},keyword:/(?:\b(?:ADDHANDLER|ADDRESSOF|ALIAS|AND|ANDALSO|AS|BEEP|BLOAD|BOOLEAN|BSAVE|BYREF|BYTE|BYVAL|CALL(?: ABSOLUTE)?|CASE|CATCH|CBOOL|CBYTE|CCHAR|CDATE|CDBL|CDEC|CHAIN|CHAR|CHDIR|CINT|CLASS|CLEAR|CLNG|CLOSE|CLS|COBJ|COM|COMMON|CONST|CONTINUE|CSBYTE|CSHORT|CSNG|CSTR|CTYPE|CUINT|CULNG|CUSHORT|DATA|DATE|DECIMAL|DECLARE|DEF(?: FN| SEG|DBL|INT|LNG|SNG|STR)|DEFAULT|DELEGATE|DIM|DIRECTCAST|DO|DOUBLE|ELSE|ELSEIF|END|ENUM|ENVIRON|ERASE|ERROR|EVENT|EXIT|FALSE|FIELD|FILES|FINALLY|FOR(?: EACH)?|FRIEND|FUNCTION|GET|GETTYPE|GETXMLNAMESPACE|GLOBAL|GOSUB|GOTO|HANDLES|IF|IMPLEMENTS|IMPORTS|IN|INHERITS|INPUT|INTEGER|INTERFACE|IOCTL|IS|ISNOT|KEY|KILL|LET|LIB|LIKE|LINE INPUT|LOCATE|LOCK|LONG|LOOP|LSET|ME|MKDIR|MOD|MODULE|MUSTINHERIT|MUSTOVERRIDE|MYBASE|MYCLASS|NAME|NAMESPACE|NARROWING|NEW|NEXT|NOT|NOTHING|NOTINHERITABLE|NOTOVERRIDABLE|OBJECT|OF|OFF|ON(?: COM| ERROR| KEY| TIMER)?|OPEN|OPERATOR|OPTION(?: BASE)?|OPTIONAL|OR|ORELSE|OUT|OVERLOADS|OVERRIDABLE|OVERRIDES|PARAMARRAY|PARTIAL|POKE|PRIVATE|PROPERTY|PROTECTED|PUBLIC|PUT|RAISEEVENT|READ|READONLY|REDIM|REM|REMOVEHANDLER|RESTORE|RESUME|RETURN|RMDIR|RSET|RUN|SBYTE|SELECT(?: CASE)?|SET|SHADOWS|SHARED|SHELL|SHORT|SINGLE|SLEEP|STATIC|STEP|STOP|STRING|STRUCTURE|SUB|SWAP|SYNCLOCK|SYSTEM|THEN|THROW|TIMER|TO|TROFF|TRON|TRUE|TRY|TRYCAST|TYPE|TYPEOF|UINTEGER|ULONG|UNLOCK|UNTIL|USHORT|USING|VIEW PRINT|WAIT|WEND|WHEN|WHILE|WIDENING|WITH|WITHEVENTS|WRITE|WRITEONLY|XOR)|\B(?:#CONST|#ELSE|#ELSEIF|#END|#IF))(?:\$|\b)/i,punctuation:/[,;:(){}]/})}class zr{constructor(i,r,s){this.property=i,this.normal=r,s&&(this.space=s)}}zr.prototype.property={};zr.prototype.normal={};zr.prototype.space=null;function Wp(l,i){const r={},s={};let o=-1;for(;++o<l.length;)Object.assign(r,l[o].property),Object.assign(s,l[o].normal);return new zr(r,s,i)}function jr(l){return l.toLowerCase()}class Kt{constructor(i,r){this.property=i,this.attribute=r}}Kt.prototype.space=null;Kt.prototype.boolean=!1;Kt.prototype.booleanish=!1;Kt.prototype.overloadedBoolean=!1;Kt.prototype.number=!1;Kt.prototype.commaSeparated=!1;Kt.prototype.spaceSeparated=!1;Kt.prototype.commaOrSpaceSeparated=!1;Kt.prototype.mustUseProperty=!1;Kt.prototype.defined=!1;let LS=0;const xe=_a(),We=_a(),Pp=_a(),W=_a(),He=_a(),xl=_a(),Mt=_a();function _a(){return 2**++LS}const fo=Object.freeze(Object.defineProperty({__proto__:null,boolean:xe,booleanish:We,commaOrSpaceSeparated:Mt,commaSeparated:xl,number:W,overloadedBoolean:Pp,spaceSeparated:He},Symbol.toStringTag,{value:"Module"})),eo=Object.keys(fo);class df extends Kt{constructor(i,r,s,o){let d=-1;if(super(i,r),ap(this,"space",o),typeof s=="number")for(;++d<eo.length;){const h=eo[d];ap(this,eo[d],(s&fo[h])===fo[h])}}}df.prototype.defined=!0;function ap(l,i,r){r&&(l[i]=r)}const US={}.hasOwnProperty;function Cl(l){const i={},r={};let s;for(s in l.properties)if(US.call(l.properties,s)){const o=l.properties[s],d=new df(s,l.transform(l.attributes||{},s),o,l.space);l.mustUseProperty&&l.mustUseProperty.includes(s)&&(d.mustUseProperty=!0),i[s]=d,r[jr(s)]=s,r[jr(d.attribute)]=s}return new zr(i,r,l.space)}const ey=Cl({space:"xlink",transform(l,i){return"xlink:"+i.slice(5).toLowerCase()},properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null}}),ty=Cl({space:"xml",transform(l,i){return"xml:"+i.slice(3).toLowerCase()},properties:{xmlLang:null,xmlBase:null,xmlSpace:null}});function ny(l,i){return i in l?l[i]:i}function ay(l,i){return ny(l,i.toLowerCase())}const ly=Cl({space:"xmlns",attributes:{xmlnsxlink:"xmlns:xlink"},transform:ay,properties:{xmlns:null,xmlnsXLink:null}}),ry=Cl({transform(l,i){return i==="role"?i:"aria-"+i.slice(4).toLowerCase()},properties:{ariaActiveDescendant:null,ariaAtomic:We,ariaAutoComplete:null,ariaBusy:We,ariaChecked:We,ariaColCount:W,ariaColIndex:W,ariaColSpan:W,ariaControls:He,ariaCurrent:null,ariaDescribedBy:He,ariaDetails:null,ariaDisabled:We,ariaDropEffect:He,ariaErrorMessage:null,ariaExpanded:We,ariaFlowTo:He,ariaGrabbed:We,ariaHasPopup:null,ariaHidden:We,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:He,ariaLevel:W,ariaLive:null,ariaModal:We,ariaMultiLine:We,ariaMultiSelectable:We,ariaOrientation:null,ariaOwns:He,ariaPlaceholder:null,ariaPosInSet:W,ariaPressed:We,ariaReadOnly:We,ariaRelevant:null,ariaRequired:We,ariaRoleDescription:He,ariaRowCount:W,ariaRowIndex:W,ariaRowSpan:W,ariaSelected:We,ariaSetSize:W,ariaSort:null,ariaValueMax:W,ariaValueMin:W,ariaValueNow:W,ariaValueText:null,role:null}}),BS=Cl({space:"html",attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},transform:ay,mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:xl,acceptCharset:He,accessKey:He,action:null,allow:null,allowFullScreen:xe,allowPaymentRequest:xe,allowUserMedia:xe,alt:null,as:null,async:xe,autoCapitalize:null,autoComplete:He,autoFocus:xe,autoPlay:xe,blocking:He,capture:null,charSet:null,checked:xe,cite:null,className:He,cols:W,colSpan:null,content:null,contentEditable:We,controls:xe,controlsList:He,coords:W|xl,crossOrigin:null,data:null,dateTime:null,decoding:null,default:xe,defer:xe,dir:null,dirName:null,disabled:xe,download:Pp,draggable:We,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:xe,formTarget:null,headers:He,height:W,hidden:xe,high:W,href:null,hrefLang:null,htmlFor:He,httpEquiv:He,id:null,imageSizes:null,imageSrcSet:null,inert:xe,inputMode:null,integrity:null,is:null,isMap:xe,itemId:null,itemProp:He,itemRef:He,itemScope:xe,itemType:He,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:xe,low:W,manifest:null,max:null,maxLength:W,media:null,method:null,min:null,minLength:W,multiple:xe,muted:xe,name:null,nonce:null,noModule:xe,noValidate:xe,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:xe,optimum:W,pattern:null,ping:He,placeholder:null,playsInline:xe,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:xe,referrerPolicy:null,rel:He,required:xe,reversed:xe,rows:W,rowSpan:W,sandbox:He,scope:null,scoped:xe,seamless:xe,selected:xe,shadowRootClonable:xe,shadowRootDelegatesFocus:xe,shadowRootMode:null,shape:null,size:W,sizes:null,slot:null,span:W,spellCheck:We,src:null,srcDoc:null,srcLang:null,srcSet:null,start:W,step:null,style:null,tabIndex:W,target:null,title:null,translate:null,type:null,typeMustMatch:xe,useMap:null,value:We,width:W,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:He,axis:null,background:null,bgColor:null,border:W,borderColor:null,bottomMargin:W,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:xe,declare:xe,event:null,face:null,frame:null,frameBorder:null,hSpace:W,leftMargin:W,link:null,longDesc:null,lowSrc:null,marginHeight:W,marginWidth:W,noResize:xe,noHref:xe,noShade:xe,noWrap:xe,object:null,profile:null,prompt:null,rev:null,rightMargin:W,rules:null,scheme:null,scrolling:We,standby:null,summary:null,text:null,topMargin:W,valueType:null,version:null,vAlign:null,vLink:null,vSpace:W,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:xe,disableRemotePlayback:xe,prefix:null,property:null,results:W,security:null,unselectable:null}}),HS=Cl({space:"svg",attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},transform:ny,properties:{about:Mt,accentHeight:W,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:W,amplitude:W,arabicForm:null,ascent:W,attributeName:null,attributeType:null,azimuth:W,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:W,by:null,calcMode:null,capHeight:W,className:He,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:W,diffuseConstant:W,direction:null,display:null,dur:null,divisor:W,dominantBaseline:null,download:xe,dx:null,dy:null,edgeMode:null,editable:null,elevation:W,enableBackground:null,end:null,event:null,exponent:W,externalResourcesRequired:null,fill:null,fillOpacity:W,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:xl,g2:xl,glyphName:xl,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:W,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:W,horizOriginX:W,horizOriginY:W,id:null,ideographic:W,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:W,k:W,k1:W,k2:W,k3:W,k4:W,kernelMatrix:Mt,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:W,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:W,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:W,overlineThickness:W,paintOrder:null,panose1:null,path:null,pathLength:W,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:He,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:W,pointsAtY:W,pointsAtZ:W,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:Mt,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:Mt,rev:Mt,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:Mt,requiredFeatures:Mt,requiredFonts:Mt,requiredFormats:Mt,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:W,specularExponent:W,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:W,strikethroughThickness:W,string:null,stroke:null,strokeDashArray:Mt,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:W,strokeOpacity:W,strokeWidth:null,style:null,surfaceScale:W,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:Mt,tabIndex:W,tableValues:null,target:null,targetX:W,targetY:W,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:Mt,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:W,underlineThickness:W,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:W,values:null,vAlphabetic:W,vMathematical:W,vectorEffect:null,vHanging:W,vIdeographic:W,version:null,vertAdvY:W,vertOriginX:W,vertOriginY:W,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:W,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null}}),GS=/^data[-\w.:]+$/i,lp=/-[a-z]/g,YS=/[A-Z]/g;function qS(l,i){const r=jr(i);let s=i,o=Kt;if(r in l.normal)return l.property[l.normal[r]];if(r.length>4&&r.slice(0,4)==="data"&&GS.test(i)){if(i.charAt(4)==="-"){const d=i.slice(5).replace(lp,XS);s="data"+d.charAt(0).toUpperCase()+d.slice(1)}else{const d=i.slice(4);if(!lp.test(d)){let h=d.replace(YS,IS);h.charAt(0)!=="-"&&(h="-"+h),i="data"+h}}o=df}return new o(s,i)}function IS(l){return"-"+l.toLowerCase()}function XS(l){return l.charAt(1).toUpperCase()}const FS=Wp([ty,ey,ly,ry,BS],"html");Wp([ty,ey,ly,ry,HS],"svg");const rp=/[#.]/g;function ZS(l,i){const r=l||"",s={};let o=0,d,h;for(;o<r.length;){rp.lastIndex=o;const m=rp.exec(r),g=r.slice(o,m?m.index:r.length);g&&(d?d==="#"?s.id=g:Array.isArray(s.className)?s.className.push(g):s.className=[g]:h=g,o+=g.length),m&&(d=m[0],o++)}return{type:"element",tagName:h||i||"div",properties:s,children:[]}}function ip(l){const i=String(l||"").trim();return i?i.split(/[ \t\n\r\f]+/g):[]}function sp(l){const i=[],r=String(l||"");let s=r.indexOf(","),o=0,d=!1;for(;!d;){s===-1&&(s=r.length,d=!0);const h=r.slice(o,s).trim();(h||!d)&&i.push(h),o=s+1,s=r.indexOf(",",o)}return i}const $S=new Set(["menu","submit","reset","button"]),iy={}.hasOwnProperty;function VS(l,i,r){return(function(o,d,...h){let m=-1,g;if(o==null)g={type:"root",children:[]},h.unshift(d);else if(g=ZS(o,i),g.tagName=g.tagName.toLowerCase(),KS(d,g.tagName)){let y;for(y in d)iy.call(d,y)&&QS(l,g.properties,y,d[y])}else h.unshift(d);for(;++m<h.length;)ho(g.children,h[m]);return g.type==="element"&&g.tagName==="template"&&(g.content={type:"root",children:g.children},g.children=[]),g})}function KS(l,i){return l==null||typeof l!="object"||Array.isArray(l)?!1:i==="input"||!l.type||typeof l.type!="string"?!0:"children"in l&&Array.isArray(l.children)?!1:i==="button"?$S.has(l.type.toLowerCase()):!("value"in l)}function QS(l,i,r,s){const o=qS(l,r);let d=-1,h;if(s!=null){if(typeof s=="number"){if(Number.isNaN(s))return;h=s}else typeof s=="boolean"?h=s:typeof s=="string"?o.spaceSeparated?h=ip(s):o.commaSeparated?h=sp(s):o.commaOrSpaceSeparated?h=ip(sp(s).join(" ")):h=up(o,o.property,s):Array.isArray(s)?h=s.concat():h=o.property==="style"?JS(s):String(s);if(Array.isArray(h)){const m=[];for(;++d<h.length;)m[d]=up(o,o.property,h[d]);h=m}o.property==="className"&&Array.isArray(i.className)&&(h=i.className.concat(h)),i[o.property]=h}}function ho(l,i){let r=-1;if(i!=null)if(typeof i=="string"||typeof i=="number")l.push({type:"text",value:String(i)});else if(Array.isArray(i))for(;++r<i.length;)ho(l,i[r]);else if(typeof i=="object"&&"type"in i)i.type==="root"?ho(l,i.children):l.push(i);else throw new Error("Expected node, nodes, or string, got `"+i+"`")}function up(l,i,r){if(typeof r=="string"){if(l.number&&r&&!Number.isNaN(Number(r)))return Number(r);if((l.boolean||l.overloadedBoolean)&&(r===""||jr(r)===jr(i)))return!0}return r}function JS(l){const i=[];let r;for(r in l)iy.call(l,r)&&i.push([r,l[r]].join(": "));return i.join("; ")}const WS=VS(FS,"div"),PS=["AElig","AMP","Aacute","Acirc","Agrave","Aring","Atilde","Auml","COPY","Ccedil","ETH","Eacute","Ecirc","Egrave","Euml","GT","Iacute","Icirc","Igrave","Iuml","LT","Ntilde","Oacute","Ocirc","Ograve","Oslash","Otilde","Ouml","QUOT","REG","THORN","Uacute","Ucirc","Ugrave","Uuml","Yacute","aacute","acirc","acute","aelig","agrave","amp","aring","atilde","auml","brvbar","ccedil","cedil","cent","copy","curren","deg","divide","eacute","ecirc","egrave","eth","euml","frac12","frac14","frac34","gt","iacute","icirc","iexcl","igrave","iquest","iuml","laquo","lt","macr","micro","middot","nbsp","not","ntilde","oacute","ocirc","ograve","ordf","ordm","oslash","otilde","ouml","para","plusmn","pound","quot","raquo","reg","sect","shy","sup1","sup2","sup3","szlig","thorn","times","uacute","ucirc","ugrave","uml","uuml","yacute","yen","yuml"],cp={0:"�",128:"€",130:"‚",131:"ƒ",132:"„",133:"…",134:"†",135:"‡",136:"ˆ",137:"‰",138:"Š",139:"‹",140:"Œ",142:"Ž",145:"‘",146:"’",147:"“",148:"”",149:"•",150:"–",151:"—",152:"˜",153:"™",154:"š",155:"›",156:"œ",158:"ž",159:"Ÿ"};function sy(l){const i=typeof l=="string"?l.charCodeAt(0):l;return i>=48&&i<=57}function eE(l){const i=typeof l=="string"?l.charCodeAt(0):l;return i>=97&&i<=102||i>=65&&i<=70||i>=48&&i<=57}function tE(l){const i=typeof l=="string"?l.charCodeAt(0):l;return i>=97&&i<=122||i>=65&&i<=90}function op(l){return tE(l)||sy(l)}const fp=document.createElement("i");function dp(l){const i="&"+l+";";fp.innerHTML=i;const r=fp.textContent;return r.charCodeAt(r.length-1)===59&&l!=="semi"||r===i?!1:r}const nE=["","Named character references must be terminated by a semicolon","Numeric character references must be terminated by a semicolon","Named character references cannot be empty","Numeric character references cannot be empty","Named character references must be known","Numeric character references cannot be disallowed","Numeric character references cannot be outside the permissible Unicode range"];function aE(l,i){const r={},s=typeof r.additional=="string"?r.additional.charCodeAt(0):r.additional,o=[];let d=0,h=-1,m="",g,y;r.position&&("start"in r.position||"indent"in r.position?(y=r.position.indent,g=r.position.start):g=r.position);let b=(g?g.line:0)||1,x=(g?g.column:0)||1,S=A(),E;for(d--;++d<=l.length;)if(E===10&&(x=(y?y[h]:0)||1),E=l.charCodeAt(d),E===38){const B=l.charCodeAt(d+1);if(B===9||B===10||B===12||B===32||B===38||B===60||Number.isNaN(B)||s&&B===s){m+=String.fromCharCode(E),x++;continue}const q=d+1;let R=q,Z=q,Y;if(B===35){Z=++R;const te=l.charCodeAt(Z);te===88||te===120?(Y="hexadecimal",Z=++R):Y="decimal"}else Y="named";let F="",H="",j="";const ae=Y==="named"?op:Y==="decimal"?sy:eE;for(Z--;++Z<=l.length;){const te=l.charCodeAt(Z);if(!ae(te))break;j+=String.fromCharCode(te),Y==="named"&&PS.includes(j)&&(F=j,H=dp(j))}let ee=l.charCodeAt(Z)===59;if(ee){Z++;const te=Y==="named"?dp(j):!1;te&&(F=j,H=te)}let re=1+Z-q,ce="";if(!(!ee&&r.nonTerminated===!1))if(!j)Y!=="named"&&C(4,re);else if(Y==="named"){if(ee&&!H)C(5,1);else if(F!==j&&(Z=R+F.length,re=1+Z-R,ee=!1),!ee){const te=F?1:3;if(r.attribute){const J=l.charCodeAt(Z);J===61?(C(te,re),H=""):op(J)?H="":C(te,re)}else C(te,re)}ce=H}else{ee||C(2,re);let te=Number.parseInt(j,Y==="hexadecimal"?16:10);if(lE(te))C(7,re),ce="�";else if(te in cp)C(6,re),ce=cp[te];else{let J="";rE(te)&&C(6,re),te>65535&&(te-=65536,J+=String.fromCharCode(te>>>10|55296),te=56320|te&1023),ce=J+String.fromCharCode(te)}}if(ce){_(),S=A(),d=Z-1,x+=Z-q+1,o.push(ce);const te=A();te.offset++,r.reference&&r.reference.call(r.referenceContext||void 0,ce,{start:S,end:te},l.slice(q-1,Z)),S=te}else j=l.slice(q-1,Z),m+=j,x+=j.length,d=Z-1}else E===10&&(b++,h++,x=0),Number.isNaN(E)?_():(m+=String.fromCharCode(E),x++);return o.join("");function A(){return{line:b,column:x,offset:d+((g?g.offset:0)||0)}}function C(B,q){let R;r.warning&&(R=A(),R.column+=q,R.offset+=q,r.warning.call(r.warningContext||void 0,nE[B],R,B))}function _(){m&&(o.push(m),r.text&&r.text.call(r.textContext||void 0,m,{start:S,end:A()}),m="")}}function lE(l){return l>=55296&&l<=57343||l>1114111}function rE(l){return l>=1&&l<=8||l===11||l>=13&&l<=31||l>=127&&l<=159||l>=64976&&l<=65007||(l&65535)===65535||(l&65535)===65534}var iE=0,is={},at={util:{type:function(l){return Object.prototype.toString.call(l).slice(8,-1)},objId:function(l){return l.__id||Object.defineProperty(l,"__id",{value:++iE}),l.__id},clone:function l(i,r){r=r||{};var s,o;switch(at.util.type(i)){case"Object":if(o=at.util.objId(i),r[o])return r[o];s={},r[o]=s;for(var d in i)i.hasOwnProperty(d)&&(s[d]=l(i[d],r));return s;case"Array":return o=at.util.objId(i),r[o]?r[o]:(s=[],r[o]=s,i.forEach(function(h,m){s[m]=l(h,r)}),s);default:return i}}},languages:{plain:is,plaintext:is,text:is,txt:is,extend:function(l,i){var r=at.util.clone(at.languages[l]);for(var s in i)r[s]=i[s];return r},insertBefore:function(l,i,r,s){s=s||at.languages;var o=s[l],d={};for(var h in o)if(o.hasOwnProperty(h)){if(h==i)for(var m in r)r.hasOwnProperty(m)&&(d[m]=r[m]);r.hasOwnProperty(h)||(d[h]=o[h])}var g=s[l];return s[l]=d,at.languages.DFS(at.languages,function(y,b){b===g&&y!=l&&(this[y]=d)}),d},DFS:function l(i,r,s,o){o=o||{};var d=at.util.objId;for(var h in i)if(i.hasOwnProperty(h)){r.call(i,h,i[h],s||h);var m=i[h],g=at.util.type(m);g==="Object"&&!o[d(m)]?(o[d(m)]=!0,l(m,r,null,o)):g==="Array"&&!o[d(m)]&&(o[d(m)]=!0,l(m,r,h,o))}}},plugins:{},highlight:function(l,i,r){var s={code:l,grammar:i,language:r};if(at.hooks.run("before-tokenize",s),!s.grammar)throw new Error('The language "'+s.language+'" has no grammar.');return s.tokens=at.tokenize(s.code,s.grammar),at.hooks.run("after-tokenize",s),Ar.stringify(at.util.encode(s.tokens),s.language)},tokenize:function(l,i){var r=i.rest;if(r){for(var s in r)i[s]=r[s];delete i.rest}var o=new sE;return cs(o,o.head,l),uy(l,o,i,o.head,0),cE(o)},hooks:{all:{},add:function(l,i){var r=at.hooks.all;r[l]=r[l]||[],r[l].push(i)},run:function(l,i){var r=at.hooks.all[l];if(!(!r||!r.length))for(var s=0,o;o=r[s++];)o(i)}},Token:Ar};function Ar(l,i,r,s){this.type=l,this.content=i,this.alias=r,this.length=(s||"").length|0}function hp(l,i,r,s){l.lastIndex=i;var o=l.exec(r);if(o&&s&&o[1]){var d=o[1].length;o.index+=d,o[0]=o[0].slice(d)}return o}function uy(l,i,r,s,o,d){for(var h in r)if(!(!r.hasOwnProperty(h)||!r[h])){var m=r[h];m=Array.isArray(m)?m:[m];for(var g=0;g<m.length;++g){if(d&&d.cause==h+","+g)return;var y=m[g],b=y.inside,x=!!y.lookbehind,S=!!y.greedy,E=y.alias;if(S&&!y.pattern.global){var A=y.pattern.toString().match(/[imsuy]*$/)[0];y.pattern=RegExp(y.pattern.source,A+"g")}for(var C=y.pattern||y,_=s.next,B=o;_!==i.tail&&!(d&&B>=d.reach);B+=_.value.length,_=_.next){var q=_.value;if(i.length>l.length)return;if(!(q instanceof Ar)){var R=1,Z;if(S){if(Z=hp(C,B,l,x),!Z||Z.index>=l.length)break;var j=Z.index,Y=Z.index+Z[0].length,F=B;for(F+=_.value.length;j>=F;)_=_.next,F+=_.value.length;if(F-=_.value.length,B=F,_.value instanceof Ar)continue;for(var H=_;H!==i.tail&&(F<Y||typeof H.value=="string");H=H.next)R++,F+=H.value.length;R--,q=l.slice(B,F),Z.index-=B}else if(Z=hp(C,0,q,x),!Z)continue;var j=Z.index,ae=Z[0],ee=q.slice(0,j),re=q.slice(j+ae.length),ce=B+q.length;d&&ce>d.reach&&(d.reach=ce);var te=_.prev;ee&&(te=cs(i,te,ee),B+=ee.length),uE(i,te,R);var J=new Ar(h,b?at.tokenize(ae,b):ae,E,ae);if(_=cs(i,te,J),re&&cs(i,_,re),R>1){var Q={cause:h+","+g,reach:ce};uy(l,i,r,_.prev,B,Q),d&&Q.reach>d.reach&&(d.reach=Q.reach)}}}}}}function sE(){var l={value:null,prev:null,next:null},i={value:null,prev:l,next:null};l.next=i,this.head=l,this.tail=i,this.length=0}function cs(l,i,r){var s=i.next,o={value:r,prev:i,next:s};return i.next=o,s.prev=o,l.length++,o}function uE(l,i,r){for(var s=i.next,o=0;o<r&&s!==l.tail;o++)s=s.next;i.next=s,s.prev=i,l.length-=o}function cE(l){for(var i=[],r=l.head.next;r!==l.tail;)i.push(r.value),r=r.next;return i}const cy=at,_l={}.hasOwnProperty;function oy(){}oy.prototype=cy;const de=new oy;de.highlight=oE;de.register=fE;de.alias=dE;de.registered=hE;de.listLanguages=gE;de.util.encode=mE;de.Token.stringify=go;function oE(l,i){if(typeof l!="string")throw new TypeError("Expected `string` for `value`, got `"+l+"`");let r,s;if(i&&typeof i=="object")r=i;else{if(s=i,typeof s!="string")throw new TypeError("Expected `string` for `name`, got `"+s+"`");if(_l.call(de.languages,s))r=de.languages[s];else throw new Error("Unknown language: `"+s+"` is not registered")}return{type:"root",children:cy.highlight.call(de,l,r,s)}}function fE(l){if(typeof l!="function"||!l.displayName)throw new Error("Expected `function` for `syntax`, got `"+l+"`");_l.call(de.languages,l.displayName)||l(de)}function dE(l,i){const r=de.languages;let s={};typeof l=="string"?i&&(s[l]=i):s=l;let o;for(o in s)if(_l.call(s,o)){const d=s[o],h=typeof d=="string"?[d]:d;let m=-1;for(;++m<h.length;)r[h[m]]=r[o]}}function hE(l){if(typeof l!="string")throw new TypeError("Expected `string` for `aliasOrLanguage`, got `"+l+"`");return _l.call(de.languages,l)}function gE(){const l=de.languages,i=[];let r;for(r in l)_l.call(l,r)&&typeof l[r]=="object"&&i.push(r);return i}function go(l,i){if(typeof l=="string")return{type:"text",value:l};if(Array.isArray(l)){const s=[];let o=-1;for(;++o<l.length;)l[o]!==null&&l[o]!==void 0&&l[o]!==""&&s.push(go(l[o],i));return s}const r={attributes:{},classes:["token",l.type],content:go(l.content,i),language:i,tag:"span",type:l.type};return l.alias&&r.classes.push(...typeof l.alias=="string"?[l.alias]:l.alias),de.hooks.run("wrap",r),WS(r.tag+"."+r.classes.join("."),pE(r.attributes),r.content)}function mE(l){return l}function pE(l){let i;for(i in l)_l.call(l,i)&&(l[i]=aE(l[i]));return l}de.register(sn);de.register(Mr);de.register(ws);de.register(Uo);de.register(Bo);de.register(Ho);de.register(Dr);de.register(Tl);de.register(Go);de.register(Yo);de.register(qo);de.register(Io);de.register(Xo);de.register(As);de.register(Fo);de.register(Zo);de.register($o);de.register(Vo);de.register(Ko);de.register(Qo);de.register(Jo);de.register(Wo);de.register(Po);de.register(Ts);de.register(ef);de.register(tf);de.register(nf);de.register(af);de.register(lf);de.register(rf);de.register(sf);de.register(uf);de.register(cf);de.register(of);de.register(Cs);de.register(ff);const yE=[{value:"suggestion",label:"Suggestion"},{value:"must_fix",label:"Must Fix"},{value:"question",label:"Question"},{value:"nitpick",label:"Nitpick"}];function ds({onSave:l,onAsk:i,onCancel:r,initialBody:s="",initialType:o="suggestion",file:d,line:h}){const[m,g]=L.useState(s),[y,b]=L.useState(o),[x,S]=L.useState(!1),[E,A]=L.useState(null),C=L.useRef(null),_=lt(Y=>Y.setDraftComment);L.useEffect(()=>{var Y;(Y=C.current)==null||Y.focus()},[]),L.useEffect(()=>{d!==void 0&&h!==void 0&&(m.trim()?_({body:m,type:y,file:d,line:h}):_(null))},[m,y,d,h,_]);function B(){m.trim()&&(_(null),l(m.trim(),y))}async function q(){if(!i||!m.trim())return;S(!0),A(null);const Y=await i(m.trim());S(!1),Y.ok?(_(null),r()):A(Y.error??"Could not ask the agent")}function R(){_(null),r()}function Z(Y){(Y.metaKey||Y.ctrlKey)&&Y.key==="Enter"?(Y.preventDefault(),B()):Y.key==="Escape"&&(Y.preventDefault(),R())}return f.jsxs("div",{className:"p-3 space-y-2",onKeyDown:Z,children:[f.jsx("textarea",{ref:C,value:m,onChange:Y=>g(Y.target.value),placeholder:"Write a comment...",rows:3,className:"w-full bg-background border border-border rounded px-3 py-2 text-text-primary text-sm placeholder:text-text-secondary/50 resize-none focus:outline-none focus:ring-1 focus:ring-accent focus:border-accent"}),E&&f.jsx("p",{role:"alert",className:"text-xs text-danger",children:E}),f.jsxs("div",{className:"flex items-center gap-2",children:[f.jsx("select",{value:y,onChange:Y=>b(Y.target.value),className:"bg-background border border-border rounded px-2 py-1.5 text-text-primary text-xs focus:outline-none focus:ring-1 focus:ring-accent cursor-pointer",children:yE.map(Y=>f.jsx("option",{value:Y.value,children:Y.label},Y.value))}),f.jsx("div",{className:"flex-1"}),f.jsx("button",{onClick:R,className:"px-3 py-1.5 text-xs text-text-secondary hover:text-text-primary transition-colors cursor-pointer",children:"Cancel"}),i&&f.jsx("button",{onClick:q,disabled:!m.trim()||x,title:"Start a thread the agent answers while you review, instead of a comment sent with your decision",className:"px-3 py-1.5 text-xs font-medium rounded text-text-secondary border border-border hover:text-text-primary hover:border-accent/40 disabled:opacity-40 disabled:cursor-not-allowed transition-colors cursor-pointer",children:x?"Asking…":"Ask agent now"}),f.jsx("button",{onClick:B,disabled:!m.trim(),className:"px-3 py-1.5 text-xs font-medium rounded bg-accent/20 text-accent border border-accent/30 hover:bg-accent/30 disabled:opacity-40 disabled:cursor-not-allowed transition-colors cursor-pointer",children:"Save"})]})]})}const bE={must_fix:"Must Fix",suggestion:"Suggestion",question:"Question",nitpick:"Nitpick"};function vE({comments:l,isFormOpen:i,file:r,line:s,onAdd:o,onAsk:d,onUpdate:h,onDelete:m,onOpenForm:g,onCloseForm:y}){const[b,x]=L.useState(null);return f.jsxs("div",{className:"border-t border-border bg-surface",children:[l.map(({comment:S,index:E})=>b===E?f.jsx(ds,{initialBody:S.body,initialType:S.type,file:r,line:s,onSave:(A,C)=>{h(E,A,C),x(null)},onCancel:()=>x(null)},E):f.jsxs("div",{className:"px-3 py-2 border-b border-border/50 group/comment",children:[f.jsxs("div",{className:"flex items-center gap-2 mb-1",children:[f.jsx("span",{className:`text-[10px] font-bold px-1.5 py-0.5 rounded border ${kv[S.type]}`,children:bE[S.type]}),f.jsxs("span",{className:"text-text-secondary text-[10px] font-mono",children:[r,":",s]}),f.jsx("div",{className:"flex-1"}),f.jsx("button",{onClick:()=>x(E),className:"opacity-0 group-hover/comment:opacity-100 p-0.5 text-text-secondary hover:text-text-primary transition-all cursor-pointer",title:"Edit comment",children:f.jsx(xv,{className:"w-3 h-3"})}),f.jsx("button",{onClick:()=>m(E),className:"opacity-0 group-hover/comment:opacity-100 p-0.5 text-text-secondary hover:text-danger transition-all cursor-pointer",title:"Delete comment",children:f.jsx(Cv,{className:"w-3 h-3"})})]}),f.jsx("p",{className:"text-text-primary text-sm whitespace-pre-wrap",children:S.body})]},E)),i&&b===null&&f.jsx(ds,{file:r,line:s,onSave:(S,E)=>{o(S,E),y()},onAsk:d,onCancel:y}),!i&&l.length>0&&b===null&&f.jsxs("button",{onClick:g,className:"flex items-center gap-1 px-3 py-1.5 text-xs text-text-secondary hover:text-accent transition-colors cursor-pointer",children:[f.jsx(xp,{className:"w-3 h-3"}),"Add comment"]})]})}function xE(l){const i=l.replies??[];return i.length>0?i[i.length-1].author:l.author??"agent"}function fy(l){return!l.dismissed&&xE(l)==="reviewer"}function mo({placeholder:l,submitLabel:i,onSubmit:r,onCancel:s}){const[o,d]=L.useState(""),[h,m]=L.useState(!1),[g,y]=L.useState(null),b=L.useRef(null);L.useEffect(()=>{var S;(S=b.current)==null||S.focus()},[]);async function x(){if(!o.trim()||h)return;m(!0),y(null);const S=await r(o.trim());m(!1),S.ok?d(""):y(S.error??"Couldn't send")}return f.jsxs("div",{className:"px-3 py-2 space-y-1.5",children:[f.jsx("textarea",{ref:b,value:o,onChange:S=>d(S.target.value),onKeyDown:S=>{S.key==="Enter"&&(S.metaKey||S.ctrlKey)?(S.preventDefault(),x()):S.key==="Escape"&&s&&(S.preventDefault(),s())},placeholder:l,rows:2,className:"w-full bg-background border border-border rounded px-2 py-1.5 text-text-primary text-sm focus:outline-none focus:border-accent resize-y"}),g&&f.jsx("p",{className:"text-danger text-xs",children:g}),f.jsxs("div",{className:"flex items-center justify-end gap-2",children:[s&&f.jsx("button",{onClick:s,className:"px-2 py-1 text-xs text-text-secondary hover:text-text-primary transition-colors cursor-pointer",children:"Cancel"}),f.jsx("button",{onClick:()=>void x(),disabled:!o.trim()||h,className:"px-2.5 py-1 text-xs rounded bg-accent/15 text-accent hover:bg-accent/25 disabled:opacity-40 disabled:cursor-not-allowed transition-colors cursor-pointer",children:h?"Sending…":i})]})]})}const SE={finding:wa,suggestion:No,question:xo,warning:El};function dy({author:l,agent:i}){return l==="reviewer"?f.jsxs("span",{className:"inline-flex items-center gap-1 text-[10px] font-semibold text-accent",children:[f.jsx(_v,{className:"w-3 h-3"}),"You"]}):f.jsxs("span",{className:"inline-flex items-center gap-1 text-[10px] text-text-secondary",children:[f.jsx(bo,{className:"w-3 h-3"}),i??"agent"]})}function EE({reply:l}){return f.jsxs("div",{className:"pl-3 ml-1.5 border-l border-border/70 py-1",children:[f.jsx(dy,{author:l.author,agent:l.agent}),f.jsx("p",{className:"text-text-primary text-sm whitespace-pre-wrap mt-0.5",children:l.body})]})}function NE({annotations:l,onDismiss:i,onReply:r}){const[s,o]=L.useState(null);if(l.length===0)return null;const d=l.some(h=>{var m;return(h.author??"agent")==="reviewer"||(((m=h.replies)==null?void 0:m.length)??0)>0});return f.jsxs("div",{className:"border-t border-border bg-surface",children:[f.jsxs("div",{className:"px-3 py-1.5 flex items-center gap-1.5 border-b border-border/50",children:[d?f.jsx(Sl,{className:"w-3 h-3 text-text-secondary"}):f.jsx(bo,{className:"w-3 h-3 text-text-secondary"}),f.jsx("span",{className:"text-[10px] font-semibold text-text-secondary uppercase tracking-wide",children:d?`Discussion${l.length>1?` (${l.length})`:""}`:`Agent ${l.length===1?"Annotation":`Annotations (${l.length})`}`})]}),l.map(h=>{const m=h.author??"agent",g=SE[h.type]??wa,y=os[h.category]??os.other,b=Rm[h.category]??Rm.other,x=h.replies??[];return f.jsxs("div",{className:"px-3 py-2 border-b border-border/50 group/annotation",children:[f.jsxs("div",{className:"flex items-center gap-2 mb-1",children:[m==="agent"?f.jsxs(f.Fragment,{children:[f.jsx(g,{className:`w-3.5 h-3.5 flex-shrink-0 ${y}`}),f.jsx("span",{className:`text-[10px] font-bold px-1.5 py-0.5 rounded border ${b}`,children:h.category}),f.jsx("span",{className:"text-text-secondary text-[10px]",children:h.source.agent})]}):f.jsx(dy,{author:"reviewer"}),f.jsx("div",{className:"flex-1"}),f.jsx("button",{onClick:()=>i(h.id),className:"opacity-0 group-hover/annotation:opacity-100 p-0.5 rounded hover:bg-text-primary/10 text-text-secondary transition-all cursor-pointer flex-shrink-0",title:"Dismiss",children:f.jsx(kr,{className:"w-3 h-3"})})]}),f.jsx("p",{className:"text-text-primary text-sm whitespace-pre-wrap",children:h.body}),x.length>0&&f.jsx("div",{className:"mt-1.5 space-y-0.5",children:x.map(S=>f.jsx(EE,{reply:S},S.id))}),fy(h)&&f.jsx("p",{className:"mt-1.5 text-[11px] text-text-secondary italic",children:"Waiting for an agent to reply — it answers when it's listening with wait_for_comments."}),r&&(s===h.id?f.jsx("div",{className:"-mx-3",children:f.jsx(mo,{placeholder:"Reply…",submitLabel:"Reply",onSubmit:async S=>{const E=await r(h.id,S);return E.ok&&o(null),E},onCancel:()=>o(null)})}):f.jsx("button",{onClick:()=>o(h.id),className:"mt-1 text-[11px] text-text-secondary hover:text-accent transition-colors cursor-pointer",children:"Reply"}))]},h.id)})]})}function wE(){const{theme:l,toggleTheme:i}=lt();return f.jsx("button",{onClick:i,className:"p-1.5 rounded text-text-secondary hover:text-text-primary transition-colors cursor-pointer",title:`Switch to ${l==="dark"?"light":"dark"} mode`,children:l==="dark"?f.jsx(Av,{className:"w-4 h-4"}):f.jsx(vv,{className:"w-4 h-4"})})}const gp={highlight(l,i){return de.highlight(l,i).children},registered(l){return de.registered(l)}};function AE(l){return{typescript:"typescript",ts:"typescript",tsx:"tsx",javascript:"javascript",js:"javascript",jsx:"jsx",json:"json",css:"css",html:"markup",xml:"markup",markdown:"markdown",md:"markdown",python:"python",py:"python",rust:"rust",rs:"rust",go:"go",java:"java",c:"c",cpp:"cpp","c++":"cpp",csharp:"csharp","c#":"csharp",ruby:"ruby",rb:"ruby",php:"php",shell:"bash",bash:"bash",sh:"bash",yaml:"yaml",yml:"yaml",toml:"toml",sql:"sql",graphql:"graphql",scss:"scss",sass:"sass",less:"less",swift:"swift",kotlin:"kotlin",scala:"scala",lua:"lua",r:"r",perl:"perl",diff:"diff"}[l.toLowerCase()]??null}function po(l){return Aa(l)||$t(l)?l.lineNumber:Na(l)?l.newLineNumber:0}function TE(l){return $t(l)?"old":"new"}function CE(l,i){const r={};for(const s of l)for(const o of s.changes){const d=po(o),h=`${i}:${d}`;r[h]||(r[h]=Lt(o))}return r}function _E(l,i,r=0){const s=/^diff --git /gm,o=[];let d;for(;(d=s.exec(l))!==null;)o.push(d.index);let h=0;for(let m=0;m<o.length;m++){const g=o[m],y=m+1<o.length?o[m+1]:l.length,b=l.slice(g,y);if(b.includes(`a/${i}`)||b.includes(`b/${i}`)){if(h===r)return b;h++}}return null}function OE(){const{diffSet:l,rawDiff:i,selectedFile:r,viewMode:s,setViewMode:o,comments:d,activeCommentKey:h,addComment:m,updateComment:g,deleteComment:y,setActiveCommentKey:b,toggleHotkeyGuide:x,toggleWorkflowTips:S,focusedHunkIndex:E,setHunkCount:A,annotations:C,dismissAnnotation:_,metadata:B,reviewId:q}=lt(),R=!!(B!=null&&B.githubPr),{isAvailable:Z,startThread:Y,replyToThread:F}=wo(),H=Z&&!!q,j=L.useMemo(()=>!l||!r?null:l.files.find(K=>Dt(K)===r)??null,[l,r]),ae=L.useMemo(()=>{if(!i||!r||!l)return null;const K=hl(r);let ne=0;for(const se of l.files){if(Dt(se)===r)break;se.path===K&&ne++}return _E(i,K,ne)},[i,r,l]),ee=L.useMemo(()=>{if(!ae)return[];try{return e1(ae)}catch{return[]}},[ae]),re=L.useMemo(()=>{if(ee.length===0||!j)return;const K=AE(j.language);if(K){try{if(!gp.registered(K))return}catch{return}try{const ne={refractor:gp,highlight:!0,language:K};return zS(ee[0].hunks,ne)}catch{return}}},[ee,j,s]),ce=L.useMemo(()=>ee.length===0||!r?{}:CE(ee[0].hunks,r),[ee,r]),te=L.useMemo(()=>{if(ee.length===0)return{};const K={};for(const ne of ee[0].hunks)for(const se of ne.changes)K[Lt(se)]=po(se);return K},[ee]),J=L.useMemo(()=>{const K={};if(ee.length===0)return K;for(const ne of ee[0].hunks)for(const se of ne.changes)K[Lt(se)]=TE(se);return K},[ee]),Q=L.useMemo(()=>r?d.map((K,ne)=>({comment:K,index:ne})).filter(K=>K.comment.file===r):[],[d,r]),M=L.useMemo(()=>{if(!r)return[];const K=hl(r);return C.filter(ne=>ne.file===K&&!ne.dismissed)},[C,r]),O=L.useMemo(()=>{const K=new Map;for(const ne of M)K.has(ne.line)||K.set(ne.line,[]),K.get(ne.line).push(ne);return K},[M]),le=L.useMemo(()=>R&&!H?{}:{onClick({change:K}){if(!K)return;const ne=Lt(K);b(h===ne?null:ne)}},[h,b,R,H]),ye=L.useCallback(({change:K,inHoverState:ne,renderDefault:se})=>{const Ee=po(K),me=!R&&r&&Q.some(Be=>Be.comment.line===Ee),pe=O.has(Ee);return ne&&(!R||H)?f.jsxs(f.Fragment,{children:[f.jsx("span",{className:"diff-gutter-add-comment",children:"+"}),se()]}):me?f.jsxs(f.Fragment,{children:[f.jsx("span",{className:"diff-comment-indicator"}),se()]}):pe?f.jsxs(f.Fragment,{children:[f.jsx("span",{className:"diff-annotation-indicator"}),se()]}):se()},[r,Q,O,R,H]),oe=L.useMemo(()=>{if(!r)return{};const K={},ne=new Map;if(!R)for(const me of Q){const pe=me.comment.line;ne.has(pe)||ne.set(pe,[]),ne.get(pe).push(me)}const se=(me,pe)=>!R&&H?Be=>Y(q,{file:hl(r),line:me,side:J[pe],body:Be}):void 0,Ee=new Set([...ne.keys(),...O.keys()]);for(const me of Ee){const pe=ce[`${r}:${me}`];if(!pe)continue;const Be=ne.get(me),Qt=O.get(me);K[pe]=f.jsxs(f.Fragment,{children:[Qt&&Qt.length>0&&f.jsx(NE,{annotations:Qt,onDismiss:_,onReply:H?(et,ft)=>F(q,et,ft):void 0}),R&&H&&h===pe&&f.jsx("div",{className:"border-t border-border bg-surface",children:f.jsx(mo,{placeholder:"Start another conversation on this line…",submitLabel:"Comment",onSubmit:async et=>{const ft=await Y(q,{file:hl(r),line:me,side:J[pe],body:et});return ft.ok&&b(null),ft},onCancel:()=>b(null)})}),!R&&Be&&Be.length>0&&f.jsx(vE,{comments:Be,isFormOpen:h===pe,file:r,line:me,onAdd:(et,ft)=>{m({file:r,line:me,body:et,type:ft})},onAsk:se(me,pe),onUpdate:(et,ft,Et)=>{g(et,{file:r,line:me,body:ft,type:Et})},onDelete:y,onOpenForm:()=>b(pe),onCloseForm:()=>b(null)}),!R&&!(Be!=null&&Be.length)&&h===pe&&f.jsx("div",{className:"border-t border-border bg-surface",children:f.jsx(ds,{file:r,line:me,onSave:(et,ft)=>{m({file:r,line:me,body:et,type:ft}),b(null)},onAsk:se(me,pe),onCancel:()=>b(null)})})]})}if(R&&H&&h&&!K[h]){const me=te[h];me!==void 0&&(K[h]=f.jsx("div",{className:"border-t border-border bg-surface",children:f.jsx(mo,{placeholder:"Ask the agent about this line…",submitLabel:"Comment",onSubmit:async pe=>{const Be=await Y(q,{file:hl(r),line:me,side:J[h],body:pe});return Be.ok&&b(null),Be},onCancel:()=>b(null)})}))}if(!R&&h&&!K[h]){const me=te[h];me!==void 0&&(K[h]=f.jsx("div",{className:"border-t border-border bg-surface",children:f.jsx(ds,{file:r,line:me,onSave:(pe,Be)=>{m({file:r,line:me,body:pe,type:Be}),b(null)},onAsk:se(me,h),onCancel:()=>b(null)})}))}return K},[r,Q,M,O,h,ce,te,J,m,g,y,_,b,R,H,q,Y,F]),w=L.useRef(null);if(L.useEffect(()=>{var K;A(((K=ee[0])==null?void 0:K.hunks.length)??0)},[ee,A]),L.useEffect(()=>{const K=w.current;if(!K||E===null)return;const ne=K.querySelectorAll("tbody.diff-hunk");ne.forEach(se=>se.classList.remove("diff-hunk-focused")),ne[E]&&(ne[E].scrollIntoView({behavior:"smooth",block:"center"}),ne[E].classList.add("diff-hunk-focused"))},[E]),L.useEffect(()=>{function K(){if(E===null||ee.length===0||!r)return;const ne=ee[0].hunks[E];if(!ne||ne.changes.length===0)return;const se=ne.changes[0],Ee=Lt(se);b(Ee)}return document.addEventListener("diffprism:open-comment",K),()=>document.removeEventListener("diffprism:open-comment",K)},[E,ee,r,b]),!r||!l)return f.jsx("div",{className:"flex-1 flex items-center justify-center bg-background",children:f.jsxs("div",{className:"text-center",children:[f.jsx(wl,{className:"w-12 h-12 text-text-secondary/40 mx-auto mb-3"}),f.jsx("p",{className:"text-text-secondary text-sm",children:"Select a file to view changes"})]})});const I=hl(r);if(j!=null&&j.binary)return f.jsxs("div",{className:"flex-1 flex flex-col bg-background",children:[f.jsx(to,{path:I,stage:j==null?void 0:j.stage}),f.jsx("div",{className:"flex-1 flex items-center justify-center",children:f.jsx("div",{className:"text-center",children:f.jsx("p",{className:"text-text-secondary text-sm",children:"Binary file — cannot display diff"})})})]});if(ee.length===0)return f.jsxs("div",{className:"flex-1 flex flex-col bg-background",children:[f.jsx(to,{path:I,stage:j==null?void 0:j.stage}),f.jsx("div",{className:"flex-1 flex items-center justify-center",children:f.jsx("div",{className:"text-center",children:f.jsx("p",{className:"text-text-secondary text-sm",children:"No diff content available for this file"})})})]});const P=ee[0];return f.jsxs("div",{className:"flex-1 flex flex-col bg-background min-h-0",children:[f.jsx(to,{path:I,stage:j==null?void 0:j.stage,additions:j==null?void 0:j.additions,deletions:j==null?void 0:j.deletions,viewMode:s,onViewModeChange:o,onToggleHotkeyGuide:x,onToggleWorkflowTips:S}),f.jsx("div",{ref:w,className:"flex-1 overflow-auto",children:f.jsx(dS,{viewType:s,diffType:P.type,hunks:P.hunks,tokens:re,widgets:oe,gutterEvents:le,renderGutter:ye,children:K=>K.map(ne=>f.jsx(Vp,{hunk:ne},ne.content))})})]})}function to({path:l,stage:i,additions:r,deletions:s,viewMode:o,onViewModeChange:d,onToggleHotkeyGuide:h,onToggleWorkflowTips:m}){return f.jsxs("div",{className:"flex items-center gap-3 px-4 py-2.5 bg-surface border-b border-border flex-shrink-0",children:[f.jsx(wl,{className:"w-4 h-4 text-text-secondary flex-shrink-0"}),f.jsx("span",{className:"text-text-primary text-sm font-mono truncate",children:l}),i&&f.jsx("span",{className:`text-[10px] font-semibold px-1.5 py-0.5 rounded border ${zv[i]}`,children:i==="staged"?"Staged":"Unstaged"}),f.jsxs("div",{className:"flex items-center gap-2 ml-auto flex-shrink-0",children:[r!==void 0&&r>0&&f.jsxs("span",{className:"text-success text-xs font-mono",children:["+",r]}),s!==void 0&&s>0&&f.jsxs("span",{className:"text-danger text-xs font-mono",children:["-",s]}),o&&d&&f.jsxs("div",{className:"flex items-center rounded border border-border ml-2",children:[f.jsx("button",{onClick:()=>d("unified"),className:`p-1 ${o==="unified"?"bg-text-primary/10 text-text-primary":"text-text-secondary hover:text-text-primary"}`,title:"Unified view",children:f.jsx(Nv,{className:"w-3.5 h-3.5"})}),f.jsx("button",{onClick:()=>d("split"),className:`p-1 ${o==="split"?"bg-text-primary/10 text-text-primary":"text-text-secondary hover:text-text-primary"}`,title:"Split view",children:f.jsx(dv,{className:"w-3.5 h-3.5"})})]}),m&&f.jsx("button",{onClick:m,className:"p-1.5 rounded text-text-secondary hover:text-text-primary transition-colors cursor-pointer",title:"Workflow tips",children:f.jsx(No,{className:"w-4 h-4"})}),h&&f.jsx("button",{onClick:h,className:"p-1.5 rounded text-text-secondary hover:text-text-primary transition-colors cursor-pointer",title:"Keyboard shortcuts (?)",children:f.jsx(xo,{className:"w-4 h-4"})}),f.jsx(wE,{})]})]})}function jE({onSubmit:l,onDismiss:i,isWatchMode:r,watchSubmitted:s,hasUnreviewedChanges:o}){const[d,h]=L.useState(""),[m,g]=L.useState(null),{diffSet:y,fileStatuses:b,comments:x,draftComment:S,saveDraftComment:E,setActiveCommentKey:A,setDraftComment:C}=lt(),_=(y==null?void 0:y.files.reduce((j,ae)=>j+ae.additions,0))??0,B=(y==null?void 0:y.files.reduce((j,ae)=>j+ae.deletions,0))??0,q=(y==null?void 0:y.files.length)??0,R=!!(S&&S.body.trim());function Z(j){const ae=Object.values(b).some(ee=>ee!=="unreviewed");l({decision:j,comments:lt.getState().comments,fileStatuses:ae?b:void 0,summary:d.trim()||void 0})}function Y(j){if(R){g(j);return}Z(j)}function F(){m&&(E(),Z(m),g(null))}function H(){m&&(C(null),A(null),Z(m),g(null))}return r&&s&&!o?f.jsx("div",{className:"bg-surface border-t border-border px-4 py-3 flex-shrink-0",children:f.jsxs("div",{className:"flex items-center gap-3",children:[f.jsx(Tr,{className:"w-4 h-4 text-success"}),f.jsx("span",{className:"text-sm text-success font-medium",children:"Review submitted"}),f.jsxs("span",{className:"relative flex h-2 w-2 ml-2",children:[f.jsx("span",{className:"animate-ping absolute inline-flex h-full w-full rounded-full bg-success opacity-75"}),f.jsx("span",{className:"relative inline-flex rounded-full h-2 w-2 bg-success"})]}),f.jsx("span",{className:"text-xs text-text-secondary",children:"Watching for changes..."})]})}):f.jsxs("div",{className:"bg-surface border-t border-border px-4 py-3 flex-shrink-0",children:[r&&s&&o&&f.jsxs("div",{className:"flex items-center gap-2 mb-3 text-xs text-accent",children:[f.jsxs("span",{className:"relative flex h-2 w-2",children:[f.jsx("span",{className:"animate-ping absolute inline-flex h-full w-full rounded-full bg-info opacity-75"}),f.jsx("span",{className:"relative inline-flex rounded-full h-2 w-2 bg-info"})]}),"New changes detected"]}),f.jsxs("div",{className:"flex items-center gap-4 mb-3",children:[f.jsxs("span",{className:"text-text-secondary text-xs",children:[q," file",q!==1?"s":""," changed"]}),_>0&&f.jsxs("span",{className:"text-success text-xs font-mono",children:["+",_]}),B>0&&f.jsxs("span",{className:"text-danger text-xs font-mono",children:["-",B]}),x.length>0&&f.jsxs("span",{className:"flex items-center gap-1 text-accent text-xs",children:[f.jsx(Sl,{className:"w-3 h-3"}),x.length," comment",x.length!==1?"s":""]})]}),f.jsx("textarea",{value:d,onChange:j=>h(j.target.value),placeholder:"Leave a summary comment (optional)...",rows:3,className:"w-full bg-background border border-border rounded-lg px-3 py-2 text-text-primary text-sm placeholder:text-text-secondary/50 resize-none focus:outline-none focus:ring-1 focus:ring-accent focus:border-accent mb-3"}),m&&f.jsxs("div",{className:"flex items-center gap-3 mb-3 px-3 py-2.5 rounded-lg bg-warning/10 border border-warning/30",children:[f.jsx(El,{className:"w-4 h-4 text-warning flex-shrink-0"}),f.jsx("span",{className:"text-sm text-text-primary",children:"You have an unsaved comment. Save it before submitting?"}),f.jsx("div",{className:"flex-1"}),f.jsx("button",{onClick:F,className:"px-3 py-1.5 text-xs font-medium rounded bg-accent/20 text-accent border border-accent/30 hover:bg-accent/30 transition-colors cursor-pointer",children:"Save & Submit"}),f.jsx("button",{onClick:H,className:"px-3 py-1.5 text-xs text-text-secondary hover:text-text-primary transition-colors cursor-pointer",children:"Discard & Submit"}),f.jsx("button",{onClick:()=>g(null),className:"px-3 py-1.5 text-xs text-text-secondary hover:text-text-primary transition-colors cursor-pointer",children:"Cancel"})]}),f.jsxs("div",{className:"flex items-center gap-3",children:[f.jsxs("button",{onClick:()=>Y("approved"),className:`flex items-center gap-2 px-4 py-2 rounded-lg text-sm font-medium transition-colors cursor-pointer ${ea.approve}`,children:[f.jsx(Tr,{className:"w-4 h-4"}),"Approve"]}),f.jsxs("button",{onClick:()=>Y("changes_requested"),className:`flex items-center gap-2 px-4 py-2 rounded-lg text-sm font-medium transition-colors cursor-pointer ${ea.reject}`,children:[f.jsx(kr,{className:"w-4 h-4"}),"Request Changes"]}),f.jsxs("button",{onClick:()=>Y("approved_with_comments"),className:`flex items-center gap-2 px-4 py-2 rounded-lg text-sm font-medium transition-colors cursor-pointer ${ea.comment}`,children:[f.jsx(Sl,{className:"w-4 h-4"}),"Approve with Comments"]}),i&&f.jsxs(f.Fragment,{children:[f.jsx("div",{className:"w-px h-6 bg-border"}),f.jsxs("button",{onClick:i,className:`flex items-center gap-2 px-4 py-2 rounded-lg text-sm font-medium transition-colors cursor-pointer ${ea.dismiss}`,children:[f.jsx(vp,{className:"w-4 h-4"}),"Dismiss"]})]})]})]})}function kE({onDismiss:l}){const{annotations:i,reviewId:r,metadata:s}=lt(),{submitPrReview:o}=wo(),[d,h]=L.useState(""),[m,g]=L.useState(new Set),[y,b]=L.useState(null),[x,S]=L.useState(null),[E,A]=L.useState(null),C=s==null?void 0:s.githubPr,_=i.filter(F=>F.author==="reviewer"&&!F.dismissed),B=!d.trim();async function q(F){if(!r)return;b(F),S(null);const H=await o(r,{event:F,summary:d.trim()||void 0,threadIds:_.filter(j=>m.has(j.id)).map(j=>j.id)});b(null),H.ok?A(H.url):S(H.error)}function R(F){g(H=>{const j=new Set(H);return j.has(F)?j.delete(F):j.add(F),j})}if(E)return f.jsxs("div",{className:"bg-surface border-t border-border px-4 py-3 flex-shrink-0 flex items-center gap-3",children:[f.jsx(Tr,{className:"w-4 h-4 text-success"}),f.jsx("span",{className:"text-sm text-success font-medium",children:"Review posted to GitHub"}),f.jsxs("a",{href:E,target:"_blank",rel:"noreferrer",className:"flex items-center gap-1 text-xs text-accent hover:underline",children:["View on GitHub",f.jsx(So,{className:"w-3 h-3"})]})]});const Z=y!==null,Y=(F,H,j,ae,ee)=>f.jsxs("button",{onClick:()=>q(F),disabled:Z||ee,className:`flex items-center gap-2 px-4 py-2 rounded-lg text-sm font-medium transition-colors cursor-pointer disabled:opacity-40 disabled:cursor-not-allowed ${j}`,children:[f.jsx(ae,{className:"w-4 h-4"}),y===F?"Posting…":H]});return f.jsxs("div",{className:"bg-surface border-t border-border px-4 py-3 flex-shrink-0",children:[f.jsxs("div",{className:"text-xs text-text-secondary mb-2",children:["Submit your review to GitHub",C?` · ${C.owner}/${C.repo}#${C.number}`:""]}),f.jsx("textarea",{value:d,onChange:F=>h(F.target.value),placeholder:"Summary — optional to approve, required to request changes or comment",rows:3,className:"w-full bg-background border border-border rounded-lg px-3 py-2 text-text-primary text-sm placeholder:text-text-secondary/50 resize-none focus:outline-none focus:ring-1 focus:ring-accent focus:border-accent mb-3"}),_.length>0&&f.jsxs("fieldset",{className:"mb-3",children:[f.jsx("legend",{className:"text-xs text-text-secondary mb-1",children:"Post your comments as inline review comments (your opening message only — agent replies stay here)"}),f.jsx("div",{className:"flex flex-col gap-1 max-h-28 overflow-y-auto",children:_.map(F=>f.jsxs("label",{className:"flex items-center gap-2 text-xs text-text-primary cursor-pointer select-none",children:[f.jsx("input",{type:"checkbox",checked:m.has(F.id),onChange:()=>R(F.id),className:"rounded border-border accent-accent"}),f.jsxs("span",{className:"font-mono text-text-secondary",children:[F.file,":",F.line]}),f.jsx("span",{className:"truncate",children:F.body})]},F.id))})]}),x&&f.jsxs("div",{role:"alert",className:"flex items-start gap-2 mb-3 px-3 py-2 rounded-lg bg-danger/10 border border-danger/30 text-sm text-text-primary whitespace-pre-line",children:[f.jsx(El,{className:"w-4 h-4 mt-0.5 text-danger flex-shrink-0"}),x]}),f.jsxs("div",{className:"flex items-center gap-3",children:[Y("APPROVE","Approve",ea.approve,Tr,!1),Y("REQUEST_CHANGES","Request changes",ea.reject,kr,B),Y("COMMENT","Comment",ea.comment,Sl,B),l&&f.jsxs(f.Fragment,{children:[f.jsx("div",{className:"w-px h-6 bg-border"}),f.jsxs("button",{onClick:l,disabled:Z,className:`flex items-center gap-2 px-4 py-2 rounded-lg text-sm font-medium transition-colors cursor-pointer disabled:opacity-40 ${ea.dismiss}`,children:[f.jsx(vp,{className:"w-4 h-4"}),"Close without posting"]})]})]})]})}const RE=navigator.platform.toUpperCase().includes("MAC"),ME=RE?"⌘":"Ctrl",DE=[{keys:["j","↓"],action:"Next file"},{keys:["k","↑"],action:"Previous file"},{keys:["s"],action:"Cycle file status"},{keys:["n"],action:"Next hunk"},{keys:["p"],action:"Previous hunk"},{keys:["c"],action:"Comment on hunk"},{keys:[`${ME} + Enter`],action:"Save comment"},{keys:["Esc"],action:"Cancel comment / Close guide"},{keys:["?"],action:"Toggle this guide"}];function zE(){const{showHotkeyGuide:l,toggleHotkeyGuide:i}=lt();return L.useEffect(()=>{if(!l)return;function r(s){(s.key==="Escape"||s.key==="?")&&(s.preventDefault(),s.stopPropagation(),i())}return document.addEventListener("keydown",r,!0),()=>document.removeEventListener("keydown",r,!0)},[l,i]),l?f.jsx("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/50",onClick:i,children:f.jsxs("div",{className:"bg-surface border border-border rounded-lg shadow-xl p-6 max-w-sm w-full mx-4",onClick:r=>r.stopPropagation(),children:[f.jsx("h2",{className:"text-text-primary text-sm font-semibold mb-4",children:"Keyboard Shortcuts"}),f.jsx("div",{className:"space-y-2",children:DE.map(r=>f.jsxs("div",{className:"flex items-center justify-between gap-4",children:[f.jsx("span",{className:"text-text-secondary text-sm",children:r.action}),f.jsx("div",{className:"flex items-center gap-1.5",children:r.keys.map((s,o)=>f.jsxs("span",{className:"flex items-center gap-1.5",children:[o>0&&f.jsx("span",{className:"text-text-secondary/50 text-xs",children:"/"}),f.jsx("kbd",{className:"px-1.5 py-0.5 text-xs font-mono rounded border border-border bg-background text-text-primary",children:s})]},s))})]},r.action))})]})}):null}const LE={navigation:"Navigation",review:"Review Workflow",commenting:"Commenting",general:"General"},UE=["navigation","review","commenting","general"],BE=[{id:"nav-files",text:"Navigate between files in the sidebar",shortcut:"j / k",category:"navigation"},{id:"nav-hunks",text:"Jump between changed hunks within a file",shortcut:"n / p",category:"navigation"},{id:"nav-select",text:"Click any file in the sidebar to view its diff",category:"navigation"},{id:"review-status",text:"Cycle a file's review status (unreviewed → reviewed → approved → needs changes)",shortcut:"s",category:"review"},{id:"review-split",text:"Toggle between unified and split (side-by-side) diff views from the toolbar",category:"review"},{id:"review-briefing",text:"Check the briefing bar at the top for a summary of changes, risk indicators, and file stats",category:"review"},{id:"comment-gutter",text:"Click a line's gutter (the + icon on hover) to add an inline comment",category:"commenting"},{id:"comment-hunk",text:"Quickly comment on the focused hunk",shortcut:"c",category:"commenting"},{id:"comment-save",text:"Save a comment from the inline form",shortcut:"Cmd/Ctrl + Enter",category:"commenting"},{id:"general-hotkeys",text:"Open the full keyboard shortcuts reference anytime",shortcut:"?",category:"general"},{id:"general-theme",text:"Toggle between dark and light mode from the toolbar",category:"general"}],mp="diffprism-tips-seen";function HE(){const{showWorkflowTips:l,toggleWorkflowTips:i}=lt();if(L.useEffect(()=>{localStorage.getItem(mp)||(localStorage.setItem(mp,"1"),i())},[]),L.useEffect(()=>{if(!l)return;function s(o){o.key==="Escape"&&(o.preventDefault(),o.stopPropagation(),i())}return document.addEventListener("keydown",s,!0),()=>document.removeEventListener("keydown",s,!0)},[l,i]),!l)return null;const r=new Map;for(const s of BE)r.has(s.category)||r.set(s.category,[]),r.get(s.category).push(s);return f.jsx("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/50",onClick:i,children:f.jsxs("div",{className:"bg-surface border border-border rounded-lg shadow-xl p-6 max-w-md w-full mx-4 max-h-[80vh] overflow-y-auto",onClick:s=>s.stopPropagation(),children:[f.jsx("h2",{className:"text-text-primary text-sm font-semibold mb-4",children:"Workflow Tips"}),f.jsx("div",{className:"space-y-4",children:UE.map(s=>{const o=r.get(s);return!o||o.length===0?null:f.jsxs("div",{children:[f.jsx("h3",{className:"text-text-secondary text-xs font-semibold uppercase tracking-wider mb-2",children:LE[s]}),f.jsx("div",{className:"space-y-1.5",children:o.map(d=>f.jsxs("div",{className:"flex items-start justify-between gap-3",children:[f.jsx("span",{className:"text-text-secondary text-sm leading-snug",children:d.text}),d.shortcut&&f.jsx("kbd",{className:"flex-shrink-0 px-1.5 py-0.5 text-xs font-mono rounded border border-border bg-background text-text-primary whitespace-nowrap",children:d.shortcut})]},d.id))})]},s)})}),f.jsxs("div",{className:"mt-5 flex items-center justify-between",children:[f.jsx("span",{className:"text-text-secondary/60 text-xs",children:"Reopen anytime from the toolbar"}),f.jsx("button",{onClick:i,className:"px-3 py-1.5 text-sm font-medium rounded bg-accent text-white hover:bg-accent/90 transition-colors cursor-pointer",children:"Got it"})]})]})})}const GE="Your comments",YE={finding:wa,suggestion:No,question:xo,warning:El};function qE({body:l}){const[i,r]=L.useState(!1),s=l.length>120||l.includes(`
344
+ |(?![\\s\\S])))+`,"m"),alias:d,inside:{line:{pattern:/(.)(?=[\s\S]).*(?:\r\n?|\n)?/,lookbehind:!0},prefix:{pattern:/[\s\S]/,alias:/\w+/.exec(s)[0]}}}}),Object.defineProperty(i.languages.diff,"PREFIXES",{value:r})})(l)}Yo.displayName="go";Yo.aliases=[];function Yo(l){l.register(sn),l.languages.go=l.languages.extend("clike",{string:{pattern:/(^|[^\\])"(?:\\.|[^"\\\r\n])*"|`[^`]*`/,lookbehind:!0,greedy:!0},keyword:/\b(?:break|case|chan|const|continue|default|defer|else|fallthrough|for|func|go(?:to)?|if|import|interface|map|package|range|return|select|struct|switch|type|var)\b/,boolean:/\b(?:_|false|iota|nil|true)\b/,number:[/\b0(?:b[01_]+|o[0-7_]+)i?\b/i,/\b0x(?:[a-f\d_]+(?:\.[a-f\d_]*)?|\.[a-f\d_]+)(?:p[+-]?\d+(?:_\d+)*)?i?(?!\w)/i,/(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?[\d_]+)?i?(?!\w)/i],operator:/[*\/%^!=]=?|\+[=+]?|-[=-]?|\|[=|]?|&(?:=|&|\^=?)?|>(?:>=?|=)?|<(?:<=?|=|-)?|:=|\.\.\./,builtin:/\b(?:append|bool|byte|cap|close|complex|complex(?:64|128)|copy|delete|error|float(?:32|64)|u?int(?:8|16|32|64)?|imag|len|make|new|panic|print(?:ln)?|real|recover|rune|string|uintptr)\b/}),l.languages.insertBefore("go","string",{char:{pattern:/'(?:\\.|[^'\\\r\n]){0,10}'/,greedy:!0}}),delete l.languages.go["class-name"]}qo.displayName="ini";qo.aliases=[];function qo(l){l.languages.ini={comment:{pattern:/(^[ \f\t\v]*)[#;][^\n\r]*/m,lookbehind:!0},section:{pattern:/(^[ \f\t\v]*)\[[^\n\r\]]*\]?/m,lookbehind:!0,inside:{"section-name":{pattern:/(^\[[ \f\t\v]*)[^ \f\t\v\]]+(?:[ \f\t\v]+[^ \f\t\v\]]+)*/,lookbehind:!0,alias:"selector"},punctuation:/\[|\]/}},key:{pattern:/(^[ \f\t\v]*)[^ \f\n\r\t\v=]+(?:[ \f\t\v]+[^ \f\n\r\t\v=]+)*(?=[ \f\t\v]*=)/m,lookbehind:!0,alias:"attr-name"},value:{pattern:/(=[ \f\t\v]*)[^ \f\n\r\t\v]+(?:[ \f\t\v]+[^ \f\n\r\t\v]+)*/,lookbehind:!0,alias:"attr-value",inside:{"inner-value":{pattern:/^("|').+(?=\1$)/,lookbehind:!0}}},punctuation:/=/}}Io.displayName="java";Io.aliases=[];function Io(l){l.register(sn),(function(i){var r=/\b(?:abstract|assert|boolean|break|byte|case|catch|char|class|const|continue|default|do|double|else|enum|exports|extends|final|finally|float|for|goto|if|implements|import|instanceof|int|interface|long|module|native|new|non-sealed|null|open|opens|package|permits|private|protected|provides|public|record(?!\s*[(){}[\]<>=%~.:,;?+\-*/&|^])|requires|return|sealed|short|static|strictfp|super|switch|synchronized|this|throw|throws|to|transient|transitive|try|uses|var|void|volatile|while|with|yield)\b/,s=/(?:[a-z]\w*\s*\.\s*)*(?:[A-Z]\w*\s*\.\s*)*/.source,o={pattern:RegExp(/(^|[^\w.])/.source+s+/[A-Z](?:[\d_A-Z]*[a-z]\w*)?\b/.source),lookbehind:!0,inside:{namespace:{pattern:/^[a-z]\w*(?:\s*\.\s*[a-z]\w*)*(?:\s*\.)?/,inside:{punctuation:/\./}},punctuation:/\./}};i.languages.java=i.languages.extend("clike",{string:{pattern:/(^|[^\\])"(?:\\.|[^"\\\r\n])*"/,lookbehind:!0,greedy:!0},"class-name":[o,{pattern:RegExp(/(^|[^\w.])/.source+s+/[A-Z]\w*(?=\s+\w+\s*[;,=()]|\s*(?:\[[\s,]*\]\s*)?::\s*new\b)/.source),lookbehind:!0,inside:o.inside},{pattern:RegExp(/(\b(?:class|enum|extends|implements|instanceof|interface|new|record|throws)\s+)/.source+s+/[A-Z]\w*\b/.source),lookbehind:!0,inside:o.inside}],keyword:r,function:[i.languages.clike.function,{pattern:/(::\s*)[a-z_]\w*/,lookbehind:!0}],number:/\b0b[01][01_]*L?\b|\b0x(?:\.[\da-f_p+-]+|[\da-f_]+(?:\.[\da-f_p+-]+)?)\b|(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?\d[\d_]*)?[dfl]?/i,operator:{pattern:/(^|[^.])(?:<<=?|>>>?=?|->|--|\+\+|&&|\|\||::|[?:~]|[-+*/%&|^!=<>]=?)/m,lookbehind:!0},constant:/\b[A-Z][A-Z_\d]+\b/}),i.languages.insertBefore("java","string",{"triple-quoted-string":{pattern:/"""[ \t]*[\r\n](?:(?:"|"")?(?:\\.|[^"\\]))*"""/,greedy:!0,alias:"string"},char:{pattern:/'(?:\\.|[^'\\\r\n]){1,6}'/,greedy:!0}}),i.languages.insertBefore("java","class-name",{annotation:{pattern:/(^|[^.])@\w+(?:\s*\.\s*\w+)*/,lookbehind:!0,alias:"punctuation"},generics:{pattern:/<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&))*>)*>)*>)*>/,inside:{"class-name":o,keyword:r,punctuation:/[<>(),.:]/,operator:/[?&|]/}},import:[{pattern:RegExp(/(\bimport\s+)/.source+s+/(?:[A-Z]\w*|\*)(?=\s*;)/.source),lookbehind:!0,inside:{namespace:o.inside.namespace,punctuation:/\./,operator:/\*/,"class-name":/\w+/}},{pattern:RegExp(/(\bimport\s+static\s+)/.source+s+/(?:\w+|\*)(?=\s*;)/.source),lookbehind:!0,alias:"static",inside:{namespace:o.inside.namespace,static:/\b\w+$/,punctuation:/\./,operator:/\*/,"class-name":/\w+/}}],namespace:{pattern:RegExp(/(\b(?:exports|import(?:\s+static)?|module|open|opens|package|provides|requires|to|transitive|uses|with)\s+)(?!<keyword>)[a-z]\w*(?:\.[a-z]\w*)*\.?/.source.replace(/<keyword>/g,function(){return r.source})),lookbehind:!0,inside:{punctuation:/\./}}})})(l)}Xo.displayName="regex";Xo.aliases=[];function Xo(l){(function(i){var r={pattern:/\\[\\(){}[\]^$+*?|.]/,alias:"escape"},s=/\\(?:x[\da-fA-F]{2}|u[\da-fA-F]{4}|u\{[\da-fA-F]+\}|0[0-7]{0,2}|[123][0-7]{2}|c[a-zA-Z]|.)/,o={pattern:/\.|\\[wsd]|\\p\{[^{}]+\}/i,alias:"class-name"},d={pattern:/\\[wsd]|\\p\{[^{}]+\}/i,alias:"class-name"},h="(?:[^\\\\-]|"+s.source+")",m=RegExp(h+"-"+h),g={pattern:/(<|')[^<>']+(?=[>']$)/,lookbehind:!0,alias:"variable"};i.languages.regex={"char-class":{pattern:/((?:^|[^\\])(?:\\\\)*)\[(?:[^\\\]]|\\[\s\S])*\]/,lookbehind:!0,inside:{"char-class-negation":{pattern:/(^\[)\^/,lookbehind:!0,alias:"operator"},"char-class-punctuation":{pattern:/^\[|\]$/,alias:"punctuation"},range:{pattern:m,inside:{escape:s,"range-punctuation":{pattern:/-/,alias:"operator"}}},"special-escape":r,"char-set":d,escape:s}},"special-escape":r,"char-set":o,backreference:[{pattern:/\\(?![123][0-7]{2})[1-9]/,alias:"keyword"},{pattern:/\\k<[^<>']+>/,alias:"keyword",inside:{"group-name":g}}],anchor:{pattern:/[$^]|\\[ABbGZz]/,alias:"function"},escape:s,group:[{pattern:/\((?:\?(?:<[^<>']+>|'[^<>']+'|[>:]|<?[=!]|[idmnsuxU]+(?:-[idmnsuxU]+)?:?))?/,alias:"punctuation",inside:{"group-name":g}},{pattern:/\)/,alias:"punctuation"}],quantifier:{pattern:/(?:[+*?]|\{\d+(?:,\d*)?\})[?+]?/,alias:"number"},alternation:{pattern:/\|/,alias:"keyword"}}})(l)}As.displayName="javascript";As.aliases=["js"];function As(l){l.register(sn),l.languages.javascript=l.languages.extend("clike",{"class-name":[l.languages.clike["class-name"],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(/(^|[^\w$])/.source+"(?:"+(/NaN|Infinity/.source+"|"+/0[bB][01]+(?:_[01]+)*n?/.source+"|"+/0[oO][0-7]+(?:_[0-7]+)*n?/.source+"|"+/0[xX][\dA-Fa-f]+(?:_[\dA-Fa-f]+)*n?/.source+"|"+/\d+(?:_\d+)*n/.source+"|"+/(?:\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[Ee][+-]?\d+(?:_\d+)*)?/.source)+")"+/(?![\w$])/.source),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),l.languages.javascript["class-name"][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,l.languages.insertBefore("javascript","keyword",{regex:{pattern:RegExp(/((?:^|[^$\w\xA0-\uFFFF."'\])\s]|\b(?:return|yield))\s*)/.source+/\//.source+"(?:"+/(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}/.source+"|"+/(?:\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.)*\])*\])*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}v[dgimyus]{0,7}/.source+")"+/(?=(?:\s|\/\*(?:[^*]|\*(?!\/))*\*\/)*(?:$|[\r\n,.;:})\]]|\/\/))/.source),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:"language-regex",inside:l.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:"function"},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:l.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:l.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:l.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:l.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),l.languages.insertBefore("javascript","string",{hashbang:{pattern:/^#!.*/,greedy:!0,alias:"comment"},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:l.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:"property"}}),l.languages.insertBefore("javascript","operator",{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:"property"}}),l.languages.markup&&(l.languages.markup.tag.addInlined("script","javascript"),l.languages.markup.tag.addAttribute(/on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)/.source,"javascript")),l.languages.js=l.languages.javascript}Fo.displayName="json";Fo.aliases=["webmanifest"];function Fo(l){l.languages.json={property:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?=\s*:)/,lookbehind:!0,greedy:!0},string:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?!\s*:)/,lookbehind:!0,greedy:!0},comment:{pattern:/\/\/.*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},number:/-?\b\d+(?:\.\d+)?(?:e[+-]?\d+)?\b/i,punctuation:/[{}[\],]/,operator:/:/,boolean:/\b(?:false|true)\b/,null:{pattern:/\bnull\b/,alias:"keyword"}},l.languages.webmanifest=l.languages.json}Zo.displayName="kotlin";Zo.aliases=["kt","kts"];function Zo(l){l.register(sn),(function(i){i.languages.kotlin=i.languages.extend("clike",{keyword:{pattern:/(^|[^.])\b(?:abstract|actual|annotation|as|break|by|catch|class|companion|const|constructor|continue|crossinline|data|do|dynamic|else|enum|expect|external|final|finally|for|fun|get|if|import|in|infix|init|inline|inner|interface|internal|is|lateinit|noinline|null|object|open|operator|out|override|package|private|protected|public|reified|return|sealed|set|super|suspend|tailrec|this|throw|to|try|typealias|val|var|vararg|when|where|while)\b/,lookbehind:!0},function:[{pattern:/(?:`[^\r\n`]+`|\b\w+)(?=\s*\()/,greedy:!0},{pattern:/(\.)(?:`[^\r\n`]+`|\w+)(?=\s*\{)/,lookbehind:!0,greedy:!0}],number:/\b(?:0[xX][\da-fA-F]+(?:_[\da-fA-F]+)*|0[bB][01]+(?:_[01]+)*|\d+(?:_\d+)*(?:\.\d+(?:_\d+)*)?(?:[eE][+-]?\d+(?:_\d+)*)?[fFL]?)\b/,operator:/\+[+=]?|-[-=>]?|==?=?|!(?:!|==?)?|[\/*%<>]=?|[?:]:?|\.\.|&&|\|\||\b(?:and|inv|or|shl|shr|ushr|xor)\b/}),delete i.languages.kotlin["class-name"];var r={"interpolation-punctuation":{pattern:/^\$\{?|\}$/,alias:"punctuation"},expression:{pattern:/[\s\S]+/,inside:i.languages.kotlin}};i.languages.insertBefore("kotlin","string",{"string-literal":[{pattern:/"""(?:[^$]|\$(?:(?!\{)|\{[^{}]*\}))*?"""/,alias:"multiline",inside:{interpolation:{pattern:/\$(?:[a-z_]\w*|\{[^{}]*\})/i,inside:r},string:/[\s\S]+/}},{pattern:/"(?:[^"\\\r\n$]|\\.|\$(?:(?!\{)|\{[^{}]*\}))*"/,alias:"singleline",inside:{interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$(?:[a-z_]\w*|\{[^{}]*\})/i,lookbehind:!0,inside:r},string:/[\s\S]+/}}],char:{pattern:/'(?:[^'\\\r\n]|\\(?:.|u[a-fA-F0-9]{0,4}))'/,greedy:!0}}),delete i.languages.kotlin.string,i.languages.insertBefore("kotlin","keyword",{annotation:{pattern:/\B@(?:\w+:)?(?:[A-Z]\w*|\[[^\]]+\])/,alias:"builtin"}}),i.languages.insertBefore("kotlin","function",{label:{pattern:/\b\w+@|@\w+\b/,alias:"symbol"}}),i.languages.kt=i.languages.kotlin,i.languages.kts=i.languages.kotlin})(l)}$o.displayName="less";$o.aliases=[];function $o(l){l.register(Tl),l.languages.less=l.languages.extend("css",{comment:[/\/\*[\s\S]*?\*\//,{pattern:/(^|[^\\])\/\/.*/,lookbehind:!0}],atrule:{pattern:/@[\w-](?:\((?:[^(){}]|\([^(){}]*\))*\)|[^(){};\s]|\s+(?!\s))*?(?=\s*\{)/,inside:{punctuation:/[:()]/}},selector:{pattern:/(?:@\{[\w-]+\}|[^{};\s@])(?:@\{[\w-]+\}|\((?:[^(){}]|\([^(){}]*\))*\)|[^(){};@\s]|\s+(?!\s))*?(?=\s*\{)/,inside:{variable:/@+[\w-]+/}},property:/(?:@\{[\w-]+\}|[\w-])+(?:\+_?)?(?=\s*:)/,operator:/[+\-*\/]/}),l.languages.insertBefore("less","property",{variable:[{pattern:/@[\w-]+\s*:/,inside:{punctuation:/:/}},/@@?[\w-]+/],"mixin-usage":{pattern:/([{;]\s*)[.#](?!\d)[\w-].*?(?=[(;])/,lookbehind:!0,alias:"function"}})}Vo.displayName="lua";Vo.aliases=[];function Vo(l){l.languages.lua={comment:/^#!.+|--(?:\[(=*)\[[\s\S]*?\]\1\]|.*)/m,string:{pattern:/(["'])(?:(?!\1)[^\\\r\n]|\\z(?:\r\n|\s)|\\(?:\r\n|[^z]))*\1|\[(=*)\[[\s\S]*?\]\2\]/,greedy:!0},number:/\b0x[a-f\d]+(?:\.[a-f\d]*)?(?:p[+-]?\d+)?\b|\b\d+(?:\.\B|(?:\.\d*)?(?:e[+-]?\d+)?\b)|\B\.\d+(?:e[+-]?\d+)?\b/i,keyword:/\b(?:and|break|do|else|elseif|end|false|for|function|goto|if|in|local|nil|not|or|repeat|return|then|true|until|while)\b/,function:/(?!\d)\w+(?=\s*(?:[({]))/,operator:[/[-+*%^&|#]|\/\/?|<[<=]?|>[>=]?|[=~]=?/,{pattern:/(^|[^.])\.\.(?!\.)/,lookbehind:!0}],punctuation:/[\[\](){},;]|\.+|:+/}}Ko.displayName="makefile";Ko.aliases=[];function Ko(l){l.languages.makefile={comment:{pattern:/(^|[^\\])#(?:\\(?:\r\n|[\s\S])|[^\\\r\n])*/,lookbehind:!0},string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"builtin-target":{pattern:/\.[A-Z][^:#=\s]+(?=\s*:(?!=))/,alias:"builtin"},target:{pattern:/^(?:[^:=\s]|[ \t]+(?![\s:]))+(?=\s*:(?!=))/m,alias:"symbol",inside:{variable:/\$+(?:(?!\$)[^(){}:#=\s]+|(?=[({]))/}},variable:/\$+(?:(?!\$)[^(){}:#=\s]+|\([@*%<^+?][DF]\)|(?=[({]))/,keyword:/-include\b|\b(?:define|else|endef|endif|export|ifn?def|ifn?eq|include|override|private|sinclude|undefine|unexport|vpath)\b/,function:{pattern:/(\()(?:abspath|addsuffix|and|basename|call|dir|error|eval|file|filter(?:-out)?|findstring|firstword|flavor|foreach|guile|if|info|join|lastword|load|notdir|or|origin|patsubst|realpath|shell|sort|strip|subst|suffix|value|warning|wildcard|word(?:list|s)?)(?=[ \t])/,lookbehind:!0},operator:/(?:::|[?:+!])?=|[|@]/,punctuation:/[:;(){}]/}}Qo.displayName="yaml";Qo.aliases=["yml"];function Qo(l){(function(i){var r=/[*&][^\s[\]{},]+/,s=/!(?:<[\w\-%#;/?:@&=+$,.!~*'()[\]]+>|(?:[a-zA-Z\d-]*!)?[\w\-%#;/?:@&=+$.~*'()]+)?/,o="(?:"+s.source+"(?:[ ]+"+r.source+")?|"+r.source+"(?:[ ]+"+s.source+")?)",d=/(?:[^\s\x00-\x08\x0e-\x1f!"#%&'*,\-:>?@[\]`{|}\x7f-\x84\x86-\x9f\ud800-\udfff\ufffe\uffff]|[?:-]<PLAIN>)(?:[ \t]*(?:(?![#:])<PLAIN>|:<PLAIN>))*/.source.replace(/<PLAIN>/g,function(){return/[^\s\x00-\x08\x0e-\x1f,[\]{}\x7f-\x84\x86-\x9f\ud800-\udfff\ufffe\uffff]/.source}),h=/"(?:[^"\\\r\n]|\\.)*"|'(?:[^'\\\r\n]|\\.)*'/.source;function m(g,y){y=(y||"").replace(/m/g,"")+"m";var b=/([:\-,[{]\s*(?:\s<<prop>>[ \t]+)?)(?:<<value>>)(?=[ \t]*(?:$|,|\]|\}|(?:[\r\n]\s*)?#))/.source.replace(/<<prop>>/g,function(){return o}).replace(/<<value>>/g,function(){return g});return RegExp(b,y)}i.languages.yaml={scalar:{pattern:RegExp(/([\-:]\s*(?:\s<<prop>>[ \t]+)?[|>])[ \t]*(?:((?:\r?\n|\r)[ \t]+)\S[^\r\n]*(?:\2[^\r\n]+)*)/.source.replace(/<<prop>>/g,function(){return o})),lookbehind:!0,alias:"string"},comment:/#.*/,key:{pattern:RegExp(/((?:^|[:\-,[{\r\n?])[ \t]*(?:<<prop>>[ \t]+)?)<<key>>(?=\s*:\s)/.source.replace(/<<prop>>/g,function(){return o}).replace(/<<key>>/g,function(){return"(?:"+d+"|"+h+")"})),lookbehind:!0,greedy:!0,alias:"atrule"},directive:{pattern:/(^[ \t]*)%.+/m,lookbehind:!0,alias:"important"},datetime:{pattern:m(/\d{4}-\d\d?-\d\d?(?:[tT]|[ \t]+)\d\d?:\d{2}:\d{2}(?:\.\d*)?(?:[ \t]*(?:Z|[-+]\d\d?(?::\d{2})?))?|\d{4}-\d{2}-\d{2}|\d\d?:\d{2}(?::\d{2}(?:\.\d*)?)?/.source),lookbehind:!0,alias:"number"},boolean:{pattern:m(/false|true/.source,"i"),lookbehind:!0,alias:"important"},null:{pattern:m(/null|~/.source,"i"),lookbehind:!0,alias:"important"},string:{pattern:m(h),lookbehind:!0,greedy:!0},number:{pattern:m(/[+-]?(?:0x[\da-f]+|0o[0-7]+|(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?|\.inf|\.nan)/.source,"i"),lookbehind:!0},tag:s,important:r,punctuation:/---|[:[\]{}\-,|>?]|\.\.\./},i.languages.yml=i.languages.yaml})(l)}Jo.displayName="markdown";Jo.aliases=["md"];function Jo(l){l.register(Dr),(function(i){var r=/(?:\\.|[^\\\n\r]|(?:\n|\r\n?)(?![\r\n]))/.source;function s(m){return m=m.replace(/<inner>/g,function(){return r}),RegExp(/((?:^|[^\\])(?:\\{2})*)/.source+"(?:"+m+")")}var o=/(?:\\.|``(?:[^`\r\n]|`(?!`))+``|`[^`\r\n]+`|[^\\|\r\n`])+/.source,d=/\|?__(?:\|__)+\|?(?:(?:\n|\r\n?)|(?![\s\S]))/.source.replace(/__/g,function(){return o}),h=/\|?[ \t]*:?-{3,}:?[ \t]*(?:\|[ \t]*:?-{3,}:?[ \t]*)+\|?(?:\n|\r\n?)/.source;i.languages.markdown=i.languages.extend("markup",{}),i.languages.insertBefore("markdown","prolog",{"front-matter-block":{pattern:/(^(?:\s*[\r\n])?)---(?!.)[\s\S]*?[\r\n]---(?!.)/,lookbehind:!0,greedy:!0,inside:{punctuation:/^---|---$/,"front-matter":{pattern:/\S+(?:\s+\S+)*/,alias:["yaml","language-yaml"],inside:i.languages.yaml}}},blockquote:{pattern:/^>(?:[\t ]*>)*/m,alias:"punctuation"},table:{pattern:RegExp("^"+d+h+"(?:"+d+")*","m"),inside:{"table-data-rows":{pattern:RegExp("^("+d+h+")(?:"+d+")*$"),lookbehind:!0,inside:{"table-data":{pattern:RegExp(o),inside:i.languages.markdown},punctuation:/\|/}},"table-line":{pattern:RegExp("^("+d+")"+h+"$"),lookbehind:!0,inside:{punctuation:/\||:?-{3,}:?/}},"table-header-row":{pattern:RegExp("^"+d+"$"),inside:{"table-header":{pattern:RegExp(o),alias:"important",inside:i.languages.markdown},punctuation:/\|/}}}},code:[{pattern:/((?:^|\n)[ \t]*\n|(?:^|\r\n?)[ \t]*\r\n?)(?: {4}|\t).+(?:(?:\n|\r\n?)(?: {4}|\t).+)*/,lookbehind:!0,alias:"keyword"},{pattern:/^```[\s\S]*?^```$/m,greedy:!0,inside:{"code-block":{pattern:/^(```.*(?:\n|\r\n?))[\s\S]+?(?=(?:\n|\r\n?)^```$)/m,lookbehind:!0},"code-language":{pattern:/^(```).+/,lookbehind:!0},punctuation:/```/}}],title:[{pattern:/\S.*(?:\n|\r\n?)(?:==+|--+)(?=[ \t]*$)/m,alias:"important",inside:{punctuation:/==+$|--+$/}},{pattern:/(^\s*)#.+/m,lookbehind:!0,alias:"important",inside:{punctuation:/^#+|#+$/}}],hr:{pattern:/(^\s*)([*-])(?:[\t ]*\2){2,}(?=\s*$)/m,lookbehind:!0,alias:"punctuation"},list:{pattern:/(^\s*)(?:[*+-]|\d+\.)(?=[\t ].)/m,lookbehind:!0,alias:"punctuation"},"url-reference":{pattern:/!?\[[^\]]+\]:[\t ]+(?:\S+|<(?:\\.|[^>\\])+>)(?:[\t ]+(?:"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\((?:\\.|[^)\\])*\)))?/,inside:{variable:{pattern:/^(!?\[)[^\]]+/,lookbehind:!0},string:/(?:"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\((?:\\.|[^)\\])*\))$/,punctuation:/^[\[\]!:]|[<>]/},alias:"url"},bold:{pattern:s(/\b__(?:(?!_)<inner>|_(?:(?!_)<inner>)+_)+__\b|\*\*(?:(?!\*)<inner>|\*(?:(?!\*)<inner>)+\*)+\*\*/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^..)[\s\S]+(?=..$)/,lookbehind:!0,inside:{}},punctuation:/\*\*|__/}},italic:{pattern:s(/\b_(?:(?!_)<inner>|__(?:(?!_)<inner>)+__)+_\b|\*(?:(?!\*)<inner>|\*\*(?:(?!\*)<inner>)+\*\*)+\*/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^.)[\s\S]+(?=.$)/,lookbehind:!0,inside:{}},punctuation:/[*_]/}},strike:{pattern:s(/(~~?)(?:(?!~)<inner>)+\2/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^~~?)[\s\S]+(?=\1$)/,lookbehind:!0,inside:{}},punctuation:/~~?/}},"code-snippet":{pattern:/(^|[^\\`])(?:``[^`\r\n]+(?:`[^`\r\n]+)*``(?!`)|`[^`\r\n]+`(?!`))/,lookbehind:!0,greedy:!0,alias:["code","keyword"]},url:{pattern:s(/!?\[(?:(?!\])<inner>)+\](?:\([^\s)]+(?:[\t ]+"(?:\\.|[^"\\])*")?\)|[ \t]?\[(?:(?!\])<inner>)+\])/.source),lookbehind:!0,greedy:!0,inside:{operator:/^!/,content:{pattern:/(^\[)[^\]]+(?=\])/,lookbehind:!0,inside:{}},variable:{pattern:/(^\][ \t]?\[)[^\]]+(?=\]$)/,lookbehind:!0},url:{pattern:/(^\]\()[^\s)]+/,lookbehind:!0},string:{pattern:/(^[ \t]+)"(?:\\.|[^"\\])*"(?=\)$)/,lookbehind:!0}}}}),["url","bold","italic","strike"].forEach(function(m){["url","bold","italic","strike","code-snippet"].forEach(function(g){m!==g&&(i.languages.markdown[m].inside.content.inside[g]=i.languages.markdown[g])})}),i.hooks.add("after-tokenize",function(m){if(m.language!=="markdown"&&m.language!=="md")return;function g(y){if(!(!y||typeof y=="string"))for(var b=0,x=y.length;b<x;b++){var S=y[b];if(S.type!=="code"){g(S.content);continue}var E=S.content[1],A=S.content[3];if(E&&A&&E.type==="code-language"&&A.type==="code-block"&&typeof E.content=="string"){var C=E.content.replace(/\b#/g,"sharp").replace(/\b\+\+/g,"pp");C=(/[a-z][\w-]*/i.exec(C)||[""])[0].toLowerCase();var _="language-"+C;A.alias?typeof A.alias=="string"?A.alias=[A.alias,_]:A.alias.push(_):A.alias=[_]}}}g(m.tokens)}),i.hooks.add("wrap",function(m){if(m.type==="code-block"){for(var g="",y=0,b=m.classes.length;y<b;y++){var x=m.classes[y],S=/language-(.+)/.exec(x);if(S){g=S[1];break}}var E=i.languages[g];if(E)m.content=i.highlight(m.content.value,E,g);else if(g&&g!=="none"&&i.plugins.autoloader){var A="md-"+new Date().valueOf()+"-"+Math.floor(Math.random()*1e16);m.attributes.id=A,i.plugins.autoloader.loadLanguages(g,function(){var C=document.getElementById(A);C&&(C.innerHTML=i.highlight(C.textContent,i.languages[g],g))})}}}),RegExp(i.languages.markup.tag.pattern.source,"gi"),i.languages.md=i.languages.markdown})(l)}Wo.displayName="objectivec";Wo.aliases=["objc"];function Wo(l){l.register(Mr),l.languages.objectivec=l.languages.extend("c",{string:{pattern:/@?"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},keyword:/\b(?:asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|in|inline|int|long|register|return|self|short|signed|sizeof|static|struct|super|switch|typedef|typeof|union|unsigned|void|volatile|while)\b|(?:@interface|@end|@implementation|@protocol|@class|@public|@protected|@private|@property|@try|@catch|@finally|@throw|@synthesize|@dynamic|@selector)\b/,operator:/-[->]?|\+\+?|!=?|<<?=?|>>?=?|==?|&&?|\|\|?|[~^%?*\/@]/}),delete l.languages.objectivec["class-name"],l.languages.objc=l.languages.objectivec}Po.displayName="perl";Po.aliases=[];function Po(l){(function(i){var r=/(?:\((?:[^()\\]|\\[\s\S])*\)|\{(?:[^{}\\]|\\[\s\S])*\}|\[(?:[^[\]\\]|\\[\s\S])*\]|<(?:[^<>\\]|\\[\s\S])*>)/.source;i.languages.perl={comment:[{pattern:/(^\s*)=\w[\s\S]*?=cut.*/m,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\$])#.*/,lookbehind:!0,greedy:!0}],string:[{pattern:RegExp(/\b(?:q|qq|qw|qx)(?![a-zA-Z0-9])\s*/.source+"(?:"+[/([^a-zA-Z0-9\s{(\[<])(?:(?!\1)[^\\]|\\[\s\S])*\1/.source,/([a-zA-Z0-9])(?:(?!\2)[^\\]|\\[\s\S])*\2/.source,r].join("|")+")"),greedy:!0},{pattern:/("|`)(?:(?!\1)[^\\]|\\[\s\S])*\1/,greedy:!0},{pattern:/'(?:[^'\\\r\n]|\\.)*'/,greedy:!0}],regex:[{pattern:RegExp(/\b(?:m|qr)(?![a-zA-Z0-9])\s*/.source+"(?:"+[/([^a-zA-Z0-9\s{(\[<])(?:(?!\1)[^\\]|\\[\s\S])*\1/.source,/([a-zA-Z0-9])(?:(?!\2)[^\\]|\\[\s\S])*\2/.source,r].join("|")+")"+/[msixpodualngc]*/.source),greedy:!0},{pattern:RegExp(/(^|[^-])\b(?:s|tr|y)(?![a-zA-Z0-9])\s*/.source+"(?:"+[/([^a-zA-Z0-9\s{(\[<])(?:(?!\2)[^\\]|\\[\s\S])*\2(?:(?!\2)[^\\]|\\[\s\S])*\2/.source,/([a-zA-Z0-9])(?:(?!\3)[^\\]|\\[\s\S])*\3(?:(?!\3)[^\\]|\\[\s\S])*\3/.source,r+/\s*/.source+r].join("|")+")"+/[msixpodualngcer]*/.source),lookbehind:!0,greedy:!0},{pattern:/\/(?:[^\/\\\r\n]|\\.)*\/[msixpodualngc]*(?=\s*(?:$|[\r\n,.;})&|\-+*~<>!?^]|(?:and|cmp|eq|ge|gt|le|lt|ne|not|or|x|xor)\b))/,greedy:!0}],variable:[/[&*$@%]\{\^[A-Z]+\}/,/[&*$@%]\^[A-Z_]/,/[&*$@%]#?(?=\{)/,/[&*$@%]#?(?:(?:::)*'?(?!\d)[\w$]+(?![\w$]))+(?:::)*/,/[&*$@%]\d+/,/(?!%=)[$@%][!"#$%&'()*+,\-.\/:;<=>?@[\\\]^_`{|}~]/],filehandle:{pattern:/<(?![<=])\S*?>|\b_\b/,alias:"symbol"},"v-string":{pattern:/v\d+(?:\.\d+)*|\d+(?:\.\d+){2,}/,alias:"string"},function:{pattern:/(\bsub[ \t]+)\w+/,lookbehind:!0},keyword:/\b(?:any|break|continue|default|delete|die|do|else|elsif|eval|for|foreach|given|goto|if|last|local|my|next|our|package|print|redo|require|return|say|state|sub|switch|undef|unless|until|use|when|while)\b/,number:/\b(?:0x[\dA-Fa-f](?:_?[\dA-Fa-f])*|0b[01](?:_?[01])*|(?:(?:\d(?:_?\d)*)?\.)?\d(?:_?\d)*(?:[Ee][+-]?\d+)?)\b/,operator:/-[rwxoRWXOezsfdlpSbctugkTBMAC]\b|\+[+=]?|-[-=>]?|\*\*?=?|\/\/?=?|=[=~>]?|~[~=]?|\|\|?=?|&&?=?|<(?:=>?|<=?)?|>>?=?|![~=]?|[%^]=?|\.(?:=|\.\.?)?|[\\?]|\bx(?:=|\b)|\b(?:and|cmp|eq|ge|gt|le|lt|ne|not|or|xor)\b/,punctuation:/[{}[\];(),:]/}})(l)}Ts.displayName="markup-templating";Ts.aliases=[];function Ts(l){l.register(Dr),(function(i){function r(s,o){return"___"+s.toUpperCase()+o+"___"}Object.defineProperties(i.languages["markup-templating"]={},{buildPlaceholders:{value:function(s,o,d,h){if(s.language===o){var m=s.tokenStack=[];s.code=s.code.replace(d,function(g){if(typeof h=="function"&&!h(g))return g;for(var y=m.length,b;s.code.indexOf(b=r(o,y))!==-1;)++y;return m[y]=g,b}),s.grammar=i.languages.markup}}},tokenizePlaceholders:{value:function(s,o){if(s.language!==o||!s.tokenStack)return;s.grammar=i.languages[o];var d=0,h=Object.keys(s.tokenStack);function m(g){for(var y=0;y<g.length&&!(d>=h.length);y++){var b=g[y];if(typeof b=="string"||b.content&&typeof b.content=="string"){var x=h[d],S=s.tokenStack[x],E=typeof b=="string"?b:b.content,A=r(o,x),C=E.indexOf(A);if(C>-1){++d;var _=E.substring(0,C),B=new i.Token(o,i.tokenize(S,s.grammar),"language-"+o,S),q=E.substring(C+A.length),R=[];_&&R.push.apply(R,m([_])),R.push(B),q&&R.push.apply(R,m([q])),typeof b=="string"?g.splice.apply(g,[y,1].concat(R)):b.content=R}}else b.content&&m(b.content)}return g}m(s.tokens)}}})})(l)}ef.displayName="php";ef.aliases=[];function ef(l){l.register(Ts),(function(i){var r=/\/\*[\s\S]*?\*\/|\/\/.*|#(?!\[).*/,s=[{pattern:/\b(?:false|true)\b/i,alias:"boolean"},{pattern:/(::\s*)\b[a-z_]\w*\b(?!\s*\()/i,greedy:!0,lookbehind:!0},{pattern:/(\b(?:case|const)\s+)\b[a-z_]\w*(?=\s*[;=])/i,greedy:!0,lookbehind:!0},/\b(?:null)\b/i,/\b[A-Z_][A-Z0-9_]*\b(?!\s*\()/],o=/\b0b[01]+(?:_[01]+)*\b|\b0o[0-7]+(?:_[0-7]+)*\b|\b0x[\da-f]+(?:_[\da-f]+)*\b|(?:\b\d+(?:_\d+)*\.?(?:\d+(?:_\d+)*)?|\B\.\d+)(?:e[+-]?\d+)?/i,d=/<?=>|\?\?=?|\.{3}|\??->|[!=]=?=?|::|\*\*=?|--|\+\+|&&|\|\||<<|>>|[?~]|[/^|%*&<>.+-]=?/,h=/[{}\[\](),:;]/;i.languages.php={delimiter:{pattern:/\?>$|^<\?(?:php(?=\s)|=)?/i,alias:"important"},comment:r,variable:/\$+(?:\w+\b|(?=\{))/,package:{pattern:/(namespace\s+|use\s+(?:function\s+)?)(?:\\?\b[a-z_]\w*)+\b(?!\\)/i,lookbehind:!0,inside:{punctuation:/\\/}},"class-name-definition":{pattern:/(\b(?:class|enum|interface|trait)\s+)\b[a-z_]\w*(?!\\)\b/i,lookbehind:!0,alias:"class-name"},"function-definition":{pattern:/(\bfunction\s+)[a-z_]\w*(?=\s*\()/i,lookbehind:!0,alias:"function"},keyword:[{pattern:/(\(\s*)\b(?:array|bool|boolean|float|int|integer|object|string)\b(?=\s*\))/i,alias:"type-casting",greedy:!0,lookbehind:!0},{pattern:/([(,?]\s*)\b(?:array(?!\s*\()|bool|callable|(?:false|null)(?=\s*\|)|float|int|iterable|mixed|object|self|static|string)\b(?=\s*\$)/i,alias:"type-hint",greedy:!0,lookbehind:!0},{pattern:/(\)\s*:\s*(?:\?\s*)?)\b(?:array(?!\s*\()|bool|callable|(?:false|null)(?=\s*\|)|float|int|iterable|mixed|never|object|self|static|string|void)\b/i,alias:"return-type",greedy:!0,lookbehind:!0},{pattern:/\b(?:array(?!\s*\()|bool|float|int|iterable|mixed|object|string|void)\b/i,alias:"type-declaration",greedy:!0},{pattern:/(\|\s*)(?:false|null)\b|\b(?:false|null)(?=\s*\|)/i,alias:"type-declaration",greedy:!0,lookbehind:!0},{pattern:/\b(?:parent|self|static)(?=\s*::)/i,alias:"static-context",greedy:!0},{pattern:/(\byield\s+)from\b/i,lookbehind:!0},/\bclass\b/i,{pattern:/((?:^|[^\s>:]|(?:^|[^-])>|(?:^|[^:]):)\s*)\b(?:abstract|and|array|as|break|callable|case|catch|clone|const|continue|declare|default|die|do|echo|else|elseif|empty|enddeclare|endfor|endforeach|endif|endswitch|endwhile|enum|eval|exit|extends|final|finally|fn|for|foreach|function|global|goto|if|implements|include|include_once|instanceof|insteadof|interface|isset|list|match|namespace|never|new|or|parent|print|private|protected|public|readonly|require|require_once|return|self|static|switch|throw|trait|try|unset|use|var|while|xor|yield|__halt_compiler)\b/i,lookbehind:!0}],"argument-name":{pattern:/([(,]\s*)\b[a-z_]\w*(?=\s*:(?!:))/i,lookbehind:!0},"class-name":[{pattern:/(\b(?:extends|implements|instanceof|new(?!\s+self|\s+static))\s+|\bcatch\s*\()\b[a-z_]\w*(?!\\)\b/i,greedy:!0,lookbehind:!0},{pattern:/(\|\s*)\b[a-z_]\w*(?!\\)\b/i,greedy:!0,lookbehind:!0},{pattern:/\b[a-z_]\w*(?!\\)\b(?=\s*\|)/i,greedy:!0},{pattern:/(\|\s*)(?:\\?\b[a-z_]\w*)+\b/i,alias:"class-name-fully-qualified",greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}},{pattern:/(?:\\?\b[a-z_]\w*)+\b(?=\s*\|)/i,alias:"class-name-fully-qualified",greedy:!0,inside:{punctuation:/\\/}},{pattern:/(\b(?:extends|implements|instanceof|new(?!\s+self\b|\s+static\b))\s+|\bcatch\s*\()(?:\\?\b[a-z_]\w*)+\b(?!\\)/i,alias:"class-name-fully-qualified",greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}},{pattern:/\b[a-z_]\w*(?=\s*\$)/i,alias:"type-declaration",greedy:!0},{pattern:/(?:\\?\b[a-z_]\w*)+(?=\s*\$)/i,alias:["class-name-fully-qualified","type-declaration"],greedy:!0,inside:{punctuation:/\\/}},{pattern:/\b[a-z_]\w*(?=\s*::)/i,alias:"static-context",greedy:!0},{pattern:/(?:\\?\b[a-z_]\w*)+(?=\s*::)/i,alias:["class-name-fully-qualified","static-context"],greedy:!0,inside:{punctuation:/\\/}},{pattern:/([(,?]\s*)[a-z_]\w*(?=\s*\$)/i,alias:"type-hint",greedy:!0,lookbehind:!0},{pattern:/([(,?]\s*)(?:\\?\b[a-z_]\w*)+(?=\s*\$)/i,alias:["class-name-fully-qualified","type-hint"],greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}},{pattern:/(\)\s*:\s*(?:\?\s*)?)\b[a-z_]\w*(?!\\)\b/i,alias:"return-type",greedy:!0,lookbehind:!0},{pattern:/(\)\s*:\s*(?:\?\s*)?)(?:\\?\b[a-z_]\w*)+\b(?!\\)/i,alias:["class-name-fully-qualified","return-type"],greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}}],constant:s,function:{pattern:/(^|[^\\\w])\\?[a-z_](?:[\w\\]*\w)?(?=\s*\()/i,lookbehind:!0,inside:{punctuation:/\\/}},property:{pattern:/(->\s*)\w+/,lookbehind:!0},number:o,operator:d,punctuation:h};var m={pattern:/\{\$(?:\{(?:\{[^{}]+\}|[^{}]+)\}|[^{}])+\}|(^|[^\\{])\$+(?:\w+(?:\[[^\r\n\[\]]+\]|->\w+)?)/,lookbehind:!0,inside:i.languages.php},g=[{pattern:/<<<'([^']+)'[\r\n](?:.*[\r\n])*?\1;/,alias:"nowdoc-string",greedy:!0,inside:{delimiter:{pattern:/^<<<'[^']+'|[a-z_]\w*;$/i,alias:"symbol",inside:{punctuation:/^<<<'?|[';]$/}}}},{pattern:/<<<(?:"([^"]+)"[\r\n](?:.*[\r\n])*?\1;|([a-z_]\w*)[\r\n](?:.*[\r\n])*?\2;)/i,alias:"heredoc-string",greedy:!0,inside:{delimiter:{pattern:/^<<<(?:"[^"]+"|[a-z_]\w*)|[a-z_]\w*;$/i,alias:"symbol",inside:{punctuation:/^<<<"?|[";]$/}},interpolation:m}},{pattern:/`(?:\\[\s\S]|[^\\`])*`/,alias:"backtick-quoted-string",greedy:!0},{pattern:/'(?:\\[\s\S]|[^\\'])*'/,alias:"single-quoted-string",greedy:!0},{pattern:/"(?:\\[\s\S]|[^\\"])*"/,alias:"double-quoted-string",greedy:!0,inside:{interpolation:m}}];i.languages.insertBefore("php","variable",{string:g,attribute:{pattern:/#\[(?:[^"'\/#]|\/(?![*/])|\/\/.*$|#(?!\[).*$|\/\*(?:[^*]|\*(?!\/))*\*\/|"(?:\\[\s\S]|[^\\"])*"|'(?:\\[\s\S]|[^\\'])*')+\](?=\s*[a-z$#])/im,greedy:!0,inside:{"attribute-content":{pattern:/^(#\[)[\s\S]+(?=\]$)/,lookbehind:!0,inside:{comment:r,string:g,"attribute-class-name":[{pattern:/([^:]|^)\b[a-z_]\w*(?!\\)\b/i,alias:"class-name",greedy:!0,lookbehind:!0},{pattern:/([^:]|^)(?:\\?\b[a-z_]\w*)+/i,alias:["class-name","class-name-fully-qualified"],greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}}],constant:s,number:o,operator:d,punctuation:h}},delimiter:{pattern:/^#\[|\]$/,alias:"punctuation"}}}}),i.hooks.add("before-tokenize",function(y){if(/<\?/.test(y.code)){var b=/<\?(?:[^"'/#]|\/(?![*/])|("|')(?:\\[\s\S]|(?!\1)[^\\])*\1|(?:\/\/|#(?!\[))(?:[^?\n\r]|\?(?!>))*(?=$|\?>|[\r\n])|#\[|\/\*(?:[^*]|\*(?!\/))*(?:\*\/|$))*?(?:\?>|$)/g;i.languages["markup-templating"].buildPlaceholders(y,"php",b)}}),i.hooks.add("after-tokenize",function(y){i.languages["markup-templating"].tokenizePlaceholders(y,"php")})})(l)}tf.displayName="python";tf.aliases=["py"];function tf(l){l.languages.python={comment:{pattern:/(^|[^\\])#.*/,lookbehind:!0,greedy:!0},"string-interpolation":{pattern:/(?:f|fr|rf)(?:("""|''')[\s\S]*?\1|("|')(?:\\.|(?!\2)[^\\\r\n])*\2)/i,greedy:!0,inside:{interpolation:{pattern:/((?:^|[^{])(?:\{\{)*)\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}])+\})+\})+\}/,lookbehind:!0,inside:{"format-spec":{pattern:/(:)[^:(){}]+(?=\}$)/,lookbehind:!0},"conversion-option":{pattern:/![sra](?=[:}]$)/,alias:"punctuation"},rest:null}},string:/[\s\S]+/}},"triple-quoted-string":{pattern:/(?:[rub]|br|rb)?("""|''')[\s\S]*?\1/i,greedy:!0,alias:"string"},string:{pattern:/(?:[rub]|br|rb)?("|')(?:\\.|(?!\1)[^\\\r\n])*\1/i,greedy:!0},function:{pattern:/((?:^|\s)def[ \t]+)[a-zA-Z_]\w*(?=\s*\()/g,lookbehind:!0},"class-name":{pattern:/(\bclass\s+)\w+/i,lookbehind:!0},decorator:{pattern:/(^[\t ]*)@\w+(?:\.\w+)*/m,lookbehind:!0,alias:["annotation","punctuation"],inside:{punctuation:/\./}},keyword:/\b(?:_(?=\s*:)|and|as|assert|async|await|break|case|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|match|nonlocal|not|or|pass|print|raise|return|try|while|with|yield)\b/,builtin:/\b(?:__import__|abs|all|any|apply|ascii|basestring|bin|bool|buffer|bytearray|bytes|callable|chr|classmethod|cmp|coerce|compile|complex|delattr|dict|dir|divmod|enumerate|eval|execfile|file|filter|float|format|frozenset|getattr|globals|hasattr|hash|help|hex|id|input|int|intern|isinstance|issubclass|iter|len|list|locals|long|map|max|memoryview|min|next|object|oct|open|ord|pow|property|range|raw_input|reduce|reload|repr|reversed|round|set|setattr|slice|sorted|staticmethod|str|sum|super|tuple|type|unichr|unicode|vars|xrange|zip)\b/,boolean:/\b(?:False|None|True)\b/,number:/\b0(?:b(?:_?[01])+|o(?:_?[0-7])+|x(?:_?[a-f0-9])+)\b|(?:\b\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\B\.\d+(?:_\d+)*)(?:e[+-]?\d+(?:_\d+)*)?j?(?!\w)/i,operator:/[-+%=]=?|!=|:=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,punctuation:/[{}[\];(),.:]/},l.languages.python["string-interpolation"].inside.interpolation.inside.rest=l.languages.python,l.languages.py=l.languages.python}nf.displayName="r";nf.aliases=[];function nf(l){l.languages.r={comment:/#.*/,string:{pattern:/(['"])(?:\\.|(?!\1)[^\\\r\n])*\1/,greedy:!0},"percent-operator":{pattern:/%[^%\s]*%/,alias:"operator"},boolean:/\b(?:FALSE|TRUE)\b/,ellipsis:/\.\.(?:\.|\d+)/,number:[/\b(?:Inf|NaN)\b/,/(?:\b0x[\dA-Fa-f]+(?:\.\d*)?|\b\d+(?:\.\d*)?|\B\.\d+)(?:[EePp][+-]?\d+)?[iL]?/],keyword:/\b(?:NA|NA_character_|NA_complex_|NA_integer_|NA_real_|NULL|break|else|for|function|if|in|next|repeat|while)\b/,operator:/->?>?|<(?:=|<?-)?|[>=!]=?|::?|&&?|\|\|?|[+*\/^$@~]/,punctuation:/[(){}\[\],;]/}}af.displayName="ruby";af.aliases=["rb"];function af(l){l.register(sn),(function(i){i.languages.ruby=i.languages.extend("clike",{comment:{pattern:/#.*|^=begin\s[\s\S]*?^=end/m,greedy:!0},"class-name":{pattern:/(\b(?:class|module)\s+|\bcatch\s+\()[\w.\\]+|\b[A-Z_]\w*(?=\s*\.\s*new\b)/,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:BEGIN|END|alias|and|begin|break|case|class|def|define_method|defined|do|each|else|elsif|end|ensure|extend|for|if|in|include|module|new|next|nil|not|or|prepend|private|protected|public|raise|redo|require|rescue|retry|return|self|super|then|throw|undef|unless|until|when|while|yield)\b/,operator:/\.{2,3}|&\.|===|<?=>|[!=]?~|(?:&&|\|\||<<|>>|\*\*|[+\-*/%<>!^&|=])=?|[?:]/,punctuation:/[(){}[\].,;]/}),i.languages.insertBefore("ruby","operator",{"double-colon":{pattern:/::/,alias:"punctuation"}});var r={pattern:/((?:^|[^\\])(?:\\{2})*)#\{(?:[^{}]|\{[^{}]*\})*\}/,lookbehind:!0,inside:{content:{pattern:/^(#\{)[\s\S]+(?=\}$)/,lookbehind:!0,inside:i.languages.ruby},delimiter:{pattern:/^#\{|\}$/,alias:"punctuation"}}};delete i.languages.ruby.function;var s="(?:"+[/([^a-zA-Z0-9\s{(\[<=])(?:(?!\1)[^\\]|\\[\s\S])*\1/.source,/\((?:[^()\\]|\\[\s\S]|\((?:[^()\\]|\\[\s\S])*\))*\)/.source,/\{(?:[^{}\\]|\\[\s\S]|\{(?:[^{}\\]|\\[\s\S])*\})*\}/.source,/\[(?:[^\[\]\\]|\\[\s\S]|\[(?:[^\[\]\\]|\\[\s\S])*\])*\]/.source,/<(?:[^<>\\]|\\[\s\S]|<(?:[^<>\\]|\\[\s\S])*>)*>/.source].join("|")+")",o=/(?:"(?:\\.|[^"\\\r\n])*"|(?:\b[a-zA-Z_]\w*|[^\s\0-\x7F]+)[?!]?|\$.)/.source;i.languages.insertBefore("ruby","keyword",{"regex-literal":[{pattern:RegExp(/%r/.source+s+/[egimnosux]{0,6}/.source),greedy:!0,inside:{interpolation:r,regex:/[\s\S]+/}},{pattern:/(^|[^/])\/(?!\/)(?:\[[^\r\n\]]+\]|\\.|[^[/\\\r\n])+\/[egimnosux]{0,6}(?=\s*(?:$|[\r\n,.;})#]))/,lookbehind:!0,greedy:!0,inside:{interpolation:r,regex:/[\s\S]+/}}],variable:/[@$]+[a-zA-Z_]\w*(?:[?!]|\b)/,symbol:[{pattern:RegExp(/(^|[^:]):/.source+o),lookbehind:!0,greedy:!0},{pattern:RegExp(/([\r\n{(,][ \t]*)/.source+o+/(?=:(?!:))/.source),lookbehind:!0,greedy:!0}],"method-definition":{pattern:/(\bdef\s+)\w+(?:\s*\.\s*\w+)?/,lookbehind:!0,inside:{function:/\b\w+$/,keyword:/^self\b/,"class-name":/^\w+/,punctuation:/\./}}}),i.languages.insertBefore("ruby","string",{"string-literal":[{pattern:RegExp(/%[qQiIwWs]?/.source+s),greedy:!0,inside:{interpolation:r,string:/[\s\S]+/}},{pattern:/("|')(?:#\{[^}]+\}|#(?!\{)|\\(?:\r\n|[\s\S])|(?!\1)[^\\#\r\n])*\1/,greedy:!0,inside:{interpolation:r,string:/[\s\S]+/}},{pattern:/<<[-~]?([a-z_]\w*)[\r\n](?:.*[\r\n])*?[\t ]*\1/i,alias:"heredoc-string",greedy:!0,inside:{delimiter:{pattern:/^<<[-~]?[a-z_]\w*|\b[a-z_]\w*$/i,inside:{symbol:/\b\w+/,punctuation:/^<<[-~]?/}},interpolation:r,string:/[\s\S]+/}},{pattern:/<<[-~]?'([a-z_]\w*)'[\r\n](?:.*[\r\n])*?[\t ]*\1/i,alias:"heredoc-string",greedy:!0,inside:{delimiter:{pattern:/^<<[-~]?'[a-z_]\w*'|\b[a-z_]\w*$/i,inside:{symbol:/\b\w+/,punctuation:/^<<[-~]?'|'$/}},string:/[\s\S]+/}}],"command-literal":[{pattern:RegExp(/%x/.source+s),greedy:!0,inside:{interpolation:r,command:{pattern:/[\s\S]+/,alias:"string"}}},{pattern:/`(?:#\{[^}]+\}|#(?!\{)|\\(?:\r\n|[\s\S])|[^\\`#\r\n])*`/,greedy:!0,inside:{interpolation:r,command:{pattern:/[\s\S]+/,alias:"string"}}}]}),delete i.languages.ruby.string,i.languages.insertBefore("ruby","number",{builtin:/\b(?:Array|Bignum|Binding|Class|Continuation|Dir|Exception|FalseClass|File|Fixnum|Float|Hash|IO|Integer|MatchData|Method|Module|NilClass|Numeric|Object|Proc|Range|Regexp|Stat|String|Struct|Symbol|TMS|Thread|ThreadGroup|Time|TrueClass)\b/,constant:/\b[A-Z][A-Z0-9_]*(?:[?!]|\b)/}),i.languages.rb=i.languages.ruby})(l)}lf.displayName="rust";lf.aliases=[];function lf(l){(function(i){for(var r=/\/\*(?:[^*/]|\*(?!\/)|\/(?!\*)|<self>)*\*\//.source,s=0;s<2;s++)r=r.replace(/<self>/g,function(){return r});r=r.replace(/<self>/g,function(){return/[^\s\S]/.source}),i.languages.rust={comment:[{pattern:RegExp(/(^|[^\\])/.source+r),lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/b?"(?:\\[\s\S]|[^\\"])*"|b?r(#*)"(?:[^"]|"(?!\1))*"\1/,greedy:!0},char:{pattern:/b?'(?:\\(?:x[0-7][\da-fA-F]|u\{(?:[\da-fA-F]_*){1,6}\}|.)|[^\\\r\n\t'])'/,greedy:!0},attribute:{pattern:/#!?\[(?:[^\[\]"]|"(?:\\[\s\S]|[^\\"])*")*\]/,greedy:!0,alias:"attr-name",inside:{string:null}},"closure-params":{pattern:/([=(,:]\s*|\bmove\s*)\|[^|]*\||\|[^|]*\|(?=\s*(?:\{|->))/,lookbehind:!0,greedy:!0,inside:{"closure-punctuation":{pattern:/^\||\|$/,alias:"punctuation"},rest:null}},"lifetime-annotation":{pattern:/'\w+/,alias:"symbol"},"fragment-specifier":{pattern:/(\$\w+:)[a-z]+/,lookbehind:!0,alias:"punctuation"},variable:/\$\w+/,"function-definition":{pattern:/(\bfn\s+)\w+/,lookbehind:!0,alias:"function"},"type-definition":{pattern:/(\b(?:enum|struct|trait|type|union)\s+)\w+/,lookbehind:!0,alias:"class-name"},"module-declaration":[{pattern:/(\b(?:crate|mod)\s+)[a-z][a-z_\d]*/,lookbehind:!0,alias:"namespace"},{pattern:/(\b(?:crate|self|super)\s*)::\s*[a-z][a-z_\d]*\b(?:\s*::(?:\s*[a-z][a-z_\d]*\s*::)*)?/,lookbehind:!0,alias:"namespace",inside:{punctuation:/::/}}],keyword:[/\b(?:Self|abstract|as|async|await|become|box|break|const|continue|crate|do|dyn|else|enum|extern|final|fn|for|if|impl|in|let|loop|macro|match|mod|move|mut|override|priv|pub|ref|return|self|static|struct|super|trait|try|type|typeof|union|unsafe|unsized|use|virtual|where|while|yield)\b/,/\b(?:bool|char|f(?:32|64)|[ui](?:8|16|32|64|128|size)|str)\b/],function:/\b[a-z_]\w*(?=\s*(?:::\s*<|\())/,macro:{pattern:/\b\w+!/,alias:"property"},constant:/\b[A-Z_][A-Z_\d]+\b/,"class-name":/\b[A-Z]\w*\b/,namespace:{pattern:/(?:\b[a-z][a-z_\d]*\s*::\s*)*\b[a-z][a-z_\d]*\s*::(?!\s*<)/,inside:{punctuation:/::/}},number:/\b(?:0x[\dA-Fa-f](?:_?[\dA-Fa-f])*|0o[0-7](?:_?[0-7])*|0b[01](?:_?[01])*|(?:(?:\d(?:_?\d)*)?\.)?\d(?:_?\d)*(?:[Ee][+-]?\d+)?)(?:_?(?:f32|f64|[iu](?:8|16|32|64|size)?))?\b/,boolean:/\b(?:false|true)\b/,punctuation:/->|\.\.=|\.{1,3}|::|[{}[\];(),:]/,operator:/[-+*\/%!^]=?|=[=>]?|&[&=]?|\|[|=]?|<<?=?|>>?=?|[@?]/},i.languages.rust["closure-params"].inside.rest=i.languages.rust,i.languages.rust.attribute.inside.string=i.languages.rust.string})(l)}rf.displayName="sass";rf.aliases=[];function rf(l){l.register(Tl),(function(i){i.languages.sass=i.languages.extend("css",{comment:{pattern:/^([ \t]*)\/[\/*].*(?:(?:\r?\n|\r)\1[ \t].+)*/m,lookbehind:!0,greedy:!0}}),i.languages.insertBefore("sass","atrule",{"atrule-line":{pattern:/^(?:[ \t]*)[@+=].+/m,greedy:!0,inside:{atrule:/(?:@[\w-]+|[+=])/}}}),delete i.languages.sass.atrule;var r=/\$[-\w]+|#\{\$[-\w]+\}/,s=[/[+*\/%]|[=!]=|<=?|>=?|\b(?:and|not|or)\b/,{pattern:/(\s)-(?=\s)/,lookbehind:!0}];i.languages.insertBefore("sass","property",{"variable-line":{pattern:/^[ \t]*\$.+/m,greedy:!0,inside:{punctuation:/:/,variable:r,operator:s}},"property-line":{pattern:/^[ \t]*(?:[^:\s]+ *:.*|:[^:\s].*)/m,greedy:!0,inside:{property:[/[^:\s]+(?=\s*:)/,{pattern:/(:)[^:\s]+/,lookbehind:!0}],punctuation:/:/,variable:r,operator:s,important:i.languages.sass.important}}}),delete i.languages.sass.property,delete i.languages.sass.important,i.languages.insertBefore("sass","punctuation",{selector:{pattern:/^([ \t]*)\S(?:,[^,\r\n]+|[^,\r\n]*)(?:,[^,\r\n]+)*(?:,(?:\r?\n|\r)\1[ \t]+\S(?:,[^,\r\n]+|[^,\r\n]*)(?:,[^,\r\n]+)*)*/m,lookbehind:!0,greedy:!0}})})(l)}sf.displayName="scss";sf.aliases=[];function sf(l){l.register(Tl),l.languages.scss=l.languages.extend("css",{comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|\/\/.*)/,lookbehind:!0},atrule:{pattern:/@[\w-](?:\([^()]+\)|[^()\s]|\s+(?!\s))*?(?=\s+[{;])/,inside:{rule:/@[\w-]+/}},url:/(?:[-a-z]+-)?url(?=\()/i,selector:{pattern:/(?=\S)[^@;{}()]?(?:[^@;{}()\s]|\s+(?!\s)|#\{\$[-\w]+\})+(?=\s*\{(?:\}|\s|[^}][^:{}]*[:{][^}]))/,inside:{parent:{pattern:/&/,alias:"important"},placeholder:/%[-\w]+/,variable:/\$[-\w]+|#\{\$[-\w]+\}/}},property:{pattern:/(?:[-\w]|\$[-\w]|#\{\$[-\w]+\})+(?=\s*:)/,inside:{variable:/\$[-\w]+|#\{\$[-\w]+\}/}}}),l.languages.insertBefore("scss","atrule",{keyword:[/@(?:content|debug|each|else(?: if)?|extend|for|forward|function|if|import|include|mixin|return|use|warn|while)\b/i,{pattern:/( )(?:from|through)(?= )/,lookbehind:!0}]}),l.languages.insertBefore("scss","important",{variable:/\$[-\w]+|#\{\$[-\w]+\}/}),l.languages.insertBefore("scss","function",{"module-modifier":{pattern:/\b(?:as|hide|show|with)\b/i,alias:"keyword"},placeholder:{pattern:/%[-\w]+/,alias:"selector"},statement:{pattern:/\B!(?:default|optional)\b/i,alias:"keyword"},boolean:/\b(?:false|true)\b/,null:{pattern:/\bnull\b/,alias:"keyword"},operator:{pattern:/(\s)(?:[-+*\/%]|[=!]=|<=?|>=?|and|not|or)(?=\s)/,lookbehind:!0}}),l.languages.scss.atrule.inside.rest=l.languages.scss}uf.displayName="sql";uf.aliases=[];function uf(l){l.languages.sql={comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|(?:--|\/\/|#).*)/,lookbehind:!0},variable:[{pattern:/@(["'`])(?:\\[\s\S]|(?!\1)[^\\])+\1/,greedy:!0},/@[\w.$]+/],string:{pattern:/(^|[^@\\])("|')(?:\\[\s\S]|(?!\2)[^\\]|\2\2)*\2/,greedy:!0,lookbehind:!0},identifier:{pattern:/(^|[^@\\])`(?:\\[\s\S]|[^`\\]|``)*`/,greedy:!0,lookbehind:!0,inside:{punctuation:/^`|`$/}},function:/\b(?:AVG|COUNT|FIRST|FORMAT|LAST|LCASE|LEN|MAX|MID|MIN|MOD|NOW|ROUND|SUM|UCASE)(?=\s*\()/i,keyword:/\b(?:ACTION|ADD|AFTER|ALGORITHM|ALL|ALTER|ANALYZE|ANY|APPLY|AS|ASC|AUTHORIZATION|AUTO_INCREMENT|BACKUP|BDB|BEGIN|BERKELEYDB|BIGINT|BINARY|BIT|BLOB|BOOL|BOOLEAN|BREAK|BROWSE|BTREE|BULK|BY|CALL|CASCADED?|CASE|CHAIN|CHAR(?:ACTER|SET)?|CHECK(?:POINT)?|CLOSE|CLUSTERED|COALESCE|COLLATE|COLUMNS?|COMMENT|COMMIT(?:TED)?|COMPUTE|CONNECT|CONSISTENT|CONSTRAINT|CONTAINS(?:TABLE)?|CONTINUE|CONVERT|CREATE|CROSS|CURRENT(?:_DATE|_TIME|_TIMESTAMP|_USER)?|CURSOR|CYCLE|DATA(?:BASES?)?|DATE(?:TIME)?|DAY|DBCC|DEALLOCATE|DEC|DECIMAL|DECLARE|DEFAULT|DEFINER|DELAYED|DELETE|DELIMITERS?|DENY|DESC|DESCRIBE|DETERMINISTIC|DISABLE|DISCARD|DISK|DISTINCT|DISTINCTROW|DISTRIBUTED|DO|DOUBLE|DROP|DUMMY|DUMP(?:FILE)?|DUPLICATE|ELSE(?:IF)?|ENABLE|ENCLOSED|END|ENGINE|ENUM|ERRLVL|ERRORS|ESCAPED?|EXCEPT|EXEC(?:UTE)?|EXISTS|EXIT|EXPLAIN|EXTENDED|FETCH|FIELDS|FILE|FILLFACTOR|FIRST|FIXED|FLOAT|FOLLOWING|FOR(?: EACH ROW)?|FORCE|FOREIGN|FREETEXT(?:TABLE)?|FROM|FULL|FUNCTION|GEOMETRY(?:COLLECTION)?|GLOBAL|GOTO|GRANT|GROUP|HANDLER|HASH|HAVING|HOLDLOCK|HOUR|IDENTITY(?:COL|_INSERT)?|IF|IGNORE|IMPORT|INDEX|INFILE|INNER|INNODB|INOUT|INSERT|INT|INTEGER|INTERSECT|INTERVAL|INTO|INVOKER|ISOLATION|ITERATE|JOIN|KEYS?|KILL|LANGUAGE|LAST|LEAVE|LEFT|LEVEL|LIMIT|LINENO|LINES|LINESTRING|LOAD|LOCAL|LOCK|LONG(?:BLOB|TEXT)|LOOP|MATCH(?:ED)?|MEDIUM(?:BLOB|INT|TEXT)|MERGE|MIDDLEINT|MINUTE|MODE|MODIFIES|MODIFY|MONTH|MULTI(?:LINESTRING|POINT|POLYGON)|NATIONAL|NATURAL|NCHAR|NEXT|NO|NONCLUSTERED|NULLIF|NUMERIC|OFF?|OFFSETS?|ON|OPEN(?:DATASOURCE|QUERY|ROWSET)?|OPTIMIZE|OPTION(?:ALLY)?|ORDER|OUT(?:ER|FILE)?|OVER|PARTIAL|PARTITION|PERCENT|PIVOT|PLAN|POINT|POLYGON|PRECEDING|PRECISION|PREPARE|PREV|PRIMARY|PRINT|PRIVILEGES|PROC(?:EDURE)?|PUBLIC|PURGE|QUICK|RAISERROR|READS?|REAL|RECONFIGURE|REFERENCES|RELEASE|RENAME|REPEAT(?:ABLE)?|REPLACE|REPLICATION|REQUIRE|RESIGNAL|RESTORE|RESTRICT|RETURN(?:ING|S)?|REVOKE|RIGHT|ROLLBACK|ROUTINE|ROW(?:COUNT|GUIDCOL|S)?|RTREE|RULE|SAVE(?:POINT)?|SCHEMA|SECOND|SELECT|SERIAL(?:IZABLE)?|SESSION(?:_USER)?|SET(?:USER)?|SHARE|SHOW|SHUTDOWN|SIMPLE|SMALLINT|SNAPSHOT|SOME|SONAME|SQL|START(?:ING)?|STATISTICS|STATUS|STRIPED|SYSTEM_USER|TABLES?|TABLESPACE|TEMP(?:ORARY|TABLE)?|TERMINATED|TEXT(?:SIZE)?|THEN|TIME(?:STAMP)?|TINY(?:BLOB|INT|TEXT)|TOP?|TRAN(?:SACTIONS?)?|TRIGGER|TRUNCATE|TSEQUAL|TYPES?|UNBOUNDED|UNCOMMITTED|UNDEFINED|UNION|UNIQUE|UNLOCK|UNPIVOT|UNSIGNED|UPDATE(?:TEXT)?|USAGE|USE|USER|USING|VALUES?|VAR(?:BINARY|CHAR|CHARACTER|YING)|VIEW|WAITFOR|WARNINGS|WHEN|WHERE|WHILE|WITH(?: ROLLUP|IN)?|WORK|WRITE(?:TEXT)?|YEAR)\b/i,boolean:/\b(?:FALSE|NULL|TRUE)\b/i,number:/\b0x[\da-f]+\b|\b\d+(?:\.\d*)?|\B\.\d+\b/i,operator:/[-+*\/=%^~]|&&?|\|\|?|!=?|<(?:=>?|<|>)?|>[>=]?|\b(?:AND|BETWEEN|DIV|ILIKE|IN|IS|LIKE|NOT|OR|REGEXP|RLIKE|SOUNDS LIKE|XOR)\b/i,punctuation:/[;[\]()`,.]/}}cf.displayName="swift";cf.aliases=[];function cf(l){l.languages.swift={comment:{pattern:/(^|[^\\:])(?:\/\/.*|\/\*(?:[^/*]|\/(?!\*)|\*(?!\/)|\/\*(?:[^*]|\*(?!\/))*\*\/)*\*\/)/,lookbehind:!0,greedy:!0},"string-literal":[{pattern:RegExp(/(^|[^"#])/.source+"(?:"+/"(?:\\(?:\((?:[^()]|\([^()]*\))*\)|\r\n|[^(])|[^\\\r\n"])*"/.source+"|"+/"""(?:\\(?:\((?:[^()]|\([^()]*\))*\)|[^(])|[^\\"]|"(?!""))*"""/.source+")"+/(?!["#])/.source),lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:/(\\\()(?:[^()]|\([^()]*\))*(?=\))/,lookbehind:!0,inside:null},"interpolation-punctuation":{pattern:/^\)|\\\($/,alias:"punctuation"},punctuation:/\\(?=[\r\n])/,string:/[\s\S]+/}},{pattern:RegExp(/(^|[^"#])(#+)/.source+"(?:"+/"(?:\\(?:#+\((?:[^()]|\([^()]*\))*\)|\r\n|[^#])|[^\\\r\n])*?"/.source+"|"+/"""(?:\\(?:#+\((?:[^()]|\([^()]*\))*\)|[^#])|[^\\])*?"""/.source+")\\2"),lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:/(\\#+\()(?:[^()]|\([^()]*\))*(?=\))/,lookbehind:!0,inside:null},"interpolation-punctuation":{pattern:/^\)|\\#+\($/,alias:"punctuation"},string:/[\s\S]+/}}],directive:{pattern:RegExp(/#/.source+"(?:"+(/(?:elseif|if)\b/.source+"(?:[ ]*"+/(?:![ \t]*)?(?:\b\w+\b(?:[ \t]*\((?:[^()]|\([^()]*\))*\))?|\((?:[^()]|\([^()]*\))*\))(?:[ \t]*(?:&&|\|\|))?/.source+")+")+"|"+/(?:else|endif)\b/.source+")"),alias:"property",inside:{"directive-name":/^#\w+/,boolean:/\b(?:false|true)\b/,number:/\b\d+(?:\.\d+)*\b/,operator:/!|&&|\|\||[<>]=?/,punctuation:/[(),]/}},literal:{pattern:/#(?:colorLiteral|column|dsohandle|file(?:ID|Literal|Path)?|function|imageLiteral|line)\b/,alias:"constant"},"other-directive":{pattern:/#\w+\b/,alias:"property"},attribute:{pattern:/@\w+/,alias:"atrule"},"function-definition":{pattern:/(\bfunc\s+)\w+/,lookbehind:!0,alias:"function"},label:{pattern:/\b(break|continue)\s+\w+|\b[a-zA-Z_]\w*(?=\s*:\s*(?:for|repeat|while)\b)/,lookbehind:!0,alias:"important"},keyword:/\b(?:Any|Protocol|Self|Type|actor|as|assignment|associatedtype|associativity|async|await|break|case|catch|class|continue|convenience|default|defer|deinit|didSet|do|dynamic|else|enum|extension|fallthrough|fileprivate|final|for|func|get|guard|higherThan|if|import|in|indirect|infix|init|inout|internal|is|isolated|lazy|left|let|lowerThan|mutating|none|nonisolated|nonmutating|open|operator|optional|override|postfix|precedencegroup|prefix|private|protocol|public|repeat|required|rethrows|return|right|safe|self|set|some|static|struct|subscript|super|switch|throw|throws|try|typealias|unowned|unsafe|var|weak|where|while|willSet)\b/,boolean:/\b(?:false|true)\b/,nil:{pattern:/\bnil\b/,alias:"constant"},"short-argument":/\$\d+\b/,omit:{pattern:/\b_\b/,alias:"keyword"},number:/\b(?:[\d_]+(?:\.[\de_]+)?|0x[a-f0-9_]+(?:\.[a-f0-9p_]+)?|0b[01_]+|0o[0-7_]+)\b/i,"class-name":/\b[A-Z](?:[A-Z_\d]*[a-z]\w*)?\b/,function:/\b[a-z_]\w*(?=\s*\()/i,constant:/\b(?:[A-Z_]{2,}|k[A-Z][A-Za-z_]+)\b/,operator:/[-+*/%=!<>&|^~?]+|\.[.\-+*/%=!<>&|^~?]+/,punctuation:/[{}[\]();,.:\\]/},l.languages.swift["string-literal"].forEach(function(i){i.inside.interpolation.inside=l.languages.swift})}of.displayName="typescript";of.aliases=["ts"];function of(l){l.register(As),(function(i){i.languages.typescript=i.languages.extend("javascript",{"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|type)\s+)(?!keyof\b)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?:\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>)?/,lookbehind:!0,greedy:!0,inside:null},builtin:/\b(?:Array|Function|Promise|any|boolean|console|never|number|string|symbol|unknown)\b/}),i.languages.typescript.keyword.push(/\b(?:abstract|declare|is|keyof|readonly|require)\b/,/\b(?:asserts|infer|interface|module|namespace|type)\b(?=\s*(?:[{_$a-zA-Z\xA0-\uFFFF]|$))/,/\btype\b(?=\s*(?:[\{*]|$))/),delete i.languages.typescript.parameter,delete i.languages.typescript["literal-property"];var r=i.languages.extend("typescript",{});delete r["class-name"],i.languages.typescript["class-name"].inside=r,i.languages.insertBefore("typescript","function",{decorator:{pattern:/@[$\w\xA0-\uFFFF]+/,inside:{at:{pattern:/^@/,alias:"operator"},function:/^[\s\S]+/}},"generic-function":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>(?=\s*\()/,greedy:!0,inside:{function:/^#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*/,generic:{pattern:/<[\s\S]+/,alias:"class-name",inside:r}}}}),i.languages.ts=i.languages.typescript})(l)}Cs.displayName="basic";Cs.aliases=[];function Cs(l){l.languages.basic={comment:{pattern:/(?:!|REM\b).+/i,inside:{keyword:/^REM/i}},string:{pattern:/"(?:""|[!#$%&'()*,\/:;<=>?^\w +\-.])*"/,greedy:!0},number:/(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:E[+-]?\d+)?/i,keyword:/\b(?:AS|BEEP|BLOAD|BSAVE|CALL(?: ABSOLUTE)?|CASE|CHAIN|CHDIR|CLEAR|CLOSE|CLS|COM|COMMON|CONST|DATA|DECLARE|DEF(?: FN| SEG|DBL|INT|LNG|SNG|STR)|DIM|DO|DOUBLE|ELSE|ELSEIF|END|ENVIRON|ERASE|ERROR|EXIT|FIELD|FILES|FOR|FUNCTION|GET|GOSUB|GOTO|IF|INPUT|INTEGER|IOCTL|KEY|KILL|LINE INPUT|LOCATE|LOCK|LONG|LOOP|LSET|MKDIR|NAME|NEXT|OFF|ON(?: COM| ERROR| KEY| TIMER)?|OPEN|OPTION BASE|OUT|POKE|PUT|READ|REDIM|REM|RESTORE|RESUME|RETURN|RMDIR|RSET|RUN|SELECT CASE|SHARED|SHELL|SINGLE|SLEEP|STATIC|STEP|STOP|STRING|SUB|SWAP|SYSTEM|THEN|TIMER|TO|TROFF|TRON|TYPE|UNLOCK|UNTIL|USING|VIEW PRINT|WAIT|WEND|WHILE|WRITE)(?:\$|\b)/i,function:/\b(?:ABS|ACCESS|ACOS|ANGLE|AREA|ARITHMETIC|ARRAY|ASIN|ASK|AT|ATN|BASE|BEGIN|BREAK|CAUSE|CEIL|CHR|CLIP|COLLATE|COLOR|CON|COS|COSH|COT|CSC|DATE|DATUM|DEBUG|DECIMAL|DEF|DEG|DEGREES|DELETE|DET|DEVICE|DISPLAY|DOT|ELAPSED|EPS|ERASABLE|EXLINE|EXP|EXTERNAL|EXTYPE|FILETYPE|FIXED|FP|GO|GRAPH|HANDLER|IDN|IMAGE|IN|INT|INTERNAL|IP|IS|KEYED|LBOUND|LCASE|LEFT|LEN|LENGTH|LET|LINE|LINES|LOG|LOG10|LOG2|LTRIM|MARGIN|MAT|MAX|MAXNUM|MID|MIN|MISSING|MOD|NATIVE|NUL|NUMERIC|OF|OPTION|ORD|ORGANIZATION|OUTIN|OUTPUT|PI|POINT|POINTER|POINTS|POS|PRINT|PROGRAM|PROMPT|RAD|RADIANS|RANDOMIZE|RECORD|RECSIZE|RECTYPE|RELATIVE|REMAINDER|REPEAT|REST|RETRY|REWRITE|RIGHT|RND|ROUND|RTRIM|SAME|SEC|SELECT|SEQUENTIAL|SET|SETTER|SGN|SIN|SINH|SIZE|SKIP|SQR|STANDARD|STATUS|STR|STREAM|STYLE|TAB|TAN|TANH|TEMPLATE|TEXT|THERE|TIME|TIMEOUT|TRACE|TRANSFORM|TRUNCATE|UBOUND|UCASE|USE|VAL|VARIABLE|VIEWPORT|WHEN|WINDOW|WITH|ZER|ZONEWIDTH)(?:\$|\b)/i,operator:/<[=>]?|>=?|[+\-*\/^=&]|\b(?:AND|EQV|IMP|NOT|OR|XOR)\b/i,punctuation:/[,;:()]/}}ff.displayName="vbnet";ff.aliases=[];function ff(l){l.register(Cs),l.languages.vbnet=l.languages.extend("basic",{comment:[{pattern:/(?:!|REM\b).+/i,inside:{keyword:/^REM/i}},{pattern:/(^|[^\\:])'.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(^|[^"])"(?:""|[^"])*"(?!")/,lookbehind:!0,greedy:!0},keyword:/(?:\b(?:ADDHANDLER|ADDRESSOF|ALIAS|AND|ANDALSO|AS|BEEP|BLOAD|BOOLEAN|BSAVE|BYREF|BYTE|BYVAL|CALL(?: ABSOLUTE)?|CASE|CATCH|CBOOL|CBYTE|CCHAR|CDATE|CDBL|CDEC|CHAIN|CHAR|CHDIR|CINT|CLASS|CLEAR|CLNG|CLOSE|CLS|COBJ|COM|COMMON|CONST|CONTINUE|CSBYTE|CSHORT|CSNG|CSTR|CTYPE|CUINT|CULNG|CUSHORT|DATA|DATE|DECIMAL|DECLARE|DEF(?: FN| SEG|DBL|INT|LNG|SNG|STR)|DEFAULT|DELEGATE|DIM|DIRECTCAST|DO|DOUBLE|ELSE|ELSEIF|END|ENUM|ENVIRON|ERASE|ERROR|EVENT|EXIT|FALSE|FIELD|FILES|FINALLY|FOR(?: EACH)?|FRIEND|FUNCTION|GET|GETTYPE|GETXMLNAMESPACE|GLOBAL|GOSUB|GOTO|HANDLES|IF|IMPLEMENTS|IMPORTS|IN|INHERITS|INPUT|INTEGER|INTERFACE|IOCTL|IS|ISNOT|KEY|KILL|LET|LIB|LIKE|LINE INPUT|LOCATE|LOCK|LONG|LOOP|LSET|ME|MKDIR|MOD|MODULE|MUSTINHERIT|MUSTOVERRIDE|MYBASE|MYCLASS|NAME|NAMESPACE|NARROWING|NEW|NEXT|NOT|NOTHING|NOTINHERITABLE|NOTOVERRIDABLE|OBJECT|OF|OFF|ON(?: COM| ERROR| KEY| TIMER)?|OPEN|OPERATOR|OPTION(?: BASE)?|OPTIONAL|OR|ORELSE|OUT|OVERLOADS|OVERRIDABLE|OVERRIDES|PARAMARRAY|PARTIAL|POKE|PRIVATE|PROPERTY|PROTECTED|PUBLIC|PUT|RAISEEVENT|READ|READONLY|REDIM|REM|REMOVEHANDLER|RESTORE|RESUME|RETURN|RMDIR|RSET|RUN|SBYTE|SELECT(?: CASE)?|SET|SHADOWS|SHARED|SHELL|SHORT|SINGLE|SLEEP|STATIC|STEP|STOP|STRING|STRUCTURE|SUB|SWAP|SYNCLOCK|SYSTEM|THEN|THROW|TIMER|TO|TROFF|TRON|TRUE|TRY|TRYCAST|TYPE|TYPEOF|UINTEGER|ULONG|UNLOCK|UNTIL|USHORT|USING|VIEW PRINT|WAIT|WEND|WHEN|WHILE|WIDENING|WITH|WITHEVENTS|WRITE|WRITEONLY|XOR)|\B(?:#CONST|#ELSE|#ELSEIF|#END|#IF))(?:\$|\b)/i,punctuation:/[,;:(){}]/})}class zr{constructor(i,r,s){this.property=i,this.normal=r,s&&(this.space=s)}}zr.prototype.property={};zr.prototype.normal={};zr.prototype.space=null;function Wp(l,i){const r={},s={};let o=-1;for(;++o<l.length;)Object.assign(r,l[o].property),Object.assign(s,l[o].normal);return new zr(r,s,i)}function jr(l){return l.toLowerCase()}class Kt{constructor(i,r){this.property=i,this.attribute=r}}Kt.prototype.space=null;Kt.prototype.boolean=!1;Kt.prototype.booleanish=!1;Kt.prototype.overloadedBoolean=!1;Kt.prototype.number=!1;Kt.prototype.commaSeparated=!1;Kt.prototype.spaceSeparated=!1;Kt.prototype.commaOrSpaceSeparated=!1;Kt.prototype.mustUseProperty=!1;Kt.prototype.defined=!1;let LS=0;const xe=_a(),We=_a(),Pp=_a(),W=_a(),He=_a(),xl=_a(),Mt=_a();function _a(){return 2**++LS}const fo=Object.freeze(Object.defineProperty({__proto__:null,boolean:xe,booleanish:We,commaOrSpaceSeparated:Mt,commaSeparated:xl,number:W,overloadedBoolean:Pp,spaceSeparated:He},Symbol.toStringTag,{value:"Module"})),eo=Object.keys(fo);class df extends Kt{constructor(i,r,s,o){let d=-1;if(super(i,r),ap(this,"space",o),typeof s=="number")for(;++d<eo.length;){const h=eo[d];ap(this,eo[d],(s&fo[h])===fo[h])}}}df.prototype.defined=!0;function ap(l,i,r){r&&(l[i]=r)}const US={}.hasOwnProperty;function Cl(l){const i={},r={};let s;for(s in l.properties)if(US.call(l.properties,s)){const o=l.properties[s],d=new df(s,l.transform(l.attributes||{},s),o,l.space);l.mustUseProperty&&l.mustUseProperty.includes(s)&&(d.mustUseProperty=!0),i[s]=d,r[jr(s)]=s,r[jr(d.attribute)]=s}return new zr(i,r,l.space)}const ey=Cl({space:"xlink",transform(l,i){return"xlink:"+i.slice(5).toLowerCase()},properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null}}),ty=Cl({space:"xml",transform(l,i){return"xml:"+i.slice(3).toLowerCase()},properties:{xmlLang:null,xmlBase:null,xmlSpace:null}});function ny(l,i){return i in l?l[i]:i}function ay(l,i){return ny(l,i.toLowerCase())}const ly=Cl({space:"xmlns",attributes:{xmlnsxlink:"xmlns:xlink"},transform:ay,properties:{xmlns:null,xmlnsXLink:null}}),ry=Cl({transform(l,i){return i==="role"?i:"aria-"+i.slice(4).toLowerCase()},properties:{ariaActiveDescendant:null,ariaAtomic:We,ariaAutoComplete:null,ariaBusy:We,ariaChecked:We,ariaColCount:W,ariaColIndex:W,ariaColSpan:W,ariaControls:He,ariaCurrent:null,ariaDescribedBy:He,ariaDetails:null,ariaDisabled:We,ariaDropEffect:He,ariaErrorMessage:null,ariaExpanded:We,ariaFlowTo:He,ariaGrabbed:We,ariaHasPopup:null,ariaHidden:We,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:He,ariaLevel:W,ariaLive:null,ariaModal:We,ariaMultiLine:We,ariaMultiSelectable:We,ariaOrientation:null,ariaOwns:He,ariaPlaceholder:null,ariaPosInSet:W,ariaPressed:We,ariaReadOnly:We,ariaRelevant:null,ariaRequired:We,ariaRoleDescription:He,ariaRowCount:W,ariaRowIndex:W,ariaRowSpan:W,ariaSelected:We,ariaSetSize:W,ariaSort:null,ariaValueMax:W,ariaValueMin:W,ariaValueNow:W,ariaValueText:null,role:null}}),BS=Cl({space:"html",attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},transform:ay,mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:xl,acceptCharset:He,accessKey:He,action:null,allow:null,allowFullScreen:xe,allowPaymentRequest:xe,allowUserMedia:xe,alt:null,as:null,async:xe,autoCapitalize:null,autoComplete:He,autoFocus:xe,autoPlay:xe,blocking:He,capture:null,charSet:null,checked:xe,cite:null,className:He,cols:W,colSpan:null,content:null,contentEditable:We,controls:xe,controlsList:He,coords:W|xl,crossOrigin:null,data:null,dateTime:null,decoding:null,default:xe,defer:xe,dir:null,dirName:null,disabled:xe,download:Pp,draggable:We,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:xe,formTarget:null,headers:He,height:W,hidden:xe,high:W,href:null,hrefLang:null,htmlFor:He,httpEquiv:He,id:null,imageSizes:null,imageSrcSet:null,inert:xe,inputMode:null,integrity:null,is:null,isMap:xe,itemId:null,itemProp:He,itemRef:He,itemScope:xe,itemType:He,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:xe,low:W,manifest:null,max:null,maxLength:W,media:null,method:null,min:null,minLength:W,multiple:xe,muted:xe,name:null,nonce:null,noModule:xe,noValidate:xe,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:xe,optimum:W,pattern:null,ping:He,placeholder:null,playsInline:xe,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:xe,referrerPolicy:null,rel:He,required:xe,reversed:xe,rows:W,rowSpan:W,sandbox:He,scope:null,scoped:xe,seamless:xe,selected:xe,shadowRootClonable:xe,shadowRootDelegatesFocus:xe,shadowRootMode:null,shape:null,size:W,sizes:null,slot:null,span:W,spellCheck:We,src:null,srcDoc:null,srcLang:null,srcSet:null,start:W,step:null,style:null,tabIndex:W,target:null,title:null,translate:null,type:null,typeMustMatch:xe,useMap:null,value:We,width:W,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:He,axis:null,background:null,bgColor:null,border:W,borderColor:null,bottomMargin:W,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:xe,declare:xe,event:null,face:null,frame:null,frameBorder:null,hSpace:W,leftMargin:W,link:null,longDesc:null,lowSrc:null,marginHeight:W,marginWidth:W,noResize:xe,noHref:xe,noShade:xe,noWrap:xe,object:null,profile:null,prompt:null,rev:null,rightMargin:W,rules:null,scheme:null,scrolling:We,standby:null,summary:null,text:null,topMargin:W,valueType:null,version:null,vAlign:null,vLink:null,vSpace:W,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:xe,disableRemotePlayback:xe,prefix:null,property:null,results:W,security:null,unselectable:null}}),HS=Cl({space:"svg",attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},transform:ny,properties:{about:Mt,accentHeight:W,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:W,amplitude:W,arabicForm:null,ascent:W,attributeName:null,attributeType:null,azimuth:W,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:W,by:null,calcMode:null,capHeight:W,className:He,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:W,diffuseConstant:W,direction:null,display:null,dur:null,divisor:W,dominantBaseline:null,download:xe,dx:null,dy:null,edgeMode:null,editable:null,elevation:W,enableBackground:null,end:null,event:null,exponent:W,externalResourcesRequired:null,fill:null,fillOpacity:W,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:xl,g2:xl,glyphName:xl,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:W,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:W,horizOriginX:W,horizOriginY:W,id:null,ideographic:W,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:W,k:W,k1:W,k2:W,k3:W,k4:W,kernelMatrix:Mt,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:W,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:W,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:W,overlineThickness:W,paintOrder:null,panose1:null,path:null,pathLength:W,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:He,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:W,pointsAtY:W,pointsAtZ:W,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:Mt,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:Mt,rev:Mt,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:Mt,requiredFeatures:Mt,requiredFonts:Mt,requiredFormats:Mt,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:W,specularExponent:W,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:W,strikethroughThickness:W,string:null,stroke:null,strokeDashArray:Mt,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:W,strokeOpacity:W,strokeWidth:null,style:null,surfaceScale:W,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:Mt,tabIndex:W,tableValues:null,target:null,targetX:W,targetY:W,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:Mt,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:W,underlineThickness:W,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:W,values:null,vAlphabetic:W,vMathematical:W,vectorEffect:null,vHanging:W,vIdeographic:W,version:null,vertAdvY:W,vertOriginX:W,vertOriginY:W,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:W,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null}}),GS=/^data[-\w.:]+$/i,lp=/-[a-z]/g,YS=/[A-Z]/g;function qS(l,i){const r=jr(i);let s=i,o=Kt;if(r in l.normal)return l.property[l.normal[r]];if(r.length>4&&r.slice(0,4)==="data"&&GS.test(i)){if(i.charAt(4)==="-"){const d=i.slice(5).replace(lp,XS);s="data"+d.charAt(0).toUpperCase()+d.slice(1)}else{const d=i.slice(4);if(!lp.test(d)){let h=d.replace(YS,IS);h.charAt(0)!=="-"&&(h="-"+h),i="data"+h}}o=df}return new o(s,i)}function IS(l){return"-"+l.toLowerCase()}function XS(l){return l.charAt(1).toUpperCase()}const FS=Wp([ty,ey,ly,ry,BS],"html");Wp([ty,ey,ly,ry,HS],"svg");const rp=/[#.]/g;function ZS(l,i){const r=l||"",s={};let o=0,d,h;for(;o<r.length;){rp.lastIndex=o;const m=rp.exec(r),g=r.slice(o,m?m.index:r.length);g&&(d?d==="#"?s.id=g:Array.isArray(s.className)?s.className.push(g):s.className=[g]:h=g,o+=g.length),m&&(d=m[0],o++)}return{type:"element",tagName:h||i||"div",properties:s,children:[]}}function ip(l){const i=String(l||"").trim();return i?i.split(/[ \t\n\r\f]+/g):[]}function sp(l){const i=[],r=String(l||"");let s=r.indexOf(","),o=0,d=!1;for(;!d;){s===-1&&(s=r.length,d=!0);const h=r.slice(o,s).trim();(h||!d)&&i.push(h),o=s+1,s=r.indexOf(",",o)}return i}const $S=new Set(["menu","submit","reset","button"]),iy={}.hasOwnProperty;function VS(l,i,r){return(function(o,d,...h){let m=-1,g;if(o==null)g={type:"root",children:[]},h.unshift(d);else if(g=ZS(o,i),g.tagName=g.tagName.toLowerCase(),KS(d,g.tagName)){let y;for(y in d)iy.call(d,y)&&QS(l,g.properties,y,d[y])}else h.unshift(d);for(;++m<h.length;)ho(g.children,h[m]);return g.type==="element"&&g.tagName==="template"&&(g.content={type:"root",children:g.children},g.children=[]),g})}function KS(l,i){return l==null||typeof l!="object"||Array.isArray(l)?!1:i==="input"||!l.type||typeof l.type!="string"?!0:"children"in l&&Array.isArray(l.children)?!1:i==="button"?$S.has(l.type.toLowerCase()):!("value"in l)}function QS(l,i,r,s){const o=qS(l,r);let d=-1,h;if(s!=null){if(typeof s=="number"){if(Number.isNaN(s))return;h=s}else typeof s=="boolean"?h=s:typeof s=="string"?o.spaceSeparated?h=ip(s):o.commaSeparated?h=sp(s):o.commaOrSpaceSeparated?h=ip(sp(s).join(" ")):h=up(o,o.property,s):Array.isArray(s)?h=s.concat():h=o.property==="style"?JS(s):String(s);if(Array.isArray(h)){const m=[];for(;++d<h.length;)m[d]=up(o,o.property,h[d]);h=m}o.property==="className"&&Array.isArray(i.className)&&(h=i.className.concat(h)),i[o.property]=h}}function ho(l,i){let r=-1;if(i!=null)if(typeof i=="string"||typeof i=="number")l.push({type:"text",value:String(i)});else if(Array.isArray(i))for(;++r<i.length;)ho(l,i[r]);else if(typeof i=="object"&&"type"in i)i.type==="root"?ho(l,i.children):l.push(i);else throw new Error("Expected node, nodes, or string, got `"+i+"`")}function up(l,i,r){if(typeof r=="string"){if(l.number&&r&&!Number.isNaN(Number(r)))return Number(r);if((l.boolean||l.overloadedBoolean)&&(r===""||jr(r)===jr(i)))return!0}return r}function JS(l){const i=[];let r;for(r in l)iy.call(l,r)&&i.push([r,l[r]].join(": "));return i.join("; ")}const WS=VS(FS,"div"),PS=["AElig","AMP","Aacute","Acirc","Agrave","Aring","Atilde","Auml","COPY","Ccedil","ETH","Eacute","Ecirc","Egrave","Euml","GT","Iacute","Icirc","Igrave","Iuml","LT","Ntilde","Oacute","Ocirc","Ograve","Oslash","Otilde","Ouml","QUOT","REG","THORN","Uacute","Ucirc","Ugrave","Uuml","Yacute","aacute","acirc","acute","aelig","agrave","amp","aring","atilde","auml","brvbar","ccedil","cedil","cent","copy","curren","deg","divide","eacute","ecirc","egrave","eth","euml","frac12","frac14","frac34","gt","iacute","icirc","iexcl","igrave","iquest","iuml","laquo","lt","macr","micro","middot","nbsp","not","ntilde","oacute","ocirc","ograve","ordf","ordm","oslash","otilde","ouml","para","plusmn","pound","quot","raquo","reg","sect","shy","sup1","sup2","sup3","szlig","thorn","times","uacute","ucirc","ugrave","uml","uuml","yacute","yen","yuml"],cp={0:"�",128:"€",130:"‚",131:"ƒ",132:"„",133:"…",134:"†",135:"‡",136:"ˆ",137:"‰",138:"Š",139:"‹",140:"Œ",142:"Ž",145:"‘",146:"’",147:"“",148:"”",149:"•",150:"–",151:"—",152:"˜",153:"™",154:"š",155:"›",156:"œ",158:"ž",159:"Ÿ"};function sy(l){const i=typeof l=="string"?l.charCodeAt(0):l;return i>=48&&i<=57}function eE(l){const i=typeof l=="string"?l.charCodeAt(0):l;return i>=97&&i<=102||i>=65&&i<=70||i>=48&&i<=57}function tE(l){const i=typeof l=="string"?l.charCodeAt(0):l;return i>=97&&i<=122||i>=65&&i<=90}function op(l){return tE(l)||sy(l)}const fp=document.createElement("i");function dp(l){const i="&"+l+";";fp.innerHTML=i;const r=fp.textContent;return r.charCodeAt(r.length-1)===59&&l!=="semi"||r===i?!1:r}const nE=["","Named character references must be terminated by a semicolon","Numeric character references must be terminated by a semicolon","Named character references cannot be empty","Numeric character references cannot be empty","Named character references must be known","Numeric character references cannot be disallowed","Numeric character references cannot be outside the permissible Unicode range"];function aE(l,i){const r={},s=typeof r.additional=="string"?r.additional.charCodeAt(0):r.additional,o=[];let d=0,h=-1,m="",g,y;r.position&&("start"in r.position||"indent"in r.position?(y=r.position.indent,g=r.position.start):g=r.position);let b=(g?g.line:0)||1,x=(g?g.column:0)||1,S=A(),E;for(d--;++d<=l.length;)if(E===10&&(x=(y?y[h]:0)||1),E=l.charCodeAt(d),E===38){const B=l.charCodeAt(d+1);if(B===9||B===10||B===12||B===32||B===38||B===60||Number.isNaN(B)||s&&B===s){m+=String.fromCharCode(E),x++;continue}const q=d+1;let R=q,Z=q,Y;if(B===35){Z=++R;const te=l.charCodeAt(Z);te===88||te===120?(Y="hexadecimal",Z=++R):Y="decimal"}else Y="named";let F="",H="",j="";const ae=Y==="named"?op:Y==="decimal"?sy:eE;for(Z--;++Z<=l.length;){const te=l.charCodeAt(Z);if(!ae(te))break;j+=String.fromCharCode(te),Y==="named"&&PS.includes(j)&&(F=j,H=dp(j))}let ee=l.charCodeAt(Z)===59;if(ee){Z++;const te=Y==="named"?dp(j):!1;te&&(F=j,H=te)}let re=1+Z-q,ce="";if(!(!ee&&r.nonTerminated===!1))if(!j)Y!=="named"&&C(4,re);else if(Y==="named"){if(ee&&!H)C(5,1);else if(F!==j&&(Z=R+F.length,re=1+Z-R,ee=!1),!ee){const te=F?1:3;if(r.attribute){const J=l.charCodeAt(Z);J===61?(C(te,re),H=""):op(J)?H="":C(te,re)}else C(te,re)}ce=H}else{ee||C(2,re);let te=Number.parseInt(j,Y==="hexadecimal"?16:10);if(lE(te))C(7,re),ce="�";else if(te in cp)C(6,re),ce=cp[te];else{let J="";rE(te)&&C(6,re),te>65535&&(te-=65536,J+=String.fromCharCode(te>>>10|55296),te=56320|te&1023),ce=J+String.fromCharCode(te)}}if(ce){_(),S=A(),d=Z-1,x+=Z-q+1,o.push(ce);const te=A();te.offset++,r.reference&&r.reference.call(r.referenceContext||void 0,ce,{start:S,end:te},l.slice(q-1,Z)),S=te}else j=l.slice(q-1,Z),m+=j,x+=j.length,d=Z-1}else E===10&&(b++,h++,x=0),Number.isNaN(E)?_():(m+=String.fromCharCode(E),x++);return o.join("");function A(){return{line:b,column:x,offset:d+((g?g.offset:0)||0)}}function C(B,q){let R;r.warning&&(R=A(),R.column+=q,R.offset+=q,r.warning.call(r.warningContext||void 0,nE[B],R,B))}function _(){m&&(o.push(m),r.text&&r.text.call(r.textContext||void 0,m,{start:S,end:A()}),m="")}}function lE(l){return l>=55296&&l<=57343||l>1114111}function rE(l){return l>=1&&l<=8||l===11||l>=13&&l<=31||l>=127&&l<=159||l>=64976&&l<=65007||(l&65535)===65535||(l&65535)===65534}var iE=0,is={},at={util:{type:function(l){return Object.prototype.toString.call(l).slice(8,-1)},objId:function(l){return l.__id||Object.defineProperty(l,"__id",{value:++iE}),l.__id},clone:function l(i,r){r=r||{};var s,o;switch(at.util.type(i)){case"Object":if(o=at.util.objId(i),r[o])return r[o];s={},r[o]=s;for(var d in i)i.hasOwnProperty(d)&&(s[d]=l(i[d],r));return s;case"Array":return o=at.util.objId(i),r[o]?r[o]:(s=[],r[o]=s,i.forEach(function(h,m){s[m]=l(h,r)}),s);default:return i}}},languages:{plain:is,plaintext:is,text:is,txt:is,extend:function(l,i){var r=at.util.clone(at.languages[l]);for(var s in i)r[s]=i[s];return r},insertBefore:function(l,i,r,s){s=s||at.languages;var o=s[l],d={};for(var h in o)if(o.hasOwnProperty(h)){if(h==i)for(var m in r)r.hasOwnProperty(m)&&(d[m]=r[m]);r.hasOwnProperty(h)||(d[h]=o[h])}var g=s[l];return s[l]=d,at.languages.DFS(at.languages,function(y,b){b===g&&y!=l&&(this[y]=d)}),d},DFS:function l(i,r,s,o){o=o||{};var d=at.util.objId;for(var h in i)if(i.hasOwnProperty(h)){r.call(i,h,i[h],s||h);var m=i[h],g=at.util.type(m);g==="Object"&&!o[d(m)]?(o[d(m)]=!0,l(m,r,null,o)):g==="Array"&&!o[d(m)]&&(o[d(m)]=!0,l(m,r,h,o))}}},plugins:{},highlight:function(l,i,r){var s={code:l,grammar:i,language:r};if(at.hooks.run("before-tokenize",s),!s.grammar)throw new Error('The language "'+s.language+'" has no grammar.');return s.tokens=at.tokenize(s.code,s.grammar),at.hooks.run("after-tokenize",s),Ar.stringify(at.util.encode(s.tokens),s.language)},tokenize:function(l,i){var r=i.rest;if(r){for(var s in r)i[s]=r[s];delete i.rest}var o=new sE;return cs(o,o.head,l),uy(l,o,i,o.head,0),cE(o)},hooks:{all:{},add:function(l,i){var r=at.hooks.all;r[l]=r[l]||[],r[l].push(i)},run:function(l,i){var r=at.hooks.all[l];if(!(!r||!r.length))for(var s=0,o;o=r[s++];)o(i)}},Token:Ar};function Ar(l,i,r,s){this.type=l,this.content=i,this.alias=r,this.length=(s||"").length|0}function hp(l,i,r,s){l.lastIndex=i;var o=l.exec(r);if(o&&s&&o[1]){var d=o[1].length;o.index+=d,o[0]=o[0].slice(d)}return o}function uy(l,i,r,s,o,d){for(var h in r)if(!(!r.hasOwnProperty(h)||!r[h])){var m=r[h];m=Array.isArray(m)?m:[m];for(var g=0;g<m.length;++g){if(d&&d.cause==h+","+g)return;var y=m[g],b=y.inside,x=!!y.lookbehind,S=!!y.greedy,E=y.alias;if(S&&!y.pattern.global){var A=y.pattern.toString().match(/[imsuy]*$/)[0];y.pattern=RegExp(y.pattern.source,A+"g")}for(var C=y.pattern||y,_=s.next,B=o;_!==i.tail&&!(d&&B>=d.reach);B+=_.value.length,_=_.next){var q=_.value;if(i.length>l.length)return;if(!(q instanceof Ar)){var R=1,Z;if(S){if(Z=hp(C,B,l,x),!Z||Z.index>=l.length)break;var j=Z.index,Y=Z.index+Z[0].length,F=B;for(F+=_.value.length;j>=F;)_=_.next,F+=_.value.length;if(F-=_.value.length,B=F,_.value instanceof Ar)continue;for(var H=_;H!==i.tail&&(F<Y||typeof H.value=="string");H=H.next)R++,F+=H.value.length;R--,q=l.slice(B,F),Z.index-=B}else if(Z=hp(C,0,q,x),!Z)continue;var j=Z.index,ae=Z[0],ee=q.slice(0,j),re=q.slice(j+ae.length),ce=B+q.length;d&&ce>d.reach&&(d.reach=ce);var te=_.prev;ee&&(te=cs(i,te,ee),B+=ee.length),uE(i,te,R);var J=new Ar(h,b?at.tokenize(ae,b):ae,E,ae);if(_=cs(i,te,J),re&&cs(i,_,re),R>1){var Q={cause:h+","+g,reach:ce};uy(l,i,r,_.prev,B,Q),d&&Q.reach>d.reach&&(d.reach=Q.reach)}}}}}}function sE(){var l={value:null,prev:null,next:null},i={value:null,prev:l,next:null};l.next=i,this.head=l,this.tail=i,this.length=0}function cs(l,i,r){var s=i.next,o={value:r,prev:i,next:s};return i.next=o,s.prev=o,l.length++,o}function uE(l,i,r){for(var s=i.next,o=0;o<r&&s!==l.tail;o++)s=s.next;i.next=s,s.prev=i,l.length-=o}function cE(l){for(var i=[],r=l.head.next;r!==l.tail;)i.push(r.value),r=r.next;return i}const cy=at,_l={}.hasOwnProperty;function oy(){}oy.prototype=cy;const de=new oy;de.highlight=oE;de.register=fE;de.alias=dE;de.registered=hE;de.listLanguages=gE;de.util.encode=mE;de.Token.stringify=go;function oE(l,i){if(typeof l!="string")throw new TypeError("Expected `string` for `value`, got `"+l+"`");let r,s;if(i&&typeof i=="object")r=i;else{if(s=i,typeof s!="string")throw new TypeError("Expected `string` for `name`, got `"+s+"`");if(_l.call(de.languages,s))r=de.languages[s];else throw new Error("Unknown language: `"+s+"` is not registered")}return{type:"root",children:cy.highlight.call(de,l,r,s)}}function fE(l){if(typeof l!="function"||!l.displayName)throw new Error("Expected `function` for `syntax`, got `"+l+"`");_l.call(de.languages,l.displayName)||l(de)}function dE(l,i){const r=de.languages;let s={};typeof l=="string"?i&&(s[l]=i):s=l;let o;for(o in s)if(_l.call(s,o)){const d=s[o],h=typeof d=="string"?[d]:d;let m=-1;for(;++m<h.length;)r[h[m]]=r[o]}}function hE(l){if(typeof l!="string")throw new TypeError("Expected `string` for `aliasOrLanguage`, got `"+l+"`");return _l.call(de.languages,l)}function gE(){const l=de.languages,i=[];let r;for(r in l)_l.call(l,r)&&typeof l[r]=="object"&&i.push(r);return i}function go(l,i){if(typeof l=="string")return{type:"text",value:l};if(Array.isArray(l)){const s=[];let o=-1;for(;++o<l.length;)l[o]!==null&&l[o]!==void 0&&l[o]!==""&&s.push(go(l[o],i));return s}const r={attributes:{},classes:["token",l.type],content:go(l.content,i),language:i,tag:"span",type:l.type};return l.alias&&r.classes.push(...typeof l.alias=="string"?[l.alias]:l.alias),de.hooks.run("wrap",r),WS(r.tag+"."+r.classes.join("."),pE(r.attributes),r.content)}function mE(l){return l}function pE(l){let i;for(i in l)_l.call(l,i)&&(l[i]=aE(l[i]));return l}de.register(sn);de.register(Mr);de.register(ws);de.register(Uo);de.register(Bo);de.register(Ho);de.register(Dr);de.register(Tl);de.register(Go);de.register(Yo);de.register(qo);de.register(Io);de.register(Xo);de.register(As);de.register(Fo);de.register(Zo);de.register($o);de.register(Vo);de.register(Ko);de.register(Qo);de.register(Jo);de.register(Wo);de.register(Po);de.register(Ts);de.register(ef);de.register(tf);de.register(nf);de.register(af);de.register(lf);de.register(rf);de.register(sf);de.register(uf);de.register(cf);de.register(of);de.register(Cs);de.register(ff);const yE=[{value:"suggestion",label:"Suggestion"},{value:"must_fix",label:"Must Fix"},{value:"question",label:"Question"},{value:"nitpick",label:"Nitpick"}];function ds({onSave:l,onAsk:i,onCancel:r,initialBody:s="",initialType:o="suggestion",file:d,line:h}){const[m,g]=L.useState(s),[y,b]=L.useState(o),[x,S]=L.useState(!1),[E,A]=L.useState(null),C=L.useRef(null),_=lt(Y=>Y.setDraftComment);L.useEffect(()=>{var Y;(Y=C.current)==null||Y.focus()},[]),L.useEffect(()=>{d!==void 0&&h!==void 0&&(m.trim()?_({body:m,type:y,file:d,line:h}):_(null))},[m,y,d,h,_]);function B(){m.trim()&&(_(null),l(m.trim(),y))}async function q(){if(!i||!m.trim())return;S(!0),A(null);const Y=await i(m.trim());S(!1),Y.ok?(_(null),r()):A(Y.error??"Could not ask the agent")}function R(){_(null),r()}function Z(Y){(Y.metaKey||Y.ctrlKey)&&Y.key==="Enter"?(Y.preventDefault(),B()):Y.key==="Escape"&&(Y.preventDefault(),R())}return f.jsxs("div",{className:"p-3 space-y-2",onKeyDown:Z,children:[f.jsx("textarea",{ref:C,value:m,onChange:Y=>g(Y.target.value),placeholder:"Write a comment...",rows:3,className:"w-full bg-background border border-border rounded px-3 py-2 text-text-primary text-sm placeholder:text-text-secondary/50 resize-none focus:outline-none focus:ring-1 focus:ring-accent focus:border-accent"}),E&&f.jsx("p",{role:"alert",className:"text-xs text-danger",children:E}),f.jsxs("div",{className:"flex items-center gap-2",children:[f.jsx("select",{value:y,onChange:Y=>b(Y.target.value),className:"bg-background border border-border rounded px-2 py-1.5 text-text-primary text-xs focus:outline-none focus:ring-1 focus:ring-accent cursor-pointer",children:yE.map(Y=>f.jsx("option",{value:Y.value,children:Y.label},Y.value))}),f.jsx("div",{className:"flex-1"}),f.jsx("button",{onClick:R,className:"px-3 py-1.5 text-xs text-text-secondary hover:text-text-primary transition-colors cursor-pointer",children:"Cancel"}),i&&f.jsx("button",{onClick:q,disabled:!m.trim()||x,title:"Start a thread the agent answers while you review, instead of a comment sent with your decision",className:"px-3 py-1.5 text-xs font-medium rounded text-text-secondary border border-border hover:text-text-primary hover:border-accent/40 disabled:opacity-40 disabled:cursor-not-allowed transition-colors cursor-pointer",children:x?"Asking…":"Ask agent now"}),f.jsx("button",{onClick:B,disabled:!m.trim(),className:"px-3 py-1.5 text-xs font-medium rounded bg-accent/20 text-accent border border-accent/30 hover:bg-accent/30 disabled:opacity-40 disabled:cursor-not-allowed transition-colors cursor-pointer",children:"Save"})]})]})}const bE={must_fix:"Must Fix",suggestion:"Suggestion",question:"Question",nitpick:"Nitpick"};function vE({comments:l,isFormOpen:i,file:r,line:s,onAdd:o,onAsk:d,onUpdate:h,onDelete:m,onOpenForm:g,onCloseForm:y}){const[b,x]=L.useState(null);return f.jsxs("div",{className:"border-t border-border bg-surface",children:[l.map(({comment:S,index:E})=>b===E?f.jsx(ds,{initialBody:S.body,initialType:S.type,file:r,line:s,onSave:(A,C)=>{h(E,A,C),x(null)},onCancel:()=>x(null)},E):f.jsxs("div",{className:"px-3 py-2 border-b border-border/50 group/comment",children:[f.jsxs("div",{className:"flex items-center gap-2 mb-1",children:[f.jsx("span",{className:`text-[10px] font-bold px-1.5 py-0.5 rounded border ${kv[S.type]}`,children:bE[S.type]}),f.jsxs("span",{className:"text-text-secondary text-[10px] font-mono",children:[r,":",s]}),f.jsx("div",{className:"flex-1"}),f.jsx("button",{onClick:()=>x(E),className:"opacity-0 group-hover/comment:opacity-100 p-0.5 text-text-secondary hover:text-text-primary transition-all cursor-pointer",title:"Edit comment",children:f.jsx(xv,{className:"w-3 h-3"})}),f.jsx("button",{onClick:()=>m(E),className:"opacity-0 group-hover/comment:opacity-100 p-0.5 text-text-secondary hover:text-danger transition-all cursor-pointer",title:"Delete comment",children:f.jsx(Cv,{className:"w-3 h-3"})})]}),f.jsx("p",{className:"text-text-primary text-sm whitespace-pre-wrap",children:S.body})]},E)),i&&b===null&&f.jsx(ds,{file:r,line:s,onSave:(S,E)=>{o(S,E),y()},onAsk:d,onCancel:y}),!i&&l.length>0&&b===null&&f.jsxs("button",{onClick:g,className:"flex items-center gap-1 px-3 py-1.5 text-xs text-text-secondary hover:text-accent transition-colors cursor-pointer",children:[f.jsx(xp,{className:"w-3 h-3"}),"Add comment"]})]})}function xE(l){const i=l.replies??[];return i.length>0?i[i.length-1].author:l.author??"agent"}function fy(l){return!l.dismissed&&xE(l)==="reviewer"}function mo({placeholder:l,submitLabel:i,onSubmit:r,onCancel:s}){const[o,d]=L.useState(""),[h,m]=L.useState(!1),[g,y]=L.useState(null),b=L.useRef(null);L.useEffect(()=>{var S;(S=b.current)==null||S.focus()},[]);async function x(){if(!o.trim()||h)return;m(!0),y(null);const S=await r(o.trim());m(!1),S.ok?d(""):y(S.error??"Couldn't send")}return f.jsxs("div",{className:"px-3 py-2 space-y-1.5",children:[f.jsx("textarea",{ref:b,value:o,onChange:S=>d(S.target.value),onKeyDown:S=>{S.key==="Enter"&&(S.metaKey||S.ctrlKey)?(S.preventDefault(),x()):S.key==="Escape"&&s&&(S.preventDefault(),s())},placeholder:l,rows:2,className:"w-full bg-background border border-border rounded px-2 py-1.5 text-text-primary text-sm focus:outline-none focus:border-accent resize-y"}),g&&f.jsx("p",{className:"text-danger text-xs",children:g}),f.jsxs("div",{className:"flex items-center justify-end gap-2",children:[s&&f.jsx("button",{onClick:s,className:"px-2 py-1 text-xs text-text-secondary hover:text-text-primary transition-colors cursor-pointer",children:"Cancel"}),f.jsx("button",{onClick:()=>void x(),disabled:!o.trim()||h,className:"px-2.5 py-1 text-xs rounded bg-accent/15 text-accent hover:bg-accent/25 disabled:opacity-40 disabled:cursor-not-allowed transition-colors cursor-pointer",children:h?"Sending…":i})]})]})}const SE={finding:wa,suggestion:No,question:xo,warning:El};function dy({author:l,agent:i}){return l==="reviewer"?f.jsxs("span",{className:"inline-flex items-center gap-1 text-[10px] font-semibold text-accent",children:[f.jsx(_v,{className:"w-3 h-3"}),"You"]}):f.jsxs("span",{className:"inline-flex items-center gap-1 text-[10px] text-text-secondary",children:[f.jsx(bo,{className:"w-3 h-3"}),i??"agent"]})}function EE({reply:l}){return f.jsxs("div",{className:"pl-3 ml-1.5 border-l border-border/70 py-1",children:[f.jsx(dy,{author:l.author,agent:l.agent}),f.jsx("p",{className:"text-text-primary text-sm whitespace-pre-wrap mt-0.5",children:l.body})]})}function NE({annotations:l,onDismiss:i,onReply:r}){const[s,o]=L.useState(null);if(l.length===0)return null;const d=l.some(h=>{var m;return(h.author??"agent")==="reviewer"||(((m=h.replies)==null?void 0:m.length)??0)>0});return f.jsxs("div",{className:"border-t border-border bg-surface",children:[f.jsxs("div",{className:"px-3 py-1.5 flex items-center gap-1.5 border-b border-border/50",children:[d?f.jsx(Sl,{className:"w-3 h-3 text-text-secondary"}):f.jsx(bo,{className:"w-3 h-3 text-text-secondary"}),f.jsx("span",{className:"text-[10px] font-semibold text-text-secondary uppercase tracking-wide",children:d?`Discussion${l.length>1?` (${l.length})`:""}`:`Agent ${l.length===1?"Annotation":`Annotations (${l.length})`}`})]}),l.map(h=>{const m=h.author??"agent",g=SE[h.type]??wa,y=os[h.category]??os.other,b=Rm[h.category]??Rm.other,x=h.replies??[];return f.jsxs("div",{className:"px-3 py-2 border-b border-border/50 group/annotation",children:[f.jsxs("div",{className:"flex items-center gap-2 mb-1",children:[m==="agent"?f.jsxs(f.Fragment,{children:[f.jsx(g,{className:`w-3.5 h-3.5 flex-shrink-0 ${y}`}),f.jsx("span",{className:`text-[10px] font-bold px-1.5 py-0.5 rounded border ${b}`,children:h.category}),f.jsx("span",{className:"text-text-secondary text-[10px]",children:h.source.agent})]}):f.jsx(dy,{author:"reviewer"}),f.jsx("div",{className:"flex-1"}),f.jsx("button",{onClick:()=>i(h.id),className:"opacity-0 group-hover/annotation:opacity-100 p-0.5 rounded hover:bg-text-primary/10 text-text-secondary transition-all cursor-pointer flex-shrink-0",title:"Dismiss",children:f.jsx(kr,{className:"w-3 h-3"})})]}),f.jsx("p",{className:"text-text-primary text-sm whitespace-pre-wrap",children:h.body}),x.length>0&&f.jsx("div",{className:"mt-1.5 space-y-0.5",children:x.map(S=>f.jsx(EE,{reply:S},S.id))}),fy(h)&&f.jsx("p",{className:"mt-1.5 text-[11px] text-text-secondary italic",children:"Waiting for the agent to reply."}),r&&(s===h.id?f.jsx("div",{className:"-mx-3",children:f.jsx(mo,{placeholder:"Reply…",submitLabel:"Reply",onSubmit:async S=>{const E=await r(h.id,S);return E.ok&&o(null),E},onCancel:()=>o(null)})}):f.jsx("button",{onClick:()=>o(h.id),className:"mt-1 text-[11px] text-text-secondary hover:text-accent transition-colors cursor-pointer",children:"Reply"}))]},h.id)})]})}function wE(){const{theme:l,toggleTheme:i}=lt();return f.jsx("button",{onClick:i,className:"p-1.5 rounded text-text-secondary hover:text-text-primary transition-colors cursor-pointer",title:`Switch to ${l==="dark"?"light":"dark"} mode`,children:l==="dark"?f.jsx(Av,{className:"w-4 h-4"}):f.jsx(vv,{className:"w-4 h-4"})})}const gp={highlight(l,i){return de.highlight(l,i).children},registered(l){return de.registered(l)}};function AE(l){return{typescript:"typescript",ts:"typescript",tsx:"tsx",javascript:"javascript",js:"javascript",jsx:"jsx",json:"json",css:"css",html:"markup",xml:"markup",markdown:"markdown",md:"markdown",python:"python",py:"python",rust:"rust",rs:"rust",go:"go",java:"java",c:"c",cpp:"cpp","c++":"cpp",csharp:"csharp","c#":"csharp",ruby:"ruby",rb:"ruby",php:"php",shell:"bash",bash:"bash",sh:"bash",yaml:"yaml",yml:"yaml",toml:"toml",sql:"sql",graphql:"graphql",scss:"scss",sass:"sass",less:"less",swift:"swift",kotlin:"kotlin",scala:"scala",lua:"lua",r:"r",perl:"perl",diff:"diff"}[l.toLowerCase()]??null}function po(l){return Aa(l)||$t(l)?l.lineNumber:Na(l)?l.newLineNumber:0}function TE(l){return $t(l)?"old":"new"}function CE(l,i){const r={};for(const s of l)for(const o of s.changes){const d=po(o),h=`${i}:${d}`;r[h]||(r[h]=Lt(o))}return r}function _E(l,i,r=0){const s=/^diff --git /gm,o=[];let d;for(;(d=s.exec(l))!==null;)o.push(d.index);let h=0;for(let m=0;m<o.length;m++){const g=o[m],y=m+1<o.length?o[m+1]:l.length,b=l.slice(g,y);if(b.includes(`a/${i}`)||b.includes(`b/${i}`)){if(h===r)return b;h++}}return null}function OE(){const{diffSet:l,rawDiff:i,selectedFile:r,viewMode:s,setViewMode:o,comments:d,activeCommentKey:h,addComment:m,updateComment:g,deleteComment:y,setActiveCommentKey:b,toggleHotkeyGuide:x,toggleWorkflowTips:S,focusedHunkIndex:E,setHunkCount:A,annotations:C,dismissAnnotation:_,metadata:B,reviewId:q}=lt(),R=!!(B!=null&&B.githubPr),{isAvailable:Z,startThread:Y,replyToThread:F}=wo(),H=Z&&!!q,j=L.useMemo(()=>!l||!r?null:l.files.find(K=>Dt(K)===r)??null,[l,r]),ae=L.useMemo(()=>{if(!i||!r||!l)return null;const K=hl(r);let ne=0;for(const se of l.files){if(Dt(se)===r)break;se.path===K&&ne++}return _E(i,K,ne)},[i,r,l]),ee=L.useMemo(()=>{if(!ae)return[];try{return e1(ae)}catch{return[]}},[ae]),re=L.useMemo(()=>{if(ee.length===0||!j)return;const K=AE(j.language);if(K){try{if(!gp.registered(K))return}catch{return}try{const ne={refractor:gp,highlight:!0,language:K};return zS(ee[0].hunks,ne)}catch{return}}},[ee,j,s]),ce=L.useMemo(()=>ee.length===0||!r?{}:CE(ee[0].hunks,r),[ee,r]),te=L.useMemo(()=>{if(ee.length===0)return{};const K={};for(const ne of ee[0].hunks)for(const se of ne.changes)K[Lt(se)]=po(se);return K},[ee]),J=L.useMemo(()=>{const K={};if(ee.length===0)return K;for(const ne of ee[0].hunks)for(const se of ne.changes)K[Lt(se)]=TE(se);return K},[ee]),Q=L.useMemo(()=>r?d.map((K,ne)=>({comment:K,index:ne})).filter(K=>K.comment.file===r):[],[d,r]),M=L.useMemo(()=>{if(!r)return[];const K=hl(r);return C.filter(ne=>ne.file===K&&!ne.dismissed)},[C,r]),O=L.useMemo(()=>{const K=new Map;for(const ne of M)K.has(ne.line)||K.set(ne.line,[]),K.get(ne.line).push(ne);return K},[M]),le=L.useMemo(()=>R&&!H?{}:{onClick({change:K}){if(!K)return;const ne=Lt(K);b(h===ne?null:ne)}},[h,b,R,H]),ye=L.useCallback(({change:K,inHoverState:ne,renderDefault:se})=>{const Ee=po(K),me=!R&&r&&Q.some(Be=>Be.comment.line===Ee),pe=O.has(Ee);return ne&&(!R||H)?f.jsxs(f.Fragment,{children:[f.jsx("span",{className:"diff-gutter-add-comment",children:"+"}),se()]}):me?f.jsxs(f.Fragment,{children:[f.jsx("span",{className:"diff-comment-indicator"}),se()]}):pe?f.jsxs(f.Fragment,{children:[f.jsx("span",{className:"diff-annotation-indicator"}),se()]}):se()},[r,Q,O,R,H]),oe=L.useMemo(()=>{if(!r)return{};const K={},ne=new Map;if(!R)for(const me of Q){const pe=me.comment.line;ne.has(pe)||ne.set(pe,[]),ne.get(pe).push(me)}const se=(me,pe)=>!R&&H?Be=>Y(q,{file:hl(r),line:me,side:J[pe],body:Be}):void 0,Ee=new Set([...ne.keys(),...O.keys()]);for(const me of Ee){const pe=ce[`${r}:${me}`];if(!pe)continue;const Be=ne.get(me),Qt=O.get(me);K[pe]=f.jsxs(f.Fragment,{children:[Qt&&Qt.length>0&&f.jsx(NE,{annotations:Qt,onDismiss:_,onReply:H?(et,ft)=>F(q,et,ft):void 0}),R&&H&&h===pe&&f.jsx("div",{className:"border-t border-border bg-surface",children:f.jsx(mo,{placeholder:"Start another conversation on this line…",submitLabel:"Comment",onSubmit:async et=>{const ft=await Y(q,{file:hl(r),line:me,side:J[pe],body:et});return ft.ok&&b(null),ft},onCancel:()=>b(null)})}),!R&&Be&&Be.length>0&&f.jsx(vE,{comments:Be,isFormOpen:h===pe,file:r,line:me,onAdd:(et,ft)=>{m({file:r,line:me,body:et,type:ft})},onAsk:se(me,pe),onUpdate:(et,ft,Et)=>{g(et,{file:r,line:me,body:ft,type:Et})},onDelete:y,onOpenForm:()=>b(pe),onCloseForm:()=>b(null)}),!R&&!(Be!=null&&Be.length)&&h===pe&&f.jsx("div",{className:"border-t border-border bg-surface",children:f.jsx(ds,{file:r,line:me,onSave:(et,ft)=>{m({file:r,line:me,body:et,type:ft}),b(null)},onAsk:se(me,pe),onCancel:()=>b(null)})})]})}if(R&&H&&h&&!K[h]){const me=te[h];me!==void 0&&(K[h]=f.jsx("div",{className:"border-t border-border bg-surface",children:f.jsx(mo,{placeholder:"Ask the agent about this line…",submitLabel:"Comment",onSubmit:async pe=>{const Be=await Y(q,{file:hl(r),line:me,side:J[h],body:pe});return Be.ok&&b(null),Be},onCancel:()=>b(null)})}))}if(!R&&h&&!K[h]){const me=te[h];me!==void 0&&(K[h]=f.jsx("div",{className:"border-t border-border bg-surface",children:f.jsx(ds,{file:r,line:me,onSave:(pe,Be)=>{m({file:r,line:me,body:pe,type:Be}),b(null)},onAsk:se(me,h),onCancel:()=>b(null)})}))}return K},[r,Q,M,O,h,ce,te,J,m,g,y,_,b,R,H,q,Y,F]),w=L.useRef(null);if(L.useEffect(()=>{var K;A(((K=ee[0])==null?void 0:K.hunks.length)??0)},[ee,A]),L.useEffect(()=>{const K=w.current;if(!K||E===null)return;const ne=K.querySelectorAll("tbody.diff-hunk");ne.forEach(se=>se.classList.remove("diff-hunk-focused")),ne[E]&&(ne[E].scrollIntoView({behavior:"smooth",block:"center"}),ne[E].classList.add("diff-hunk-focused"))},[E]),L.useEffect(()=>{function K(){if(E===null||ee.length===0||!r)return;const ne=ee[0].hunks[E];if(!ne||ne.changes.length===0)return;const se=ne.changes[0],Ee=Lt(se);b(Ee)}return document.addEventListener("diffprism:open-comment",K),()=>document.removeEventListener("diffprism:open-comment",K)},[E,ee,r,b]),!r||!l)return f.jsx("div",{className:"flex-1 flex items-center justify-center bg-background",children:f.jsxs("div",{className:"text-center",children:[f.jsx(wl,{className:"w-12 h-12 text-text-secondary/40 mx-auto mb-3"}),f.jsx("p",{className:"text-text-secondary text-sm",children:"Select a file to view changes"})]})});const I=hl(r);if(j!=null&&j.binary)return f.jsxs("div",{className:"flex-1 flex flex-col bg-background",children:[f.jsx(to,{path:I,stage:j==null?void 0:j.stage}),f.jsx("div",{className:"flex-1 flex items-center justify-center",children:f.jsx("div",{className:"text-center",children:f.jsx("p",{className:"text-text-secondary text-sm",children:"Binary file — cannot display diff"})})})]});if(ee.length===0)return f.jsxs("div",{className:"flex-1 flex flex-col bg-background",children:[f.jsx(to,{path:I,stage:j==null?void 0:j.stage}),f.jsx("div",{className:"flex-1 flex items-center justify-center",children:f.jsx("div",{className:"text-center",children:f.jsx("p",{className:"text-text-secondary text-sm",children:"No diff content available for this file"})})})]});const P=ee[0];return f.jsxs("div",{className:"flex-1 flex flex-col bg-background min-h-0",children:[f.jsx(to,{path:I,stage:j==null?void 0:j.stage,additions:j==null?void 0:j.additions,deletions:j==null?void 0:j.deletions,viewMode:s,onViewModeChange:o,onToggleHotkeyGuide:x,onToggleWorkflowTips:S}),f.jsx("div",{ref:w,className:"flex-1 overflow-auto",children:f.jsx(dS,{viewType:s,diffType:P.type,hunks:P.hunks,tokens:re,widgets:oe,gutterEvents:le,renderGutter:ye,children:K=>K.map(ne=>f.jsx(Vp,{hunk:ne},ne.content))})})]})}function to({path:l,stage:i,additions:r,deletions:s,viewMode:o,onViewModeChange:d,onToggleHotkeyGuide:h,onToggleWorkflowTips:m}){return f.jsxs("div",{className:"flex items-center gap-3 px-4 py-2.5 bg-surface border-b border-border flex-shrink-0",children:[f.jsx(wl,{className:"w-4 h-4 text-text-secondary flex-shrink-0"}),f.jsx("span",{className:"text-text-primary text-sm font-mono truncate",children:l}),i&&f.jsx("span",{className:`text-[10px] font-semibold px-1.5 py-0.5 rounded border ${zv[i]}`,children:i==="staged"?"Staged":"Unstaged"}),f.jsxs("div",{className:"flex items-center gap-2 ml-auto flex-shrink-0",children:[r!==void 0&&r>0&&f.jsxs("span",{className:"text-success text-xs font-mono",children:["+",r]}),s!==void 0&&s>0&&f.jsxs("span",{className:"text-danger text-xs font-mono",children:["-",s]}),o&&d&&f.jsxs("div",{className:"flex items-center rounded border border-border ml-2",children:[f.jsx("button",{onClick:()=>d("unified"),className:`p-1 ${o==="unified"?"bg-text-primary/10 text-text-primary":"text-text-secondary hover:text-text-primary"}`,title:"Unified view",children:f.jsx(Nv,{className:"w-3.5 h-3.5"})}),f.jsx("button",{onClick:()=>d("split"),className:`p-1 ${o==="split"?"bg-text-primary/10 text-text-primary":"text-text-secondary hover:text-text-primary"}`,title:"Split view",children:f.jsx(dv,{className:"w-3.5 h-3.5"})})]}),m&&f.jsx("button",{onClick:m,className:"p-1.5 rounded text-text-secondary hover:text-text-primary transition-colors cursor-pointer",title:"Workflow tips",children:f.jsx(No,{className:"w-4 h-4"})}),h&&f.jsx("button",{onClick:h,className:"p-1.5 rounded text-text-secondary hover:text-text-primary transition-colors cursor-pointer",title:"Keyboard shortcuts (?)",children:f.jsx(xo,{className:"w-4 h-4"})}),f.jsx(wE,{})]})]})}function jE({onSubmit:l,onDismiss:i,isWatchMode:r,watchSubmitted:s,hasUnreviewedChanges:o}){const[d,h]=L.useState(""),[m,g]=L.useState(null),{diffSet:y,fileStatuses:b,comments:x,draftComment:S,saveDraftComment:E,setActiveCommentKey:A,setDraftComment:C}=lt(),_=(y==null?void 0:y.files.reduce((j,ae)=>j+ae.additions,0))??0,B=(y==null?void 0:y.files.reduce((j,ae)=>j+ae.deletions,0))??0,q=(y==null?void 0:y.files.length)??0,R=!!(S&&S.body.trim());function Z(j){const ae=Object.values(b).some(ee=>ee!=="unreviewed");l({decision:j,comments:lt.getState().comments,fileStatuses:ae?b:void 0,summary:d.trim()||void 0})}function Y(j){if(R){g(j);return}Z(j)}function F(){m&&(E(),Z(m),g(null))}function H(){m&&(C(null),A(null),Z(m),g(null))}return r&&s&&!o?f.jsx("div",{className:"bg-surface border-t border-border px-4 py-3 flex-shrink-0",children:f.jsxs("div",{className:"flex items-center gap-3",children:[f.jsx(Tr,{className:"w-4 h-4 text-success"}),f.jsx("span",{className:"text-sm text-success font-medium",children:"Review submitted"}),f.jsxs("span",{className:"relative flex h-2 w-2 ml-2",children:[f.jsx("span",{className:"animate-ping absolute inline-flex h-full w-full rounded-full bg-success opacity-75"}),f.jsx("span",{className:"relative inline-flex rounded-full h-2 w-2 bg-success"})]}),f.jsx("span",{className:"text-xs text-text-secondary",children:"Watching for changes..."})]})}):f.jsxs("div",{className:"bg-surface border-t border-border px-4 py-3 flex-shrink-0",children:[r&&s&&o&&f.jsxs("div",{className:"flex items-center gap-2 mb-3 text-xs text-accent",children:[f.jsxs("span",{className:"relative flex h-2 w-2",children:[f.jsx("span",{className:"animate-ping absolute inline-flex h-full w-full rounded-full bg-info opacity-75"}),f.jsx("span",{className:"relative inline-flex rounded-full h-2 w-2 bg-info"})]}),"New changes detected"]}),f.jsxs("div",{className:"flex items-center gap-4 mb-3",children:[f.jsxs("span",{className:"text-text-secondary text-xs",children:[q," file",q!==1?"s":""," changed"]}),_>0&&f.jsxs("span",{className:"text-success text-xs font-mono",children:["+",_]}),B>0&&f.jsxs("span",{className:"text-danger text-xs font-mono",children:["-",B]}),x.length>0&&f.jsxs("span",{className:"flex items-center gap-1 text-accent text-xs",children:[f.jsx(Sl,{className:"w-3 h-3"}),x.length," comment",x.length!==1?"s":""]})]}),f.jsx("textarea",{value:d,onChange:j=>h(j.target.value),placeholder:"Leave a summary comment (optional)...",rows:3,className:"w-full bg-background border border-border rounded-lg px-3 py-2 text-text-primary text-sm placeholder:text-text-secondary/50 resize-none focus:outline-none focus:ring-1 focus:ring-accent focus:border-accent mb-3"}),m&&f.jsxs("div",{className:"flex items-center gap-3 mb-3 px-3 py-2.5 rounded-lg bg-warning/10 border border-warning/30",children:[f.jsx(El,{className:"w-4 h-4 text-warning flex-shrink-0"}),f.jsx("span",{className:"text-sm text-text-primary",children:"You have an unsaved comment. Save it before submitting?"}),f.jsx("div",{className:"flex-1"}),f.jsx("button",{onClick:F,className:"px-3 py-1.5 text-xs font-medium rounded bg-accent/20 text-accent border border-accent/30 hover:bg-accent/30 transition-colors cursor-pointer",children:"Save & Submit"}),f.jsx("button",{onClick:H,className:"px-3 py-1.5 text-xs text-text-secondary hover:text-text-primary transition-colors cursor-pointer",children:"Discard & Submit"}),f.jsx("button",{onClick:()=>g(null),className:"px-3 py-1.5 text-xs text-text-secondary hover:text-text-primary transition-colors cursor-pointer",children:"Cancel"})]}),f.jsxs("div",{className:"flex items-center gap-3",children:[f.jsxs("button",{onClick:()=>Y("approved"),className:`flex items-center gap-2 px-4 py-2 rounded-lg text-sm font-medium transition-colors cursor-pointer ${ea.approve}`,children:[f.jsx(Tr,{className:"w-4 h-4"}),"Approve"]}),f.jsxs("button",{onClick:()=>Y("changes_requested"),className:`flex items-center gap-2 px-4 py-2 rounded-lg text-sm font-medium transition-colors cursor-pointer ${ea.reject}`,children:[f.jsx(kr,{className:"w-4 h-4"}),"Request Changes"]}),f.jsxs("button",{onClick:()=>Y("approved_with_comments"),className:`flex items-center gap-2 px-4 py-2 rounded-lg text-sm font-medium transition-colors cursor-pointer ${ea.comment}`,children:[f.jsx(Sl,{className:"w-4 h-4"}),"Approve with Comments"]}),i&&f.jsxs(f.Fragment,{children:[f.jsx("div",{className:"w-px h-6 bg-border"}),f.jsxs("button",{onClick:i,className:`flex items-center gap-2 px-4 py-2 rounded-lg text-sm font-medium transition-colors cursor-pointer ${ea.dismiss}`,children:[f.jsx(vp,{className:"w-4 h-4"}),"Dismiss"]})]})]})]})}function kE({onDismiss:l}){const{annotations:i,reviewId:r,metadata:s}=lt(),{submitPrReview:o}=wo(),[d,h]=L.useState(""),[m,g]=L.useState(new Set),[y,b]=L.useState(null),[x,S]=L.useState(null),[E,A]=L.useState(null),C=s==null?void 0:s.githubPr,_=i.filter(F=>F.author==="reviewer"&&!F.dismissed),B=!d.trim();async function q(F){if(!r)return;b(F),S(null);const H=await o(r,{event:F,summary:d.trim()||void 0,threadIds:_.filter(j=>m.has(j.id)).map(j=>j.id)});b(null),H.ok?A(H.url):S(H.error)}function R(F){g(H=>{const j=new Set(H);return j.has(F)?j.delete(F):j.add(F),j})}if(E)return f.jsxs("div",{className:"bg-surface border-t border-border px-4 py-3 flex-shrink-0 flex items-center gap-3",children:[f.jsx(Tr,{className:"w-4 h-4 text-success"}),f.jsx("span",{className:"text-sm text-success font-medium",children:"Review posted to GitHub"}),f.jsxs("a",{href:E,target:"_blank",rel:"noreferrer",className:"flex items-center gap-1 text-xs text-accent hover:underline",children:["View on GitHub",f.jsx(So,{className:"w-3 h-3"})]})]});const Z=y!==null,Y=(F,H,j,ae,ee)=>f.jsxs("button",{onClick:()=>q(F),disabled:Z||ee,className:`flex items-center gap-2 px-4 py-2 rounded-lg text-sm font-medium transition-colors cursor-pointer disabled:opacity-40 disabled:cursor-not-allowed ${j}`,children:[f.jsx(ae,{className:"w-4 h-4"}),y===F?"Posting…":H]});return f.jsxs("div",{className:"bg-surface border-t border-border px-4 py-3 flex-shrink-0",children:[f.jsxs("div",{className:"text-xs text-text-secondary mb-2",children:["Submit your review to GitHub",C?` · ${C.owner}/${C.repo}#${C.number}`:""]}),f.jsx("textarea",{value:d,onChange:F=>h(F.target.value),placeholder:"Summary — optional to approve, required to request changes or comment",rows:3,className:"w-full bg-background border border-border rounded-lg px-3 py-2 text-text-primary text-sm placeholder:text-text-secondary/50 resize-none focus:outline-none focus:ring-1 focus:ring-accent focus:border-accent mb-3"}),_.length>0&&f.jsxs("fieldset",{className:"mb-3",children:[f.jsx("legend",{className:"text-xs text-text-secondary mb-1",children:"Post your comments as inline review comments (your opening message only — agent replies stay here)"}),f.jsx("div",{className:"flex flex-col gap-1 max-h-28 overflow-y-auto",children:_.map(F=>f.jsxs("label",{className:"flex items-center gap-2 text-xs text-text-primary cursor-pointer select-none",children:[f.jsx("input",{type:"checkbox",checked:m.has(F.id),onChange:()=>R(F.id),className:"rounded border-border accent-accent"}),f.jsxs("span",{className:"font-mono text-text-secondary",children:[F.file,":",F.line]}),f.jsx("span",{className:"truncate",children:F.body})]},F.id))})]}),x&&f.jsxs("div",{role:"alert",className:"flex items-start gap-2 mb-3 px-3 py-2 rounded-lg bg-danger/10 border border-danger/30 text-sm text-text-primary whitespace-pre-line",children:[f.jsx(El,{className:"w-4 h-4 mt-0.5 text-danger flex-shrink-0"}),x]}),f.jsxs("div",{className:"flex items-center gap-3",children:[Y("APPROVE","Approve",ea.approve,Tr,!1),Y("REQUEST_CHANGES","Request changes",ea.reject,kr,B),Y("COMMENT","Comment",ea.comment,Sl,B),l&&f.jsxs(f.Fragment,{children:[f.jsx("div",{className:"w-px h-6 bg-border"}),f.jsxs("button",{onClick:l,disabled:Z,className:`flex items-center gap-2 px-4 py-2 rounded-lg text-sm font-medium transition-colors cursor-pointer disabled:opacity-40 ${ea.dismiss}`,children:[f.jsx(vp,{className:"w-4 h-4"}),"Close without posting"]})]})]})]})}const RE=navigator.platform.toUpperCase().includes("MAC"),ME=RE?"⌘":"Ctrl",DE=[{keys:["j","↓"],action:"Next file"},{keys:["k","↑"],action:"Previous file"},{keys:["s"],action:"Cycle file status"},{keys:["n"],action:"Next hunk"},{keys:["p"],action:"Previous hunk"},{keys:["c"],action:"Comment on hunk"},{keys:[`${ME} + Enter`],action:"Save comment"},{keys:["Esc"],action:"Cancel comment / Close guide"},{keys:["?"],action:"Toggle this guide"}];function zE(){const{showHotkeyGuide:l,toggleHotkeyGuide:i}=lt();return L.useEffect(()=>{if(!l)return;function r(s){(s.key==="Escape"||s.key==="?")&&(s.preventDefault(),s.stopPropagation(),i())}return document.addEventListener("keydown",r,!0),()=>document.removeEventListener("keydown",r,!0)},[l,i]),l?f.jsx("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/50",onClick:i,children:f.jsxs("div",{className:"bg-surface border border-border rounded-lg shadow-xl p-6 max-w-sm w-full mx-4",onClick:r=>r.stopPropagation(),children:[f.jsx("h2",{className:"text-text-primary text-sm font-semibold mb-4",children:"Keyboard Shortcuts"}),f.jsx("div",{className:"space-y-2",children:DE.map(r=>f.jsxs("div",{className:"flex items-center justify-between gap-4",children:[f.jsx("span",{className:"text-text-secondary text-sm",children:r.action}),f.jsx("div",{className:"flex items-center gap-1.5",children:r.keys.map((s,o)=>f.jsxs("span",{className:"flex items-center gap-1.5",children:[o>0&&f.jsx("span",{className:"text-text-secondary/50 text-xs",children:"/"}),f.jsx("kbd",{className:"px-1.5 py-0.5 text-xs font-mono rounded border border-border bg-background text-text-primary",children:s})]},s))})]},r.action))})]})}):null}const LE={navigation:"Navigation",review:"Review Workflow",commenting:"Commenting",general:"General"},UE=["navigation","review","commenting","general"],BE=[{id:"nav-files",text:"Navigate between files in the sidebar",shortcut:"j / k",category:"navigation"},{id:"nav-hunks",text:"Jump between changed hunks within a file",shortcut:"n / p",category:"navigation"},{id:"nav-select",text:"Click any file in the sidebar to view its diff",category:"navigation"},{id:"review-status",text:"Cycle a file's review status (unreviewed → reviewed → approved → needs changes)",shortcut:"s",category:"review"},{id:"review-split",text:"Toggle between unified and split (side-by-side) diff views from the toolbar",category:"review"},{id:"review-briefing",text:"Check the briefing bar at the top for a summary of changes, risk indicators, and file stats",category:"review"},{id:"comment-gutter",text:"Click a line's gutter (the + icon on hover) to add an inline comment",category:"commenting"},{id:"comment-hunk",text:"Quickly comment on the focused hunk",shortcut:"c",category:"commenting"},{id:"comment-save",text:"Save a comment from the inline form",shortcut:"Cmd/Ctrl + Enter",category:"commenting"},{id:"general-hotkeys",text:"Open the full keyboard shortcuts reference anytime",shortcut:"?",category:"general"},{id:"general-theme",text:"Toggle between dark and light mode from the toolbar",category:"general"}],mp="diffprism-tips-seen";function HE(){const{showWorkflowTips:l,toggleWorkflowTips:i}=lt();if(L.useEffect(()=>{localStorage.getItem(mp)||(localStorage.setItem(mp,"1"),i())},[]),L.useEffect(()=>{if(!l)return;function s(o){o.key==="Escape"&&(o.preventDefault(),o.stopPropagation(),i())}return document.addEventListener("keydown",s,!0),()=>document.removeEventListener("keydown",s,!0)},[l,i]),!l)return null;const r=new Map;for(const s of BE)r.has(s.category)||r.set(s.category,[]),r.get(s.category).push(s);return f.jsx("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/50",onClick:i,children:f.jsxs("div",{className:"bg-surface border border-border rounded-lg shadow-xl p-6 max-w-md w-full mx-4 max-h-[80vh] overflow-y-auto",onClick:s=>s.stopPropagation(),children:[f.jsx("h2",{className:"text-text-primary text-sm font-semibold mb-4",children:"Workflow Tips"}),f.jsx("div",{className:"space-y-4",children:UE.map(s=>{const o=r.get(s);return!o||o.length===0?null:f.jsxs("div",{children:[f.jsx("h3",{className:"text-text-secondary text-xs font-semibold uppercase tracking-wider mb-2",children:LE[s]}),f.jsx("div",{className:"space-y-1.5",children:o.map(d=>f.jsxs("div",{className:"flex items-start justify-between gap-3",children:[f.jsx("span",{className:"text-text-secondary text-sm leading-snug",children:d.text}),d.shortcut&&f.jsx("kbd",{className:"flex-shrink-0 px-1.5 py-0.5 text-xs font-mono rounded border border-border bg-background text-text-primary whitespace-nowrap",children:d.shortcut})]},d.id))})]},s)})}),f.jsxs("div",{className:"mt-5 flex items-center justify-between",children:[f.jsx("span",{className:"text-text-secondary/60 text-xs",children:"Reopen anytime from the toolbar"}),f.jsx("button",{onClick:i,className:"px-3 py-1.5 text-sm font-medium rounded bg-accent text-white hover:bg-accent/90 transition-colors cursor-pointer",children:"Got it"})]})]})})}const GE="Your comments",YE={finding:wa,suggestion:No,question:xo,warning:El};function qE({body:l}){const[i,r]=L.useState(!1),s=l.length>120||l.includes(`
345
345
  `),o=L.useCallback(d=>{d.stopPropagation(),r(h=>!h)},[]);return s?i?f.jsxs("div",{children:[f.jsx("p",{className:"text-xs text-text-primary whitespace-pre-wrap",children:l}),f.jsx("button",{onClick:o,className:"text-[10px] text-accent hover:underline mt-0.5 cursor-pointer",children:"Show less"})]}):f.jsxs("div",{children:[f.jsx("p",{className:"text-xs text-text-primary truncate",children:l}),f.jsx("button",{onClick:o,className:"text-[10px] text-accent hover:underline mt-0.5 cursor-pointer",children:"Show more"})]}):f.jsx("p",{className:"text-xs text-text-primary",children:l})}function IE({annotations:l,onDismiss:i,onNavigate:r}){const[s,o]=L.useState(!1),d=L.useMemo(()=>{const g=s?l:l.filter(b=>!b.dismissed),y=new Map;for(const b of g){const x=(b.author??"agent")==="reviewer"?GE:b.source.agent;y.has(x)||y.set(x,[]),y.get(x).push(b)}return y},[l,s]),h=l.filter(g=>!g.dismissed).length,m=l.some(g=>(g.author??"agent")==="reviewer");return l.length===0?null:f.jsxs("div",{className:"border-t border-border flex-shrink-0 max-h-[40%] overflow-hidden flex flex-col",children:[f.jsxs("div",{className:"px-4 py-2 flex items-center justify-between",children:[f.jsxs("div",{className:"flex items-center gap-2",children:[m?f.jsx(Sl,{className:"w-4 h-4 text-text-secondary"}):f.jsx(bo,{className:"w-4 h-4 text-text-secondary"}),f.jsxs("span",{className:"text-xs font-semibold text-text-secondary uppercase tracking-wide",children:[m?"Annotations & comments":"Agent Annotations"," (",h,")"]})]}),l.some(g=>g.dismissed)&&f.jsxs("button",{onClick:()=>o(!s),className:"flex items-center gap-1 text-xs text-text-secondary hover:text-text-primary cursor-pointer",children:[s?f.jsx(gv,{className:"w-3 h-3"}):f.jsx(Eo,{className:"w-3 h-3"}),s?"Hide dismissed":"Show dismissed"]})]}),f.jsx("div",{className:"flex-1 min-h-0 overflow-y-auto",children:Array.from(d.entries()).map(([g,y])=>f.jsxs("div",{className:"border-t border-border/50",children:[f.jsxs("div",{className:"px-4 py-1.5 flex items-center gap-2",children:[f.jsx("span",{className:"text-xs font-medium text-accent",children:g}),f.jsxs("span",{className:"text-xs text-text-secondary",children:["(",y.length,")"]})]}),y.map(b=>{var E;const x=YE[b.type]??wa,S=os[b.category]??os.other;return f.jsxs("div",{className:`px-4 py-2 flex items-start gap-2 hover:bg-text-primary/5 cursor-pointer group ${b.dismissed?"opacity-40":""}`,onClick:()=>r(b.file),children:[f.jsx(x,{className:`w-3.5 h-3.5 mt-0.5 flex-shrink-0 ${S}`}),f.jsxs("div",{className:"flex-1 min-w-0",children:[f.jsxs("div",{className:"flex items-center gap-2 mb-0.5",children:[f.jsxs("span",{className:"text-xs text-text-secondary font-mono truncate",children:[b.file,":",b.line]}),(b.author??"agent")==="agent"&&f.jsx("span",{className:`text-[10px] font-semibold uppercase ${S}`,children:b.category})]}),f.jsx(qE,{body:b.body}),fy(b)?f.jsx("p",{className:"text-[10px] text-text-secondary italic mt-0.5",children:"Waiting for an agent"}):(((E=b.replies)==null?void 0:E.length)??0)>0?f.jsxs("p",{className:"text-[10px] text-text-secondary mt-0.5",children:[b.replies.length," ",b.replies.length===1?"reply":"replies"]}):null]}),!b.dismissed&&f.jsx("button",{onClick:A=>{A.stopPropagation(),i(b.id)},className:"p-0.5 rounded hover:bg-text-primary/10 text-text-secondary opacity-0 group-hover:opacity-100 cursor-pointer flex-shrink-0",title:"Dismiss",children:f.jsx(kr,{className:"w-3 h-3"})})]},b.id)})]},g))})]})}function hy({onSubmit:l,onDismiss:i,isWatchMode:r,watchSubmitted:s,hasUnreviewedChanges:o}){const{annotations:d,dismissAnnotation:h,selectFile:m,diffSet:g,metadata:y}=lt(),b=!!(y!=null&&y.githubPr),x=S=>{if(!g)return;if(g.files.find(C=>Dt(C)===S)){m(S);return}const A=g.files.find(C=>C.path===S);A&&m(Dt(A))};return f.jsxs("div",{className:"h-screen flex flex-col bg-background",children:[f.jsx(Bv,{}),f.jsx(Hv,{}),f.jsxs("div",{className:"flex flex-1 min-h-0",children:[f.jsxs("div",{className:"w-[280px] flex-shrink-0 flex flex-col overflow-hidden",children:[f.jsx("div",{className:"flex-1 min-h-0",children:f.jsx(Vv,{onSubmit:l})}),f.jsx(IE,{annotations:d,onDismiss:h,onNavigate:x})]}),f.jsx(OE,{})]}),b?f.jsx(kE,{onDismiss:i}):f.jsx(jE,{onSubmit:l,onDismiss:i,isWatchMode:r,watchSubmitted:s,hasUnreviewedChanges:o}),f.jsx(zE,{}),f.jsx(HE,{})]})}function XE(l){const r=Date.now()-l,s=Math.floor(r/6e4);if(s<1)return"just now";if(s<60)return`${s}m ago`;const o=Math.floor(s/60);return o<24?`${o}h ago`:`${Math.floor(o/24)}d ago`}function FE(l){if(l.startsWith("github:"))return l.slice(7);const i=l.split("/");return i[i.length-1]||l}const pp={pending:"Pending",in_review:"In Review",changes_requested:"Changes Req.",approved:"Approved",approved_with_comments:"Approved",dismissed:"Dismissed",submitted:"Submitted"};function ZE(l){const{status:i,decision:r}=l,s=i==="submitted"?r??"submitted":i,o=km[s]??km.submitted,d=pp[s]??pp.submitted;return f.jsx("span",{className:`inline-flex items-center px-1.5 py-0.5 text-[10px] font-medium rounded ${o}`,children:d})}function $E({sessions:l,activeSessionId:i,onSelect:r,onClose:s,onOpenProject:o,onReviewPr:d}){return f.jsxs("div",{className:"flex flex-col h-full bg-surface border-r border-border",children:[f.jsxs("div",{className:"px-3 py-3 border-b border-border flex items-center justify-between",children:[f.jsxs("div",{children:[f.jsx("h2",{className:"text-text-primary text-xs font-semibold uppercase tracking-wider",children:"Sessions"}),f.jsxs("span",{className:"text-text-secondary text-[10px]",children:[l.length," session",l.length!==1?"s":""]})]}),f.jsxs("div",{className:"flex items-center gap-1",children:[d&&f.jsx("button",{onClick:d,className:"p-1 rounded hover:bg-border/50 text-text-secondary hover:text-accent transition-colors",title:"Review GitHub PR",children:f.jsx(ta,{className:"w-3.5 h-3.5"})}),o&&f.jsx("button",{onClick:o,className:"p-1 rounded hover:bg-border/50 text-text-secondary hover:text-text-primary transition-colors",title:"Open project",children:f.jsx(xp,{className:"w-3.5 h-3.5"})})]})]}),f.jsx("div",{className:"flex-1 overflow-y-auto",children:l.length===0?f.jsx("div",{className:"flex flex-col items-center justify-center h-full px-4 text-center",children:f.jsx("p",{className:"text-text-secondary text-xs",children:"No sessions yet. Reviews will appear here automatically."})}):f.jsx("div",{className:"py-1",children:l.map(h=>{const m=h.id===i,g=h.source==="manual",y=h.projectPath.startsWith("github:");return f.jsxs("div",{className:`group relative px-3 py-2.5 cursor-pointer border-l-2 transition-colors ${m?"bg-accent/10 border-l-accent":h.needsAttention?"bg-warning/5 border-l-warning hover:bg-warning/10":"border-l-transparent hover:bg-border/20"}`,onClick:()=>r(h.id),role:"button",tabIndex:0,onKeyDown:b=>{(b.key==="Enter"||b.key===" ")&&r(h.id)},children:[f.jsx("button",{onClick:b=>{b.stopPropagation(),s(h.id)},className:"absolute top-1.5 right-1.5 p-0.5 rounded hover:bg-border/50 text-text-secondary hover:text-text-primary transition-colors opacity-0 group-hover:opacity-100",style:{opacity:m?1:void 0},title:"Dismiss session",children:f.jsx(kr,{className:"w-3 h-3"})}),f.jsxs("div",{className:"flex items-start justify-between gap-1.5 mb-1 pr-7",children:[f.jsxs("div",{className:"flex items-center gap-1.5 min-w-0 flex-1",children:[h.needsAttention&&f.jsx(wa,{className:"w-3.5 h-3.5 text-warning flex-shrink-0 animate-pulse"}),h.hasNewChanges&&f.jsx(Sv,{className:"w-3 h-3 text-accent flex-shrink-0 animate-pulse","aria-label":"New changes",children:f.jsx("title",{children:"New changes since you last looked"})}),y?f.jsx(ta,{className:"w-3.5 h-3.5 text-accent flex-shrink-0"}):g?f.jsx(Ea,{className:"w-3.5 h-3.5 text-text-secondary flex-shrink-0"}):null,f.jsx("span",{className:"text-text-primary text-xs font-medium truncate",children:h.title||FE(h.projectPath)})]}),f.jsx("div",{className:"flex-shrink-0",children:ZE(h)})]}),h.reasoning&&f.jsx("p",{className:"text-text-secondary text-[11px] leading-tight mb-1 line-clamp-2",children:h.reasoning}),f.jsxs("div",{className:"flex items-center gap-2 text-[10px] text-text-secondary",children:[h.branch&&f.jsxs("span",{className:"flex items-center gap-0.5 truncate",children:[f.jsx(Tn,{className:"w-2.5 h-2.5"}),h.branch]}),f.jsxs("span",{className:"flex items-center gap-0.5 ml-auto flex-shrink-0",children:[f.jsx(fv,{className:"w-2.5 h-2.5"}),XE(h.createdAt)]})]}),f.jsxs("div",{className:"flex items-center gap-2 mt-0.5 text-[10px]",children:[f.jsxs("span",{className:"text-text-secondary",children:[h.fileCount," file",h.fileCount!==1?"s":""]}),h.additions>0&&f.jsxs("span",{className:"text-success font-mono",children:["+",h.additions]}),h.deletions>0&&f.jsxs("span",{className:"text-danger font-mono",children:["-",h.deletions]})]})]},h.id)})})})]})}function VE({permission:l,enabled:i,onToggle:r}){const s=l==="denied",o=l==="granted"&&i,d=s?"Notifications blocked by browser":o?"Notifications on":"Enable notifications";return f.jsx("button",{onClick:r,disabled:s,className:`p-1.5 rounded transition-colors cursor-pointer ${s?"text-text-secondary/50 cursor-not-allowed":o?"text-accent hover:text-accent/80":"text-text-secondary hover:text-text-primary"}`,title:d,children:o?f.jsx(sv,{className:"w-4 h-4"}):f.jsx(iv,{className:"w-4 h-4"})})}function KE(){const[l,i]=L.useState(null);return L.useEffect(()=>{const r=new URLSearchParams(window.location.search).get("httpPort");r&&fetch(`http://localhost:${r}/api/feedback?kind=feedback`).then(s=>s.ok?s.json():null).then(s=>{s!=null&&s.url&&i(s.url)}).catch(()=>{})},[]),l?f.jsxs("a",{href:l,target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-1.5 text-[11px] text-text-secondary hover:text-text-primary transition-colors",title:"Opens a prefilled GitHub issue. Nothing is sent until you submit it.",children:[f.jsx(Sl,{className:"w-3 h-3"}),"Send feedback"]}):null}function QE(){return new URLSearchParams(window.location.search).get("httpPort")}function JE({onSuccess:l}){const[i,r]=L.useState(""),[s,o]=L.useState(!1),[d,h]=L.useState(null),m=L.useCallback(async()=>{const y=QE();if(!(!y||!i.trim())){o(!0),h(null);try{const b=await fetch(`http://localhost:${y}/api/pr/open`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({prUrl:i.trim()})}),x=await b.json();b.ok?(r(""),l==null||l()):h(x.error??"Failed to open PR")}catch{h("Could not connect to server")}finally{o(!1)}}},[i,l]),g=L.useCallback(y=>{y.key==="Enter"&&!y.shiftKey&&i.trim()&&(y.preventDefault(),m())},[m,i]);return f.jsxs("div",{className:"space-y-3",children:[f.jsxs("div",{className:"relative",children:[f.jsx("input",{type:"text",value:i,onChange:y=>{r(y.target.value),d&&h(null)},onKeyDown:g,placeholder:"https://github.com/owner/repo/pull/123",className:"w-full bg-background border border-border rounded-md px-3 py-2 pl-9 text-text-primary text-xs placeholder:text-text-secondary/50 focus:outline-none focus:border-accent focus:ring-1 focus:ring-accent/30 transition-colors",disabled:s,autoFocus:!0}),f.jsx(ta,{className:"absolute left-3 top-1/2 -translate-y-1/2 w-3.5 h-3.5 text-text-secondary"})]}),f.jsx("button",{onClick:m,disabled:s||!i.trim(),className:"w-full bg-accent/15 text-accent text-xs font-medium rounded-md px-3 py-2 hover:bg-accent/25 disabled:opacity-50 disabled:cursor-not-allowed transition-colors flex items-center justify-center gap-1.5",children:s?f.jsxs(f.Fragment,{children:[f.jsx(no,{className:"w-3.5 h-3.5 animate-spin"}),"Fetching PR..."]}):f.jsxs(f.Fragment,{children:[f.jsx(So,{className:"w-3.5 h-3.5"}),"Review PR"]})}),d&&f.jsx("p",{className:"text-danger text-xs",children:d}),f.jsxs("p",{className:"text-text-secondary text-[10px]",children:["Also accepts ",f.jsx("code",{className:"text-accent/70",children:"owner/repo#123"})," format"]})]})}const WE=[{value:"working-copy",label:"Working Copy"},{value:"unstaged",label:"Unstaged"},{value:"staged",label:"Staged"}];function hs(){return new URLSearchParams(window.location.search).get("httpPort")}function PE(l){const[i,r]=L.useState(null),[s,o]=L.useState(!1),d=L.useCallback(async h=>{const m=hs();if(m){o(!0);try{const g=h?`?path=${encodeURIComponent(h)}`:"",y=await fetch(`http://localhost:${m}/api/fs/list${g}`);if(y.ok){const b=await y.json();r(b)}}catch{}finally{o(!1)}}},[]);return L.useEffect(()=>{d(l)},[d,l]),{listing:i,loadingDir:s,fetchDir:d}}function eN({onSuccess:l}){const[i,r]=L.useState(),[s,o]=L.useState(null),[d,h]=L.useState(!1),[m,g]=L.useState(null),{listing:y,loadingDir:b,fetchDir:x}=PE(i);L.useEffect(()=>{const E=hs();E&&fetch(`http://localhost:${E}/api/status`).then(A=>A.json()).then(A=>{const C=A;if(C.cwd&&r(C.cwd),C.defaultDiffRef){const _=C.defaultDiffRef;o(B=>B??_)}}).catch(()=>{})},[]);const S=L.useCallback(async E=>{const A=hs();if(A){h(!0),g(null);try{const C=await fetch(`http://localhost:${A}/api/projects/open`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(s?{projectPath:E,diffRef:s}:{projectPath:E})}),_=await C.json();C.ok?l==null||l():g(_.error??"Failed to open project")}catch{g("Could not connect to server")}finally{h(!1)}}},[s,l]);return f.jsxs("div",{className:"space-y-3",children:[y&&f.jsxs("div",{className:"flex items-center gap-1 text-text-secondary text-[11px] font-mono truncate min-h-[20px]",children:[y.parentPath&&f.jsx("button",{onClick:()=>x(y.parentPath),className:"p-0.5 rounded hover:bg-border/50 hover:text-text-primary transition-colors flex-shrink-0",title:"Go up",children:f.jsx(vo,{className:"w-3 h-3"})}),f.jsx("span",{className:"truncate",children:y.path}),y.isGitRepo&&f.jsx(Tn,{className:"w-3 h-3 text-success flex-shrink-0 ml-1"})]}),(y==null?void 0:y.isGitRepo)&&f.jsxs("button",{onClick:()=>S(y.path),disabled:d,className:"w-full bg-accent/15 text-accent text-xs font-medium rounded px-3 py-2 hover:bg-accent/25 disabled:opacity-50 disabled:cursor-not-allowed transition-colors flex items-center justify-center gap-1.5",children:[f.jsx(Ea,{className:"w-3.5 h-3.5"}),d?"Opening...":`Open ${y.path.split("/").pop()}`]}),f.jsx("div",{className:"border border-border rounded max-h-[280px] overflow-y-auto",children:b?f.jsx("div",{className:"px-3 py-4 text-text-secondary text-xs text-center",children:"Loading..."}):(y==null?void 0:y.dirs.length)===0?f.jsx("div",{className:"px-3 py-4 text-text-secondary text-xs text-center",children:"No subdirectories"}):y==null?void 0:y.dirs.map(E=>f.jsxs("button",{onClick:()=>{g(null),E.isGitRepo,x(E.path)},onDoubleClick:()=>{E.isGitRepo&&S(E.path)},className:"w-full flex items-center gap-2 px-3 py-1.5 text-left hover:bg-border/30 transition-colors group",children:[f.jsx(bv,{className:`w-3.5 h-3.5 flex-shrink-0 ${E.isGitRepo?"text-accent":"text-text-secondary"}`}),f.jsx("span",{className:"text-text-primary text-xs truncate flex-1",children:E.name}),E.isGitRepo&&f.jsx(Tn,{className:"w-3 h-3 text-success flex-shrink-0"})]},E.path))}),f.jsxs("div",{children:[f.jsx("label",{className:"block text-text-secondary text-xs mb-1",children:"Diff scope"}),f.jsx("select",{value:s??"",disabled:s===null,onChange:E=>o(E.target.value),className:"w-full bg-background border border-border rounded px-3 py-1.5 text-text-primary text-xs focus:outline-none focus:border-accent",children:WE.map(E=>f.jsx("option",{value:E.value,children:E.label},E.value))})]}),m&&f.jsx("p",{className:"text-danger text-xs",children:m})]})}function tN({sessions:l,activeSessionId:i,hasDiffLoaded:r,onSelectSession:s,onCloseSession:o,onSubmit:d,onDismiss:h,notificationPermission:m,notificationsEnabled:g,onToggleNotifications:y}){const[b,x]=L.useState("none");return f.jsxs("div",{className:"h-screen flex bg-background",children:[f.jsxs("div",{className:"w-[260px] flex-shrink-0 flex flex-col",children:[f.jsx($E,{sessions:l,activeSessionId:i,onSelect:s,onClose:o,onOpenProject:()=>x("open-project"),onReviewPr:()=>x("review-pr")}),f.jsxs("div",{className:"px-3 py-2 border-t border-border border-r border-r-border bg-surface space-y-1.5",children:[y&&m&&f.jsx(VE,{permission:m,enabled:g??!1,onToggle:y}),f.jsx(KE,{})]})]}),f.jsx("div",{className:"flex-1 min-w-0",children:r?f.jsx(hy,{onSubmit:d,onDismiss:h,isWatchMode:!0,watchSubmitted:!1,hasUnreviewedChanges:!0}):b==="open-project"?f.jsx("div",{className:"flex flex-col items-center justify-center h-full px-8",children:f.jsxs("div",{className:"max-w-sm w-full",children:[f.jsxs("div",{className:"flex items-center gap-2 mb-4",children:[f.jsx(Ea,{className:"w-5 h-5 text-accent"}),f.jsx("h2",{className:"text-text-primary text-lg font-semibold",children:"Open Project"})]}),f.jsx("div",{className:"bg-surface border border-border rounded-lg p-5",children:f.jsx(eN,{onSuccess:()=>x("none")})}),f.jsx("button",{onClick:()=>x("none"),className:"mt-3 text-text-secondary text-xs hover:text-text-primary transition-colors",children:"Cancel"})]})}):b==="review-pr"?f.jsx("div",{className:"flex flex-col items-center justify-center h-full px-8",children:f.jsxs("div",{className:"max-w-sm w-full",children:[f.jsxs("div",{className:"flex items-center gap-2 mb-4",children:[f.jsx(ta,{className:"w-5 h-5 text-accent"}),f.jsx("h2",{className:"text-text-primary text-lg font-semibold",children:"Review PR"})]}),f.jsx("div",{className:"bg-surface border border-border rounded-lg p-5",children:f.jsx(JE,{onSuccess:()=>x("none")})}),f.jsx("button",{onClick:()=>x("none"),className:"mt-3 text-text-secondary text-xs hover:text-text-primary transition-colors",children:"Cancel"})]})}):f.jsx(nN,{hasAnySessions:l.length>0,onOpenProject:()=>x("open-project"),onReviewPr:()=>x("review-pr")})})]})}function nN({hasAnySessions:l,onOpenProject:i,onReviewPr:r}){return l?f.jsxs("div",{className:"flex flex-col items-center justify-center h-full text-center px-8",children:[f.jsx("div",{className:"w-14 h-14 rounded-full bg-surface border border-border flex items-center justify-center mb-4",children:f.jsx(wl,{className:"w-7 h-7 text-text-secondary"})}),f.jsx("h2",{className:"text-text-primary text-lg font-semibold mb-2",children:"Select a session"}),f.jsx("p",{className:"text-text-secondary text-sm max-w-sm mb-4",children:"Click a session in the sidebar to view its diff, annotations, and submit your review."}),f.jsxs("div",{className:"flex items-center gap-4",children:[f.jsxs("button",{onClick:r,className:"flex items-center gap-1.5 text-accent text-xs font-medium hover:text-accent/80 transition-colors",children:[f.jsx(ta,{className:"w-3.5 h-3.5"}),"Review PR"]}),f.jsxs("button",{onClick:i,className:"flex items-center gap-1.5 text-text-secondary text-xs font-medium hover:text-text-primary transition-colors",children:[f.jsx(Ea,{className:"w-3.5 h-3.5"}),"Open Project"]})]})]}):f.jsx(aN,{onOpenProject:i,onReviewPr:r})}function aN({onOpenProject:l,onReviewPr:i}){const[r,s]=L.useState(null);L.useEffect(()=>{const d=hs();d&&fetch(`http://localhost:${d}/api/status`).then(h=>h.json()).then(h=>{s(h)}).catch(()=>{})},[]);const o=d=>{if(d<60)return`${Math.floor(d)}s`;if(d<3600)return`${Math.floor(d/60)}m ${Math.floor(d%60)}s`;const h=Math.floor(d/3600),m=Math.floor(d%3600/60);return`${h}h ${m}m`};return f.jsx("div",{className:"flex flex-col items-center justify-center h-full px-8",children:f.jsxs("div",{className:"max-w-md w-full",children:[f.jsxs("div",{className:"text-center mb-8",children:[f.jsx("h1",{className:"text-text-primary text-2xl font-bold mb-1",children:"DiffPrism"}),f.jsx("p",{className:"text-text-secondary text-sm",children:"Code review for AI-generated changes"})]}),f.jsxs("div",{className:"flex gap-3 mb-4",children:[f.jsxs("button",{onClick:i,className:"flex-1 flex items-center justify-center gap-2 bg-accent/15 text-accent text-sm font-medium rounded-lg px-4 py-3 hover:bg-accent/25 transition-colors",children:[f.jsx(ta,{className:"w-4 h-4"}),"Review PR"]}),f.jsxs("button",{onClick:l,className:"flex-1 flex items-center justify-center gap-2 bg-surface border border-border text-text-primary text-sm font-medium rounded-lg px-4 py-3 hover:bg-border/30 transition-colors",children:[f.jsx(Ea,{className:"w-4 h-4"}),"Open Project"]})]}),f.jsxs("div",{className:"bg-surface border border-border rounded-lg p-6",children:[f.jsx("h2",{className:"text-text-primary text-sm font-semibold mb-4",children:"Getting Started"}),f.jsxs("div",{className:"mb-5",children:[f.jsxs("div",{className:"flex items-center gap-2 mb-2",children:[f.jsx(Tv,{className:"w-4 h-4 text-text-secondary"}),f.jsx("span",{className:"text-text-secondary text-xs font-medium",children:"From the terminal"})]}),f.jsxs("div",{className:"space-y-1.5 pl-6",children:[f.jsx("code",{className:"block text-accent text-xs",children:"$ diffprism review"}),f.jsx("code",{className:"block text-accent text-xs",children:"$ diffprism review --staged"})]})]}),f.jsxs("div",{className:"mb-5",children:[f.jsxs("div",{className:"flex items-center gap-2 mb-2",children:[f.jsx(wl,{className:"w-4 h-4 text-text-secondary"}),f.jsx("span",{className:"text-text-secondary text-xs font-medium",children:"From Claude Code"})]}),f.jsxs("p",{className:"text-text-secondary text-xs pl-6",children:["Type ",f.jsx("code",{className:"text-accent",children:"/review"})," or use the"," ",f.jsx("code",{className:"text-accent",children:"open_review"})," MCP tool"]})]}),f.jsxs("div",{children:[f.jsxs("div",{className:"flex items-center gap-2 mb-2",children:[f.jsx(wv,{className:"w-4 h-4 text-text-secondary"}),f.jsx("span",{className:"text-text-secondary text-xs font-medium",children:"First time?"})]}),f.jsxs("div",{className:"pl-6",children:[f.jsx("code",{className:"block text-accent text-xs mb-1",children:"$ diffprism setup"}),f.jsx("p",{className:"text-text-secondary text-xs",children:"Configures Claude Code integration in one command"})]})]})]}),r&&f.jsxs("p",{className:"text-text-secondary text-xs text-center mt-4",children:["Server running · PID ",r.pid," · up ",o(r.uptime)]})]})})}function lN(){const{permission:l,enabled:i,toggle:r,notifyNewSession:s,notifySessionUpdated:o,notifyDiffUpdated:d,notifyAnnotationAdded:h}=ev({onSessionSelect:J}),{sendResult:m,selectSession:g,closeSession:y,connectionStatus:b}=W0({onSessionAdded:s,onSessionUpdated:o,onDiffUpdated:d,onAnnotationAdded:h}),{diffSet:x,metadata:S,theme:E,isWatchMode:A,watchSubmitted:C,hasUnreviewedChanges:_,setWatchSubmitted:B,isServerMode:q,sessions:R,activeSessionId:Z,selectSession:Y,removeSession:F,clearReview:H}=lt(),[j,ae]=L.useState(!1),[ee,re]=L.useState(3);tv(),L.useEffect(()=>{const O=document.documentElement;E==="dark"?O.classList.add("dark"):O.classList.remove("dark")},[E]);function ce(O){m(O),q?H():A?B(!0):ae(!0)}function te(){m({decision:"dismissed",comments:[]}),q&&Z?(F(Z),y(Z)):A?B(!0):ae(!0)}function J(O){Y(O),g(O)}function Q(O){F(O),y(O)}const M=L.useCallback(()=>{window.close()},[]);return L.useEffect(()=>{if(!j||A||q)return;if(ee<=0){M();return}const O=setTimeout(()=>{re(le=>le-1)},1e3);return()=>clearTimeout(O)},[j,ee,M,A,q]),j?f.jsx("div",{className:"h-screen flex items-center justify-center bg-background",children:f.jsxs("div",{className:"text-center",children:[f.jsx("div",{className:"w-16 h-16 rounded-full bg-success/15 border border-success/30 flex items-center justify-center mx-auto mb-4",children:f.jsx("svg",{className:"w-8 h-8 text-success",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:f.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M5 13l4 4L19 7"})})}),f.jsx("h1",{className:"text-text-primary text-xl font-semibold mb-2",children:"Review Submitted"}),f.jsxs("p",{className:"text-text-secondary text-sm",children:["Closing in ",ee,"s..."]})]})}):q?b==="disconnected"?f.jsx("div",{className:"h-screen flex items-center justify-center bg-background",children:f.jsxs("div",{className:"text-center",children:[f.jsx("div",{className:"w-12 h-12 rounded-full bg-danger/15 border border-danger/30 flex items-center justify-center mx-auto mb-4",children:f.jsx("svg",{className:"w-6 h-6 text-danger",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:f.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M6 18L18 6M6 6l12 12"})})}),f.jsx("h1",{className:"text-text-primary text-lg font-semibold mb-2",children:"Connection Lost"}),f.jsx("p",{className:"text-text-secondary text-sm",children:"Unable to connect to the DiffPrism server."})]})}):f.jsx(tN,{sessions:R,activeSessionId:Z,hasDiffLoaded:!!x,onSelectSession:J,onCloseSession:Q,onSubmit:ce,onDismiss:te,notificationPermission:l,notificationsEnabled:i,onToggleNotifications:r}):x?f.jsx(hy,{onSubmit:ce,onDismiss:te,isWatchMode:A||q,watchSubmitted:C,hasUnreviewedChanges:_}):f.jsx("div",{className:"h-screen flex items-center justify-center bg-background",children:f.jsx("div",{className:"text-center",children:b==="disconnected"?f.jsxs(f.Fragment,{children:[f.jsx("div",{className:"w-12 h-12 rounded-full bg-danger/15 border border-danger/30 flex items-center justify-center mx-auto mb-4",children:f.jsx("svg",{className:"w-6 h-6 text-danger",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:f.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M6 18L18 6M6 6l12 12"})})}),f.jsx("h1",{className:"text-text-primary text-lg font-semibold mb-2",children:"Connection Lost"}),f.jsx("p",{className:"text-text-secondary text-sm",children:"Unable to connect to the DiffPrism server. Please check the terminal and try again."})]}):f.jsxs(f.Fragment,{children:[f.jsx("div",{className:"mb-4 flex justify-center",children:f.jsx("div",{className:"w-8 h-8 border-2 border-accent/30 border-t-accent rounded-full animate-spin"})}),f.jsx("h1",{className:"text-text-primary text-lg font-semibold mb-2",children:b==="connecting"?"Connecting...":"Waiting for review data..."}),f.jsx("p",{className:"text-text-secondary text-sm",children:(S==null?void 0:S.title)??"Loading review..."})]})})})}$0.createRoot(document.getElementById("root")).render(f.jsx(lN,{}));
@@ -5,7 +5,7 @@
5
5
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
6
6
  <link rel="icon" type="image/svg+xml" href="/favicon.svg" />
7
7
  <title>DiffPrism</title>
8
- <script type="module" crossorigin src="/assets/index-Zw97bHGn.js"></script>
8
+ <script type="module" crossorigin src="/assets/index-CLWtGr9m.js"></script>
9
9
  <link rel="stylesheet" crossorigin href="/assets/index-BulxhOr3.css">
10
10
  </head>
11
11
  <body style="background-color: var(--color-background); margin: 0;">