v-code-diff 1.14.0 → 1.14.1

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
@@ -4,18 +4,19 @@
4
4
  [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
5
5
  [![Downloads](https://img.shields.io/npm/dm/v-code-diff?minimal=true)](https://www.npmjs.com/package/v-code-diff)
6
6
 
7
- > A code diff display plugin, available for Vue2 / Vue3.
7
+ > A code diff viewer for Vue 2.6, Vue 2.7, and Vue 3.
8
8
 
9
9
  <p align='center'>
10
10
  <b>English</b> | <a href="https://github.com/Shimada666/v-code-diff/blob/main/README-zh.md">简体中文</a>
11
11
  </p>
12
12
 
13
- Old Version:
13
+ Old version:
14
14
 
15
- 0.x version, latest version 0.3.12 (traditional version, improved based
16
- on [vue-code-diff](https://github.com/ddchef/vue-code-diff), is no longer maintained. We will try to align the
17
- functionality of 0.x version in 1.x version and minimize migration cost as much as possible).
18
- This project references the following projects, and I would like to express my gratitude to the original authors!
15
+ The 0.x line ended at 0.3.12 and is no longer maintained. It was based on
16
+ [vue-code-diff](https://github.com/ddchef/vue-code-diff). Version 1.x aims to preserve its core behavior while keeping
17
+ migration straightforward.
18
+
19
+ This project draws inspiration from the following projects. Thanks to their original authors:
19
20
 
20
21
  - [vue-diff](https://github.com/hoiheart/vue-diff)
21
22
  - [vue-code-diff](https://github.com/ddchef/vue-code-diff)
@@ -34,7 +35,7 @@ This project references the following projects, and I would like to express my g
34
35
 
35
36
  ## Install
36
37
 
37
- install `v-code-diff`
38
+ Install `v-code-diff`:
38
39
 
39
40
  ```bash
40
41
  # npm
@@ -47,25 +48,26 @@ yarn add v-code-diff
47
48
  pnpm add v-code-diff
48
49
  ```
49
50
 
50
- Use the explicit entry for your Vue version. These entries do not depend on
51
- `postinstall`, so they also work when the package manager blocks dependency
52
- scripts:
53
-
54
- | Vue version | Import path |
55
- | --- | --- |
56
- | Vue 2.6 | `v-code-diff/vue2` |
57
- | Vue 2.7 | `v-code-diff/vue2.7` |
58
- | Vue 3 | `v-code-diff/vue3` |
51
+ `v-code-diff` uses `postinstall` to select the build for your Vue version. Do not install it with `--ignore-scripts`.
52
+ If pnpm reports that the build script was blocked, approve it and let pnpm run the script:
59
53
 
60
- The legacy `v-code-diff` root entry remains available when dependency scripts
61
- are enabled.
54
+ ```shell
55
+ pnpm approve-builds v-code-diff
56
+ ```
62
57
 
63
- Vue2.6 developers need install composition-api
58
+ Vue 2.6 users must also install and register `@vue/composition-api`:
64
59
 
65
60
  ```shell
66
61
  pnpm add @vue/composition-api
67
62
  ```
68
63
 
64
+ ```ts
65
+ import Vue from 'vue'
66
+ import VueCompositionAPI from '@vue/composition-api'
67
+
68
+ Vue.use(VueCompositionAPI)
69
+ ```
70
+
69
71
  ## Getting Started
70
72
 
71
73
  ### Vue3
@@ -74,7 +76,7 @@ pnpm add @vue/composition-api
74
76
  > Recommend using local registration for better tree-shaking support.
75
77
  ```vue
76
78
  <script setup>
77
- import { CodeDiff } from 'v-code-diff/vue3'
79
+ import { CodeDiff } from 'v-code-diff'
78
80
  </script>
79
81
 
80
82
  <template>
@@ -92,14 +94,13 @@ import { CodeDiff } from 'v-code-diff/vue3'
92
94
 
93
95
  ```ts
94
96
  import { createApp } from 'vue'
95
- import CodeDiff from 'v-code-diff/vue3'
97
+ import CodeDiff from 'v-code-diff'
98
+ import App from './App.vue'
96
99
 
97
- app
98
- .use(CodeDiff)
99
- .mount('#app')
100
+ createApp(App).use(CodeDiff).mount('#app')
100
101
  ```
101
102
 
102
- then
103
+ Then use the component in any template:
103
104
 
104
105
  ```vue
105
106
  <template>
@@ -117,8 +118,7 @@ then
117
118
  > Recommend using local registration for better tree-shaking support.
118
119
  ```vue
119
120
  <script>
120
- // Use v-code-diff/vue2.7 instead when running Vue 2.7.
121
- import { CodeDiff } from 'v-code-diff/vue2'
121
+ import { CodeDiff } from 'v-code-diff'
122
122
  export default {
123
123
  components: {
124
124
  CodeDiff
@@ -139,8 +139,7 @@ export default {
139
139
  #### Register globally
140
140
  ```ts
141
141
  import Vue from 'vue'
142
- // Use v-code-diff/vue2.7 instead when running Vue 2.7.
143
- import CodeDiff from 'v-code-diff/vue2'
142
+ import CodeDiff from 'v-code-diff'
144
143
 
145
144
  Vue.use(CodeDiff)
146
145
  ```
@@ -157,15 +156,15 @@ Vue.use(CodeDiff)
157
156
 
158
157
  | Prop | Description | Type | Optional Values | Default Value |
159
158
  |---------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-----------|---------------------------|---------------|
160
- | language | Code language, such as typescript, defaults to plain text. [View all supported languages](https://github.com/highlightjs/highlight.js/blob/main/SUPPORTED_LANGUAGES.md) | string | - | plaintext |
159
+ | language | Syntax-highlighting language, such as javascript. Defaults to plain text. | string | - | plaintext |
161
160
  | oldString | Old string | string | - | - |
162
161
  | newString | New string | string | - | - |
163
- | context | The number of lines to separate different parts so that they are not hidden | number | - | 10 |
164
- | outputFormat | Display mode | string | line-by-lineside-by-side | line-by-line |
165
- | diffStyle | Difference style, word-level differences or letter-level differences | string | word, char | word |
166
- |forceInlineComparison| Force inline comparison (word or char level) | boolean | - | false |
162
+ | context | Number of unchanged lines shown around each change | number | - | 10 |
163
+ | outputFormat | Display mode | string | line-by-line, side-by-side | line-by-line |
164
+ | diffStyle | Inline difference granularity: words or characters | string | word, char | word |
165
+ | forceInlineComparison | Force inline comparison (word or char level) | boolean | - | false |
167
166
  | trim | Remove blank characters at the beginning and end of the string | boolean | - | false |
168
- | noDiffLineFeed | Don't diff Windows line feed (CRLF) and Linux line feed (LF) | boolean | - | false |
167
+ | noDiffLineFeed | Normalize Windows (CRLF) and Unix (LF) line endings before comparison | boolean | - | false |
169
168
  | maxHeight | Maximum height of component, for example: 300px | string | - | undefined |
170
169
  | filename | Filename | string | - | undefined |
171
170
  | newFilename | New filename | string | - | undefined |
@@ -178,18 +177,17 @@ Vue.use(CodeDiff)
178
177
 
179
178
  | Name | Description | Type |
180
179
  | ---- | --------------------------- | ------------------------------------------------------------------------------- |
181
- | diff | triggers when diff finished | (result: {stat: { isChanged: boolean, addNum: number, delNum: number}}) => void |
180
+ | diff | Emitted after the diff is calculated | (result: {stat: { isChanged: boolean, addNum: number, delNum: number}}) => void |
182
181
 
183
182
  ## Slot
184
183
 
185
184
  | Name | Description |
186
185
  | ---- | ----------------------------------------------------------- |
187
- | stat | Custom statistical content, The scope parameter is { stat } |
186
+ | stat | Custom statistics content. The slot prop is `{ stat }`. |
188
187
 
189
188
  ## Extend languages
190
189
 
191
- In order to reduce the size of the packaged file, the system only supports the following commonly used languages by
192
- default.
190
+ To keep the bundle small, the following languages are registered by default:
193
191
 
194
192
  - plaintext
195
193
  - xml/html
@@ -201,7 +199,7 @@ default.
201
199
  - bash
202
200
  - sql
203
201
 
204
- If the language you need is not included, you can manually import the relevant language highlighting module.
202
+ To use another language, import and register its highlighting module manually.
205
203
 
206
204
  ```shell
207
205
  pnpm add highlight.js
@@ -244,17 +242,13 @@ CodeDiff.hljs.registerLanguage('c', c)
244
242
 
245
243
  ## Migrate from 0.x version
246
244
 
247
- The v-code-diff 1.x version has features such as reduced packaging size and improved performance compared to the 0.x
248
- version. And we will try to align the functions with the 0.x version as much as possible to reduce your migration cost.
245
+ Version 1.x has a smaller bundle and better performance than 0.x while preserving its core behavior.
249
246
 
250
247
  Key points:
251
248
 
252
- - In the 1.x version, language recognition and highlighting will no longer be automatically performed, you need to
253
- manually specify the language type, such as language="python", if not specified, it will default to plaintext
254
- and will not be highlighted.
255
- - In the 1.x version, due to the fact that rendering and highlighting are performed at the same time, the component
256
- events
257
- have been removed.
249
+ - Version 1.x no longer detects or highlights languages automatically. Set the language explicitly, such as
250
+ `language="python"`; if omitted, it defaults to `plaintext` without syntax highlighting.
251
+ - The legacy `before-render` and `after-render` events were removed. The `diff` event remains available.
258
252
  - Large results render 1,000 lines at a time. Use the load-more control to reveal the next batch.
259
253
  - Inline word/character markers are skipped when a changed line pair exceeds 10,000 characters. Set
260
254
  `force-inline-comparison` to keep detailed markers when the extra processing time is acceptable.
@@ -265,19 +259,18 @@ Key points:
265
259
  - newFilename - new
266
260
  - theme - new
267
261
 
268
- Below is a detailed comparison of the two versions, you can refer to it to complete the migration.
262
+ The tables below summarize the migration details.
269
263
 
270
- ### The difference of event.
264
+ ### Event changes
271
265
 
272
- The component events are no longer provided in the 1.x version as rendering and highlighting are carried out
273
- simultaneously.
266
+ The legacy `before-render` and `after-render` events are no longer provided in 1.x.
274
267
 
275
268
  | Event Name | Change Status |
276
269
  | ------------- | ------------------ |
277
270
  | before-render | No longer provided |
278
271
  | after-render | No longer provided |
279
272
 
280
- ### The difference of prop.
273
+ ### Prop changes
281
274
 
282
275
  | Prop | Description | Change Status |
283
276
  | ---------------------- | --------------------------------------------------------------------------- | ----------------------------------------------- |
@@ -290,8 +283,8 @@ simultaneously.
290
283
  | diffStyle | Difference style, word-level differences or letter-level differences | None |
291
284
  | drawFileList | Display file comparison list | Removed in version 1.x |
292
285
  | renderNothingWhenEmpty | Do not render when there is no comparison | Removed in version 1.x |
293
- | fileName | File name | To be determined, not under development |
294
- | newFilename | | New in version 1. To be determined, not under development |
286
+ | fileName | File name | Renamed to `filename` in 1.x |
287
+ | newFilename | New file name | Added in 1.x |
295
288
  | isShowNoChange | Display source code when there is no comparison | Removed as it became the default in version 1.x |
296
289
  | trim | Remove blank characters at the beginning and end of the string | None |
297
290
  | noDiffLineFeed | Don't diff Windows line feed (CRLF) and Linux line feed (LF) | None |
package/dist/v2/index.cjs CHANGED
@@ -8,7 +8,9 @@
8
8
  https://github.com/highlightjs/highlight.js/issues/2277`),F=v,B=M),R===void 0&&(R=!0);const q={code:B,language:F};ie("before:highlight",q);const Y=q.result?q.result:l(q.language,q.code,R);return Y.code=q.code,ie("after:highlight",Y),Y}function l(v,M,R,B){const F=Object.create(null);function q(w,C){return w.keywords[C]}function Y(){if(!O.keywords){G.addText(P);return}let w=0;O.keywordPatternRe.lastIndex=0;let C=O.keywordPatternRe.exec(P),I="";for(;C;){I+=P.substring(w,C.index);const U=X.case_insensitive?C[0].toLowerCase():C[0],K=q(O,U);if(K){const[ne,Zn]=K;if(G.addText(I),I="",F[U]=(F[U]||0)+1,F[U]<=Jt&&(Me+=Zn),ne.startsWith("_"))I+=C[0];else{const Yn=X.classNameAliases[ne]||ne;V(C[0],Yn)}}else I+=C[0];w=O.keywordPatternRe.lastIndex,C=O.keywordPatternRe.exec(P)}I+=P.substring(w),G.addText(I)}function ye(){if(P==="")return;let w=null;if(typeof O.subLanguage=="string"){if(!n[O.subLanguage]){G.addText(P);return}w=l(O.subLanguage,P,!0,en[O.subLanguage]),en[O.subLanguage]=w._top}else w=h(P,O.subLanguage.length?O.subLanguage:null);O.relevance>0&&(Me+=w.relevance),G.__addSublanguage(w._emitter,w.language)}function Q(){O.subLanguage!=null?ye():Y(),P=""}function V(w,C){w!==""&&(G.startScope(C),G.addText(w),G.endScope())}function Ye(w,C){let I=1;const U=C.length-1;for(;I<=U;){if(!w._emit[I]){I++;continue}const K=X.classNameAliases[w[I]]||w[I],ne=C[I];K?V(ne,K):(P=ne,Y(),P=""),I++}}function Ve(w,C){return w.scope&&typeof w.scope=="string"&&G.openNode(X.classNameAliases[w.scope]||w.scope),w.beginScope&&(w.beginScope._wrap?(V(P,X.classNameAliases[w.beginScope._wrap]||w.beginScope._wrap),P=""):w.beginScope._multi&&(Ye(w.beginScope,C),P="")),O=Object.create(w,{parent:{value:O}}),O}function Xe(w,C,I){let U=pt(w.endRe,I);if(U){if(w["on:end"]){const K=new rn(w);w["on:end"](C,K),K.isMatchIgnored&&(U=!1)}if(U){for(;w.endsParent&&w.parent;)w=w.parent;return w}}if(w.endsWithParent)return Xe(w.parent,C,I)}function Kn(w){return O.matcher.regexIndex===0?(P+=w[0],1):(Oe=!0,0)}function Wn(w){const C=w[0],I=w.rule,U=new rn(I),K=[I.__beforeBegin,I["on:begin"]];for(const ne of K)if(ne&&(ne(w,U),U.isMatchIgnored))return Kn(C);return I.skip?P+=C:(I.excludeBegin&&(P+=C),Q(),!I.returnBegin&&!I.excludeBegin&&(P=C)),Ve(I,w),I.returnBegin?0:C.length}function qn(w){const C=w[0],I=M.substring(w.index),U=Xe(O,w,I);if(!U)return un;const K=O;O.endScope&&O.endScope._wrap?(Q(),V(C,O.endScope._wrap)):O.endScope&&O.endScope._multi?(Q(),Ye(O.endScope,w)):K.skip?P+=C:(K.returnEnd||K.excludeEnd||(P+=C),Q(),K.excludeEnd&&(P=C));do O.scope&&G.closeNode(),!O.skip&&!O.subLanguage&&(Me+=O.relevance),O=O.parent;while(O!==U.parent);return U.starts&&Ve(U.starts,w),K.returnEnd?0:C.length}function Qn(){const w=[];for(let C=O;C!==X;C=C.parent)C.scope&&w.unshift(C.scope);w.forEach(C=>G.openNode(C))}let we={};function Je(w,C){const I=C&&C[0];if(P+=w,I==null)return Q(),0;if(we.type==="begin"&&C.type==="end"&&we.index===C.index&&I===""){if(P+=M.slice(C.index,C.index+1),!g){const U=new Error(`0 width match regex (${v})`);throw U.languageName=v,U.badRule=we.rule,U}return 1}if(we=C,C.type==="begin")return Wn(C);if(C.type==="illegal"&&!R){const U=new Error('Illegal lexeme "'+I+'" for mode "'+(O.scope||"<unnamed>")+'"');throw U.mode=O,U}else if(C.type==="end"){const U=qn(C);if(U!==un)return U}if(C.type==="illegal"&&I==="")return 1;if(Re>1e5&&Re>C.index*3)throw new Error("potential infinite loop, way more iterations than matches");return P+=I,I.length}const X=A(v);if(!X)throw le(t.replace("{}",v)),new Error('Unknown language: "'+v+'"');const jn=Zt(X);let Le="",O=B||jn;const en={},G=new r.__emitter(r);Qn();let P="",Me=0,oe=0,Re=0,Oe=!1;try{if(X.__emitTokens)X.__emitTokens(M,G);else{for(O.matcher.considerAll();;){Re++,Oe?Oe=!1:O.matcher.considerAll(),O.matcher.lastIndex=oe;const w=O.matcher.exec(M);if(!w)break;const C=M.substring(oe,w.index),I=Je(C,w);oe=w.index+I}Je(M.substring(oe))}return G.finalize(),Le=G.toHTML(),{language:v,value:Le,relevance:Me,illegal:!1,_emitter:G,_top:O}}catch(w){if(w.message&&w.message.includes("Illegal"))return{language:v,value:ke(M),illegal:!0,relevance:0,_illegalBy:{message:w.message,index:oe,context:M.slice(oe-100,oe+100),mode:w.mode,resultSoFar:Le},_emitter:G};if(g)return{language:v,value:ke(M),illegal:!1,relevance:0,errorRaised:w,_emitter:G,_top:O};throw w}}function u(v){const M={value:ke(v),illegal:!1,relevance:0,_top:i,_emitter:new r.__emitter(r)};return M._emitter.addText(v),M}function h(v,M){M=M||r.languages||Object.keys(n);const R=u(v),B=M.filter(A).filter($).map(Q=>l(Q,v,!1));B.unshift(R);const F=B.sort((Q,V)=>{if(Q.relevance!==V.relevance)return V.relevance-Q.relevance;if(Q.language&&V.language){if(A(Q.language).supersetOf===V.language)return 1;if(A(V.language).supersetOf===Q.language)return-1}return 0}),[q,Y]=F,ye=q;return ye.secondBest=Y,ye}function d(v,M,R){const B=M&&s[M]||R;v.classList.add("hljs"),v.classList.add(`language-${B}`)}function p(v){let M=null;const R=c(v);if(a(R))return;if(ie("before:highlightElement",{el:v,language:R}),v.dataset.highlighted){console.log("Element previously highlighted. To highlight again, first unset `dataset.highlighted`.",v);return}if(v.children.length>0&&(r.ignoreUnescapedHTML||(console.warn("One of your code blocks includes unescaped HTML. This is a potentially serious security risk."),console.warn("https://github.com/highlightjs/highlight.js/wiki/security"),console.warn("The element with unescaped HTML:"),console.warn(v)),r.throwUnescapedHTML))throw new Xt("One of your code blocks includes unescaped HTML.",v.innerHTML);M=v;const B=M.textContent,F=R?o(B,{language:R,ignoreIllegals:!0}):h(B);v.innerHTML=F.value,v.dataset.highlighted="yes",d(v,R,F.language),v.result={language:F.language,re:F.relevance,relevance:F.relevance},F.secondBest&&(v.secondBest={language:F.secondBest.language,relevance:F.secondBest.relevance}),ie("after:highlightElement",{el:v,result:F,text:B})}function _(v){r=cn(r,v)}const b=()=>{y(),fe("10.6.0","initHighlighting() deprecated. Use highlightAll() now.")};function m(){y(),fe("10.6.0","initHighlightingOnLoad() deprecated. Use highlightAll() now.")}let E=!1;function y(){if(document.readyState==="loading"){E=!0;return}document.querySelectorAll(r.cssSelector).forEach(p)}function T(){E&&y()}typeof window!="undefined"&&window.addEventListener&&window.addEventListener("DOMContentLoaded",T,!1);function N(v,M){let R=null;try{R=M(e)}catch(B){if(le("Language definition for '{}' could not be registered.".replace("{}",v)),g)le(B);else throw B;R=i}R.name||(R.name=v),n[v]=R,R.rawDefinition=M.bind(null,e),R.aliases&&L(R.aliases,{languageName:v})}function S(v){delete n[v];for(const M of Object.keys(s))s[M]===v&&delete s[M]}function k(){return Object.keys(n)}function A(v){return v=(v||"").toLowerCase(),n[v]||n[s[v]]}function L(v,{languageName:M}){typeof v=="string"&&(v=[v]),v.forEach(R=>{s[R.toLowerCase()]=M})}function $(v){const M=A(v);return M&&!M.disableAutodetect}function x(v){v["before:highlightBlock"]&&!v["before:highlightElement"]&&(v["before:highlightElement"]=M=>{v["before:highlightBlock"](Object.assign({block:M.el},M))}),v["after:highlightBlock"]&&!v["after:highlightElement"]&&(v["after:highlightElement"]=M=>{v["after:highlightBlock"](Object.assign({block:M.el},M))})}function z(v){x(v),f.push(v)}function W(v){const M=f.indexOf(v);M!==-1&&f.splice(M,1)}function ie(v,M){const R=v;f.forEach(function(B){B[R]&&B[R](M)})}function ue(v){return fe("10.7.0","highlightBlock will be removed entirely in v12.0"),fe("10.7.0","Please use highlightElement now."),p(v)}Object.assign(e,{highlight:o,highlightAuto:h,highlightAll:y,highlightElement:p,highlightBlock:ue,configure:_,initHighlighting:b,initHighlightingOnLoad:m,registerLanguage:N,unregisterLanguage:S,listLanguages:k,getLanguage:A,registerAliases:L,autoDetection:$,inherit:cn,addPlugin:z,removePlugin:W}),e.debugMode=function(){g=!1},e.safeMode=function(){g=!0},e.versionString=Vt,e.regex={concat:ce,lookahead:Tn,either:Ke,optional:ht,anyNumberOfTimes:gt};for(const v in Ae)typeof Ae[v]=="object"&&An(Ae[v]);return Object.assign(e,Ae),e},he=$n({});he.newInstance=()=>$n({});var ei=he;he.HighlightJS=he;he.default=he;const j=ot(ei);function ni(e){const n=e.regex,s=n.concat(/[\p{L}_]/u,n.optional(/[\p{L}0-9_.-]*:/u),/[\p{L}0-9_.-]*/u),f=/[\p{L}0-9._:-]+/u,g={className:"symbol",begin:/&[a-z]+;|&#[0-9]+;|&#x[a-f0-9]+;/},t={begin:/\s/,contains:[{className:"keyword",begin:/#?[a-z_][a-z1-9_-]+/,illegal:/\n/}]},i=e.inherit(t,{begin:/\(/,end:/\)/}),r=e.inherit(e.APOS_STRING_MODE,{className:"string"}),a=e.inherit(e.QUOTE_STRING_MODE,{className:"string"}),c={endsWithParent:!0,illegal:/</,relevance:0,contains:[{className:"attr",begin:f,relevance:0},{begin:/=\s*/,relevance:0,contains:[{className:"string",endsParent:!0,variants:[{begin:/"/,end:/"/,contains:[g]},{begin:/'/,end:/'/,contains:[g]},{begin:/[^\s"'=<>`]+/}]}]}]};return{name:"HTML, XML",aliases:["html","xhtml","rss","atom","xjb","xsd","xsl","plist","wsf","svg"],case_insensitive:!0,unicodeRegex:!0,contains:[{className:"meta",begin:/<![a-z]/,end:/>/,relevance:10,contains:[t,a,r,i,{begin:/\[/,end:/\]/,contains:[{className:"meta",begin:/<![a-z]/,end:/>/,contains:[t,i,a,r]}]}]},e.COMMENT(/<!--/,/-->/,{relevance:10}),{begin:/<!\[CDATA\[/,end:/\]\]>/,relevance:10},g,{className:"meta",end:/\?>/,variants:[{begin:/<\?xml/,relevance:10,contains:[a]},{begin:/<\?[a-z][a-z0-9]+/}]},{className:"tag",begin:/<style(?=\s|>)/,end:/>/,keywords:{name:"style"},contains:[c],starts:{end:/<\/style>/,returnEnd:!0,subLanguage:["css","xml"]}},{className:"tag",begin:/<script(?=\s|>)/,end:/>/,keywords:{name:"script"},contains:[c],starts:{end:/<\/script>/,returnEnd:!0,subLanguage:["javascript","handlebars","xml"]}},{className:"tag",begin:/<>|<\/>/},{className:"tag",begin:n.concat(/</,n.lookahead(n.concat(s,n.either(/\/>/,/>/,/\s/)))),end:/\/?>/,contains:[{className:"name",begin:s,relevance:0,starts:c}]},{className:"tag",begin:n.concat(/<\//,n.lookahead(n.concat(s,/>/))),contains:[{className:"name",begin:s,relevance:0},{begin:/>/,relevance:0,endsParent:!0}]}]}}const fn="[A-Za-z$_][0-9A-Za-z$_]*",ti=["as","in","of","if","for","while","finally","var","new","function","do","return","void","else","break","catch","instanceof","with","throw","case","default","try","switch","continue","typeof","delete","let","yield","const","class","debugger","async","await","static","import","from","export","extends"],ii=["true","false","null","undefined","NaN","Infinity"],Bn=["Object","Function","Boolean","Symbol","Math","Date","Number","BigInt","String","RegExp","Array","Float32Array","Float64Array","Int8Array","Uint8Array","Uint8ClampedArray","Int16Array","Int32Array","Uint16Array","Uint32Array","BigInt64Array","BigUint64Array","Set","Map","WeakSet","WeakMap","ArrayBuffer","SharedArrayBuffer","Atomics","DataView","JSON","Promise","Generator","GeneratorFunction","AsyncFunction","Reflect","Proxy","Intl","WebAssembly"],xn=["Error","EvalError","InternalError","RangeError","ReferenceError","SyntaxError","TypeError","URIError"],Un=["setInterval","setTimeout","clearInterval","clearTimeout","require","exports","eval","isFinite","isNaN","parseFloat","parseInt","decodeURI","decodeURIComponent","encodeURI","encodeURIComponent","escape","unescape"],ri=["arguments","this","super","console","window","document","localStorage","sessionStorage","module","global"],si=[].concat(Un,Bn,xn);function ai(e){const n=e.regex,s=(M,{after:R})=>{const B="</"+M[0].slice(1);return M.input.indexOf(B,R)!==-1},f=fn,g={begin:"<>",end:"</>"},t=/<[A-Za-z0-9\\._:-]+\s*\/>/,i={begin:/<[A-Za-z0-9\\._:-]+/,end:/\/[A-Za-z0-9\\._:-]+>|\/>/,isTrulyOpeningTag:(M,R)=>{const B=M[0].length+M.index,F=M.input[B];if(F==="<"||F===","){R.ignoreMatch();return}F===">"&&(s(M,{after:B})||R.ignoreMatch());let q;const Y=M.input.substring(B);if(q=Y.match(/^\s*=/)){R.ignoreMatch();return}if((q=Y.match(/^\s+extends\s+/))&&q.index===0){R.ignoreMatch();return}}},r={$pattern:fn,keyword:ti,literal:ii,built_in:si,"variable.language":ri},a="[0-9](_?[0-9])*",c=`\\.(${a})`,o="0|[1-9](_?[0-9])*|0[0-7]*[89][0-9]*",l={className:"number",variants:[{begin:`(\\b(${o})((${c})|\\.)?|(${c}))[eE][+-]?(${a})\\b`},{begin:`\\b(${o})\\b((${c})\\b|\\.)?|(${c})\\b`},{begin:"\\b(0|[1-9](_?[0-9])*)n\\b"},{begin:"\\b0[xX][0-9a-fA-F](_?[0-9a-fA-F])*n?\\b"},{begin:"\\b0[bB][0-1](_?[0-1])*n?\\b"},{begin:"\\b0[oO][0-7](_?[0-7])*n?\\b"},{begin:"\\b0[0-7]+n?\\b"}],relevance:0},u={className:"subst",begin:"\\$\\{",end:"\\}",keywords:r,contains:[]},h={begin:".?html`",end:"",starts:{end:"`",returnEnd:!1,contains:[e.BACKSLASH_ESCAPE,u],subLanguage:"xml"}},d={begin:".?css`",end:"",starts:{end:"`",returnEnd:!1,contains:[e.BACKSLASH_ESCAPE,u],subLanguage:"css"}},p={begin:".?gql`",end:"",starts:{end:"`",returnEnd:!1,contains:[e.BACKSLASH_ESCAPE,u],subLanguage:"graphql"}},_={className:"string",begin:"`",end:"`",contains:[e.BACKSLASH_ESCAPE,u]},m={className:"comment",variants:[e.COMMENT(/\/\*\*(?!\/)/,"\\*/",{relevance:0,contains:[{begin:"(?=@[A-Za-z]+)",relevance:0,contains:[{className:"doctag",begin:"@[A-Za-z]+"},{className:"type",begin:"\\{",end:"\\}",excludeEnd:!0,excludeBegin:!0,relevance:0},{className:"variable",begin:f+"(?=\\s*(-)|$)",endsParent:!0,relevance:0},{begin:/(?=[^\n])\s/,relevance:0}]}]}),e.C_BLOCK_COMMENT_MODE,e.C_LINE_COMMENT_MODE]},E=[e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,h,d,p,_,{match:/\$\d+/},l];u.contains=E.concat({begin:/\{/,end:/\}/,keywords:r,contains:["self"].concat(E)});const y=[].concat(m,u.contains),T=y.concat([{begin:/(\s*)\(/,end:/\)/,keywords:r,contains:["self"].concat(y)}]),N={className:"params",begin:/(\s*)\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:r,contains:T},S={variants:[{match:[/class/,/\s+/,f,/\s+/,/extends/,/\s+/,n.concat(f,"(",n.concat(/\./,f),")*")],scope:{1:"keyword",3:"title.class",5:"keyword",7:"title.class.inherited"}},{match:[/class/,/\s+/,f],scope:{1:"keyword",3:"title.class"}}]},k={relevance:0,match:n.either(/\bJSON/,/\b[A-Z][a-z]+([A-Z][a-z]*|\d)*/,/\b[A-Z]{2,}([A-Z][a-z]+|\d)+([A-Z][a-z]*)*/,/\b[A-Z]{2,}[a-z]+([A-Z][a-z]+|\d)*([A-Z][a-z]*)*/),className:"title.class",keywords:{_:[...Bn,...xn]}},A={label:"use_strict",className:"meta",relevance:10,begin:/^\s*['"]use (strict|asm)['"]/},L={variants:[{match:[/function/,/\s+/,f,/(?=\s*\()/]},{match:[/function/,/\s*(?=\()/]}],className:{1:"keyword",3:"title.function"},label:"func.def",contains:[N],illegal:/%/},$={relevance:0,match:/\b[A-Z][A-Z_0-9]+\b/,className:"variable.constant"};function x(M){return n.concat("(?!",M.join("|"),")")}const z={match:n.concat(/\b/,x([...Un,"super","import"].map(M=>`${M}\\s*\\(`)),f,n.lookahead(/\s*\(/)),className:"title.function",relevance:0},W={begin:n.concat(/\./,n.lookahead(n.concat(f,/(?![0-9A-Za-z$_(])/))),end:f,excludeBegin:!0,keywords:"prototype",className:"property",relevance:0},ie={match:[/get|set/,/\s+/,f,/(?=\()/],className:{1:"keyword",3:"title.function"},contains:[{begin:/\(\)/},N]},ue="(\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)|"+e.UNDERSCORE_IDENT_RE+")\\s*=>",v={match:[/const|var|let/,/\s+/,f,/\s*/,/=\s*/,/(async\s*)?/,n.lookahead(ue)],keywords:"async",className:{1:"keyword",3:"title.function"},contains:[N]};return{name:"JavaScript",aliases:["js","jsx","mjs","cjs"],keywords:r,exports:{PARAMS_CONTAINS:T,CLASS_REFERENCE:k},illegal:/#(?![$_A-z])/,contains:[e.SHEBANG({label:"shebang",binary:"node",relevance:5}),A,e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,h,d,p,_,m,{match:/\$\d+/},l,k,{className:"attr",begin:f+n.lookahead(":"),relevance:0},v,{begin:"("+e.RE_STARTERS_RE+"|\\b(case|return|throw)\\b)\\s*",keywords:"return throw case",relevance:0,contains:[m,e.REGEXP_MODE,{className:"function",begin:ue,returnBegin:!0,end:"\\s*=>",contains:[{className:"params",variants:[{begin:e.UNDERSCORE_IDENT_RE,relevance:0},{className:null,begin:/\(\s*\)/,skip:!0},{begin:/(\s*)\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:r,contains:T}]}]},{begin:/,/,relevance:0},{match:/\s+/,relevance:0},{variants:[{begin:g.begin,end:g.end},{match:t},{begin:i.begin,"on:begin":i.isTrulyOpeningTag,end:i.end}],subLanguage:"xml",contains:[{begin:i.begin,end:i.end,skip:!0,contains:["self"]}]}]},L,{beginKeywords:"while if switch catch for"},{begin:"\\b(?!function)"+e.UNDERSCORE_IDENT_RE+"\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)\\s*\\{",returnBegin:!0,label:"func.def",contains:[N,e.inherit(e.TITLE_MODE,{begin:f,className:"title.function"})]},{match:/\.\.\./,relevance:0},W,{match:"\\$"+f,relevance:0},{match:[/\bconstructor(?=\s*\()/],className:{1:"title.function"},contains:[N]},z,$,S,ie,{match:/\$[(.]/}]}}function oi(e){const n={className:"attr",begin:/"(\\.|[^\\"\r\n])*"(?=\s*:)/,relevance:1.01},s={match:/[{}[\],:]/,className:"punctuation",relevance:0},f=["true","false","null"],g={scope:"literal",beginKeywords:f.join(" ")};return{name:"JSON",aliases:["jsonc"],keywords:{literal:f},contains:[n,s,e.QUOTE_STRING_MODE,g,e.C_NUMBER_MODE,e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE],illegal:"\\S"}}function li(e){const n="true false yes no null",s="[\\w#;/?:@&=+$,.~*'()[\\]]+",f={className:"attr",variants:[{begin:/\w[\w :()\./-]*:(?=[ \t]|$)/},{begin:/"\w[\w :()\./-]*":(?=[ \t]|$)/},{begin:/'\w[\w :()\./-]*':(?=[ \t]|$)/}]},g={className:"template-variable",variants:[{begin:/\{\{/,end:/\}\}/},{begin:/%\{/,end:/\}/}]},t={className:"string",relevance:0,variants:[{begin:/'/,end:/'/},{begin:/"/,end:/"/},{begin:/\S+/}],contains:[e.BACKSLASH_ESCAPE,g]},i=e.inherit(t,{variants:[{begin:/'/,end:/'/},{begin:/"/,end:/"/},{begin:/[^\s,{}[\]]+/}]}),l={className:"number",begin:"\\b"+"[0-9]{4}(-[0-9][0-9]){0,2}"+"([Tt \\t][0-9][0-9]?(:[0-9][0-9]){2})?"+"(\\.[0-9]*)?"+"([ \\t])*(Z|[-+][0-9][0-9]?(:[0-9][0-9])?)?"+"\\b"},u={end:",",endsWithParent:!0,excludeEnd:!0,keywords:n,relevance:0},h={begin:/\{/,end:/\}/,contains:[u],illegal:"\\n",relevance:0},d={begin:"\\[",end:"\\]",contains:[u],illegal:"\\n",relevance:0},p=[f,{className:"meta",begin:"^---\\s*$",relevance:10},{className:"string",begin:"[\\|>]([1-9]?[+-])?[ ]*\\n( +)[^ ][^\\n]*\\n(\\2[^\\n]+\\n?)*"},{begin:"<%[%=-]?",end:"[%-]?%>",subLanguage:"ruby",excludeBegin:!0,excludeEnd:!0,relevance:0},{className:"type",begin:"!\\w+!"+s},{className:"type",begin:"!<"+s+">"},{className:"type",begin:"!"+s},{className:"type",begin:"!!"+s},{className:"meta",begin:"&"+e.UNDERSCORE_IDENT_RE+"$"},{className:"meta",begin:"\\*"+e.UNDERSCORE_IDENT_RE+"$"},{className:"bullet",begin:"-(?=[ ]|$)",relevance:0},e.HASH_COMMENT_MODE,{beginKeywords:n,keywords:{literal:n}},l,{className:"number",begin:e.C_NUMBER_RE+"\\b",relevance:0},h,d,t],_=[...p];return _.pop(),_.push(i),u.contains=_,{name:"YAML",case_insensitive:!0,aliases:["yml"],contains:p}}function ci(e){return{name:"Plain text",aliases:["text","txt"],disableAutodetect:!0}}function ui(e){const n=e.regex,s=/[\p{XID_Start}_]\p{XID_Continue}*/u,f=["and","as","assert","async","await","break","case","class","continue","def","del","elif","else","except","finally","for","from","global","if","import","in","is","lambda","match","nonlocal|10","not","or","pass","raise","return","try","while","with","yield"],r={$pattern:/[A-Za-z]\w+|__\w+__/,keyword:f,built_in:["__import__","abs","all","any","ascii","bin","bool","breakpoint","bytearray","bytes","callable","chr","classmethod","compile","complex","delattr","dict","dir","divmod","enumerate","eval","exec","filter","float","format","frozenset","getattr","globals","hasattr","hash","help","hex","id","input","int","isinstance","issubclass","iter","len","list","locals","map","max","memoryview","min","next","object","oct","open","ord","pow","print","property","range","repr","reversed","round","set","setattr","slice","sorted","staticmethod","str","sum","super","tuple","type","vars","zip"],literal:["__debug__","Ellipsis","False","None","NotImplemented","True"],type:["Any","Callable","Coroutine","Dict","List","Literal","Generic","Optional","Sequence","Set","Tuple","Type","Union"]},a={className:"meta",begin:/^(>>>|\.\.\.) /},c={className:"subst",begin:/\{/,end:/\}/,keywords:r,illegal:/#/},o={begin:/\{\{/,relevance:0},l={className:"string",contains:[e.BACKSLASH_ESCAPE],variants:[{begin:/([uU]|[bB]|[rR]|[bB][rR]|[rR][bB])?'''/,end:/'''/,contains:[e.BACKSLASH_ESCAPE,a],relevance:10},{begin:/([uU]|[bB]|[rR]|[bB][rR]|[rR][bB])?"""/,end:/"""/,contains:[e.BACKSLASH_ESCAPE,a],relevance:10},{begin:/([fF][rR]|[rR][fF]|[fF])'''/,end:/'''/,contains:[e.BACKSLASH_ESCAPE,a,o,c]},{begin:/([fF][rR]|[rR][fF]|[fF])"""/,end:/"""/,contains:[e.BACKSLASH_ESCAPE,a,o,c]},{begin:/([uU]|[rR])'/,end:/'/,relevance:10},{begin:/([uU]|[rR])"/,end:/"/,relevance:10},{begin:/([bB]|[bB][rR]|[rR][bB])'/,end:/'/},{begin:/([bB]|[bB][rR]|[rR][bB])"/,end:/"/},{begin:/([fF][rR]|[rR][fF]|[fF])'/,end:/'/,contains:[e.BACKSLASH_ESCAPE,o,c]},{begin:/([fF][rR]|[rR][fF]|[fF])"/,end:/"/,contains:[e.BACKSLASH_ESCAPE,o,c]},e.APOS_STRING_MODE,e.QUOTE_STRING_MODE]},u="[0-9](_?[0-9])*",h=`(\\b(${u}))?\\.(${u})|\\b(${u})\\.`,d=`\\b|${f.join("|")}`,p={className:"number",relevance:0,variants:[{begin:`(\\b(${u})|(${h}))[eE][+-]?(${u})[jJ]?(?=${d})`},{begin:`(${h})[jJ]?`},{begin:`\\b([1-9](_?[0-9])*|0+(_?0)*)[lLjJ]?(?=${d})`},{begin:`\\b0[bB](_?[01])+[lL]?(?=${d})`},{begin:`\\b0[oO](_?[0-7])+[lL]?(?=${d})`},{begin:`\\b0[xX](_?[0-9a-fA-F])+[lL]?(?=${d})`},{begin:`\\b(${u})[jJ](?=${d})`}]},_={className:"comment",begin:n.lookahead(/# type:/),end:/$/,keywords:r,contains:[{begin:/# type:/},{begin:/#/,end:/\b\B/,endsWithParent:!0}]},b={className:"params",variants:[{className:"",begin:/\(\s*\)/,skip:!0},{begin:/\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:r,contains:["self",a,p,l,e.HASH_COMMENT_MODE]}]};return c.contains=[l,p,a],{name:"Python",aliases:["py","gyp","ipython"],unicodeRegex:!0,keywords:r,illegal:/(<\/|\?)|=>/,contains:[a,p,{scope:"variable.language",match:/\bself\b/},{beginKeywords:"if",relevance:0},{match:/\bor\b/,scope:"keyword"},l,_,e.HASH_COMMENT_MODE,{match:[/\bdef/,/\s+/,s],scope:{1:"keyword",3:"title.function"},contains:[b]},{variants:[{match:[/\bclass/,/\s+/,s,/\s*/,/\(\s*/,s,/\s*\)/]},{match:[/\bclass/,/\s+/,s]}],scope:{1:"keyword",3:"title.class",6:"title.class.inherited"}},{className:"meta",begin:/^[\t ]*@/,end:/(?=#)|$/,contains:[p,b,l]}]}}var ge="[0-9](_*[0-9])*",Ne=`\\.(${ge})`,Te="[0-9a-fA-F](_*[0-9a-fA-F])*",gn={className:"number",variants:[{begin:`(\\b(${ge})((${Ne})|\\.)?|(${Ne}))[eE][+-]?(${ge})[fFdD]?\\b`},{begin:`\\b(${ge})((${Ne})[fFdD]?\\b|\\.([fFdD]\\b)?)`},{begin:`(${Ne})[fFdD]?\\b`},{begin:`\\b(${ge})[fFdD]\\b`},{begin:`\\b0[xX]((${Te})\\.?|(${Te})?\\.(${Te}))[pP][+-]?(${ge})[fFdD]?\\b`},{begin:"\\b(0|[1-9](_*[0-9])*)[lL]?\\b"},{begin:`\\b0[xX](${Te})[lL]?\\b`},{begin:"\\b0(_*[0-7])*[lL]?\\b"},{begin:"\\b0[bB][01](_*[01])*[lL]?\\b"}],relevance:0};function Pn(e,n,s){return s===-1?"":e.replace(n,f=>Pn(e,n,s-1))}function fi(e){const n=e.regex,s="[À-ʸa-zA-Z_$][À-ʸa-zA-Z_$0-9]*",f=s+Pn("(?:<"+s+"~~~(?:\\s*,\\s*"+s+"~~~)*>)?",/~~~/g,2),a={keyword:["synchronized","abstract","private","var","static","if","const ","for","while","strictfp","finally","protected","import","native","final","void","enum","else","break","transient","catch","instanceof","volatile","case","assert","package","default","public","try","switch","continue","throws","protected","public","private","module","requires","exports","do","sealed","yield","permits","goto"],literal:["false","true","null"],type:["char","boolean","long","float","int","byte","short","double"],built_in:["super","this"]},c={className:"meta",begin:"@"+s,contains:[{begin:/\(/,end:/\)/,contains:["self"]}]},o={className:"params",begin:/\(/,end:/\)/,keywords:a,relevance:0,contains:[e.C_BLOCK_COMMENT_MODE],endsParent:!0};return{name:"Java",aliases:["jsp"],keywords:a,illegal:/<\/|#/,contains:[e.COMMENT("/\\*\\*","\\*/",{relevance:0,contains:[{begin:/\w+@/,relevance:0},{className:"doctag",begin:"@[A-Za-z]+"}]}),{begin:/import java\.[a-z]+\./,keywords:"import",relevance:2},e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE,{begin:/"""/,end:/"""/,className:"string",contains:[e.BACKSLASH_ESCAPE]},e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,{match:[/\b(?:class|interface|enum|extends|implements|new)/,/\s+/,s],className:{1:"keyword",3:"title.class"}},{match:/non-sealed/,scope:"keyword"},{begin:[n.concat(/(?!else)/,s),/\s+/,s,/\s+/,/=(?!=)/],className:{1:"type",3:"variable",5:"operator"}},{begin:[/record/,/\s+/,s],className:{1:"keyword",3:"title.class"},contains:[o,e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE]},{beginKeywords:"new throw return else",relevance:0},{begin:["(?:"+f+"\\s+)",e.UNDERSCORE_IDENT_RE,/\s*(?=\()/],className:{2:"title.function"},keywords:a,contains:[{className:"params",begin:/\(/,end:/\)/,keywords:a,relevance:0,contains:[c,e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,gn,e.C_BLOCK_COMMENT_MODE]},e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE]},gn,c]}}function gi(e){const n=e.regex,s={},f={begin:/\$\{/,end:/\}/,contains:["self",{begin:/:-/,contains:[s]}]};Object.assign(s,{className:"variable",variants:[{begin:n.concat(/\$[\w\d#@][\w\d_]*/,"(?![\\w\\d])(?![$])")},f]});const g={className:"subst",begin:/\$\(/,end:/\)/,contains:[e.BACKSLASH_ESCAPE]},t=e.inherit(e.COMMENT(),{match:[/(^|\s)/,/#.*$/],scope:{2:"comment"}}),i={begin:/<<-?\s*(?=\w+)/,starts:{contains:[e.END_SAME_AS_BEGIN({begin:/(\w+)/,end:/(\w+)/,className:"string"})]}},r={className:"string",begin:/"/,end:/"/,contains:[e.BACKSLASH_ESCAPE,s,g]};g.contains.push(r);const a={match:/\\"/},c={className:"string",begin:/'/,end:/'/},o={match:/\\'/},l={begin:/\$?\(\(/,end:/\)\)/,contains:[{begin:/\d+#[0-9a-f]+/,className:"number"},e.NUMBER_MODE,s]},u=["fish","bash","zsh","sh","csh","ksh","tcsh","dash","scsh"],h=e.SHEBANG({binary:`(${u.join("|")})`,relevance:10}),d={className:"function",begin:/\w[\w\d_]*\s*\(\s*\)\s*\{/,returnBegin:!0,contains:[e.inherit(e.TITLE_MODE,{begin:/\w[\w\d_]*/})],relevance:0},p=["if","then","else","elif","fi","for","while","until","in","do","done","case","esac","function","select"],_=["true","false"],b={match:/(\/[a-z._-]+)+/},m=["break","cd","continue","eval","exec","exit","export","getopts","hash","pwd","readonly","return","shift","test","times","trap","umask","unset"],E=["alias","bind","builtin","caller","command","declare","echo","enable","help","let","local","logout","mapfile","printf","read","readarray","source","sudo","type","typeset","ulimit","unalias"],y=["autoload","bg","bindkey","bye","cap","chdir","clone","comparguments","compcall","compctl","compdescribe","compfiles","compgroups","compquote","comptags","comptry","compvalues","dirs","disable","disown","echotc","echoti","emulate","fc","fg","float","functions","getcap","getln","history","integer","jobs","kill","limit","log","noglob","popd","print","pushd","pushln","rehash","sched","setcap","setopt","stat","suspend","ttyctl","unfunction","unhash","unlimit","unsetopt","vared","wait","whence","where","which","zcompile","zformat","zftp","zle","zmodload","zparseopts","zprof","zpty","zregexparse","zsocket","zstyle","ztcp"],T=["chcon","chgrp","chown","chmod","cp","dd","df","dir","dircolors","ln","ls","mkdir","mkfifo","mknod","mktemp","mv","realpath","rm","rmdir","shred","sync","touch","truncate","vdir","b2sum","base32","base64","cat","cksum","comm","csplit","cut","expand","fmt","fold","head","join","md5sum","nl","numfmt","od","paste","ptx","pr","sha1sum","sha224sum","sha256sum","sha384sum","sha512sum","shuf","sort","split","sum","tac","tail","tr","tsort","unexpand","uniq","wc","arch","basename","chroot","date","dirname","du","echo","env","expr","factor","groups","hostid","id","link","logname","nice","nohup","nproc","pathchk","pinky","printenv","printf","pwd","readlink","runcon","seq","sleep","stat","stdbuf","stty","tee","test","timeout","tty","uname","unlink","uptime","users","who","whoami","yes"];return{name:"Bash",aliases:["sh","zsh"],keywords:{$pattern:/\b[a-z][a-z0-9._-]+\b/,keyword:p,literal:_,built_in:[...m,...E,"set","shopt",...y,...T]},contains:[h,e.SHEBANG(),d,l,t,i,b,r,a,c,o,s]}}function hi(e){const n=e.regex,s=e.COMMENT("--","$"),f={className:"string",variants:[{begin:/'/,end:/'/,contains:[{begin:/''/}]}]},g={begin:/"/,end:/"/,contains:[{begin:/""/}]},t=["true","false","unknown"],i=["double precision","large object","with timezone","without timezone"],r=["bigint","binary","blob","boolean","char","character","clob","date","dec","decfloat","decimal","float","int","integer","interval","nchar","nclob","national","numeric","real","row","smallint","time","timestamp","varchar","varying","varbinary"],a=["add","asc","collation","desc","final","first","last","view"],c=["abs","acos","all","allocate","alter","and","any","are","array","array_agg","array_max_cardinality","as","asensitive","asin","asymmetric","at","atan","atomic","authorization","avg","begin","begin_frame","begin_partition","between","bigint","binary","blob","boolean","both","by","call","called","cardinality","cascaded","case","cast","ceil","ceiling","char","char_length","character","character_length","check","classifier","clob","close","coalesce","collate","collect","column","commit","condition","connect","constraint","contains","convert","copy","corr","corresponding","cos","cosh","count","covar_pop","covar_samp","create","cross","cube","cume_dist","current","current_catalog","current_date","current_default_transform_group","current_path","current_role","current_row","current_schema","current_time","current_timestamp","current_path","current_role","current_transform_group_for_type","current_user","cursor","cycle","date","day","deallocate","dec","decimal","decfloat","declare","default","define","delete","dense_rank","deref","describe","deterministic","disconnect","distinct","double","drop","dynamic","each","element","else","empty","end","end_frame","end_partition","end-exec","equals","escape","every","except","exec","execute","exists","exp","external","extract","false","fetch","filter","first_value","float","floor","for","foreign","frame_row","free","from","full","function","fusion","get","global","grant","group","grouping","groups","having","hold","hour","identity","in","indicator","initial","inner","inout","insensitive","insert","int","integer","intersect","intersection","interval","into","is","join","json_array","json_arrayagg","json_exists","json_object","json_objectagg","json_query","json_table","json_table_primitive","json_value","lag","language","large","last_value","lateral","lead","leading","left","like","like_regex","listagg","ln","local","localtime","localtimestamp","log","log10","lower","match","match_number","match_recognize","matches","max","member","merge","method","min","minute","mod","modifies","module","month","multiset","national","natural","nchar","nclob","new","no","none","normalize","not","nth_value","ntile","null","nullif","numeric","octet_length","occurrences_regex","of","offset","old","omit","on","one","only","open","or","order","out","outer","over","overlaps","overlay","parameter","partition","pattern","per","percent","percent_rank","percentile_cont","percentile_disc","period","portion","position","position_regex","power","precedes","precision","prepare","primary","procedure","ptf","range","rank","reads","real","recursive","ref","references","referencing","regr_avgx","regr_avgy","regr_count","regr_intercept","regr_r2","regr_slope","regr_sxx","regr_sxy","regr_syy","release","result","return","returns","revoke","right","rollback","rollup","row","row_number","rows","running","savepoint","scope","scroll","search","second","seek","select","sensitive","session_user","set","show","similar","sin","sinh","skip","smallint","some","specific","specifictype","sql","sqlexception","sqlstate","sqlwarning","sqrt","start","static","stddev_pop","stddev_samp","submultiset","subset","substring","substring_regex","succeeds","sum","symmetric","system","system_time","system_user","table","tablesample","tan","tanh","then","time","timestamp","timezone_hour","timezone_minute","to","trailing","translate","translate_regex","translation","treat","trigger","trim","trim_array","true","truncate","uescape","union","unique","unknown","unnest","update","upper","user","using","value","values","value_of","var_pop","var_samp","varbinary","varchar","varying","versioning","when","whenever","where","width_bucket","window","with","within","without","year"],o=["abs","acos","array_agg","asin","atan","avg","cast","ceil","ceiling","coalesce","corr","cos","cosh","count","covar_pop","covar_samp","cume_dist","dense_rank","deref","element","exp","extract","first_value","floor","json_array","json_arrayagg","json_exists","json_object","json_objectagg","json_query","json_table","json_table_primitive","json_value","lag","last_value","lead","listagg","ln","log","log10","lower","max","min","mod","nth_value","ntile","nullif","percent_rank","percentile_cont","percentile_disc","position","position_regex","power","rank","regr_avgx","regr_avgy","regr_count","regr_intercept","regr_r2","regr_slope","regr_sxx","regr_sxy","regr_syy","row_number","sin","sinh","sqrt","stddev_pop","stddev_samp","substring","substring_regex","sum","tan","tanh","translate","translate_regex","treat","trim","trim_array","unnest","upper","value_of","var_pop","var_samp","width_bucket"],l=["current_catalog","current_date","current_default_transform_group","current_path","current_role","current_schema","current_transform_group_for_type","current_user","session_user","system_time","system_user","current_time","localtime","current_timestamp","localtimestamp"],u=["create table","insert into","primary key","foreign key","not null","alter table","add constraint","grouping sets","on overflow","character set","respect nulls","ignore nulls","nulls first","nulls last","depth first","breadth first"],h=o,d=[...c,...a].filter(E=>!o.includes(E)),p={className:"variable",begin:/@[a-z0-9][a-z0-9_]*/},_={className:"operator",begin:/[-+*/=%^~]|&&?|\|\|?|!=?|<(?:=>?|<|>)?|>[>=]?/,relevance:0},b={begin:n.concat(/\b/,n.either(...h),/\s*\(/),relevance:0,keywords:{built_in:h}};function m(E,{exceptions:y,when:T}={}){const N=T;return y=y||[],E.map(S=>S.match(/\|\d+$/)||y.includes(S)?S:N(S)?`${S}|0`:S)}return{name:"SQL",case_insensitive:!0,illegal:/[{}]|<\//,keywords:{$pattern:/\b[\w\.]+/,keyword:m(d,{when:E=>E.length<3}),literal:t,type:r,built_in:l},contains:[{begin:n.either(...u),relevance:0,keywords:{$pattern:/[\w\.]+/,keyword:d.concat(u),literal:t,type:r}},{className:"type",begin:n.either(...i)},b,p,f,g,e.C_NUMBER_MODE,e.C_BLOCK_COMMENT_MODE,s,_]}}j.registerLanguage("xml",ni);j.registerLanguage("javascript",ai);j.registerLanguage("json",oi);j.registerLanguage("yaml",li);j.registerLanguage("plaintext",ci);j.registerLanguage("python",ui);j.registerLanguage("java",fi);j.registerLanguage("bash",gi);j.registerLanguage("sql",hi);var D=(e=>(e.EQUAL="equal",e.DELETE="removed",e.ADD="added",e.EMPTY="empty",e))(D||{});const J="<code-diff-modified>",ee="</code-diff-modified>",di=1e4,Z=1e3,hn=J.replace("<","&lt;").replace(">","&gt;"),dn=ee.replace("<","&lt;").replace(">","&gt;");function pi(e){const n={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"};return e.replace(/[&<>"']/g,s=>n[s])}function se(e){return e===void 0?D.EQUAL:e.added?D.ADD:e.removed?D.DELETE:D.EQUAL}function Fn(e,n,s="word",f=!1){if(typeof e=="undefined"||typeof n=="undefined")return[e,n];if(!f&&e.length+n.length>di)return[e,n];const t=(s==="char"?et:tt)(e,n),i=t.filter(a=>se(a)!==D.ADD).map(a=>se(a)===D.DELETE?`${J}${a.value}${ee}`:a.value).join(""),r=t.filter(a=>se(a)!==D.DELETE).map(a=>se(a)===D.ADD?`${J}${a.value}${ee}`:a.value).join("");return[i,r]}function Hn(e,n){if(e===n)return e?[{count:e.replace(/\n$/,"").split(`
9
9
  `).length,value:e}]:[];const s=e.endsWith(`
10
10
  `),f=n.endsWith(`
11
- `);s!==f&&(s?e=e.slice(0,-1):n=n.slice(0,-1));let g;if(e.length+n.length>=1e5&&e.includes(`
11
+ `);s!==f&&(s?e=e.slice(0,-1):n=n.slice(0,-1)),e&&(e+=`
12
+ `),n&&(n+=`
13
+ `);let g;if(e.length+n.length>=1e5&&e.includes(`
12
14
  `)&&n.includes(`
13
15
  `)){const t=e?e.replace(/\n$/,"").split(`
14
16
  `):[],i=n?n.replace(/\n$/,"").split(`
@@ -4676,7 +4676,9 @@ function Gn(e, n) {
4676
4676
  const s = e.endsWith(`
4677
4677
  `), f = n.endsWith(`
4678
4678
  `);
4679
- s !== f && (s ? e = e.slice(0, -1) : n = n.slice(0, -1));
4679
+ s !== f && (s ? e = e.slice(0, -1) : n = n.slice(0, -1)), e && (e += `
4680
+ `), n && (n += `
4681
+ `);
4680
4682
  let g;
4681
4683
  if (e.length + n.length >= 1e5 && e.includes(`
4682
4684
  `) && n.includes(`
@@ -8,7 +8,9 @@
8
8
  https://github.com/highlightjs/highlight.js/issues/2277`),H=v,B=M),R===void 0&&(R=!0);const q={code:B,language:H};oe("before:highlight",q);const Y=q.result?q.result:l(q.language,q.code,R);return Y.code=q.code,oe("after:highlight",Y),Y}function l(v,M,R,B){const H=Object.create(null);function q(w,L){return w.keywords[L]}function Y(){if(!O.keywords){G.addText(F);return}let w=0;O.keywordPatternRe.lastIndex=0;let L=O.keywordPatternRe.exec(F),I="";for(;L;){I+=F.substring(w,L.index);const U=ee.case_insensitive?L[0].toLowerCase():L[0],K=q(O,U);if(K){const[re,ti]=K;if(G.addText(I),I="",H[U]=(H[U]||0)+1,H[U]<=Kt&&(Ce+=ti),re.startsWith("_"))I+=L[0];else{const ri=ee.classNameAliases[re]||re;V(L[0],ri)}}else I+=L[0];w=O.keywordPatternRe.lastIndex,L=O.keywordPatternRe.exec(F)}I+=F.substring(w),G.addText(I)}function De(){if(F==="")return;let w=null;if(typeof O.subLanguage=="string"){if(!n[O.subLanguage]){G.addText(F);return}w=l(O.subLanguage,F,!0,zn[O.subLanguage]),zn[O.subLanguage]=w._top}else w=h(F,O.subLanguage.length?O.subLanguage:null);O.relevance>0&&(Ce+=w.relevance),G.__addSublanguage(w._emitter,w.language)}function Q(){O.subLanguage!=null?De():Y(),F=""}function V(w,L){w!==""&&(G.startScope(L),G.addText(w),G.endScope())}function Un(w,L){let I=1;const U=L.length-1;for(;I<=U;){if(!w._emit[I]){I++;continue}const K=ee.classNameAliases[w[I]]||w[I],re=L[I];K?V(re,K):(F=re,Y(),F=""),I++}}function Pn(w,L){return w.scope&&typeof w.scope=="string"&&G.openNode(ee.classNameAliases[w.scope]||w.scope),w.beginScope&&(w.beginScope._wrap?(V(F,ee.classNameAliases[w.beginScope._wrap]||w.beginScope._wrap),F=""):w.beginScope._multi&&(Un(w.beginScope,L),F="")),O=Object.create(w,{parent:{value:O}}),O}function Fn(w,L,I){let U=ot(w.endRe,I);if(U){if(w["on:end"]){const K=new Ve(w);w["on:end"](L,K),K.isMatchIgnored&&(U=!1)}if(U){for(;w.endsParent&&w.parent;)w=w.parent;return w}}if(w.endsWithParent)return Fn(w.parent,L,I)}function Xr(w){return O.matcher.regexIndex===0?(F+=w[0],1):(je=!0,0)}function Jr(w){const L=w[0],I=w.rule,U=new Ve(I),K=[I.__beforeBegin,I["on:begin"]];for(const re of K)if(re&&(re(w,U),U.isMatchIgnored))return Xr(L);return I.skip?F+=L:(I.excludeBegin&&(F+=L),Q(),!I.returnBegin&&!I.excludeBegin&&(F=L)),Pn(I,w),I.returnBegin?0:L.length}function Vr(w){const L=w[0],I=M.substring(w.index),U=Fn(O,w,I);if(!U)return _n;const K=O;O.endScope&&O.endScope._wrap?(Q(),V(L,O.endScope._wrap)):O.endScope&&O.endScope._multi?(Q(),Un(O.endScope,w)):K.skip?F+=L:(K.returnEnd||K.excludeEnd||(F+=L),Q(),K.excludeEnd&&(F=L));do O.scope&&G.closeNode(),!O.skip&&!O.subLanguage&&(Ce+=O.relevance),O=O.parent;while(O!==U.parent);return U.starts&&Pn(U.starts,w),K.returnEnd?0:L.length}function ei(){const w=[];for(let L=O;L!==ee;L=L.parent)L.scope&&w.unshift(L.scope);w.forEach(L=>G.openNode(L))}let Le={};function Hn(w,L){const I=L&&L[0];if(F+=w,I==null)return Q(),0;if(Le.type==="begin"&&L.type==="end"&&Le.index===L.index&&I===""){if(F+=M.slice(L.index,L.index+1),!g){const U=new Error(`0 width match regex (${v})`);throw U.languageName=v,U.badRule=Le.rule,U}return 1}if(Le=L,L.type==="begin")return Jr(L);if(L.type==="illegal"&&!R){const U=new Error('Illegal lexeme "'+I+'" for mode "'+(O.scope||"<unnamed>")+'"');throw U.mode=O,U}else if(L.type==="end"){const U=Vr(L);if(U!==_n)return U}if(L.type==="illegal"&&I==="")return 1;if(Qe>1e5&&Qe>L.index*3)throw new Error("potential infinite loop, way more iterations than matches");return F+=I,I.length}const ee=N(v);if(!ee)throw ce(t.replace("{}",v)),new Error('Unknown language: "'+v+'"');const ni=Ft(ee);let qe="",O=B||ni;const zn={},G=new i.__emitter(i);ei();let F="",Ce=0,ue=0,Qe=0,je=!1;try{if(ee.__emitTokens)ee.__emitTokens(M,G);else{for(O.matcher.considerAll();;){Qe++,je?je=!1:O.matcher.considerAll(),O.matcher.lastIndex=ue;const w=O.matcher.exec(M);if(!w)break;const L=M.substring(ue,w.index),I=Hn(L,w);ue=w.index+I}Hn(M.substring(ue))}return G.finalize(),qe=G.toHTML(),{language:v,value:qe,relevance:Ce,illegal:!1,_emitter:G,_top:O}}catch(w){if(w.message&&w.message.includes("Illegal"))return{language:v,value:Fe(M),illegal:!0,relevance:0,_illegalBy:{message:w.message,index:ue,context:M.slice(ue-100,ue+100),mode:w.mode,resultSoFar:qe},_emitter:G};if(g)return{language:v,value:Fe(M),illegal:!1,relevance:0,errorRaised:w,_emitter:G,_top:O};throw w}}function u(v){const M={value:Fe(v),illegal:!1,relevance:0,_top:r,_emitter:new i.__emitter(i)};return M._emitter.addText(v),M}function h(v,M){M=M||i.languages||Object.keys(n);const R=u(v),B=M.filter(N).filter($).map(Q=>l(Q,v,!1));B.unshift(R);const H=B.sort((Q,V)=>{if(Q.relevance!==V.relevance)return V.relevance-Q.relevance;if(Q.language&&V.language){if(N(Q.language).supersetOf===V.language)return 1;if(N(V.language).supersetOf===Q.language)return-1}return 0}),[q,Y]=H,De=q;return De.secondBest=Y,De}function d(v,M,R){const B=M&&s[M]||R;v.classList.add("hljs"),v.classList.add(`language-${B}`)}function p(v){let M=null;const R=c(v);if(a(R))return;if(oe("before:highlightElement",{el:v,language:R}),v.dataset.highlighted){console.log("Element previously highlighted. To highlight again, first unset `dataset.highlighted`.",v);return}if(v.children.length>0&&(i.ignoreUnescapedHTML||(console.warn("One of your code blocks includes unescaped HTML. This is a potentially serious security risk."),console.warn("https://github.com/highlightjs/highlight.js/wiki/security"),console.warn("The element with unescaped HTML:"),console.warn(v)),i.throwUnescapedHTML))throw new Gt("One of your code blocks includes unescaped HTML.",v.innerHTML);M=v;const B=M.textContent,H=R?o(B,{language:R,ignoreIllegals:!0}):h(B);v.innerHTML=H.value,v.dataset.highlighted="yes",d(v,R,H.language),v.result={language:H.language,re:H.relevance,relevance:H.relevance},H.secondBest&&(v.secondBest={language:H.secondBest.language,relevance:H.secondBest.relevance}),oe("after:highlightElement",{el:v,result:H,text:B})}function _(v){i=pn(i,v)}const b=()=>{y(),fe("10.6.0","initHighlighting() deprecated. Use highlightAll() now.")};function m(){y(),fe("10.6.0","initHighlightingOnLoad() deprecated. Use highlightAll() now.")}let E=!1;function y(){if(document.readyState==="loading"){E=!0;return}document.querySelectorAll(i.cssSelector).forEach(p)}function A(){E&&y()}typeof window!="undefined"&&window.addEventListener&&window.addEventListener("DOMContentLoaded",A,!1);function T(v,M){let R=null;try{R=M(e)}catch(B){if(ce("Language definition for '{}' could not be registered.".replace("{}",v)),g)ce(B);else throw B;R=r}R.name||(R.name=v),n[v]=R,R.rawDefinition=M.bind(null,e),R.aliases&&C(R.aliases,{languageName:v})}function D(v){delete n[v];for(const M of Object.keys(s))s[M]===v&&delete s[M]}function k(){return Object.keys(n)}function N(v){return v=(v||"").toLowerCase(),n[v]||n[s[v]]}function C(v,{languageName:M}){typeof v=="string"&&(v=[v]),v.forEach(R=>{s[R.toLowerCase()]=M})}function $(v){const M=N(v);return M&&!M.disableAutodetect}function x(v){v["before:highlightBlock"]&&!v["before:highlightElement"]&&(v["before:highlightElement"]=M=>{v["before:highlightBlock"](Object.assign({block:M.el},M))}),v["after:highlightBlock"]&&!v["after:highlightElement"]&&(v["after:highlightElement"]=M=>{v["after:highlightBlock"](Object.assign({block:M.el},M))})}function z(v){x(v),f.push(v)}function W(v){const M=f.indexOf(v);M!==-1&&f.splice(M,1)}function oe(v,M){const R=v;f.forEach(function(B){B[R]&&B[R](M)})}function de(v){return fe("10.7.0","highlightBlock will be removed entirely in v12.0"),fe("10.7.0","Please use highlightElement now."),p(v)}Object.assign(e,{highlight:o,highlightAuto:h,highlightAll:y,highlightElement:p,highlightBlock:de,configure:_,initHighlighting:b,initHighlightingOnLoad:m,registerLanguage:T,unregisterLanguage:D,listLanguages:k,getLanguage:N,registerAliases:C,autoDetection:$,inherit:pn,addPlugin:z,removePlugin:W}),e.debugMode=function(){g=!1},e.safeMode=function(){g=!0},e.versionString=zt,e.regex={concat:le,lookahead:rn,either:xe,optional:st,anyNumberOfTimes:it};for(const v in Ne)typeof Ne[v]=="object"&&Je(Ne[v]);return Object.assign(e,Ne),e},ge=bn({});ge.newInstance=()=>bn({});var Wt=ge;ge.HighlightJS=ge,ge.default=ge;const j=Vn(Wt);function qt(e){const n=e.regex,s=n.concat(/[\p{L}_]/u,n.optional(/[\p{L}0-9_.-]*:/u),/[\p{L}0-9_.-]*/u),f=/[\p{L}0-9._:-]+/u,g={className:"symbol",begin:/&[a-z]+;|&#[0-9]+;|&#x[a-f0-9]+;/},t={begin:/\s/,contains:[{className:"keyword",begin:/#?[a-z_][a-z1-9_-]+/,illegal:/\n/}]},r=e.inherit(t,{begin:/\(/,end:/\)/}),i=e.inherit(e.APOS_STRING_MODE,{className:"string"}),a=e.inherit(e.QUOTE_STRING_MODE,{className:"string"}),c={endsWithParent:!0,illegal:/</,relevance:0,contains:[{className:"attr",begin:f,relevance:0},{begin:/=\s*/,relevance:0,contains:[{className:"string",endsParent:!0,variants:[{begin:/"/,end:/"/,contains:[g]},{begin:/'/,end:/'/,contains:[g]},{begin:/[^\s"'=<>`]+/}]}]}]};return{name:"HTML, XML",aliases:["html","xhtml","rss","atom","xjb","xsd","xsl","plist","wsf","svg"],case_insensitive:!0,unicodeRegex:!0,contains:[{className:"meta",begin:/<![a-z]/,end:/>/,relevance:10,contains:[t,a,i,r,{begin:/\[/,end:/\]/,contains:[{className:"meta",begin:/<![a-z]/,end:/>/,contains:[t,r,a,i]}]}]},e.COMMENT(/<!--/,/-->/,{relevance:10}),{begin:/<!\[CDATA\[/,end:/\]\]>/,relevance:10},g,{className:"meta",end:/\?>/,variants:[{begin:/<\?xml/,relevance:10,contains:[a]},{begin:/<\?[a-z][a-z0-9]+/}]},{className:"tag",begin:/<style(?=\s|>)/,end:/>/,keywords:{name:"style"},contains:[c],starts:{end:/<\/style>/,returnEnd:!0,subLanguage:["css","xml"]}},{className:"tag",begin:/<script(?=\s|>)/,end:/>/,keywords:{name:"script"},contains:[c],starts:{end:/<\/script>/,returnEnd:!0,subLanguage:["javascript","handlebars","xml"]}},{className:"tag",begin:/<>|<\/>/},{className:"tag",begin:n.concat(/</,n.lookahead(n.concat(s,n.either(/\/>/,/>/,/\s/)))),end:/\/?>/,contains:[{className:"name",begin:s,relevance:0,starts:c}]},{className:"tag",begin:n.concat(/<\//,n.lookahead(n.concat(s,/>/))),contains:[{className:"name",begin:s,relevance:0},{begin:/>/,relevance:0,endsParent:!0}]}]}}const vn="[A-Za-z$_][0-9A-Za-z$_]*",Qt=["as","in","of","if","for","while","finally","var","new","function","do","return","void","else","break","catch","instanceof","with","throw","case","default","try","switch","continue","typeof","delete","let","yield","const","class","debugger","async","await","static","import","from","export","extends"],jt=["true","false","null","undefined","NaN","Infinity"],mn=["Object","Function","Boolean","Symbol","Math","Date","Number","BigInt","String","RegExp","Array","Float32Array","Float64Array","Int8Array","Uint8Array","Uint8ClampedArray","Int16Array","Int32Array","Uint16Array","Uint32Array","BigInt64Array","BigUint64Array","Set","Map","WeakSet","WeakMap","ArrayBuffer","SharedArrayBuffer","Atomics","DataView","JSON","Promise","Generator","GeneratorFunction","AsyncFunction","Reflect","Proxy","Intl","WebAssembly"],En=["Error","EvalError","InternalError","RangeError","ReferenceError","SyntaxError","TypeError","URIError"],yn=["setInterval","setTimeout","clearInterval","clearTimeout","require","exports","eval","isFinite","isNaN","parseFloat","parseInt","decodeURI","decodeURIComponent","encodeURI","encodeURIComponent","escape","unescape"],Zt=["arguments","this","super","console","window","document","localStorage","sessionStorage","module","global"],Yt=[].concat(yn,mn,En);function Xt(e){const n=e.regex,s=(M,{after:R})=>{const B="</"+M[0].slice(1);return M.input.indexOf(B,R)!==-1},f=vn,g={begin:"<>",end:"</>"},t=/<[A-Za-z0-9\\._:-]+\s*\/>/,r={begin:/<[A-Za-z0-9\\._:-]+/,end:/\/[A-Za-z0-9\\._:-]+>|\/>/,isTrulyOpeningTag:(M,R)=>{const B=M[0].length+M.index,H=M.input[B];if(H==="<"||H===","){R.ignoreMatch();return}H===">"&&(s(M,{after:B})||R.ignoreMatch());let q;const Y=M.input.substring(B);if(q=Y.match(/^\s*=/)){R.ignoreMatch();return}if((q=Y.match(/^\s+extends\s+/))&&q.index===0){R.ignoreMatch();return}}},i={$pattern:vn,keyword:Qt,literal:jt,built_in:Yt,"variable.language":Zt},a="[0-9](_?[0-9])*",c=`\\.(${a})`,o="0|[1-9](_?[0-9])*|0[0-7]*[89][0-9]*",l={className:"number",variants:[{begin:`(\\b(${o})((${c})|\\.)?|(${c}))[eE][+-]?(${a})\\b`},{begin:`\\b(${o})\\b((${c})\\b|\\.)?|(${c})\\b`},{begin:"\\b(0|[1-9](_?[0-9])*)n\\b"},{begin:"\\b0[xX][0-9a-fA-F](_?[0-9a-fA-F])*n?\\b"},{begin:"\\b0[bB][0-1](_?[0-1])*n?\\b"},{begin:"\\b0[oO][0-7](_?[0-7])*n?\\b"},{begin:"\\b0[0-7]+n?\\b"}],relevance:0},u={className:"subst",begin:"\\$\\{",end:"\\}",keywords:i,contains:[]},h={begin:".?html`",end:"",starts:{end:"`",returnEnd:!1,contains:[e.BACKSLASH_ESCAPE,u],subLanguage:"xml"}},d={begin:".?css`",end:"",starts:{end:"`",returnEnd:!1,contains:[e.BACKSLASH_ESCAPE,u],subLanguage:"css"}},p={begin:".?gql`",end:"",starts:{end:"`",returnEnd:!1,contains:[e.BACKSLASH_ESCAPE,u],subLanguage:"graphql"}},_={className:"string",begin:"`",end:"`",contains:[e.BACKSLASH_ESCAPE,u]},m={className:"comment",variants:[e.COMMENT(/\/\*\*(?!\/)/,"\\*/",{relevance:0,contains:[{begin:"(?=@[A-Za-z]+)",relevance:0,contains:[{className:"doctag",begin:"@[A-Za-z]+"},{className:"type",begin:"\\{",end:"\\}",excludeEnd:!0,excludeBegin:!0,relevance:0},{className:"variable",begin:f+"(?=\\s*(-)|$)",endsParent:!0,relevance:0},{begin:/(?=[^\n])\s/,relevance:0}]}]}),e.C_BLOCK_COMMENT_MODE,e.C_LINE_COMMENT_MODE]},E=[e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,h,d,p,_,{match:/\$\d+/},l];u.contains=E.concat({begin:/\{/,end:/\}/,keywords:i,contains:["self"].concat(E)});const y=[].concat(m,u.contains),A=y.concat([{begin:/(\s*)\(/,end:/\)/,keywords:i,contains:["self"].concat(y)}]),T={className:"params",begin:/(\s*)\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:i,contains:A},D={variants:[{match:[/class/,/\s+/,f,/\s+/,/extends/,/\s+/,n.concat(f,"(",n.concat(/\./,f),")*")],scope:{1:"keyword",3:"title.class",5:"keyword",7:"title.class.inherited"}},{match:[/class/,/\s+/,f],scope:{1:"keyword",3:"title.class"}}]},k={relevance:0,match:n.either(/\bJSON/,/\b[A-Z][a-z]+([A-Z][a-z]*|\d)*/,/\b[A-Z]{2,}([A-Z][a-z]+|\d)+([A-Z][a-z]*)*/,/\b[A-Z]{2,}[a-z]+([A-Z][a-z]+|\d)*([A-Z][a-z]*)*/),className:"title.class",keywords:{_:[...mn,...En]}},N={label:"use_strict",className:"meta",relevance:10,begin:/^\s*['"]use (strict|asm)['"]/},C={variants:[{match:[/function/,/\s+/,f,/(?=\s*\()/]},{match:[/function/,/\s*(?=\()/]}],className:{1:"keyword",3:"title.function"},label:"func.def",contains:[T],illegal:/%/},$={relevance:0,match:/\b[A-Z][A-Z_0-9]+\b/,className:"variable.constant"};function x(M){return n.concat("(?!",M.join("|"),")")}const z={match:n.concat(/\b/,x([...yn,"super","import"].map(M=>`${M}\\s*\\(`)),f,n.lookahead(/\s*\(/)),className:"title.function",relevance:0},W={begin:n.concat(/\./,n.lookahead(n.concat(f,/(?![0-9A-Za-z$_(])/))),end:f,excludeBegin:!0,keywords:"prototype",className:"property",relevance:0},oe={match:[/get|set/,/\s+/,f,/(?=\()/],className:{1:"keyword",3:"title.function"},contains:[{begin:/\(\)/},T]},de="(\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)|"+e.UNDERSCORE_IDENT_RE+")\\s*=>",v={match:[/const|var|let/,/\s+/,f,/\s*/,/=\s*/,/(async\s*)?/,n.lookahead(de)],keywords:"async",className:{1:"keyword",3:"title.function"},contains:[T]};return{name:"JavaScript",aliases:["js","jsx","mjs","cjs"],keywords:i,exports:{PARAMS_CONTAINS:A,CLASS_REFERENCE:k},illegal:/#(?![$_A-z])/,contains:[e.SHEBANG({label:"shebang",binary:"node",relevance:5}),N,e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,h,d,p,_,m,{match:/\$\d+/},l,k,{className:"attr",begin:f+n.lookahead(":"),relevance:0},v,{begin:"("+e.RE_STARTERS_RE+"|\\b(case|return|throw)\\b)\\s*",keywords:"return throw case",relevance:0,contains:[m,e.REGEXP_MODE,{className:"function",begin:de,returnBegin:!0,end:"\\s*=>",contains:[{className:"params",variants:[{begin:e.UNDERSCORE_IDENT_RE,relevance:0},{className:null,begin:/\(\s*\)/,skip:!0},{begin:/(\s*)\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:i,contains:A}]}]},{begin:/,/,relevance:0},{match:/\s+/,relevance:0},{variants:[{begin:g.begin,end:g.end},{match:t},{begin:r.begin,"on:begin":r.isTrulyOpeningTag,end:r.end}],subLanguage:"xml",contains:[{begin:r.begin,end:r.end,skip:!0,contains:["self"]}]}]},C,{beginKeywords:"while if switch catch for"},{begin:"\\b(?!function)"+e.UNDERSCORE_IDENT_RE+"\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)\\s*\\{",returnBegin:!0,label:"func.def",contains:[T,e.inherit(e.TITLE_MODE,{begin:f,className:"title.function"})]},{match:/\.\.\./,relevance:0},W,{match:"\\$"+f,relevance:0},{match:[/\bconstructor(?=\s*\()/],className:{1:"title.function"},contains:[T]},z,$,D,oe,{match:/\$[(.]/}]}}function Jt(e){const n={className:"attr",begin:/"(\\.|[^\\"\r\n])*"(?=\s*:)/,relevance:1.01},s={match:/[{}[\],:]/,className:"punctuation",relevance:0},f=["true","false","null"],g={scope:"literal",beginKeywords:f.join(" ")};return{name:"JSON",aliases:["jsonc"],keywords:{literal:f},contains:[n,s,e.QUOTE_STRING_MODE,g,e.C_NUMBER_MODE,e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE],illegal:"\\S"}}function Vt(e){const n="true false yes no null",s="[\\w#;/?:@&=+$,.~*'()[\\]]+",f={className:"attr",variants:[{begin:/\w[\w :()\./-]*:(?=[ \t]|$)/},{begin:/"\w[\w :()\./-]*":(?=[ \t]|$)/},{begin:/'\w[\w :()\./-]*':(?=[ \t]|$)/}]},g={className:"template-variable",variants:[{begin:/\{\{/,end:/\}\}/},{begin:/%\{/,end:/\}/}]},t={className:"string",relevance:0,variants:[{begin:/'/,end:/'/},{begin:/"/,end:/"/},{begin:/\S+/}],contains:[e.BACKSLASH_ESCAPE,g]},r=e.inherit(t,{variants:[{begin:/'/,end:/'/},{begin:/"/,end:/"/},{begin:/[^\s,{}[\]]+/}]}),l={className:"number",begin:"\\b"+"[0-9]{4}(-[0-9][0-9]){0,2}"+"([Tt \\t][0-9][0-9]?(:[0-9][0-9]){2})?"+"(\\.[0-9]*)?"+"([ \\t])*(Z|[-+][0-9][0-9]?(:[0-9][0-9])?)?"+"\\b"},u={end:",",endsWithParent:!0,excludeEnd:!0,keywords:n,relevance:0},h={begin:/\{/,end:/\}/,contains:[u],illegal:"\\n",relevance:0},d={begin:"\\[",end:"\\]",contains:[u],illegal:"\\n",relevance:0},p=[f,{className:"meta",begin:"^---\\s*$",relevance:10},{className:"string",begin:"[\\|>]([1-9]?[+-])?[ ]*\\n( +)[^ ][^\\n]*\\n(\\2[^\\n]+\\n?)*"},{begin:"<%[%=-]?",end:"[%-]?%>",subLanguage:"ruby",excludeBegin:!0,excludeEnd:!0,relevance:0},{className:"type",begin:"!\\w+!"+s},{className:"type",begin:"!<"+s+">"},{className:"type",begin:"!"+s},{className:"type",begin:"!!"+s},{className:"meta",begin:"&"+e.UNDERSCORE_IDENT_RE+"$"},{className:"meta",begin:"\\*"+e.UNDERSCORE_IDENT_RE+"$"},{className:"bullet",begin:"-(?=[ ]|$)",relevance:0},e.HASH_COMMENT_MODE,{beginKeywords:n,keywords:{literal:n}},l,{className:"number",begin:e.C_NUMBER_RE+"\\b",relevance:0},h,d,t],_=[...p];return _.pop(),_.push(r),u.contains=_,{name:"YAML",case_insensitive:!0,aliases:["yml"],contains:p}}function er(e){return{name:"Plain text",aliases:["text","txt"],disableAutodetect:!0}}function nr(e){const n=e.regex,s=/[\p{XID_Start}_]\p{XID_Continue}*/u,f=["and","as","assert","async","await","break","case","class","continue","def","del","elif","else","except","finally","for","from","global","if","import","in","is","lambda","match","nonlocal|10","not","or","pass","raise","return","try","while","with","yield"],i={$pattern:/[A-Za-z]\w+|__\w+__/,keyword:f,built_in:["__import__","abs","all","any","ascii","bin","bool","breakpoint","bytearray","bytes","callable","chr","classmethod","compile","complex","delattr","dict","dir","divmod","enumerate","eval","exec","filter","float","format","frozenset","getattr","globals","hasattr","hash","help","hex","id","input","int","isinstance","issubclass","iter","len","list","locals","map","max","memoryview","min","next","object","oct","open","ord","pow","print","property","range","repr","reversed","round","set","setattr","slice","sorted","staticmethod","str","sum","super","tuple","type","vars","zip"],literal:["__debug__","Ellipsis","False","None","NotImplemented","True"],type:["Any","Callable","Coroutine","Dict","List","Literal","Generic","Optional","Sequence","Set","Tuple","Type","Union"]},a={className:"meta",begin:/^(>>>|\.\.\.) /},c={className:"subst",begin:/\{/,end:/\}/,keywords:i,illegal:/#/},o={begin:/\{\{/,relevance:0},l={className:"string",contains:[e.BACKSLASH_ESCAPE],variants:[{begin:/([uU]|[bB]|[rR]|[bB][rR]|[rR][bB])?'''/,end:/'''/,contains:[e.BACKSLASH_ESCAPE,a],relevance:10},{begin:/([uU]|[bB]|[rR]|[bB][rR]|[rR][bB])?"""/,end:/"""/,contains:[e.BACKSLASH_ESCAPE,a],relevance:10},{begin:/([fF][rR]|[rR][fF]|[fF])'''/,end:/'''/,contains:[e.BACKSLASH_ESCAPE,a,o,c]},{begin:/([fF][rR]|[rR][fF]|[fF])"""/,end:/"""/,contains:[e.BACKSLASH_ESCAPE,a,o,c]},{begin:/([uU]|[rR])'/,end:/'/,relevance:10},{begin:/([uU]|[rR])"/,end:/"/,relevance:10},{begin:/([bB]|[bB][rR]|[rR][bB])'/,end:/'/},{begin:/([bB]|[bB][rR]|[rR][bB])"/,end:/"/},{begin:/([fF][rR]|[rR][fF]|[fF])'/,end:/'/,contains:[e.BACKSLASH_ESCAPE,o,c]},{begin:/([fF][rR]|[rR][fF]|[fF])"/,end:/"/,contains:[e.BACKSLASH_ESCAPE,o,c]},e.APOS_STRING_MODE,e.QUOTE_STRING_MODE]},u="[0-9](_?[0-9])*",h=`(\\b(${u}))?\\.(${u})|\\b(${u})\\.`,d=`\\b|${f.join("|")}`,p={className:"number",relevance:0,variants:[{begin:`(\\b(${u})|(${h}))[eE][+-]?(${u})[jJ]?(?=${d})`},{begin:`(${h})[jJ]?`},{begin:`\\b([1-9](_?[0-9])*|0+(_?0)*)[lLjJ]?(?=${d})`},{begin:`\\b0[bB](_?[01])+[lL]?(?=${d})`},{begin:`\\b0[oO](_?[0-7])+[lL]?(?=${d})`},{begin:`\\b0[xX](_?[0-9a-fA-F])+[lL]?(?=${d})`},{begin:`\\b(${u})[jJ](?=${d})`}]},_={className:"comment",begin:n.lookahead(/# type:/),end:/$/,keywords:i,contains:[{begin:/# type:/},{begin:/#/,end:/\b\B/,endsWithParent:!0}]},b={className:"params",variants:[{className:"",begin:/\(\s*\)/,skip:!0},{begin:/\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:i,contains:["self",a,p,l,e.HASH_COMMENT_MODE]}]};return c.contains=[l,p,a],{name:"Python",aliases:["py","gyp","ipython"],unicodeRegex:!0,keywords:i,illegal:/(<\/|\?)|=>/,contains:[a,p,{scope:"variable.language",match:/\bself\b/},{beginKeywords:"if",relevance:0},{match:/\bor\b/,scope:"keyword"},l,_,e.HASH_COMMENT_MODE,{match:[/\bdef/,/\s+/,s],scope:{1:"keyword",3:"title.function"},contains:[b]},{variants:[{match:[/\bclass/,/\s+/,s,/\s*/,/\(\s*/,s,/\s*\)/]},{match:[/\bclass/,/\s+/,s]}],scope:{1:"keyword",3:"title.class",6:"title.class.inherited"}},{className:"meta",begin:/^[\t ]*@/,end:/(?=#)|$/,contains:[p,b,l]}]}}var he="[0-9](_*[0-9])*",Se=`\\.(${he})`,Ae="[0-9a-fA-F](_*[0-9a-fA-F])*",wn={className:"number",variants:[{begin:`(\\b(${he})((${Se})|\\.)?|(${Se}))[eE][+-]?(${he})[fFdD]?\\b`},{begin:`\\b(${he})((${Se})[fFdD]?\\b|\\.([fFdD]\\b)?)`},{begin:`(${Se})[fFdD]?\\b`},{begin:`\\b(${he})[fFdD]\\b`},{begin:`\\b0[xX]((${Ae})\\.?|(${Ae})?\\.(${Ae}))[pP][+-]?(${he})[fFdD]?\\b`},{begin:"\\b(0|[1-9](_*[0-9])*)[lL]?\\b"},{begin:`\\b0[xX](${Ae})[lL]?\\b`},{begin:"\\b0(_*[0-7])*[lL]?\\b"},{begin:"\\b0[bB][01](_*[01])*[lL]?\\b"}],relevance:0};function Mn(e,n,s){return s===-1?"":e.replace(n,f=>Mn(e,n,s-1))}function tr(e){const n=e.regex,s="[À-ʸa-zA-Z_$][À-ʸa-zA-Z_$0-9]*",f=s+Mn("(?:<"+s+"~~~(?:\\s*,\\s*"+s+"~~~)*>)?",/~~~/g,2),a={keyword:["synchronized","abstract","private","var","static","if","const ","for","while","strictfp","finally","protected","import","native","final","void","enum","else","break","transient","catch","instanceof","volatile","case","assert","package","default","public","try","switch","continue","throws","protected","public","private","module","requires","exports","do","sealed","yield","permits","goto"],literal:["false","true","null"],type:["char","boolean","long","float","int","byte","short","double"],built_in:["super","this"]},c={className:"meta",begin:"@"+s,contains:[{begin:/\(/,end:/\)/,contains:["self"]}]},o={className:"params",begin:/\(/,end:/\)/,keywords:a,relevance:0,contains:[e.C_BLOCK_COMMENT_MODE],endsParent:!0};return{name:"Java",aliases:["jsp"],keywords:a,illegal:/<\/|#/,contains:[e.COMMENT("/\\*\\*","\\*/",{relevance:0,contains:[{begin:/\w+@/,relevance:0},{className:"doctag",begin:"@[A-Za-z]+"}]}),{begin:/import java\.[a-z]+\./,keywords:"import",relevance:2},e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE,{begin:/"""/,end:/"""/,className:"string",contains:[e.BACKSLASH_ESCAPE]},e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,{match:[/\b(?:class|interface|enum|extends|implements|new)/,/\s+/,s],className:{1:"keyword",3:"title.class"}},{match:/non-sealed/,scope:"keyword"},{begin:[n.concat(/(?!else)/,s),/\s+/,s,/\s+/,/=(?!=)/],className:{1:"type",3:"variable",5:"operator"}},{begin:[/record/,/\s+/,s],className:{1:"keyword",3:"title.class"},contains:[o,e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE]},{beginKeywords:"new throw return else",relevance:0},{begin:["(?:"+f+"\\s+)",e.UNDERSCORE_IDENT_RE,/\s*(?=\()/],className:{2:"title.function"},keywords:a,contains:[{className:"params",begin:/\(/,end:/\)/,keywords:a,relevance:0,contains:[c,e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,wn,e.C_BLOCK_COMMENT_MODE]},e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE]},wn,c]}}function rr(e){const n=e.regex,s={},f={begin:/\$\{/,end:/\}/,contains:["self",{begin:/:-/,contains:[s]}]};Object.assign(s,{className:"variable",variants:[{begin:n.concat(/\$[\w\d#@][\w\d_]*/,"(?![\\w\\d])(?![$])")},f]});const g={className:"subst",begin:/\$\(/,end:/\)/,contains:[e.BACKSLASH_ESCAPE]},t=e.inherit(e.COMMENT(),{match:[/(^|\s)/,/#.*$/],scope:{2:"comment"}}),r={begin:/<<-?\s*(?=\w+)/,starts:{contains:[e.END_SAME_AS_BEGIN({begin:/(\w+)/,end:/(\w+)/,className:"string"})]}},i={className:"string",begin:/"/,end:/"/,contains:[e.BACKSLASH_ESCAPE,s,g]};g.contains.push(i);const a={match:/\\"/},c={className:"string",begin:/'/,end:/'/},o={match:/\\'/},l={begin:/\$?\(\(/,end:/\)\)/,contains:[{begin:/\d+#[0-9a-f]+/,className:"number"},e.NUMBER_MODE,s]},u=["fish","bash","zsh","sh","csh","ksh","tcsh","dash","scsh"],h=e.SHEBANG({binary:`(${u.join("|")})`,relevance:10}),d={className:"function",begin:/\w[\w\d_]*\s*\(\s*\)\s*\{/,returnBegin:!0,contains:[e.inherit(e.TITLE_MODE,{begin:/\w[\w\d_]*/})],relevance:0},p=["if","then","else","elif","fi","for","while","until","in","do","done","case","esac","function","select"],_=["true","false"],b={match:/(\/[a-z._-]+)+/},m=["break","cd","continue","eval","exec","exit","export","getopts","hash","pwd","readonly","return","shift","test","times","trap","umask","unset"],E=["alias","bind","builtin","caller","command","declare","echo","enable","help","let","local","logout","mapfile","printf","read","readarray","source","sudo","type","typeset","ulimit","unalias"],y=["autoload","bg","bindkey","bye","cap","chdir","clone","comparguments","compcall","compctl","compdescribe","compfiles","compgroups","compquote","comptags","comptry","compvalues","dirs","disable","disown","echotc","echoti","emulate","fc","fg","float","functions","getcap","getln","history","integer","jobs","kill","limit","log","noglob","popd","print","pushd","pushln","rehash","sched","setcap","setopt","stat","suspend","ttyctl","unfunction","unhash","unlimit","unsetopt","vared","wait","whence","where","which","zcompile","zformat","zftp","zle","zmodload","zparseopts","zprof","zpty","zregexparse","zsocket","zstyle","ztcp"],A=["chcon","chgrp","chown","chmod","cp","dd","df","dir","dircolors","ln","ls","mkdir","mkfifo","mknod","mktemp","mv","realpath","rm","rmdir","shred","sync","touch","truncate","vdir","b2sum","base32","base64","cat","cksum","comm","csplit","cut","expand","fmt","fold","head","join","md5sum","nl","numfmt","od","paste","ptx","pr","sha1sum","sha224sum","sha256sum","sha384sum","sha512sum","shuf","sort","split","sum","tac","tail","tr","tsort","unexpand","uniq","wc","arch","basename","chroot","date","dirname","du","echo","env","expr","factor","groups","hostid","id","link","logname","nice","nohup","nproc","pathchk","pinky","printenv","printf","pwd","readlink","runcon","seq","sleep","stat","stdbuf","stty","tee","test","timeout","tty","uname","unlink","uptime","users","who","whoami","yes"];return{name:"Bash",aliases:["sh","zsh"],keywords:{$pattern:/\b[a-z][a-z0-9._-]+\b/,keyword:p,literal:_,built_in:[...m,...E,"set","shopt",...y,...A]},contains:[h,e.SHEBANG(),d,l,t,r,b,i,a,c,o,s]}}function ir(e){const n=e.regex,s=e.COMMENT("--","$"),f={className:"string",variants:[{begin:/'/,end:/'/,contains:[{begin:/''/}]}]},g={begin:/"/,end:/"/,contains:[{begin:/""/}]},t=["true","false","unknown"],r=["double precision","large object","with timezone","without timezone"],i=["bigint","binary","blob","boolean","char","character","clob","date","dec","decfloat","decimal","float","int","integer","interval","nchar","nclob","national","numeric","real","row","smallint","time","timestamp","varchar","varying","varbinary"],a=["add","asc","collation","desc","final","first","last","view"],c=["abs","acos","all","allocate","alter","and","any","are","array","array_agg","array_max_cardinality","as","asensitive","asin","asymmetric","at","atan","atomic","authorization","avg","begin","begin_frame","begin_partition","between","bigint","binary","blob","boolean","both","by","call","called","cardinality","cascaded","case","cast","ceil","ceiling","char","char_length","character","character_length","check","classifier","clob","close","coalesce","collate","collect","column","commit","condition","connect","constraint","contains","convert","copy","corr","corresponding","cos","cosh","count","covar_pop","covar_samp","create","cross","cube","cume_dist","current","current_catalog","current_date","current_default_transform_group","current_path","current_role","current_row","current_schema","current_time","current_timestamp","current_path","current_role","current_transform_group_for_type","current_user","cursor","cycle","date","day","deallocate","dec","decimal","decfloat","declare","default","define","delete","dense_rank","deref","describe","deterministic","disconnect","distinct","double","drop","dynamic","each","element","else","empty","end","end_frame","end_partition","end-exec","equals","escape","every","except","exec","execute","exists","exp","external","extract","false","fetch","filter","first_value","float","floor","for","foreign","frame_row","free","from","full","function","fusion","get","global","grant","group","grouping","groups","having","hold","hour","identity","in","indicator","initial","inner","inout","insensitive","insert","int","integer","intersect","intersection","interval","into","is","join","json_array","json_arrayagg","json_exists","json_object","json_objectagg","json_query","json_table","json_table_primitive","json_value","lag","language","large","last_value","lateral","lead","leading","left","like","like_regex","listagg","ln","local","localtime","localtimestamp","log","log10","lower","match","match_number","match_recognize","matches","max","member","merge","method","min","minute","mod","modifies","module","month","multiset","national","natural","nchar","nclob","new","no","none","normalize","not","nth_value","ntile","null","nullif","numeric","octet_length","occurrences_regex","of","offset","old","omit","on","one","only","open","or","order","out","outer","over","overlaps","overlay","parameter","partition","pattern","per","percent","percent_rank","percentile_cont","percentile_disc","period","portion","position","position_regex","power","precedes","precision","prepare","primary","procedure","ptf","range","rank","reads","real","recursive","ref","references","referencing","regr_avgx","regr_avgy","regr_count","regr_intercept","regr_r2","regr_slope","regr_sxx","regr_sxy","regr_syy","release","result","return","returns","revoke","right","rollback","rollup","row","row_number","rows","running","savepoint","scope","scroll","search","second","seek","select","sensitive","session_user","set","show","similar","sin","sinh","skip","smallint","some","specific","specifictype","sql","sqlexception","sqlstate","sqlwarning","sqrt","start","static","stddev_pop","stddev_samp","submultiset","subset","substring","substring_regex","succeeds","sum","symmetric","system","system_time","system_user","table","tablesample","tan","tanh","then","time","timestamp","timezone_hour","timezone_minute","to","trailing","translate","translate_regex","translation","treat","trigger","trim","trim_array","true","truncate","uescape","union","unique","unknown","unnest","update","upper","user","using","value","values","value_of","var_pop","var_samp","varbinary","varchar","varying","versioning","when","whenever","where","width_bucket","window","with","within","without","year"],o=["abs","acos","array_agg","asin","atan","avg","cast","ceil","ceiling","coalesce","corr","cos","cosh","count","covar_pop","covar_samp","cume_dist","dense_rank","deref","element","exp","extract","first_value","floor","json_array","json_arrayagg","json_exists","json_object","json_objectagg","json_query","json_table","json_table_primitive","json_value","lag","last_value","lead","listagg","ln","log","log10","lower","max","min","mod","nth_value","ntile","nullif","percent_rank","percentile_cont","percentile_disc","position","position_regex","power","rank","regr_avgx","regr_avgy","regr_count","regr_intercept","regr_r2","regr_slope","regr_sxx","regr_sxy","regr_syy","row_number","sin","sinh","sqrt","stddev_pop","stddev_samp","substring","substring_regex","sum","tan","tanh","translate","translate_regex","treat","trim","trim_array","unnest","upper","value_of","var_pop","var_samp","width_bucket"],l=["current_catalog","current_date","current_default_transform_group","current_path","current_role","current_schema","current_transform_group_for_type","current_user","session_user","system_time","system_user","current_time","localtime","current_timestamp","localtimestamp"],u=["create table","insert into","primary key","foreign key","not null","alter table","add constraint","grouping sets","on overflow","character set","respect nulls","ignore nulls","nulls first","nulls last","depth first","breadth first"],h=o,d=[...c,...a].filter(E=>!o.includes(E)),p={className:"variable",begin:/@[a-z0-9][a-z0-9_]*/},_={className:"operator",begin:/[-+*/=%^~]|&&?|\|\|?|!=?|<(?:=>?|<|>)?|>[>=]?/,relevance:0},b={begin:n.concat(/\b/,n.either(...h),/\s*\(/),relevance:0,keywords:{built_in:h}};function m(E,{exceptions:y,when:A}={}){const T=A;return y=y||[],E.map(D=>D.match(/\|\d+$/)||y.includes(D)?D:T(D)?`${D}|0`:D)}return{name:"SQL",case_insensitive:!0,illegal:/[{}]|<\//,keywords:{$pattern:/\b[\w\.]+/,keyword:m(d,{when:E=>E.length<3}),literal:t,type:i,built_in:l},contains:[{begin:n.either(...u),relevance:0,keywords:{$pattern:/[\w\.]+/,keyword:d.concat(u),literal:t,type:i}},{className:"type",begin:n.either(...r)},b,p,f,g,e.C_NUMBER_MODE,e.C_BLOCK_COMMENT_MODE,s,_]}}j.registerLanguage("xml",qt),j.registerLanguage("javascript",Xt),j.registerLanguage("json",Jt),j.registerLanguage("yaml",Vt),j.registerLanguage("plaintext",er),j.registerLanguage("python",nr),j.registerLanguage("java",tr),j.registerLanguage("bash",rr),j.registerLanguage("sql",ir);var S=(e=>(e.EQUAL="equal",e.DELETE="removed",e.ADD="added",e.EMPTY="empty",e))(S||{});const X="<code-diff-modified>",J="</code-diff-modified>",sr=1e4,Z=1e3,Nn=X.replace("<","&lt;").replace(">","&gt;"),Tn=J.replace("<","&lt;").replace(">","&gt;");function ar(e){const n={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"};return e.replace(/[&<>"']/g,s=>n[s])}function se(e){return e===void 0?S.EQUAL:e.added?S.ADD:e.removed?S.DELETE:S.EQUAL}function Sn(e,n,s="word",f=!1){if(typeof e=="undefined"||typeof n=="undefined")return[e,n];if(!f&&e.length+n.length>sr)return[e,n];const t=(s==="char"?qn:jn)(e,n),r=t.filter(a=>se(a)!==S.ADD).map(a=>se(a)===S.DELETE?`${X}${a.value}${J}`:a.value).join(""),i=t.filter(a=>se(a)!==S.DELETE).map(a=>se(a)===S.ADD?`${X}${a.value}${J}`:a.value).join("");return[r,i]}function An(e,n){if(e===n)return e?[{count:e.replace(/\n$/,"").split(`
9
9
  `).length,value:e}]:[];const s=e.endsWith(`
10
10
  `),f=n.endsWith(`
11
- `);s!==f&&(s?e=e.slice(0,-1):n=n.slice(0,-1));let g;if(e.length+n.length>=1e5&&e.includes(`
11
+ `);s!==f&&(s?e=e.slice(0,-1):n=n.slice(0,-1)),e&&(e+=`
12
+ `),n&&(n+=`
13
+ `);let g;if(e.length+n.length>=1e5&&e.includes(`
12
14
  `)&&n.includes(`
13
15
  `)){const t=e?e.replace(/\n$/,"").split(`
14
16
  `):[],r=n?n.replace(/\n$/,"").split(`