import{c as ae,ap as xt,aq as Et,g as ot,r as Ct,ar as St,as as Nt,b as Tt,at as st,ai as Ft,u as ft,R as U,af as kt,au as At,av as Ot,am as Dt,aj as Fe,a6 as Vt,an as Bt,ak as Ye}from"./index.1f70e7cd.js";Prism.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:/[{}[\];(),.:]/};Prism.languages.python["string-interpolation"].inside.interpolation.inside.rest=Prism.languages.python;Prism.languages.py=Prism.languages.python;var _e={},dt={},He={exports:{}};/*!

 diff v4.0.1

Software License Agreement (BSD License)

Copyright (c) 2009-2015, Kevin Decker <kpdecker@gmail.com>

All rights reserved.

Redistribution and use of this software in source and binary forms, with or without modification,
are permitted provided that the following conditions are met:

* Redistributions of source code must retain the above
  copyright notice, this list of conditions and the
  following disclaimer.

* Redistributions in binary form must reproduce the above
  copyright notice, this list of conditions and the
  following disclaimer in the documentation and/or other
  materials provided with the distribution.

* Neither the name of Kevin Decker nor the names of its
  contributors may be used to endorse or promote products
  derived from this software without specific prior
  written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR
IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
@license
*/(function(f,i){(function(n,o){o(i)})(ae,function(n){function o(){}o.prototype={diff:function(e,r){var l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},u=l.callback;typeof l=="function"&&(u=l,l={}),this.options=l;var s=this;function h(D){return u?(setTimeout(function(){u(void 0,D)},0),!0):D}e=this.castInput(e),r=this.castInput(r),e=this.removeEmpty(this.tokenize(e)),r=this.removeEmpty(this.tokenize(r));var p=r.length,m=e.length,y=1,O=p+m,B=[{newPos:-1,components:[]}],F=this.extractCommon(B[0],r,e,0);if(B[0].newPos+1>=p&&F+1>=m)return h([{value:this.join(r),count:r.length}]);function _(){for(var D=-1*y;D<=y;D+=2){var Q=void 0,ee=B[D-1],K=B[D+1],te=(K?K.newPos:0)-D;ee&&(B[D-1]=void 0);var X=ee&&ee.newPos+1<p,ue=K&&0<=te&&te<m;if(!X&&!ue){B[D]=void 0;continue}if(!X||ue&&ee.newPos<K.newPos?(Q=d(K),s.pushComponent(Q.components,void 0,!0)):(Q=ee,Q.newPos++,s.pushComponent(Q.components,!0,void 0)),te=s.extractCommon(Q,r,e,D),Q.newPos+1>=p&&te+1>=m)return h(c(s,Q.components,r,e,s.useLongestToken));B[D]=Q}y++}if(u)(function D(){setTimeout(function(){if(y>O)return u();_()||D()},0)})();else for(;y<=O;){var Z=_();if(Z)return Z}},pushComponent:function(e,r,l){var u=e[e.length-1];u&&u.added===r&&u.removed===l?e[e.length-1]={count:u.count+1,added:r,removed:l}:e.push({count:1,added:r,removed:l})},extractCommon:function(e,r,l,u){for(var s=r.length,h=l.length,p=e.newPos,m=p-u,y=0;p+1<s&&m+1<h&&this.equals(r[p+1],l[m+1]);)p++,m++,y++;return y&&e.components.push({count:y}),e.newPos=p,m},equals:function(e,r){return this.options.comparator?this.options.comparator(e,r):e===r||this.options.ignoreCase&&e.toLowerCase()===r.toLowerCase()},removeEmpty:function(e){for(var r=[],l=0;l<e.length;l++)e[l]&&r.push(e[l]);return r},castInput:function(e){return e},tokenize:function(e){return e.split("")},join:function(e){return e.join("")}};function c(t,e,r,l,u){for(var s=0,h=e.length,p=0,m=0;s<h;s++){var y=e[s];if(y.removed){if(y.value=t.join(l.slice(m,m+y.count)),m+=y.count,s&&e[s-1].added){var B=e[s-1];e[s-1]=e[s],e[s]=B}}else{if(!y.added&&u){var O=r.slice(p,p+y.count);O=O.map(function(_,Z){var D=l[m+Z];return D.length>_.length?D:_}),y.value=t.join(O)}else y.value=t.join(r.slice(p,p+y.count));p+=y.count,y.added||(m+=y.count)}}var F=e[h-1];return h>1&&typeof F.value=="string"&&(F.added||F.removed)&&t.equals("",F.value)&&(e[h-2].value+=F.value,e.pop()),e}function d(t){return{newPos:t.newPos,components:t.components.slice(0)}}var g=new o;function S(t,e,r){return g.diff(t,e,r)}function x(t,e){if(typeof t=="function")e.callback=t;else if(t)for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r]);return e}var k=/^[A-Za-z\xC0-\u02C6\u02C8-\u02D7\u02DE-\u02FF\u1E00-\u1EFF]+$/,v=/\S/,L=new o;L.equals=function(t,e){return this.options.ignoreCase&&(t=t.toLowerCase(),e=e.toLowerCase()),t===e||this.options.ignoreWhitespace&&!v.test(t)&&!v.test(e)},L.tokenize=function(t){for(var e=t.split(/(\s+|[()[\]{}'"]|\b)/),r=0;r<e.length-1;r++)!e[r+1]&&e[r+2]&&k.test(e[r])&&k.test(e[r+2])&&(e[r]+=e[r+2],e.splice(r+1,2),r--);return e};function A(t,e,r){return r=x(r,{ignoreWhitespace:!0}),L.diff(t,e,r)}function b(t,e,r){return L.diff(t,e,r)}var a=new o;a.tokenize=function(t){var e=[],r=t.split(/(\n|\r\n)/);r[r.length-1]||r.pop();for(var l=0;l<r.length;l++){var u=r[l];l%2&&!this.options.newlineIsToken?e[e.length-1]+=u:(this.options.ignoreWhitespace&&(u=u.trim()),e.push(u))}return e};function w(t,e,r){return a.diff(t,e,r)}function E(t,e,r){var l=x(r,{ignoreWhitespace:!0});return a.diff(t,e,l)}var C=new o;C.tokenize=function(t){return t.split(/(\S.+?[.!?])(?=\s+|$)/)};function T(t,e,r){return C.diff(t,e,r)}var N=new o;N.tokenize=function(t){return t.split(/([{}:;,]|\s+)/)};function q(t,e,r){return N.diff(t,e,r)}function I(t){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?I=function(e){return typeof e}:I=function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},I(t)}function V(t){return H(t)||G(t)||W()}function H(t){if(Array.isArray(t)){for(var e=0,r=new Array(t.length);e<t.length;e++)r[e]=t[e];return r}}function G(t){if(Symbol.iterator in Object(t)||Object.prototype.toString.call(t)==="[object Arguments]")return Array.from(t)}function W(){throw new TypeError("Invalid attempt to spread non-iterable instance")}var j=Object.prototype.toString,R=new o;R.useLongestToken=!0,R.tokenize=a.tokenize,R.castInput=function(t){var e=this.options,r=e.undefinedReplacement,l=e.stringifyReplacer,u=l===void 0?function(s,h){return typeof h>"u"?r:h}:l;return typeof t=="string"?t:JSON.stringify(M(t,null,null,u),u,"  ")},R.equals=function(t,e){return o.prototype.equals.call(R,t.replace(/,([\r\n])/g,"$1"),e.replace(/,([\r\n])/g,"$1"))};function J(t,e,r){return R.diff(t,e,r)}function M(t,e,r,l,u){e=e||[],r=r||[],l&&(t=l(u,t));var s;for(s=0;s<e.length;s+=1)if(e[s]===t)return r[s];var h;if(j.call(t)==="[object Array]"){for(e.push(t),h=new Array(t.length),r.push(h),s=0;s<t.length;s+=1)h[s]=M(t[s],e,r,l,u);return e.pop(),r.pop(),h}if(t&&t.toJSON&&(t=t.toJSON()),I(t)==="object"&&t!==null){e.push(t),h={},r.push(h);var p=[],m;for(m in t)t.hasOwnProperty(m)&&p.push(m);for(p.sort(),s=0;s<p.length;s+=1)m=p[s],h[m]=M(t[m],e,r,l,m);e.pop(),r.pop()}else h=t;return h}var P=new o;P.tokenize=function(t){return t.slice()},P.join=P.removeEmpty=function(t){return t};function Y(t,e,r){return P.diff(t,e,r)}function $(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=t.split(/\r\n|[\n\v\f\r\x85]/),l=t.match(/\r\n|[\n\v\f\r\x85]/g)||[],u=[],s=0;function h(){var y={};for(u.push(y);s<r.length;){var O=r[s];if(/^(\-\-\-|\+\+\+|@@)\s/.test(O))break;var B=/^(?:Index:|diff(?: -r \w+)+)\s+(.+?)\s*$/.exec(O);B&&(y.index=B[1]),s++}for(p(y),p(y),y.hunks=[];s<r.length;){var F=r[s];if(/^(Index:|diff|\-\-\-|\+\+\+)\s/.test(F))break;if(/^@@/.test(F))y.hunks.push(m());else{if(F&&e.strict)throw new Error("Unknown line "+(s+1)+" "+JSON.stringify(F));s++}}}function p(y){var O=/^(---|\+\+\+)\s+(.*)$/.exec(r[s]);if(O){var B=O[1]==="---"?"old":"new",F=O[2].split("	",2),_=F[0].replace(/\\\\/g,"\\");/^".*"$/.test(_)&&(_=_.substr(1,_.length-2)),y[B+"FileName"]=_,y[B+"Header"]=(F[1]||"").trim(),s++}}function m(){for(var y=s,O=r[s++],B=O.split(/@@ -(\d+)(?:,(\d+))? \+(\d+)(?:,(\d+))? @@/),F={oldStart:+B[1],oldLines:+B[2]||1,newStart:+B[3],newLines:+B[4]||1,lines:[],linedelimiters:[]},_=0,Z=0;s<r.length&&!(r[s].indexOf("--- ")===0&&s+2<r.length&&r[s+1].indexOf("+++ ")===0&&r[s+2].indexOf("@@")===0);s++){var D=r[s].length==0&&s!=r.length-1?" ":r[s][0];if(D==="+"||D==="-"||D===" "||D==="\\")F.lines.push(r[s]),F.linedelimiters.push(l[s]||`
`),D==="+"?_++:D==="-"?Z++:D===" "&&(_++,Z++);else break}if(!_&&F.newLines===1&&(F.newLines=0),!Z&&F.oldLines===1&&(F.oldLines=0),e.strict){if(_!==F.newLines)throw new Error("Added line count did not match for hunk at line "+(y+1));if(Z!==F.oldLines)throw new Error("Removed line count did not match for hunk at line "+(y+1))}return F}for(;s<r.length;)h();return u}function pe(t,e,r){var l=!0,u=!1,s=!1,h=1;return function p(){if(l&&!s){if(u?h++:l=!1,t+h<=r)return h;s=!0}if(!u)return s||(l=!0),e<=t-h?-h++:(u=!0,p())}}function be(t,e){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};if(typeof e=="string"&&(e=$(e)),Array.isArray(e)){if(e.length>1)throw new Error("applyPatch only works with a single input.");e=e[0]}var l=t.split(/\r\n|[\n\v\f\r\x85]/),u=t.match(/\r\n|[\n\v\f\r\x85]/g)||[],s=e.hunks,h=r.compareLine||function(Be,Ee,Te,we){return Ee===we},p=0,m=r.fuzzFactor||0,y=0,O=0,B,F;function _(Be,Ee){for(var Te=0;Te<Be.lines.length;Te++){var we=Be.lines[Te],Re=we.length>0?we[0]:" ",Lt=we.length>0?we.substr(1):we;if(Re===" "||Re==="-"){if(!h(Ee+1,l[Ee],Re,Lt)&&(p++,p>m))return!1;Ee++}}return!0}for(var Z=0;Z<s.length;Z++){for(var D=s[Z],Q=l.length-D.oldLines,ee=0,K=O+D.oldStart-1,te=pe(K,y,Q);ee!==void 0;ee=te())if(_(D,K+ee)){D.offset=O+=ee;break}if(ee===void 0)return!1;y=D.offset+D.oldStart+D.oldLines}for(var X=0,ue=0;ue<s.length;ue++){var ie=s[ue],le=ie.oldStart+ie.offset+X-1;X+=ie.newLines-ie.oldLines,le<0&&(le=0);for(var ce=0;ce<ie.lines.length;ce++){var he=ie.lines[ce],me=he.length>0?he[0]:" ",Ne=he.length>0?he.substr(1):he,Ve=ie.linedelimiters[ce];if(me===" ")le++;else if(me==="-")l.splice(le,1),u.splice(le,1);else if(me==="+")l.splice(le,0,Ne),u.splice(le,0,Ve),le++;else if(me==="\\"){var xe=ie.lines[ce-1]?ie.lines[ce-1][0]:null;xe==="+"?B=!0:xe==="-"&&(F=!0)}}}if(B)for(;!l[l.length-1];)l.pop(),u.pop();else F&&(l.push(""),u.push(`
`));for(var ye=0;ye<l.length-1;ye++)l[ye]=l[ye]+u[ye];return l.join("")}function fe(t,e){typeof t=="string"&&(t=$(t));var r=0;function l(){var u=t[r++];if(!u)return e.complete();e.loadFile(u,function(s,h){if(s)return e.complete(s);var p=be(h,u,e);e.patched(u,p,function(m){if(m)return e.complete(m);l()})})}l()}function de(t,e,r,l,u,s,h){h||(h={}),typeof h.context>"u"&&(h.context=4);var p=w(r,l,h);p.push({value:"",lines:[]});function m(ee){return ee.map(function(K){return" "+K})}for(var y=[],O=0,B=0,F=[],_=1,Z=1,D=function(K){var te=p[K],X=te.lines||te.value.replace(/\n$/,"").split(`
`);if(te.lines=X,te.added||te.removed){var ue;if(!O){var ie=p[K-1];O=_,B=Z,ie&&(F=h.context>0?m(ie.lines.slice(-h.context)):[],O-=F.length,B-=F.length)}(ue=F).push.apply(ue,V(X.map(function(ye){return(te.added?"+":"-")+ye}))),te.added?Z+=X.length:_+=X.length}else{if(O)if(X.length<=h.context*2&&K<p.length-2){var le;(le=F).push.apply(le,V(m(X)))}else{var ce,he=Math.min(X.length,h.context);(ce=F).push.apply(ce,V(m(X.slice(0,he))));var me={oldStart:O,oldLines:_-O+he,newStart:B,newLines:Z-B+he,lines:F};if(K>=p.length-2&&X.length<=h.context){var Ne=/\n$/.test(r),Ve=/\n$/.test(l),xe=X.length==0&&F.length>me.oldLines;!Ne&&xe&&F.splice(me.oldLines,0,"\\ No newline at end of file"),(!Ne&&!xe||!Ve)&&F.push("\\ No newline at end of file")}y.push(me),O=0,B=0,F=[]}_+=X.length,Z+=X.length}},Q=0;Q<p.length;Q++)D(Q);return{oldFileName:t,newFileName:e,oldHeader:u,newHeader:s,hunks:y}}function ve(t,e,r,l,u,s,h){var p=de(t,e,r,l,u,s,h),m=[];t==e&&m.push("Index: "+t),m.push("==================================================================="),m.push("--- "+p.oldFileName+(typeof p.oldHeader>"u"?"":"	"+p.oldHeader)),m.push("+++ "+p.newFileName+(typeof p.newHeader>"u"?"":"	"+p.newHeader));for(var y=0;y<p.hunks.length;y++){var O=p.hunks[y];m.push("@@ -"+O.oldStart+","+O.oldLines+" +"+O.newStart+","+O.newLines+" @@"),m.push.apply(m,O.lines)}return m.join(`
`)+`
`}function ne(t,e,r,l,u,s){return ve(t,t,e,r,l,u,s)}function re(t,e){return t.length!==e.length?!1:Ae(t,e)}function Ae(t,e){if(e.length>t.length)return!1;for(var r=0;r<e.length;r++)if(e[r]!==t[r])return!1;return!0}function ht(t){var e=De(t.lines),r=e.oldLines,l=e.newLines;r!==void 0?t.oldLines=r:delete t.oldLines,l!==void 0?t.newLines=l:delete t.newLines}function pt(t,e,r){t=Pe(t,r),e=Pe(e,r);var l={};(t.index||e.index)&&(l.index=t.index||e.index),(t.newFileName||e.newFileName)&&(We(t)?We(e)?(l.oldFileName=Se(l,t.oldFileName,e.oldFileName),l.newFileName=Se(l,t.newFileName,e.newFileName),l.oldHeader=Se(l,t.oldHeader,e.oldHeader),l.newHeader=Se(l,t.newHeader,e.newHeader)):(l.oldFileName=t.oldFileName,l.newFileName=t.newFileName,l.oldHeader=t.oldHeader,l.newHeader=t.newHeader):(l.oldFileName=e.oldFileName||t.oldFileName,l.newFileName=e.newFileName||t.newFileName,l.oldHeader=e.oldHeader||t.oldHeader,l.newHeader=e.newHeader||t.newHeader)),l.hunks=[];for(var u=0,s=0,h=0,p=0;u<t.hunks.length||s<e.hunks.length;){var m=t.hunks[u]||{oldStart:1/0},y=e.hunks[s]||{oldStart:1/0};if(je(m,y))l.hunks.push($e(m,h)),u++,p+=m.newLines-m.oldLines;else if(je(y,m))l.hunks.push($e(y,p)),s++,h+=y.newLines-y.oldLines;else{var O={oldStart:Math.min(m.oldStart,y.oldStart),oldLines:0,newStart:Math.min(m.newStart+h,y.oldStart+p),newLines:0,lines:[]};vt(O,m.oldStart,m.lines,y.oldStart,y.lines),s++,u++,l.hunks.push(O)}}return l}function Pe(t,e){if(typeof t=="string"){if(/^@@/m.test(t)||/^Index:/m.test(t))return $(t)[0];if(!e)throw new Error("Must provide a base reference or pass in a patch");return de(void 0,void 0,e,t)}return t}function We(t){return t.newFileName&&t.newFileName!==t.oldFileName}function Se(t,e,r){return e===r?e:(t.conflict=!0,{mine:e,theirs:r})}function je(t,e){return t.oldStart<e.oldStart&&t.oldStart+t.oldLines<e.oldStart}function $e(t,e){return{oldStart:t.oldStart,oldLines:t.oldLines,newStart:t.newStart+e,newLines:t.newLines,lines:t.lines}}function vt(t,e,r,l,u){var s={offset:e,lines:r,index:0},h={offset:l,lines:u,index:0};for(Ue(t,s,h),Ue(t,h,s);s.index<s.lines.length&&h.index<h.lines.length;){var p=s.lines[s.index],m=h.lines[h.index];if((p[0]==="-"||p[0]==="+")&&(m[0]==="-"||m[0]==="+"))mt(t,s,h);else if(p[0]==="+"&&m[0]===" "){var y;(y=t.lines).push.apply(y,V(ge(s)))}else if(m[0]==="+"&&p[0]===" "){var O;(O=t.lines).push.apply(O,V(ge(h)))}else p[0]==="-"&&m[0]===" "?qe(t,s,h):m[0]==="-"&&p[0]===" "?qe(t,h,s,!0):p===m?(t.lines.push(p),s.index++,h.index++):Oe(t,ge(s),ge(h))}Je(t,s),Je(t,h),ht(t)}function mt(t,e,r){var l=ge(e),u=ge(r);if(Ze(l)&&Ze(u)){if(Ae(l,u)&&Xe(r,l,l.length-u.length)){var s;(s=t.lines).push.apply(s,V(l));return}else if(Ae(u,l)&&Xe(e,u,u.length-l.length)){var h;(h=t.lines).push.apply(h,V(u));return}}else if(re(l,u)){var p;(p=t.lines).push.apply(p,V(l));return}Oe(t,l,u)}function qe(t,e,r,l){var u=ge(e),s=gt(r,u);if(s.merged){var h;(h=t.lines).push.apply(h,V(s.merged))}else Oe(t,l?s:u,l?u:s)}function Oe(t,e,r){t.conflict=!0,t.lines.push({conflict:!0,mine:e,theirs:r})}function Ue(t,e,r){for(;e.offset<r.offset&&e.index<e.lines.length;){var l=e.lines[e.index++];t.lines.push(l),e.offset++}}function Je(t,e){for(;e.index<e.lines.length;){var r=e.lines[e.index++];t.lines.push(r)}}function ge(t){for(var e=[],r=t.lines[t.index][0];t.index<t.lines.length;){var l=t.lines[t.index];if(r==="-"&&l[0]==="+"&&(r="+"),r===l[0])e.push(l),t.index++;else break}return e}function gt(t,e){for(var r=[],l=[],u=0,s=!1,h=!1;u<e.length&&t.index<t.lines.length;){var p=t.lines[t.index],m=e[u];if(m[0]==="+")break;if(s=s||p[0]!==" ",l.push(m),u++,p[0]==="+")for(h=!0;p[0]==="+";)r.push(p),p=t.lines[++t.index];m.substr(1)===p.substr(1)?(r.push(p),t.index++):h=!0}if((e[u]||"")[0]==="+"&&s&&(h=!0),h)return r;for(;u<e.length;)l.push(e[u++]);return{merged:l,changes:r}}function Ze(t){return t.reduce(function(e,r){return e&&r[0]==="-"},!0)}function Xe(t,e,r){for(var l=0;l<r;l++){var u=e[e.length-r+l].substr(1);if(t.lines[t.index+l]!==" "+u)return!1}return t.index+=r,!0}function De(t){var e=0,r=0;return t.forEach(function(l){if(typeof l!="string"){var u=De(l.mine),s=De(l.theirs);e!==void 0&&(u.oldLines===s.oldLines?e+=u.oldLines:e=void 0),r!==void 0&&(u.newLines===s.newLines?r+=u.newLines:r=void 0)}else r!==void 0&&(l[0]==="+"||l[0]===" ")&&r++,e!==void 0&&(l[0]==="-"||l[0]===" ")&&e++}),{oldLines:e,newLines:r}}function yt(t){for(var e=[],r,l,u=0;u<t.length;u++)r=t[u],r.added?l=1:r.removed?l=-1:l=0,e.push([l,r.value]);return e}function wt(t){for(var e=[],r=0;r<t.length;r++){var l=t[r];l.added?e.push("<ins>"):l.removed&&e.push("<del>"),e.push(bt(l.value)),l.added?e.push("</ins>"):l.removed&&e.push("</del>")}return e.join("")}function bt(t){var e=t;return e=e.replace(/&/g,"&amp;"),e=e.replace(/</g,"&lt;"),e=e.replace(/>/g,"&gt;"),e=e.replace(/"/g,"&quot;"),e}n.Diff=o,n.diffChars=S,n.diffWords=A,n.diffWordsWithSpace=b,n.diffLines=w,n.diffTrimmedLines=E,n.diffSentences=T,n.diffCss=q,n.diffJson=J,n.diffArrays=Y,n.structuredPatch=de,n.createTwoFilesPatch=ve,n.createPatch=ne,n.applyPatch=be,n.applyPatches=fe,n.parsePatch=$,n.merge=pt,n.convertChangesToDMP=yt,n.convertChangesToXML=wt,n.canonicalize=M,Object.defineProperty(n,"__esModule",{value:!0})})})(He,He.exports);(function(f){var i=ae&&ae.__read||function(v,L){var A=typeof Symbol=="function"&&v[Symbol.iterator];if(!A)return v;var b=A.call(v),a,w=[],E;try{for(;(L===void 0||L-- >0)&&!(a=b.next()).done;)w.push(a.value)}catch(C){E={error:C}}finally{try{a&&!a.done&&(A=b.return)&&A.call(b)}finally{if(E)throw E.error}}return w},n=ae&&ae.__spread||function(){for(var v=[],L=0;L<arguments.length;L++)v=v.concat(i(arguments[L]));return v};Object.defineProperty(f,"__esModule",{value:!0});var o=He.exports,c=o,d;(function(v){v[v.DEFAULT=0]="DEFAULT",v[v.ADDED=1]="ADDED",v[v.REMOVED=2]="REMOVED"})(d=f.DiffType||(f.DiffType={}));var g;(function(v){v.CHARS="diffChars",v.WORDS="diffWords",v.WORDS_WITH_SPACE="diffWordsWithSpace",v.LINES="diffLines",v.TRIMMED_LINES="diffTrimmedLines",v.SENTENCES="diffSentences",v.CSS="diffCss"})(g=f.DiffMethod||(f.DiffMethod={}));var S=function(v){var L=v.split(`
`),A=L.every(function(w){return!w});if(A)return L.length===2?[]:(L.pop(),L);var b=L[L.length-1],a=L[0];return b||L.pop(),a||L.shift(),L},x=function(v,L,A){A===void 0&&(A=g.CHARS);var b=c[A](v,L),a={left:[],right:[]};return b.forEach(function(w){var E=w.added,C=w.removed,T=w.value,N={};return E&&(N.type=d.ADDED,N.value=T,a.right.push(N)),C&&(N.type=d.REMOVED,N.value=T,a.left.push(N)),!C&&!E&&(N.type=d.DEFAULT,N.value=T,a.right.push(N),a.left.push(N)),N}),a},k=function(v,L,A,b,a){A===void 0&&(A=!1),b===void 0&&(b=g.CHARS),a===void 0&&(a=0);var w=o.diffLines(v.trimRight(),L.trimRight(),{newlineIsToken:!0,ignoreWhitespace:!1,ignoreCase:!1}),E=a,C=a,T=[],N=0,q=[],I=[],V=function(H,G,W,j,R){var J=S(H);return J.map(function(M,P){var Y={},$={};if(!(I.includes(G+"-"+P)||R&&P!==0)){if(W||j)if(q.includes(N)||q.push(N),j){C+=1,Y.lineNumber=C,Y.type=d.REMOVED,Y.value=M||" ";var pe=w[G+1];if(pe&&pe.added){var be=S(pe.value)[P];if(be){var fe=V(pe.value,G,!0,!1,!0)[0].right,de=fe.value,ve=fe.lineNumber,ne=fe.type;if(I.push(G+1+"-"+P),$.lineNumber=ve,$.type=ne,A)$.value=de;else{var re=x(M,de,b);$.value=re.right,Y.value=re.left}}}}else E+=1,$.lineNumber=E,$.type=d.ADDED,$.value=M;else C+=1,E+=1,Y.lineNumber=C,Y.type=d.DEFAULT,Y.value=M,$.lineNumber=E,$.type=d.DEFAULT,$.value=M;return N+=1,{right:$,left:Y}}}).filter(Boolean)};return w.forEach(function(H,G){var W=H.added,j=H.removed,R=H.value;T=n(T,V(R,G,W,j))}),{lineInformation:T,diffLines:q}};f.computeLineInformation=k})(dt);var ze={};function Rt(f){if(f.sheet)return f.sheet;for(var i=0;i<document.styleSheets.length;i++)if(document.styleSheets[i].ownerNode===f)return document.styleSheets[i]}function It(f){var i=document.createElement("style");return i.setAttribute("data-emotion",f.key),f.nonce!==void 0&&i.setAttribute("nonce",f.nonce),i.appendChild(document.createTextNode("")),i}var Gt=function(){function f(n){this.isSpeedy=n.speedy===void 0?!0:n.speedy,this.tags=[],this.ctr=0,this.nonce=n.nonce,this.key=n.key,this.container=n.container,this.before=null}var i=f.prototype;return i.insert=function(o){if(this.ctr%(this.isSpeedy?65e3:1)===0){var c=It(this),d;this.tags.length===0?d=this.before:d=this.tags[this.tags.length-1].nextSibling,this.container.insertBefore(c,d),this.tags.push(c)}var g=this.tags[this.tags.length-1];if(this.isSpeedy){var S=Rt(g);try{var x=o.charCodeAt(1)===105&&o.charCodeAt(0)===64;S.insertRule(o,x?0:S.cssRules.length)}catch{}}else g.appendChild(document.createTextNode(o));this.ctr++},i.flush=function(){this.tags.forEach(function(o){return o.parentNode.removeChild(o)}),this.tags=[],this.ctr=0},f}(),Me="/*|*/",Ht=Me+"}";function Mt(f){f&&ke.current.insert(f+"}")}var ke={current:null},_t=function(i,n,o,c,d,g,S,x,k,v){switch(i){case 1:{switch(n.charCodeAt(0)){case 64:return ke.current.insert(n+";"),"";case 108:if(n.charCodeAt(2)===98)return""}break}case 2:{if(x===0)return n+Me;break}case 3:switch(x){case 102:case 112:return ke.current.insert(o[0]+n),"";default:return n+(v===0?Me:"")}case-2:n.split(Ht).forEach(Mt)}},zt=function(i){i===void 0&&(i={});var n=i.key||"css",o;i.prefix!==void 0&&(o={prefix:i.prefix});var c=new xt(o),d={},g;{g=i.container||document.head;var S=document.querySelectorAll("style[data-emotion-"+n+"]");Array.prototype.forEach.call(S,function(v){var L=v.getAttribute("data-emotion-"+n);L.split(" ").forEach(function(A){d[A]=!0}),v.parentNode!==g&&g.appendChild(v)})}var x;c.use(i.stylisPlugins)(_t),x=function(L,A,b,a){var w=A.name;ke.current=b,c(L,A.styles),a&&(k.inserted[w]=!0)};var k={key:n,sheet:new Gt({key:n,container:g,nonce:i.nonce,speedy:i.speedy}),nonce:i.nonce,inserted:d,registered:{},insert:x};return k};function Pt(f){for(var i=0,n,o=0,c=f.length;c>=4;++o,c-=4)n=f.charCodeAt(o)&255|(f.charCodeAt(++o)&255)<<8|(f.charCodeAt(++o)&255)<<16|(f.charCodeAt(++o)&255)<<24,n=(n&65535)*1540483477+((n>>>16)*59797<<16),n^=n>>>24,i=(n&65535)*1540483477+((n>>>16)*59797<<16)^(i&65535)*1540483477+((i>>>16)*59797<<16);switch(c){case 3:i^=(f.charCodeAt(o+2)&255)<<16;case 2:i^=(f.charCodeAt(o+1)&255)<<8;case 1:i^=f.charCodeAt(o)&255,i=(i&65535)*1540483477+((i>>>16)*59797<<16)}return i^=i>>>13,i=(i&65535)*1540483477+((i>>>16)*59797<<16),((i^i>>>15)>>>0).toString(36)}function Wt(f){var i={};return function(n){return i[n]===void 0&&(i[n]=f(n)),i[n]}}var jt=/[A-Z]|^ms/g,$t=/_EMO_([^_]+?)_([^]*?)_EMO_/g,ut=function(i){return i.charCodeAt(1)===45},Qe=function(i){return i!=null&&typeof i!="boolean"},Ie=Wt(function(f){return ut(f)?f:f.replace(jt,"-$&").toLowerCase()}),Ke=function(i,n){switch(i){case"animation":case"animationName":if(typeof n=="string")return n.replace($t,function(o,c,d){return oe={name:c,styles:d,next:oe},c})}return Et[i]!==1&&!ut(i)&&typeof n=="number"&&n!==0?n+"px":n};function Ce(f,i,n,o){if(n==null)return"";if(n.__emotion_styles!==void 0)return n;switch(typeof n){case"boolean":return"";case"object":{if(n.anim===1)return oe={name:n.name,styles:n.styles,next:oe},n.name;if(n.styles!==void 0){var c=n.next;if(c!==void 0)for(;c!==void 0;)oe={name:c.name,styles:c.styles,next:oe},c=c.next;var d=n.styles+";";return d}return qt(f,i,n)}case"function":{if(f!==void 0){var g=oe,S=n(f);return oe=g,Ce(f,i,S,o)}break}}if(i==null)return n;var x=i[n];return x!==void 0&&!o?x:n}function qt(f,i,n){var o="";if(Array.isArray(n))for(var c=0;c<n.length;c++)o+=Ce(f,i,n[c],!1);else for(var d in n){var g=n[d];if(typeof g!="object")i!=null&&i[g]!==void 0?o+=d+"{"+i[g]+"}":Qe(g)&&(o+=Ie(d)+":"+Ke(d,g)+";");else if(Array.isArray(g)&&typeof g[0]=="string"&&(i==null||i[g[0]]===void 0))for(var S=0;S<g.length;S++)Qe(g[S])&&(o+=Ie(d)+":"+Ke(d,g[S])+";");else{var x=Ce(f,i,g,!1);switch(d){case"animation":case"animationName":{o+=Ie(d)+":"+x+";";break}default:o+=d+"{"+x+"}"}}}return o}var et=/label:\s*([^\s;\n{]+)\s*;/g,oe,Ge=function(i,n,o){if(i.length===1&&typeof i[0]=="object"&&i[0]!==null&&i[0].styles!==void 0)return i[0];var c=!0,d="";oe=void 0;var g=i[0];g==null||g.raw===void 0?(c=!1,d+=Ce(o,n,g,!1)):d+=g[0];for(var S=1;S<i.length;S++)d+=Ce(o,n,i[S],d.charCodeAt(d.length-1)===46),c&&(d+=g[S]);et.lastIndex=0;for(var x="",k;(k=et.exec(d))!==null;)x+="-"+k[1];var v=Pt(d)+x;return{name:v,styles:d,next:oe}},Ut=!0;function ct(f,i,n){var o="";return n.split(" ").forEach(function(c){f[c]!==void 0?i.push(f[c]):o+=c+" "}),o}var Jt=function(i,n,o){var c=i.key+"-"+n.name;if((o===!1||Ut===!1)&&i.registered[c]===void 0&&(i.registered[c]=n.styles),i.inserted[n.name]===void 0){var d=n;do i.insert("."+c,d,i.sheet,!0),d=d.next;while(d!==void 0)}};function tt(f,i){if(f.inserted[i.name]===void 0)return f.insert("",i,f.sheet,!0)}function nt(f,i,n){var o=[],c=ct(f,o,n);return o.length<2?n:c+i(o)}var Zt=function(i){var n=zt(i);n.sheet.speedy=function(S){this.isSpeedy=S},n.compat=!0;var o=function(){for(var x=arguments.length,k=new Array(x),v=0;v<x;v++)k[v]=arguments[v];var L=Ge(k,n.registered,void 0);return Jt(n,L,!1),n.key+"-"+L.name},c=function(){for(var x=arguments.length,k=new Array(x),v=0;v<x;v++)k[v]=arguments[v];var L=Ge(k,n.registered),A="animation-"+L.name;return tt(n,{name:L.name,styles:"@keyframes "+A+"{"+L.styles+"}"}),A},d=function(){for(var x=arguments.length,k=new Array(x),v=0;v<x;v++)k[v]=arguments[v];var L=Ge(k,n.registered);tt(n,L)},g=function(){for(var x=arguments.length,k=new Array(x),v=0;v<x;v++)k[v]=arguments[v];return nt(n.registered,o,Xt(k))};return{css:o,cx:g,injectGlobal:d,keyframes:c,hydrate:function(x){x.forEach(function(k){n.inserted[k]=!0})},flush:function(){n.registered={},n.inserted={},n.sheet.flush()},sheet:n.sheet,cache:n,getRegisteredStyles:ct.bind(null,n.registered),merge:nt.bind(null,n.registered,o)}},Xt=function f(i){for(var n="",o=0;o<i.length;o++){var c=i[o];if(c!=null){var d=void 0;switch(typeof c){case"boolean":break;case"object":{if(Array.isArray(c))d=f(c);else{d="";for(var g in c)c[g]&&g&&(d&&(d+=" "),d+=g)}break}default:d=c}d&&(n&&(n+=" "),n+=d)}}return n},se=Zt(),Yt=se.flush,Qt=se.hydrate,Kt=se.cx,en=se.merge,tn=se.getRegisteredStyles,nn=se.injectGlobal,rn=se.keyframes,ln=se.css,an=se.sheet,on=se.cache;const sn=Object.freeze(Object.defineProperty({__proto__:null,cache:on,css:ln,cx:Kt,flush:Yt,getRegisteredStyles:tn,hydrate:Qt,injectGlobal:nn,keyframes:rn,merge:en,sheet:an},Symbol.toStringTag,{value:"Module"})),fn=ot(sn);var Le=ae&&ae.__assign||function(){return Le=Object.assign||function(f){for(var i,n=1,o=arguments.length;n<o;n++){i=arguments[n];for(var c in i)Object.prototype.hasOwnProperty.call(i,c)&&(f[c]=i[c])}return f},Le.apply(this,arguments)},dn=ae&&ae.__rest||function(f,i){var n={};for(var o in f)Object.prototype.hasOwnProperty.call(f,o)&&i.indexOf(o)<0&&(n[o]=f[o]);if(f!=null&&typeof Object.getOwnPropertySymbols=="function")for(var c=0,o=Object.getOwnPropertySymbols(f);c<o.length;c++)i.indexOf(o[c])<0&&Object.prototype.propertyIsEnumerable.call(f,o[c])&&(n[o[c]]=f[o[c]]);return n};Object.defineProperty(ze,"__esModule",{value:!0});var z=fn;ze.default=function(f,i){var n,o,c,d,g,S,x;i===void 0&&(i=!1);var k=f.variables,v=k===void 0?{}:k,L=dn(f,["variables"]),A={light:Le({diffViewerBackground:"#fff",diffViewerColor:"212529",addedBackground:"#e6ffed",addedColor:"#24292e",removedBackground:"#ffeef0",removedColor:"#24292e",wordAddedBackground:"#acf2bd",wordRemovedBackground:"#fdb8c0",addedGutterBackground:"#cdffd8",removedGutterBackground:"#ffdce0",gutterBackground:"#f7f7f7",gutterBackgroundDark:"#f3f1f1",highlightBackground:"#fffbdd",highlightGutterBackground:"#fff5b1",codeFoldGutterBackground:"#dbedff",codeFoldBackground:"#f1f8ff",emptyLineBackground:"#fafbfc",gutterColor:"#212529",addedGutterColor:"#212529",removedGutterColor:"#212529",codeFoldContentColor:"#212529",diffViewerTitleBackground:"#fafbfc",diffViewerTitleColor:"#212529",diffViewerTitleBorderColor:"#eee"},v.light||{}),dark:Le({diffViewerBackground:"#2e303c",diffViewerColor:"#FFF",addedBackground:"#044B53",addedColor:"white",removedBackground:"#632F34",removedColor:"white",wordAddedBackground:"#055d67",wordRemovedBackground:"#7d383f",addedGutterBackground:"#034148",removedGutterBackground:"#632b30",gutterBackground:"#2c2f3a",gutterBackgroundDark:"#262933",highlightBackground:"#2a3967",highlightGutterBackground:"#2d4077",codeFoldGutterBackground:"#21232b",codeFoldBackground:"#262831",emptyLineBackground:"#363946",gutterColor:"#464c67",addedGutterColor:"#8c8c8c",removedGutterColor:"#8c8c8c",codeFoldContentColor:"#555a7b",diffViewerTitleBackground:"#2f323e",diffViewerTitleColor:"#555a7b",diffViewerTitleBorderColor:"#353846"},v.dark||{})},b=i?A.dark:A.light,a=z.css({width:"100%",label:"content"}),w=z.css((n={},n["."+a]={width:"50%"},n.label="split-view",n)),E=z.css({width:"100%",background:b.diffViewerBackground,pre:{margin:0,whiteSpace:"pre-wrap",lineHeight:"25px"},label:"diff-container",borderCollapse:"collapse"}),C=z.css({color:b.codeFoldContentColor,label:"code-fold-content"}),T=z.css({color:b.diffViewerColor,label:"content-text"}),N=z.css((o={background:b.diffViewerTitleBackground,padding:10,borderBottom:"1px solid "+b.diffViewerTitleBorderColor,label:"title-block",":last-child":{borderLeft:"1px solid "+b.diffViewerTitleBorderColor}},o["."+T]={color:b.diffViewerTitleColor},o)),q=z.css({color:b.gutterColor,label:"line-number"}),I=z.css((c={background:b.removedBackground,color:b.removedColor,pre:{color:b.removedColor}},c["."+q]={color:b.removedGutterColor},c.label="diff-removed",c)),V=z.css((d={background:b.addedBackground,color:b.addedColor,pre:{color:b.addedColor}},d["."+q]={color:b.addedGutterColor},d.label="diff-added",d)),H=z.css({padding:2,display:"inline-flex",borderRadius:1,label:"word-diff"}),G=z.css({background:b.wordAddedBackground,label:"word-added"}),W=z.css({background:b.wordRemovedBackground,label:"word-removed"}),j=z.css({backgroundColor:b.codeFoldGutterBackground,label:"code-fold-gutter"}),R=z.css({backgroundColor:b.codeFoldBackground,height:40,fontSize:14,fontWeight:700,label:"code-fold",a:{textDecoration:"underline !important",cursor:"pointer",pre:{display:"inline"}}}),J=z.css({backgroundColor:b.emptyLineBackground,label:"empty-line"}),M=z.css((g={width:25,paddingLeft:10,paddingRight:10,userSelect:"none",label:"marker"},g["&."+V]={pre:{color:b.addedColor}},g["&."+I]={pre:{color:b.removedColor}},g)),P=z.css((S={background:b.highlightBackground,label:"highlighted-line"},S["."+G+", ."+W]={backgroundColor:"initial"},S)),Y=z.css({label:"highlighted-gutter"}),$=z.css((x={userSelect:"none",minWidth:50,padding:"0 10px",label:"gutter",textAlign:"right",background:b.gutterBackground,"&:hover":{cursor:"pointer",background:b.gutterBackgroundDark,pre:{opacity:1}},pre:{opacity:.5}},x["&."+V]={background:b.addedGutterBackground},x["&."+I]={background:b.removedGutterBackground},x["&."+Y]={background:b.highlightGutterBackground,"&:hover":{background:b.highlightGutterBackground}},x)),pe=z.css({"&:hover":{background:b.gutterBackground,cursor:"initial"},label:"empty-gutter"}),be=z.css({verticalAlign:"baseline",label:"line"}),fe={diffContainer:E,diffRemoved:I,diffAdded:V,splitView:w,marker:M,highlightedGutter:Y,highlightedLine:P,gutter:$,line:be,wordDiff:H,wordAdded:G,wordRemoved:W,codeFoldGutter:j,codeFold:R,emptyGutter:pe,emptyLine:J,lineNumber:q,contentText:T,content:a,codeFoldContent:C,titleBlock:N},de=Object.keys(L).reduce(function(ve,ne){var re;return Le({},ve,(re={},re[ne]=z.css(L[ne]),re))},{});return Object.keys(fe).reduce(function(ve,ne){var re;return Le({},ve,(re={},re[ne]=de[ne]?z.cx(fe[ne],de[ne]):fe[ne],re))},{})};var rt=Number.isNaN||function(i){return typeof i=="number"&&i!==i};function un(f,i){return!!(f===i||rt(f)&&rt(i))}function cn(f,i){if(f.length!==i.length)return!1;for(var n=0;n<f.length;n++)if(!un(f[n],i[n]))return!1;return!0}function hn(f,i){i===void 0&&(i=cn);var n,o=[],c,d=!1;function g(){for(var S=[],x=0;x<arguments.length;x++)S[x]=arguments[x];return d&&n===this&&i(S,o)||(c=f.apply(this,S),d=!0,n=this,o=S),c}return g}const pn=Object.freeze(Object.defineProperty({__proto__:null,default:hn},Symbol.toStringTag,{value:"Module"})),vn=ot(pn);(function(f){var i=ae&&ae.__extends||function(){var L=function(A,b){return L=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,w){a.__proto__=w}||function(a,w){for(var E in w)w.hasOwnProperty(E)&&(a[E]=w[E])},L(A,b)};return function(A,b){L(A,b);function a(){this.constructor=A}A.prototype=b===null?Object.create(b):(a.prototype=b.prototype,new a)}}();Object.defineProperty(f,"__esModule",{value:!0});var n=Ct.exports,o=St.exports,c=Nt.exports,d=dt;f.DiffMethod=d.DiffMethod;var g=ze,S=vn,x=S.default||S,k;(function(L){L.LEFT="L",L.RIGHT="R"})(k=f.LineNumberPrefix||(f.LineNumberPrefix={}));var v=function(L){i(A,L);function A(b){var a=L.call(this,b)||this;return a.resetCodeBlocks=function(){return a.state.expandedBlocks.length>0?(a.setState({expandedBlocks:[]}),!0):!1},a.onBlockExpand=function(w){var E=a.state.expandedBlocks.slice();E.push(w),a.setState({expandedBlocks:E})},a.computeStyles=x(g.default),a.onLineNumberClickProxy=function(w){return a.props.onLineNumberClick?function(E){return a.props.onLineNumberClick(w,E)}:function(){}},a.renderWordDiff=function(w,E){return w.map(function(C,T){var N;return n.createElement("span",{key:T,className:c.default(a.styles.wordDiff,(N={},N[a.styles.wordAdded]=C.type===d.DiffType.ADDED,N[a.styles.wordRemoved]=C.type===d.DiffType.REMOVED,N))},E?E(C.value):C.value)})},a.renderLine=function(w,E,C,T,N,q){var I,V,H,G,W=C+"-"+w,j=q+"-"+N,R=a.props.highlightLines.includes(W)||a.props.highlightLines.includes(j),J=E===d.DiffType.ADDED,M=E===d.DiffType.REMOVED,P;return Array.isArray(T)?P=a.renderWordDiff(T,a.props.renderContent):a.props.renderContent?P=a.props.renderContent(T):P=T,n.createElement(n.Fragment,null,!a.props.hideLineNumbers&&n.createElement("td",{onClick:w&&a.onLineNumberClickProxy(W),className:c.default(a.styles.gutter,(I={},I[a.styles.emptyGutter]=!w,I[a.styles.diffAdded]=J,I[a.styles.diffRemoved]=M,I[a.styles.highlightedGutter]=R,I))},n.createElement("pre",{className:a.styles.lineNumber},w)),!a.props.splitView&&!a.props.hideLineNumbers&&n.createElement("td",{onClick:N&&a.onLineNumberClickProxy(j),className:c.default(a.styles.gutter,(V={},V[a.styles.emptyGutter]=!N,V[a.styles.diffAdded]=J,V[a.styles.diffRemoved]=M,V[a.styles.highlightedGutter]=R,V))},n.createElement("pre",{className:a.styles.lineNumber},N)),n.createElement("td",{className:c.default(a.styles.marker,(H={},H[a.styles.emptyLine]=!P,H[a.styles.diffAdded]=J,H[a.styles.diffRemoved]=M,H[a.styles.highlightedLine]=R,H))},n.createElement("pre",null,J&&"+",M&&"-")),n.createElement("td",{className:c.default(a.styles.content,(G={},G[a.styles.emptyLine]=!P,G[a.styles.diffAdded]=J,G[a.styles.diffRemoved]=M,G[a.styles.highlightedLine]=R,G))},n.createElement("pre",{className:a.styles.contentText},P)))},a.renderSplitView=function(w,E){var C=w.left,T=w.right;return n.createElement("tr",{key:E,className:a.styles.line},a.renderLine(C.lineNumber,C.type,k.LEFT,C.value),a.renderLine(T.lineNumber,T.type,k.RIGHT,T.value))},a.renderInlineView=function(w,E){var C=w.left,T=w.right,N;return C.type===d.DiffType.REMOVED&&T.type===d.DiffType.ADDED?n.createElement(n.Fragment,{key:E},n.createElement("tr",{className:a.styles.line},a.renderLine(C.lineNumber,C.type,k.LEFT,C.value,null)),n.createElement("tr",{className:a.styles.line},a.renderLine(null,T.type,k.RIGHT,T.value,T.lineNumber))):(C.type===d.DiffType.REMOVED&&(N=a.renderLine(C.lineNumber,C.type,k.LEFT,C.value,null)),C.type===d.DiffType.DEFAULT&&(N=a.renderLine(C.lineNumber,C.type,k.LEFT,C.value,T.lineNumber,k.RIGHT)),T.type===d.DiffType.ADDED&&(N=a.renderLine(null,T.type,k.RIGHT,T.value,T.lineNumber)),n.createElement("tr",{key:E,className:a.styles.line},N))},a.onBlockClickProxy=function(w){return function(){return a.onBlockExpand(w)}},a.renderSkippedLineIndicator=function(w,E,C,T){var N,q=a.props,I=q.hideLineNumbers,V=q.splitView,H=a.props.codeFoldMessageRenderer?a.props.codeFoldMessageRenderer(w,C,T):n.createElement("pre",{className:a.styles.codeFoldContent},"Expand ",w," lines ..."),G=n.createElement("td",null,n.createElement("a",{onClick:a.onBlockClickProxy(E),tabIndex:0},H)),W=!V&&!I;return n.createElement("tr",{key:C+"-"+T,className:a.styles.codeFold},!I&&n.createElement("td",{className:a.styles.codeFoldGutter}),n.createElement("td",{className:c.default((N={},N[a.styles.codeFoldGutter]=W,N))}),W?n.createElement(n.Fragment,null,n.createElement("td",null),G):n.createElement(n.Fragment,null,G,n.createElement("td",null)),n.createElement("td",null),n.createElement("td",null))},a.renderDiff=function(){var w=a.props,E=w.oldValue,C=w.newValue,T=w.splitView,N=w.disableWordDiff,q=w.compareMethod,I=w.linesOffset,V=d.computeLineInformation(E,C,N,q,I),H=V.lineInformation,G=V.diffLines,W=a.props.extraLinesSurroundingDiff<0?0:a.props.extraLinesSurroundingDiff,j=[];return H.map(function(R,J){var M=G[0],P=M-J;if(a.props.showDiffOnly&&(P===-W&&(j=[],G.shift()),R.left.type===d.DiffType.DEFAULT&&(P>W||typeof M>"u")&&!a.state.expandedBlocks.includes(M)))return j.push(J+1),J===H.length-1&&j.length>1?a.renderSkippedLineIndicator(j.length,M,R.left.lineNumber,R.right.lineNumber):null;var Y=T?a.renderSplitView(R,J):a.renderInlineView(R,J);if(P===W&&j.length>0){var $=j.length;return j=[],n.createElement(n.Fragment,{key:J},a.renderSkippedLineIndicator($,M,R.left.lineNumber,R.right.lineNumber),Y)}return Y})},a.render=function(){var w,E=a.props,C=E.oldValue,T=E.newValue,N=E.useDarkTheme,q=E.leftTitle,I=E.rightTitle,V=E.splitView,H=E.hideLineNumbers;if(typeof C!="string"||typeof T!="string")throw Error('"oldValue" and "newValue" should be strings');a.styles=a.computeStyles(a.props.styles,N);var G=a.renderDiff(),W=H?2:3,j=H?2:4,R=(q||I)&&n.createElement("tr",null,n.createElement("td",{colSpan:V?W:j,className:a.styles.titleBlock},n.createElement("pre",{className:a.styles.contentText},q)),V&&n.createElement("td",{colSpan:W,className:a.styles.titleBlock},n.createElement("pre",{className:a.styles.contentText},I)));return n.createElement("table",{className:c.default(a.styles.diffContainer,(w={},w[a.styles.splitView]=V,w))},n.createElement("tbody",null,R,G))},a.state={expandedBlocks:[]},a}return A.defaultProps={oldValue:"",newValue:"",splitView:!0,highlightLines:[],disableWordDiff:!1,compareMethod:d.DiffMethod.CHARS,styles:{},hideLineNumbers:!1,extraLinesSurroundingDiff:3,showDiffOnly:!0,useDarkTheme:!1,linesOffset:0},A.propTypes={oldValue:o.string.isRequired,newValue:o.string.isRequired,splitView:o.bool,disableWordDiff:o.bool,compareMethod:o.oneOf(Object.values(d.DiffMethod)),renderContent:o.func,onLineNumberClick:o.func,extraLinesSurroundingDiff:o.number,styles:o.object,hideLineNumbers:o.bool,showDiffOnly:o.bool,highlightLines:o.arrayOf(o.string),leftTitle:o.oneOfType([o.string,o.element]),rightTitle:o.oneOfType([o.string,o.element]),linesOffset:o.number},A}(n.Component);f.default=v})(_e);const mn=Tt(_e),it=25*1024*1024,lt=500,at=1e3,gn=f=>{const i=U.useMemo(()=>f.fileContents.map(g=>Bt(g.extension,g.text,lt,at)),[f.fileContents]),n=U.useMemo(()=>i.some(g=>g.truncatedTotalLines),[i]),o=U.useMemo(()=>i.some(g=>g.truncatedLineLength),[i]),c=U.useMemo(()=>i.map(g=>g.text),[i]),d=g=>U.createElement("pre",{style:{display:"inline"},dangerouslySetInnerHTML:{__html:Ye.highlight(g||"",Ye.languages.python,"python")}});return U.createElement("div",{style:{width:"100%",height:"100%",overflowY:"auto"}},o&&U.createElement(Fe,{textAlign:"center"},"Warning: some lines truncated to ",lt," characters for display"),n&&U.createElement(Fe,{textAlign:"center"},"Warning: truncated to ",at," lines for display"),(o||n)&&f.fileContents.length>=2&&f.fileContents[0].text!==f.fileContents[1].text&&U.createElement(Fe,{textAlign:"center"},"Warning: Files differ but we truncated the content prior to diffing. Diff display may not show all mismatches."),U.createElement(mn,{oldValue:c[0]??void 0,newValue:c[1]??void 0,renderContent:d,compareMethod:_e.DiffMethod.WORDS,styles:{contentText:{overflow:"hidden"}}}))},yn=f=>{const i=f.input,n=st(kt,"file",i,{}),o=ft(n),c=U.useMemo(()=>{const d=At(Ot(i.type)),g=Dt(d)&&d.extension!=null?d.extension:"";return(o.result??[]).map(S=>({extension:g,text:S}))},[o.result,i.type]);return o.loading?U.createElement("div",null):U.createElement(gn,{fileContents:c})},wn=f=>f.sizes.filter(n=>(n??0)>it).length>0?U.createElement(Fe,{textAlign:"center"},"Text view limited to files less than"," ",Vt(it).format("0.0b")):U.createElement(U.Fragment,null,f.children),Ln=f=>{const i=st(Ft,"file",f.input,{}),n=ft(i);return n.loading?U.createElement("div",null):U.createElement(wn,{sizes:n.result},U.createElement(yn,{...f}))};export{Ln as default};
//# sourceMappingURL=Component.8f8ec3c1.js.map
