@spotlightjs/spotlight 2.8.0 → 2.8.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.
|
@@ -201,4 +201,4 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
201
201
|
`)+`
|
|
202
202
|
`}function fy(e,t,n,r,a,s,i){return OA(py(e,t,n,r,a,s,i))}function L8(e,t,n,r,a,s){return fy(e,e,t,n,r,a,s)}var hd={};Object.defineProperty(hd,"__esModule",{value:!0});hd.arrayEqual=v8;hd.arrayStartsWith=Ty;function v8(e,t){return e.length!==t.length?!1:Ty(e,t)}function Ty(e,t){if(t.length>e.length)return!1;for(var n=0;n<t.length;n++)if(t[n]!==e[n])return!1;return!0}Object.defineProperty(Td,"__esModule",{value:!0});Td.calcLineCount=hy;Td.merge=k8;var M8=ri,P8=iu,Hp=hd;function Ui(e){return U8(e)||w8(e)||x8(e)||D8()}function D8(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
203
203
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function x8(e,t){if(e){if(typeof e=="string")return NT(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return NT(e,t)}}function w8(e){if(typeof Symbol<"u"&&Symbol.iterator in Object(e))return Array.from(e)}function U8(e){if(Array.isArray(e))return NT(e)}function NT(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function hy(e){var t=OT(e.lines),n=t.oldLines,r=t.newLines;n!==void 0?e.oldLines=n:delete e.oldLines,r!==void 0?e.newLines=r:delete e.newLines}function k8(e,t,n){e=q_(e,n),t=q_(t,n);var r={};(e.index||t.index)&&(r.index=e.index||t.index),(e.newFileName||t.newFileName)&&(J_(e)?J_(t)?(r.oldFileName=Ju(r,e.oldFileName,t.oldFileName),r.newFileName=Ju(r,e.newFileName,t.newFileName),r.oldHeader=Ju(r,e.oldHeader,t.oldHeader),r.newHeader=Ju(r,e.newHeader,t.newHeader)):(r.oldFileName=e.oldFileName,r.newFileName=e.newFileName,r.oldHeader=e.oldHeader,r.newHeader=e.newHeader):(r.oldFileName=t.oldFileName||e.oldFileName,r.newFileName=t.newFileName||e.newFileName,r.oldHeader=t.oldHeader||e.oldHeader,r.newHeader=t.newHeader||e.newHeader)),r.hunks=[];for(var a=0,s=0,i=0,o=0;a<e.hunks.length||s<t.hunks.length;){var l=e.hunks[a]||{oldStart:1/0},u=t.hunks[s]||{oldStart:1/0};if(Z_(l,u))r.hunks.push(Q_(l,i)),a++,o+=l.newLines-l.oldLines;else if(Z_(u,l))r.hunks.push(Q_(u,o)),s++,i+=u.newLines-u.oldLines;else{var c={oldStart:Math.min(l.oldStart,u.oldStart),oldLines:0,newStart:Math.min(l.newStart+i,u.oldStart+o),newLines:0,lines:[]};G8(c,l.oldStart,l.lines,u.oldStart,u.lines),s++,a++,r.hunks.push(c)}}return r}function q_(e,t){if(typeof e=="string"){if(/^@@/m.test(e)||/^Index:/m.test(e))return(0,P8.parsePatch)(e)[0];if(!t)throw new Error("Must provide a base reference or pass in a patch");return(0,M8.structuredPatch)(void 0,void 0,t,e)}return e}function J_(e){return e.newFileName&&e.newFileName!==e.oldFileName}function Ju(e,t,n){return t===n?t:(e.conflict=!0,{mine:t,theirs:n})}function Z_(e,t){return e.oldStart<t.oldStart&&e.oldStart+e.oldLines<t.oldStart}function Q_(e,t){return{oldStart:e.oldStart,oldLines:e.oldLines,newStart:e.newStart+t,newLines:e.newLines,lines:e.lines}}function G8(e,t,n,r,a){var s={offset:t,lines:n,index:0},i={offset:r,lines:a,index:0};for(eN(e,s,i),eN(e,i,s);s.index<s.lines.length&&i.index<i.lines.length;){var o=s.lines[s.index],l=i.lines[i.index];if((o[0]==="-"||o[0]==="+")&&(l[0]==="-"||l[0]==="+"))B8(e,s,i);else if(o[0]==="+"&&l[0]===" "){var u;(u=e.lines).push.apply(u,Ui(ys(s)))}else if(l[0]==="+"&&o[0]===" "){var c;(c=e.lines).push.apply(c,Ui(ys(i)))}else o[0]==="-"&&l[0]===" "?$_(e,s,i):l[0]==="-"&&o[0]===" "?$_(e,i,s,!0):o===l?(e.lines.push(o),s.index++,i.index++):IA(e,ys(s),ys(i))}tN(e,s),tN(e,i),hy(e)}function B8(e,t,n){var r=ys(t),a=ys(n);if(nN(r)&&nN(a)){if((0,Hp.arrayStartsWith)(r,a)&&rN(n,r,r.length-a.length)){var s;(s=e.lines).push.apply(s,Ui(r));return}else if((0,Hp.arrayStartsWith)(a,r)&&rN(t,a,a.length-r.length)){var i;(i=e.lines).push.apply(i,Ui(a));return}}else if((0,Hp.arrayEqual)(r,a)){var o;(o=e.lines).push.apply(o,Ui(r));return}IA(e,r,a)}function $_(e,t,n,r){var a=ys(t),s=F8(n,a);if(s.merged){var i;(i=e.lines).push.apply(i,Ui(s.merged))}else IA(e,r?s:a,r?a:s)}function IA(e,t,n){e.conflict=!0,e.lines.push({conflict:!0,mine:t,theirs:n})}function eN(e,t,n){for(;t.offset<n.offset&&t.index<t.lines.length;){var r=t.lines[t.index++];e.lines.push(r),t.offset++}}function tN(e,t){for(;t.index<t.lines.length;){var n=t.lines[t.index++];e.lines.push(n)}}function ys(e){for(var t=[],n=e.lines[e.index][0];e.index<e.lines.length;){var r=e.lines[e.index];if(n==="-"&&r[0]==="+"&&(n="+"),n===r[0])t.push(r),e.index++;else break}return t}function F8(e,t){for(var n=[],r=[],a=0,s=!1,i=!1;a<t.length&&e.index<e.lines.length;){var o=e.lines[e.index],l=t[a];if(l[0]==="+")break;if(s=s||o[0]!==" ",r.push(l),a++,o[0]==="+")for(i=!0;o[0]==="+";)n.push(o),o=e.lines[++e.index];l.substr(1)===o.substr(1)?(n.push(o),e.index++):i=!0}if((t[a]||"")[0]==="+"&&s&&(i=!0),i)return n;for(;a<t.length;)r.push(t[a++]);return{merged:r,changes:n}}function nN(e){return e.reduce(function(t,n){return t&&n[0]==="-"},!0)}function rN(e,t,n){for(var r=0;r<n;r++){var a=t[t.length-n+r].substr(1);if(e.lines[e.index+r]!==" "+a)return!1}return e.index+=n,!0}function OT(e){var t=0,n=0;return e.forEach(function(r){if(typeof r!="string"){var a=OT(r.mine),s=OT(r.theirs);t!==void 0&&(a.oldLines===s.oldLines?t+=a.oldLines:t=void 0),n!==void 0&&(a.newLines===s.newLines?n+=a.newLines:n=void 0)}else n!==void 0&&(r[0]==="+"||r[0]===" ")&&n++,t!==void 0&&(r[0]==="-"||r[0]===" ")&&t++}),{oldLines:t,newLines:n}}var gA={};Object.defineProperty(gA,"__esModule",{value:!0});gA.reversePatch=Ay;function aN(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function sN(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?aN(Object(n),!0).forEach(function(r){H8(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):aN(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function H8(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ay(e){return Array.isArray(e)?e.map(Ay).reverse():sN(sN({},e),{},{oldFileName:e.newFileName,oldHeader:e.newHeader,newFileName:e.oldFileName,newHeader:e.oldHeader,hunks:e.hunks.map(function(t){return{oldLines:t.newLines,oldStart:t.newStart,newLines:t.oldLines,newStart:t.oldStart,linedelimiters:t.linedelimiters,lines:t.lines.map(function(n){return n.startsWith("-")?"+".concat(n.slice(1)):n.startsWith("+")?"-".concat(n.slice(1)):n})}})})}var CA={};Object.defineProperty(CA,"__esModule",{value:!0});CA.convertChangesToDMP=Y8;function Y8(e){for(var t=[],n,r,a=0;a<e.length;a++)n=e[a],n.added?r=1:n.removed?r=-1:r=0,t.push([r,n.value]);return t}var yA={};Object.defineProperty(yA,"__esModule",{value:!0});yA.convertChangesToXML=V8;function V8(e){for(var t=[],n=0;n<e.length;n++){var r=e[n];r.added?t.push("<ins>"):r.removed&&t.push("<del>"),t.push(W8(r.value)),r.added?t.push("</ins>"):r.removed&&t.push("</del>")}return t.join("")}function W8(e){var t=e;return t=t.replace(/&/g,"&"),t=t.replace(/</g,"<"),t=t.replace(/>/g,">"),t=t.replace(/"/g,"""),t}(function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"Diff",{enumerable:!0,get:function(){return t.default}}),Object.defineProperty(e,"diffChars",{enumerable:!0,get:function(){return n.diffChars}}),Object.defineProperty(e,"diffWords",{enumerable:!0,get:function(){return r.diffWords}}),Object.defineProperty(e,"diffWordsWithSpace",{enumerable:!0,get:function(){return r.diffWordsWithSpace}}),Object.defineProperty(e,"diffLines",{enumerable:!0,get:function(){return a.diffLines}}),Object.defineProperty(e,"diffTrimmedLines",{enumerable:!0,get:function(){return a.diffTrimmedLines}}),Object.defineProperty(e,"diffSentences",{enumerable:!0,get:function(){return s.diffSentences}}),Object.defineProperty(e,"diffCss",{enumerable:!0,get:function(){return i.diffCss}}),Object.defineProperty(e,"diffJson",{enumerable:!0,get:function(){return o.diffJson}}),Object.defineProperty(e,"canonicalize",{enumerable:!0,get:function(){return o.canonicalize}}),Object.defineProperty(e,"diffArrays",{enumerable:!0,get:function(){return l.diffArrays}}),Object.defineProperty(e,"applyPatch",{enumerable:!0,get:function(){return u.applyPatch}}),Object.defineProperty(e,"applyPatches",{enumerable:!0,get:function(){return u.applyPatches}}),Object.defineProperty(e,"parsePatch",{enumerable:!0,get:function(){return c.parsePatch}}),Object.defineProperty(e,"merge",{enumerable:!0,get:function(){return E.merge}}),Object.defineProperty(e,"reversePatch",{enumerable:!0,get:function(){return f.reversePatch}}),Object.defineProperty(e,"structuredPatch",{enumerable:!0,get:function(){return A.structuredPatch}}),Object.defineProperty(e,"createTwoFilesPatch",{enumerable:!0,get:function(){return A.createTwoFilesPatch}}),Object.defineProperty(e,"createPatch",{enumerable:!0,get:function(){return A.createPatch}}),Object.defineProperty(e,"formatPatch",{enumerable:!0,get:function(){return A.formatPatch}}),Object.defineProperty(e,"convertChangesToDMP",{enumerable:!0,get:function(){return _.convertChangesToDMP}}),Object.defineProperty(e,"convertChangesToXML",{enumerable:!0,get:function(){return g.convertChangesToXML}});var t=I(Ta),n=tu,r=_o,a=Ts,s=ru,i=au,o=No,l=su,u=fd,c=iu,E=Td,f=gA,A=ri,_=CA,g=yA;function I(d){return d&&d.__esModule?d:{default:d}}})(oy);var j8=st&&st.__createBinding||(Object.create?function(e,t,n,r){r===void 0&&(r=n);var a=Object.getOwnPropertyDescriptor(t,n);(!a||("get"in a?!t.__esModule:a.writable||a.configurable))&&(a={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,a)}:function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]}),X8=st&&st.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),K8=st&&st.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var n in e)n!=="default"&&Object.prototype.hasOwnProperty.call(e,n)&&j8(t,e,n);return X8(t,e),t};Object.defineProperty(Ja,"__esModule",{value:!0});Ja.computeLineInformation=Ja.DiffMethod=Ja.DiffType=void 0;const IT=K8(oy),z8=IT;var $r;(function(e){e[e.DEFAULT=0]="DEFAULT",e[e.ADDED=1]="ADDED",e[e.REMOVED=2]="REMOVED",e[e.CHANGED=3]="CHANGED"})($r||(Ja.DiffType=$r={}));var SE;(function(e){e.CHARS="diffChars",e.WORDS="diffWords",e.WORDS_WITH_SPACE="diffWordsWithSpace",e.LINES="diffLines",e.TRIMMED_LINES="diffTrimmedLines",e.SENTENCES="diffSentences",e.CSS="diffCss",e.JSON="diffJson"})(SE||(Ja.DiffMethod=SE={}));const iN=e=>e===""?[]:e.replace(/\n$/,"").split(`
|
|
204
|
-
`),q8=(e,t,n=SE.CHARS)=>{const r=z8[n](e,t),a={left:[],right:[]};return r.forEach(({added:s,removed:i,value:o})=>{const l={};return s&&(l.type=$r.ADDED,l.value=o,a.right.push(l)),i&&(l.type=$r.REMOVED,l.value=o,a.left.push(l)),!i&&!s&&(l.type=$r.DEFAULT,l.value=o,a.right.push(l),a.left.push(l)),l}),a},J8=(e,t,n=!1,r=SE.CHARS,a=0,s=[])=>{let i=[];typeof e=="string"&&typeof t=="string"?i=IT.diffLines(e.trimRight(),t.trimRight(),{newlineIsToken:!1,ignoreWhitespace:!1,ignoreCase:!1}):i=IT.diffJson(e,t);let o=a,l=a,u=[],c=0;const E=[],f=[],A=(_,g,I,d,p)=>iN(_).map((m,h)=>{const O={},T={};if(!(f.includes(`${g}-${h}`)||p&&h!==0)){if(I||d){let N=!0;if(d){l+=1,O.lineNumber=l,O.type=$r.REMOVED,O.value=m||" ";const C=i[g+1];if(C&&C.added){const P=iN(C.value)[h];if(P){const S=A(P,g,!0,!1,!0),{value:L,lineNumber:D,type:B}=S[0].right;if(f.push(`${g+1}-${h}`),T.lineNumber=D,O.value===L)N=!1,T.type=0,O.type=0,T.value=L;else if(T.type=B,n)T.value=L;else{const F=q8(m,L,r);T.value=F.right,O.value=F.left}}}}else o+=1,T.lineNumber=o,T.type=$r.ADDED,T.value=m;N&&!p&&(E.includes(c)||E.push(c))}else l+=1,o+=1,O.lineNumber=l,O.type=$r.DEFAULT,O.value=m,T.lineNumber=o,T.type=$r.DEFAULT,T.value=m;return(s!=null&&s.includes(`L-${O.lineNumber}`)||s!=null&&s.includes(`R-${T.lineNumber}`)&&!E.includes(c))&&E.push(c),p||(c+=1),{right:T,left:O}}}).filter(Boolean);return i.forEach(({added:_,removed:g,value:I},d)=>{u=[...u,...A(I,d,_,g)]}),{lineInformation:u,diffLines:E}};Ja.computeLineInformation=J8;var bA={},Z8=!1;function Q8(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}function $8(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),e.nonce!==void 0&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t}var eY=function(){function e(n){var r=this;this._insertTag=function(a){var s;r.tags.length===0?r.insertionPoint?s=r.insertionPoint.nextSibling:r.prepend?s=r.container.firstChild:s=r.before:s=r.tags[r.tags.length-1].nextSibling,r.container.insertBefore(a,s),r.tags.push(a)},this.isSpeedy=n.speedy===void 0?!Z8:n.speedy,this.tags=[],this.ctr=0,this.nonce=n.nonce,this.key=n.key,this.container=n.container,this.prepend=n.prepend,this.insertionPoint=n.insertionPoint,this.before=null}var t=e.prototype;return t.hydrate=function(n){n.forEach(this._insertTag)},t.insert=function(n){this.ctr%(this.isSpeedy?65e3:1)===0&&this._insertTag($8(this));var r=this.tags[this.tags.length-1];if(this.isSpeedy){var a=Q8(r);try{a.insertRule(n,a.cssRules.length)}catch{}}else r.appendChild(document.createTextNode(n));this.ctr++},t.flush=function(){this.tags.forEach(function(n){var r;return(r=n.parentNode)==null?void 0:r.removeChild(n)}),this.tags=[],this.ctr=0},e}(),rn="-ms-",mE="-moz-",Fe="-webkit-",Ry="comm",LA="rule",vA="decl",tY="@import",Sy="@keyframes",nY="@layer",rY=Math.abs,Ad=String.fromCharCode,aY=Object.assign;function sY(e,t){return Xt(e,0)^45?(((t<<2^Xt(e,0))<<2^Xt(e,1))<<2^Xt(e,2))<<2^Xt(e,3):0}function my(e){return e.trim()}function iY(e,t){return(e=t.exec(e))?e[0]:e}function He(e,t,n){return e.replace(t,n)}function gT(e,t){return e.indexOf(t)}function Xt(e,t){return e.charCodeAt(t)|0}function wl(e,t,n){return e.slice(t,n)}function vr(e){return e.length}function MA(e){return e.length}function Zu(e,t){return t.push(e),e}function oY(e,t){return e.map(t).join("")}var Rd=1,no=1,_y=0,Ln=0,Nt=0,Oo="";function Sd(e,t,n,r,a,s,i){return{value:e,root:t,parent:n,type:r,props:a,children:s,line:Rd,column:no,length:i,return:""}}function Fo(e,t){return aY(Sd("",null,null,"",null,null,0),e,{length:-e.length},t)}function lY(){return Nt}function uY(){return Nt=Ln>0?Xt(Oo,--Ln):0,no--,Nt===10&&(no=1,Rd--),Nt}function Hn(){return Nt=Ln<_y?Xt(Oo,Ln++):0,no++,Nt===10&&(no=1,Rd++),Nt}function Gr(){return Xt(Oo,Ln)}function mc(){return Ln}function ou(e,t){return wl(Oo,e,t)}function Ul(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function Ny(e){return Rd=no=1,_y=vr(Oo=e),Ln=0,[]}function Oy(e){return Oo="",e}function _c(e){return my(ou(Ln-1,CT(e===91?e+2:e===40?e+1:e)))}function cY(e){for(;(Nt=Gr())&&Nt<33;)Hn();return Ul(e)>2||Ul(Nt)>3?"":" "}function EY(e,t){for(;--t&&Hn()&&!(Nt<48||Nt>102||Nt>57&&Nt<65||Nt>70&&Nt<97););return ou(e,mc()+(t<6&&Gr()==32&&Hn()==32))}function CT(e){for(;Hn();)switch(Nt){case e:return Ln;case 34:case 39:e!==34&&e!==39&&CT(Nt);break;case 40:e===41&&CT(e);break;case 92:Hn();break}return Ln}function dY(e,t){for(;Hn()&&e+Nt!==57&&!(e+Nt===84&&Gr()===47););return"/*"+ou(t,Ln-1)+"*"+Ad(e===47?e:Hn())}function pY(e){for(;!Ul(Gr());)Hn();return ou(e,Ln)}function fY(e){return Oy(Nc("",null,null,null,[""],e=Ny(e),0,[0],e))}function Nc(e,t,n,r,a,s,i,o,l){for(var u=0,c=0,E=i,f=0,A=0,_=0,g=1,I=1,d=1,p=0,m="",h=a,O=s,T=r,N=m;I;)switch(_=p,p=Hn()){case 40:if(_!=108&&Xt(N,E-1)==58){gT(N+=He(_c(p),"&","&\f"),"&\f")!=-1&&(d=-1);break}case 34:case 39:case 91:N+=_c(p);break;case 9:case 10:case 13:case 32:N+=cY(_);break;case 92:N+=EY(mc()-1,7);continue;case 47:switch(Gr()){case 42:case 47:Zu(TY(dY(Hn(),mc()),t,n),l);break;default:N+="/"}break;case 123*g:o[u++]=vr(N)*d;case 125*g:case 59:case 0:switch(p){case 0:case 125:I=0;case 59+c:d==-1&&(N=He(N,/\f/g,"")),A>0&&vr(N)-E&&Zu(A>32?lN(N+";",r,n,E-1):lN(He(N," ","")+";",r,n,E-2),l);break;case 59:N+=";";default:if(Zu(T=oN(N,t,n,u,c,a,o,m,h=[],O=[],E),s),p===123)if(c===0)Nc(N,t,T,T,h,s,E,o,O);else switch(f===99&&Xt(N,3)===110?100:f){case 100:case 108:case 109:case 115:Nc(e,T,T,r&&Zu(oN(e,T,T,0,0,a,o,m,a,h=[],E),O),a,O,E,o,r?h:O);break;default:Nc(N,T,T,T,[""],O,0,o,O)}}u=c=A=0,g=d=1,m=N="",E=i;break;case 58:E=1+vr(N),A=_;default:if(g<1){if(p==123)--g;else if(p==125&&g++==0&&uY()==125)continue}switch(N+=Ad(p),p*g){case 38:d=c>0?1:(N+="\f",-1);break;case 44:o[u++]=(vr(N)-1)*d,d=1;break;case 64:Gr()===45&&(N+=_c(Hn())),f=Gr(),c=E=vr(m=N+=pY(mc())),p++;break;case 45:_===45&&vr(N)==2&&(g=0)}}return s}function oN(e,t,n,r,a,s,i,o,l,u,c){for(var E=a-1,f=a===0?s:[""],A=MA(f),_=0,g=0,I=0;_<r;++_)for(var d=0,p=wl(e,E+1,E=rY(g=i[_])),m=e;d<A;++d)(m=my(g>0?f[d]+" "+p:He(p,/&\f/g,f[d])))&&(l[I++]=m);return Sd(e,t,n,a===0?LA:o,l,u,c)}function TY(e,t,n){return Sd(e,t,n,Ry,Ad(lY()),wl(e,2,-2),0)}function lN(e,t,n,r){return Sd(e,t,n,vA,wl(e,0,r),wl(e,r+1,-1),r)}function ki(e,t){for(var n="",r=MA(e),a=0;a<r;a++)n+=t(e[a],a,e,t)||"";return n}function hY(e,t,n,r){switch(e.type){case nY:if(e.children.length)break;case tY:case vA:return e.return=e.return||e.value;case Ry:return"";case Sy:return e.return=e.value+"{"+ki(e.children,r)+"}";case LA:e.value=e.props.join(",")}return vr(n=ki(e.children,r))?e.return=e.value+"{"+n+"}":""}function AY(e){var t=MA(e);return function(n,r,a,s){for(var i="",o=0;o<t;o++)i+=e[o](n,r,a,s)||"";return i}}function RY(e){return function(t){t.root||(t=t.return)&&e(t)}}function SY(e){var t=Object.create(null);return function(n){return t[n]===void 0&&(t[n]=e(n)),t[n]}}var mY=function(e,t,n){for(var r=0,a=0;r=a,a=Gr(),r===38&&a===12&&(t[n]=1),!Ul(a);)Hn();return ou(e,Ln)},_Y=function(e,t){var n=-1,r=44;do switch(Ul(r)){case 0:r===38&&Gr()===12&&(t[n]=1),e[n]+=mY(Ln-1,t,n);break;case 2:e[n]+=_c(r);break;case 4:if(r===44){e[++n]=Gr()===58?"&\f":"",t[n]=e[n].length;break}default:e[n]+=Ad(r)}while(r=Hn());return e},NY=function(e,t){return Oy(_Y(Ny(e),t))},uN=new WeakMap,OY=function(e){if(!(e.type!=="rule"||!e.parent||e.length<1)){for(var t=e.value,n=e.parent,r=e.column===n.column&&e.line===n.line;n.type!=="rule";)if(n=n.parent,!n)return;if(!(e.props.length===1&&t.charCodeAt(0)!==58&&!uN.get(n))&&!r){uN.set(e,!0);for(var a=[],s=NY(t,a),i=n.props,o=0,l=0;o<s.length;o++)for(var u=0;u<i.length;u++,l++)e.props[l]=a[o]?s[o].replace(/&\f/g,i[u]):i[u]+" "+s[o]}}},IY=function(e){if(e.type==="decl"){var t=e.value;t.charCodeAt(0)===108&&t.charCodeAt(2)===98&&(e.return="",e.value="")}};function Iy(e,t){switch(sY(e,t)){case 5103:return Fe+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return Fe+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return Fe+e+mE+e+rn+e+e;case 6828:case 4268:return Fe+e+rn+e+e;case 6165:return Fe+e+rn+"flex-"+e+e;case 5187:return Fe+e+He(e,/(\w+).+(:[^]+)/,Fe+"box-$1$2"+rn+"flex-$1$2")+e;case 5443:return Fe+e+rn+"flex-item-"+He(e,/flex-|-self/,"")+e;case 4675:return Fe+e+rn+"flex-line-pack"+He(e,/align-content|flex-|-self/,"")+e;case 5548:return Fe+e+rn+He(e,"shrink","negative")+e;case 5292:return Fe+e+rn+He(e,"basis","preferred-size")+e;case 6060:return Fe+"box-"+He(e,"-grow","")+Fe+e+rn+He(e,"grow","positive")+e;case 4554:return Fe+He(e,/([^-])(transform)/g,"$1"+Fe+"$2")+e;case 6187:return He(He(He(e,/(zoom-|grab)/,Fe+"$1"),/(image-set)/,Fe+"$1"),e,"")+e;case 5495:case 3959:return He(e,/(image-set\([^]*)/,Fe+"$1$`$1");case 4968:return He(He(e,/(.+:)(flex-)?(.*)/,Fe+"box-pack:$3"+rn+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+Fe+e+e;case 4095:case 3583:case 4068:case 2532:return He(e,/(.+)-inline(.+)/,Fe+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(vr(e)-1-t>6)switch(Xt(e,t+1)){case 109:if(Xt(e,t+4)!==45)break;case 102:return He(e,/(.+:)(.+)-([^]+)/,"$1"+Fe+"$2-$3$1"+mE+(Xt(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~gT(e,"stretch")?Iy(He(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(Xt(e,t+1)!==115)break;case 6444:switch(Xt(e,vr(e)-3-(~gT(e,"!important")&&10))){case 107:return He(e,":",":"+Fe)+e;case 101:return He(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+Fe+(Xt(e,14)===45?"inline-":"")+"box$3$1"+Fe+"$2$3$1"+rn+"$2box$3")+e}break;case 5936:switch(Xt(e,t+11)){case 114:return Fe+e+rn+He(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return Fe+e+rn+He(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return Fe+e+rn+He(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return Fe+e+rn+e+e}return e}var gY=function(e,t,n,r){if(e.length>-1&&!e.return)switch(e.type){case vA:e.return=Iy(e.value,e.length);break;case Sy:return ki([Fo(e,{value:He(e.value,"@","@"+Fe)})],r);case LA:if(e.length)return oY(e.props,function(a){switch(iY(a,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return ki([Fo(e,{props:[He(a,/:(read-\w+)/,":"+mE+"$1")]})],r);case"::placeholder":return ki([Fo(e,{props:[He(a,/:(plac\w+)/,":"+Fe+"input-$1")]}),Fo(e,{props:[He(a,/:(plac\w+)/,":"+mE+"$1")]}),Fo(e,{props:[He(a,/:(plac\w+)/,rn+"input-$1")]})],r)}return""})}},CY=[gY],yY=function(e){var t=e.key;if(t==="css"){var n=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(n,function(_){var g=_.getAttribute("data-emotion");g.indexOf(" ")!==-1&&(document.head.appendChild(_),_.setAttribute("data-s",""))})}var r=e.stylisPlugins||CY,a={},s,i=[];s=e.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+t+' "]'),function(_){for(var g=_.getAttribute("data-emotion").split(" "),I=1;I<g.length;I++)a[g[I]]=!0;i.push(_)});var o,l=[OY,IY];{var u,c=[hY,RY(function(_){u.insert(_)})],E=AY(l.concat(r,c)),f=function(_){return ki(fY(_),E)};o=function(_,g,I,d){u=I,f(_?_+"{"+g.styles+"}":g.styles),d&&(A.inserted[g.name]=!0)}}var A={key:t,sheet:new eY({key:t,container:s,nonce:e.nonce,speedy:e.speedy,prepend:e.prepend,insertionPoint:e.insertionPoint}),nonce:e.nonce,inserted:a,registered:{},insert:o};return A.sheet.hydrate(i),A};function bY(e){for(var t=0,n,r=0,a=e.length;a>=4;++r,a-=4)n=e.charCodeAt(r)&255|(e.charCodeAt(++r)&255)<<8|(e.charCodeAt(++r)&255)<<16|(e.charCodeAt(++r)&255)<<24,n=(n&65535)*1540483477+((n>>>16)*59797<<16),n^=n>>>24,t=(n&65535)*1540483477+((n>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(a){case 3:t^=(e.charCodeAt(r+2)&255)<<16;case 2:t^=(e.charCodeAt(r+1)&255)<<8;case 1:t^=e.charCodeAt(r)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var LY={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},vY=!1,MY=/[A-Z]|^ms/g,PY=/_EMO_([^_]+?)_([^]*?)_EMO_/g,gy=function(e){return e.charCodeAt(1)===45},cN=function(e){return e!=null&&typeof e!="boolean"},Yp=SY(function(e){return gy(e)?e:e.replace(MY,"-$&").toLowerCase()}),EN=function(e,t){switch(e){case"animation":case"animationName":if(typeof t=="string")return t.replace(PY,function(n,r,a){return wa={name:r,styles:a,next:wa},r})}return LY[e]!==1&&!gy(e)&&typeof t=="number"&&t!==0?t+"px":t},DY="Component selectors can only be used in conjunction with @emotion/babel-plugin, the swc Emotion plugin, or another Emotion-aware compiler transform.";function _E(e,t,n){if(n==null)return"";var r=n;if(r.__emotion_styles!==void 0)return r;switch(typeof n){case"boolean":return"";case"object":{var a=n;if(a.anim===1)return wa={name:a.name,styles:a.styles,next:wa},a.name;var s=n;if(s.styles!==void 0){var i=s.next;if(i!==void 0)for(;i!==void 0;)wa={name:i.name,styles:i.styles,next:wa},i=i.next;var o=s.styles+";";return o}return xY(e,t,n)}}var l=n;if(t==null)return l;var u=t[l];return u!==void 0?u:l}function xY(e,t,n){var r="";if(Array.isArray(n))for(var a=0;a<n.length;a++)r+=_E(e,t,n[a])+";";else for(var s in n){var i=n[s];if(typeof i!="object"){var o=i;t!=null&&t[o]!==void 0?r+=s+"{"+t[o]+"}":cN(o)&&(r+=Yp(s)+":"+EN(s,o)+";")}else{if(s==="NO_COMPONENT_SELECTOR"&&vY)throw new Error(DY);if(Array.isArray(i)&&typeof i[0]=="string"&&(t==null||t[i[0]]===void 0))for(var l=0;l<i.length;l++)cN(i[l])&&(r+=Yp(s)+":"+EN(s,i[l])+";");else{var u=_E(e,t,i);switch(s){case"animation":case"animationName":{r+=Yp(s)+":"+u+";";break}default:r+=s+"{"+u+"}"}}}}return r}var dN=/label:\s*([^\s;{]+)\s*(;|$)/g,wa;function Vp(e,t,n){if(e.length===1&&typeof e[0]=="object"&&e[0]!==null&&e[0].styles!==void 0)return e[0];var r=!0,a="";wa=void 0;var s=e[0];if(s==null||s.raw===void 0)r=!1,a+=_E(n,t,s);else{var i=s;a+=i[0]}for(var o=1;o<e.length;o++)if(a+=_E(n,t,e[o]),r){var l=s;a+=l[o]}dN.lastIndex=0;for(var u="",c;(c=dN.exec(a))!==null;)u+="-"+c[1];var E=bY(a)+u;return{name:E,styles:a,next:wa}}function Cy(e,t,n){var r="";return n.split(" ").forEach(function(a){e[a]!==void 0?t.push(e[a]+";"):a&&(r+=a+" ")}),r}var wY=function(e,t,n){var r=e.key+"-"+t.name;e.registered[r]===void 0&&(e.registered[r]=t.styles)},UY=function(e,t,n){wY(e,t);var r=e.key+"-"+t.name;if(e.inserted[t.name]===void 0){var a=t;do e.insert(t===a?"."+r:"",a,e.sheet,!0),a=a.next;while(a!==void 0)}};function pN(e,t){if(e.inserted[t.name]===void 0)return e.insert("",t,e.sheet,!0)}function fN(e,t,n){var r=[],a=Cy(e,r,n);return r.length<2?n:a+t(r)}var kY=function(e){var t=yY(e);t.sheet.speedy=function(i){this.isSpeedy=i},t.compat=!0;var n=function(){for(var i=arguments.length,o=new Array(i),l=0;l<i;l++)o[l]=arguments[l];var u=Vp(o,t.registered,void 0);return UY(t,u),t.key+"-"+u.name},r=function(){for(var i=arguments.length,o=new Array(i),l=0;l<i;l++)o[l]=arguments[l];var u=Vp(o,t.registered),c="animation-"+u.name;return pN(t,{name:u.name,styles:"@keyframes "+c+"{"+u.styles+"}"}),c},a=function(){for(var i=arguments.length,o=new Array(i),l=0;l<i;l++)o[l]=arguments[l];var u=Vp(o,t.registered);pN(t,u)},s=function(){for(var i=arguments.length,o=new Array(i),l=0;l<i;l++)o[l]=arguments[l];return fN(t.registered,n,GY(o))};return{css:n,cx:s,injectGlobal:a,keyframes:r,hydrate:function(i){i.forEach(function(o){t.inserted[o]=!0})},flush:function(){t.registered={},t.inserted={},t.sheet.flush()},sheet:t.sheet,cache:t,getRegisteredStyles:Cy.bind(null,t.registered),merge:fN.bind(null,t.registered,n)}},GY=function e(t){for(var n="",r=0;r<t.length;r++){var a=t[r];if(a!=null){var s=void 0;switch(typeof a){case"boolean":break;case"object":{if(Array.isArray(a))s=e(a);else{s="";for(var i in a)a[i]&&i&&(s&&(s+=" "),s+=i)}break}default:s=a}s&&(n&&(n+=" "),n+=s)}}return n};const BY=Object.freeze(Object.defineProperty({__proto__:null,default:kY},Symbol.toStringTag,{value:"Module"})),FY=RN(BY);var HY=st&&st.__rest||function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)t.indexOf(r[a])<0&&Object.prototype.propertyIsEnumerable.call(e,r[a])&&(n[r[a]]=e[r[a]]);return n},YY=st&&st.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(bA,"__esModule",{value:!0});const VY=YY(FY);bA.default=(e,t=!1,n="")=>{const{variables:r={}}=e,a=HY(e,["variables"]),s={light:Object.assign({diffViewerBackground:"#fff",diffViewerColor:"#212529",addedBackground:"#e6ffed",addedColor:"#24292e",removedBackground:"#ffeef0",removedColor:"#24292e",changedBackground:"#fffbdd",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"},r.light||{}),dark:Object.assign({diffViewerBackground:"#2e303c",diffViewerColor:"#FFF",addedBackground:"#044B53",addedColor:"white",removedBackground:"#632F34",removedColor:"white",changedBackground:"#3e302c",wordAddedBackground:"#055d67",wordRemovedBackground:"#7d383f",addedGutterBackground:"#034148",removedGutterBackground:"#632b30",gutterBackground:"#2c2f3a",gutterBackgroundDark:"#262933",highlightBackground:"#2a3967",highlightGutterBackground:"#2d4077",codeFoldGutterBackground:"#21232b",codeFoldBackground:"#262831",emptyLineBackground:"#363946",gutterColor:"#666c87",addedGutterColor:"#8c8c8c",removedGutterColor:"#8c8c8c",codeFoldContentColor:"#656a8b",diffViewerTitleBackground:"#2f323e",diffViewerTitleColor:"#555a7b",diffViewerTitleBorderColor:"#353846"},r.dark||{})},i=t?s.dark:s.light,{css:o,cx:l}=(0,VY.default)({key:"react-diff",nonce:n}),u=o({width:"100%",label:"content"}),c=o({[`.${u}`]:{width:"50%"},label:"split-view"}),E=o({width:"100%",background:i.diffViewerBackground,pre:{margin:0,whiteSpace:"pre-wrap",lineHeight:"25px"},label:"diff-container",borderCollapse:"collapse"}),f=o({color:i.codeFoldContentColor,label:"code-fold-content"}),A=o({color:i.diffViewerColor,label:"content-text"}),_=o({background:i.diffViewerTitleBackground,padding:10,borderBottom:`1px solid ${i.diffViewerTitleBorderColor}`,label:"title-block",":last-child":{borderLeft:`1px solid ${i.diffViewerTitleBorderColor}`},[`.${A}`]:{color:i.diffViewerTitleColor}}),g=o({color:i.gutterColor,label:"line-number"}),I=o({background:i.removedBackground,color:i.removedColor,pre:{color:i.removedColor},[`.${g}`]:{color:i.removedGutterColor},label:"diff-removed"}),d=o({background:i.addedBackground,color:i.addedColor,pre:{color:i.addedColor},[`.${g}`]:{color:i.addedGutterColor},label:"diff-added"}),p=o({background:i.changedBackground,[`.${g}`]:{color:i.gutterColor},label:"diff-changed"}),m=o({padding:2,display:"inline-flex",borderRadius:4,wordBreak:"break-all",label:"word-diff"}),h=o({background:i.wordAddedBackground,label:"word-added"}),O=o({background:i.wordRemovedBackground,label:"word-removed"}),T=o({backgroundColor:i.codeFoldGutterBackground,label:"code-fold-gutter"}),N=o({backgroundColor:i.codeFoldBackground,height:40,fontSize:14,fontWeight:700,label:"code-fold",a:{textDecoration:"underline !important",cursor:"pointer",pre:{display:"inline"}}}),C=o({backgroundColor:i.emptyLineBackground,label:"empty-line"}),P=o({width:25,paddingLeft:10,paddingRight:10,userSelect:"none",label:"marker",[`&.${d}`]:{pre:{color:i.addedColor}},[`&.${I}`]:{pre:{color:i.removedColor}}}),S=o({background:i.highlightBackground,label:"highlighted-line",[`.${h}, .${O}`]:{backgroundColor:"initial"}}),L=o({label:"highlighted-gutter"}),D=o({userSelect:"none",minWidth:50,padding:"0 10px",whiteSpace:"nowrap",label:"gutter",textAlign:"right",background:i.gutterBackground,"&:hover":{cursor:"pointer",background:i.gutterBackgroundDark,pre:{opacity:1}},pre:{opacity:.5},[`&.${d}`]:{background:i.addedGutterBackground},[`&.${I}`]:{background:i.removedGutterBackground},[`&.${L}`]:{background:i.highlightGutterBackground,"&:hover":{background:i.highlightGutterBackground}}}),B=o({"&:hover":{background:i.gutterBackground,cursor:"initial"},label:"empty-gutter"}),F=o({verticalAlign:"baseline",label:"line"}),W={diffContainer:E,diffRemoved:I,diffAdded:d,diffChanged:p,splitView:c,marker:P,highlightedGutter:L,highlightedLine:S,gutter:D,line:F,wordDiff:m,wordAdded:h,wordRemoved:O,codeFoldGutter:T,codeFold:N,emptyGutter:B,emptyLine:C,lineNumber:g,contentText:A,content:u,codeFoldContent:f,titleBlock:_},H=Object.keys(a).reduce((k,U)=>Object.assign(Object.assign({},k),{[U]:o(a[U])}),{});return Object.keys(W).reduce((k,U)=>Object.assign(Object.assign({},k),{[U]:H[U]?l(W[U],H[U]):W[U]}),{})};var md={};Object.defineProperty(md,"__esModule",{value:!0});md.computeHiddenBlocks=void 0;function WY(e,t,n){let r=0,a,s={},i=[];return e.forEach((o,l)=>{const u=t.some(c=>c>=l-n&&c<=l+n);!u&&a==null?(a={index:r,startLine:l,endLine:l,lines:1},i.push(a),s[l]=a.index,r++):u?a=void 0:(a.endLine=l,a.lines++,s[l]=a.index)}),{lineBlocks:s,blocks:i}}md.computeHiddenBlocks=WY;var TN=Number.isNaN||function(e){return typeof e=="number"&&e!==e};function jY(e,t){return!!(e===t||TN(e)&&TN(t))}function XY(e,t){if(e.length!==t.length)return!1;for(var n=0;n<e.length;n++)if(!jY(e[n],t[n]))return!1;return!0}function KY(e,t){t===void 0&&(t=XY);var n=null;function r(){for(var a=[],s=0;s<arguments.length;s++)a[s]=arguments[s];if(n&&n.lastThis===this&&t(a,n.lastArgs))return n.lastResult;var i=e.apply(this,a);return n={lastResult:i,lastArgs:a,lastThis:this},i}return r.clear=function(){n=null},r}const zY=Object.freeze(Object.defineProperty({__proto__:null,default:KY},Symbol.toStringTag,{value:"Module"})),qY=RN(zY);(function(e){var t=st&&st.__createBinding||(Object.create?function(g,I,d,p){p===void 0&&(p=d);var m=Object.getOwnPropertyDescriptor(I,d);(!m||("get"in m?!I.__esModule:m.writable||m.configurable))&&(m={enumerable:!0,get:function(){return I[d]}}),Object.defineProperty(g,p,m)}:function(g,I,d,p){p===void 0&&(p=d),g[p]=I[d]}),n=st&&st.__setModuleDefault||(Object.create?function(g,I){Object.defineProperty(g,"default",{enumerable:!0,value:I})}:function(g,I){g.default=I}),r=st&&st.__importStar||function(g){if(g&&g.__esModule)return g;var I={};if(g!=null)for(var d in g)d!=="default"&&Object.prototype.hasOwnProperty.call(g,d)&&t(I,g,d);return n(I,g),I},a=st&&st.__importDefault||function(g){return g&&g.__esModule?g:{default:g}};Object.defineProperty(e,"__esModule",{value:!0}),e.DiffMethod=e.LineNumberPrefix=void 0;const s=R,i=r(x),o=a(X6),l=Ja;Object.defineProperty(e,"DiffMethod",{enumerable:!0,get:function(){return l.DiffMethod}});const u=a(bA),c=md,E=qY,f=E.default||E;var A;(function(g){g.LEFT="L",g.RIGHT="R"})(A||(e.LineNumberPrefix=A={}));class _ extends i.Component{constructor(I){super(I),this.resetCodeBlocks=()=>this.state.expandedBlocks.length>0?(this.setState({expandedBlocks:[]}),!0):!1,this.onBlockExpand=d=>{const p=this.state.expandedBlocks.slice();p.push(d),this.setState({expandedBlocks:p})},this.computeStyles=f(u.default),this.onLineNumberClickProxy=d=>this.props.onLineNumberClick?p=>this.props.onLineNumberClick(d,p):()=>{},this.renderWordDiff=(d,p)=>d.map((m,h)=>(0,s.jsx)("span",{className:(0,o.default)(this.styles.wordDiff,{[this.styles.wordAdded]:m.type===l.DiffType.ADDED,[this.styles.wordRemoved]:m.type===l.DiffType.REMOVED}),children:p?p(m.value):m.value},h)),this.renderLine=(d,p,m,h,O,T)=>{const N=`${m}-${d}`,C=`${T}-${O}`,P=this.props.highlightLines.includes(N)||this.props.highlightLines.includes(C),S=p===l.DiffType.ADDED,L=p===l.DiffType.REMOVED,D=p===l.DiffType.CHANGED;let B;return Array.isArray(h)?B=this.renderWordDiff(h,this.props.renderContent):this.props.renderContent?B=this.props.renderContent(h):B=h,(0,s.jsxs)(i.Fragment,{children:[!this.props.hideLineNumbers&&(0,s.jsx)("td",{onClick:d&&this.onLineNumberClickProxy(N),className:(0,o.default)(this.styles.gutter,{[this.styles.emptyGutter]:!d,[this.styles.diffAdded]:S,[this.styles.diffRemoved]:L,[this.styles.diffChanged]:D,[this.styles.highlightedGutter]:P}),children:(0,s.jsx)("pre",{className:this.styles.lineNumber,children:d})}),!this.props.splitView&&!this.props.hideLineNumbers&&(0,s.jsx)("td",{onClick:O&&this.onLineNumberClickProxy(C),className:(0,o.default)(this.styles.gutter,{[this.styles.emptyGutter]:!O,[this.styles.diffAdded]:S,[this.styles.diffRemoved]:L,[this.styles.diffChanged]:D,[this.styles.highlightedGutter]:P}),children:(0,s.jsx)("pre",{className:this.styles.lineNumber,children:O})}),this.props.renderGutter?this.props.renderGutter({lineNumber:d,type:p,prefix:m,value:h,additionalLineNumber:O,additionalPrefix:T,styles:this.styles}):null,!this.props.hideMarkers&&(0,s.jsx)("td",{className:(0,o.default)(this.styles.marker,{[this.styles.emptyLine]:!B,[this.styles.diffAdded]:S,[this.styles.diffRemoved]:L,[this.styles.diffChanged]:D,[this.styles.highlightedLine]:P}),children:(0,s.jsxs)("pre",{children:[S&&"+",L&&"-"]})}),(0,s.jsx)("td",{className:(0,o.default)(this.styles.content,{[this.styles.emptyLine]:!B,[this.styles.diffAdded]:S,[this.styles.diffRemoved]:L,[this.styles.diffChanged]:D,[this.styles.highlightedLine]:P}),children:(0,s.jsx)("pre",{className:this.styles.contentText,children:B})})]})},this.renderSplitView=({left:d,right:p},m)=>(0,s.jsxs)("tr",{className:this.styles.line,children:[this.renderLine(d.lineNumber,d.type,A.LEFT,d.value),this.renderLine(p.lineNumber,p.type,A.RIGHT,p.value)]},m),this.renderInlineView=({left:d,right:p},m)=>{let h;return d.type===l.DiffType.REMOVED&&p.type===l.DiffType.ADDED?(0,s.jsxs)(i.Fragment,{children:[(0,s.jsx)("tr",{className:this.styles.line,children:this.renderLine(d.lineNumber,d.type,A.LEFT,d.value,null)}),(0,s.jsx)("tr",{className:this.styles.line,children:this.renderLine(null,p.type,A.RIGHT,p.value,p.lineNumber)})]},m):(d.type===l.DiffType.REMOVED&&(h=this.renderLine(d.lineNumber,d.type,A.LEFT,d.value,null)),d.type===l.DiffType.DEFAULT&&(h=this.renderLine(d.lineNumber,d.type,A.LEFT,d.value,p.lineNumber,A.RIGHT)),p.type===l.DiffType.ADDED&&(h=this.renderLine(null,p.type,A.RIGHT,p.value,p.lineNumber)),(0,s.jsx)("tr",{className:this.styles.line,children:h},m))},this.onBlockClickProxy=d=>()=>this.onBlockExpand(d),this.renderSkippedLineIndicator=(d,p,m,h)=>{const{hideLineNumbers:O,splitView:T}=this.props,N=this.props.codeFoldMessageRenderer?this.props.codeFoldMessageRenderer(d,m,h):(0,s.jsxs)("pre",{className:this.styles.codeFoldContent,children:["Expand ",d," lines ..."]}),C=(0,s.jsx)("td",{children:(0,s.jsx)("a",{onClick:this.onBlockClickProxy(p),tabIndex:0,children:N})}),P=!T&&!O;return(0,s.jsxs)("tr",{className:this.styles.codeFold,children:[!O&&(0,s.jsx)("td",{className:this.styles.codeFoldGutter}),this.props.renderGutter?(0,s.jsx)("td",{className:this.styles.codeFoldGutter}):null,(0,s.jsx)("td",{className:(0,o.default)({[this.styles.codeFoldGutter]:P})}),P?(0,s.jsxs)(i.Fragment,{children:[(0,s.jsx)("td",{}),C]}):(0,s.jsxs)(i.Fragment,{children:[C,this.props.renderGutter?(0,s.jsx)("td",{}):null,(0,s.jsx)("td",{})]}),(0,s.jsx)("td",{}),(0,s.jsx)("td",{})]},`${m}-${h}`)},this.renderDiff=()=>{const{oldValue:d,newValue:p,splitView:m,disableWordDiff:h,compareMethod:O,linesOffset:T}=this.props,{lineInformation:N,diffLines:C}=(0,l.computeLineInformation)(d,p,h,O,T,this.props.alwaysShowLines),P=this.props.extraLinesSurroundingDiff<0?0:Math.round(this.props.extraLinesSurroundingDiff),{lineBlocks:S,blocks:L}=(0,c.computeHiddenBlocks)(N,C,P);return N.map((D,B)=>{if(this.props.showDiffOnly){const F=S[B];if(F!==void 0){const W=L[F].endLine===B;if(!this.state.expandedBlocks.includes(F)&&W)return(0,s.jsx)(i.Fragment,{children:this.renderSkippedLineIndicator(L[F].lines,F,D.left.lineNumber,D.right.lineNumber)},B);if(!this.state.expandedBlocks.includes(F))return null}}return m?this.renderSplitView(D,B):this.renderInlineView(D,B)})},this.render=()=>{const{oldValue:d,newValue:p,useDarkTheme:m,leftTitle:h,rightTitle:O,splitView:T,hideLineNumbers:N,hideMarkers:C,nonce:P}=this.props;if(this.props.compareMethod!==l.DiffMethod.JSON&&(typeof d!="string"||typeof p!="string"))throw Error('"oldValue" and "newValue" should be strings');this.styles=this.computeStyles(this.props.styles,m,P);const S=this.renderDiff();let L=N?2:3,D=N?2:4;C&&(L-=1,D-=1);const B=this.props.renderGutter?1:0,F=(h||O)&&(0,s.jsxs)("tr",{children:[(0,s.jsx)("td",{colSpan:(T?L:D)+B,className:this.styles.titleBlock,children:(0,s.jsx)("pre",{className:this.styles.contentText,children:h})}),T&&(0,s.jsx)("td",{colSpan:L+B,className:this.styles.titleBlock,children:(0,s.jsx)("pre",{className:this.styles.contentText,children:O})})]});return(0,s.jsx)("table",{className:(0,o.default)(this.styles.diffContainer,{[this.styles.splitView]:T}),children:(0,s.jsxs)("tbody",{children:[F,S]})})},this.state={expandedBlocks:[]}}}_.defaultProps={oldValue:"",newValue:"",splitView:!0,highlightLines:[],disableWordDiff:!1,compareMethod:l.DiffMethod.CHARS,styles:{},hideLineNumbers:!1,hideMarkers:!1,extraLinesSurroundingDiff:3,showDiffOnly:!0,useDarkTheme:!1,linesOffset:0,nonce:""},e.default=_})(j6);function hN(e){const t=new CSSStyleSheet;return t.replaceSync(e),t}async function JY(e){gh("open",{path:e})}async function ZY(){gh("close")}function AN(){return!!(window.__spotlight&&window.document.getElementById("sentry-spotlight-root"))}async function QY(e={}){var t;if(typeof document>"u"||AN())return;const n=(t=window.__spotlight)==null?void 0:t.initOptions;n&&(e={...n,...e});const{openOnInit:r=!1,sidecarUrl:a=Lv,anchor:s=KO,integrations:i,experiments:o=kf,showClearEventsButton:l=!0,initialEvents:u=void 0,startFrom:c=void 0}=e,E=new URL(a).origin===document.location.origin,f=QO(a,"/stream"),A=e.fullPage??E,_=e.showTriggerButton??!A,g=e.injectImmediately??(E||A),I=e.debug??document.location.hash.endsWith("debug");I&&Hv();const d={...kf,...o},p=()=>[zw({injectIntoSDK:!E})],m={open:JY,close:ZY,experiments:d,sidecarUrl:f},[h]=await ZO(i??p(),m),O=document.createElement("div");O.id="sentry-spotlight-root";const T=O.attachShadow({mode:"open"}),N=document.createElement("div");A?(O.style.height="100%",O.style.backgroundColor=_v.indigo[950],N.style.height="inherit"):(N.style.position="absolute",N.style.top="0",N.style.left="0",N.style.right="0"),T.appendChild(N);const C=hN(Wv);T.adoptedStyleSheets=[hN(Eb),C];const P=h.flatMap(D=>{var B;return((B=D.tabs)==null?void 0:B.call(D,{processedEvents:[]}).map(F=>({...F,processedEvents:[]})))||[]}),S=c||(P.length?`/${P[0].id}`:"/no-tabs");Ke("Starting from",S),E&&D6(S,{debug:I}),Yf.createRoot(N).render(R.jsx(sv,{initialEntries:[S],children:R.jsx(PM,{context:m,children:R.jsx(Vv,{integrations:h,openOnInit:r,showTriggerButton:_,sidecarUrl:a,anchor:s,fullPage:A,showClearEventsButton:l,initialEvents:u})})}));function L(){if(AN()){Ke("Spotlight already injected, bailing.");return}Ke("Injecting into application");const D=new CSSStyleSheet;D.replaceSync(`body.${Gf} { overflow: hidden!important; }`),document.adoptedStyleSheets=[...document.adoptedStyleSheets,D],document.body.append(O)}document.readyState==="complete"||g?L():window.addEventListener("load",L),window.addEventListener("error",L)}(function(e){e&&e.init({integrations:[e.sentry(),e.console()]})})(window.Spotlight);QY({sidecarUrl:document.location.href});
|
|
204
|
+
`),q8=(e,t,n=SE.CHARS)=>{const r=z8[n](e,t),a={left:[],right:[]};return r.forEach(({added:s,removed:i,value:o})=>{const l={};return s&&(l.type=$r.ADDED,l.value=o,a.right.push(l)),i&&(l.type=$r.REMOVED,l.value=o,a.left.push(l)),!i&&!s&&(l.type=$r.DEFAULT,l.value=o,a.right.push(l),a.left.push(l)),l}),a},J8=(e,t,n=!1,r=SE.CHARS,a=0,s=[])=>{let i=[];typeof e=="string"&&typeof t=="string"?i=IT.diffLines(e.trimRight(),t.trimRight(),{newlineIsToken:!1,ignoreWhitespace:!1,ignoreCase:!1}):i=IT.diffJson(e,t);let o=a,l=a,u=[],c=0;const E=[],f=[],A=(_,g,I,d,p)=>iN(_).map((m,h)=>{const O={},T={};if(!(f.includes(`${g}-${h}`)||p&&h!==0)){if(I||d){let N=!0;if(d){l+=1,O.lineNumber=l,O.type=$r.REMOVED,O.value=m||" ";const C=i[g+1];if(C&&C.added){const P=iN(C.value)[h];if(P){const S=A(P,g,!0,!1,!0),{value:L,lineNumber:D,type:B}=S[0].right;if(f.push(`${g+1}-${h}`),T.lineNumber=D,O.value===L)N=!1,T.type=0,O.type=0,T.value=L;else if(T.type=B,n)T.value=L;else{const F=q8(m,L,r);T.value=F.right,O.value=F.left}}}}else o+=1,T.lineNumber=o,T.type=$r.ADDED,T.value=m;N&&!p&&(E.includes(c)||E.push(c))}else l+=1,o+=1,O.lineNumber=l,O.type=$r.DEFAULT,O.value=m,T.lineNumber=o,T.type=$r.DEFAULT,T.value=m;return(s!=null&&s.includes(`L-${O.lineNumber}`)||s!=null&&s.includes(`R-${T.lineNumber}`)&&!E.includes(c))&&E.push(c),p||(c+=1),{right:T,left:O}}}).filter(Boolean);return i.forEach(({added:_,removed:g,value:I},d)=>{u=[...u,...A(I,d,_,g)]}),{lineInformation:u,diffLines:E}};Ja.computeLineInformation=J8;var bA={},Z8=!1;function Q8(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}function $8(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),e.nonce!==void 0&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t}var eY=function(){function e(n){var r=this;this._insertTag=function(a){var s;r.tags.length===0?r.insertionPoint?s=r.insertionPoint.nextSibling:r.prepend?s=r.container.firstChild:s=r.before:s=r.tags[r.tags.length-1].nextSibling,r.container.insertBefore(a,s),r.tags.push(a)},this.isSpeedy=n.speedy===void 0?!Z8:n.speedy,this.tags=[],this.ctr=0,this.nonce=n.nonce,this.key=n.key,this.container=n.container,this.prepend=n.prepend,this.insertionPoint=n.insertionPoint,this.before=null}var t=e.prototype;return t.hydrate=function(n){n.forEach(this._insertTag)},t.insert=function(n){this.ctr%(this.isSpeedy?65e3:1)===0&&this._insertTag($8(this));var r=this.tags[this.tags.length-1];if(this.isSpeedy){var a=Q8(r);try{a.insertRule(n,a.cssRules.length)}catch{}}else r.appendChild(document.createTextNode(n));this.ctr++},t.flush=function(){this.tags.forEach(function(n){var r;return(r=n.parentNode)==null?void 0:r.removeChild(n)}),this.tags=[],this.ctr=0},e}(),rn="-ms-",mE="-moz-",Fe="-webkit-",Ry="comm",LA="rule",vA="decl",tY="@import",Sy="@keyframes",nY="@layer",rY=Math.abs,Ad=String.fromCharCode,aY=Object.assign;function sY(e,t){return Xt(e,0)^45?(((t<<2^Xt(e,0))<<2^Xt(e,1))<<2^Xt(e,2))<<2^Xt(e,3):0}function my(e){return e.trim()}function iY(e,t){return(e=t.exec(e))?e[0]:e}function He(e,t,n){return e.replace(t,n)}function gT(e,t){return e.indexOf(t)}function Xt(e,t){return e.charCodeAt(t)|0}function wl(e,t,n){return e.slice(t,n)}function vr(e){return e.length}function MA(e){return e.length}function Zu(e,t){return t.push(e),e}function oY(e,t){return e.map(t).join("")}var Rd=1,no=1,_y=0,Ln=0,Nt=0,Oo="";function Sd(e,t,n,r,a,s,i){return{value:e,root:t,parent:n,type:r,props:a,children:s,line:Rd,column:no,length:i,return:""}}function Fo(e,t){return aY(Sd("",null,null,"",null,null,0),e,{length:-e.length},t)}function lY(){return Nt}function uY(){return Nt=Ln>0?Xt(Oo,--Ln):0,no--,Nt===10&&(no=1,Rd--),Nt}function Hn(){return Nt=Ln<_y?Xt(Oo,Ln++):0,no++,Nt===10&&(no=1,Rd++),Nt}function Gr(){return Xt(Oo,Ln)}function mc(){return Ln}function ou(e,t){return wl(Oo,e,t)}function Ul(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function Ny(e){return Rd=no=1,_y=vr(Oo=e),Ln=0,[]}function Oy(e){return Oo="",e}function _c(e){return my(ou(Ln-1,CT(e===91?e+2:e===40?e+1:e)))}function cY(e){for(;(Nt=Gr())&&Nt<33;)Hn();return Ul(e)>2||Ul(Nt)>3?"":" "}function EY(e,t){for(;--t&&Hn()&&!(Nt<48||Nt>102||Nt>57&&Nt<65||Nt>70&&Nt<97););return ou(e,mc()+(t<6&&Gr()==32&&Hn()==32))}function CT(e){for(;Hn();)switch(Nt){case e:return Ln;case 34:case 39:e!==34&&e!==39&&CT(Nt);break;case 40:e===41&&CT(e);break;case 92:Hn();break}return Ln}function dY(e,t){for(;Hn()&&e+Nt!==57&&!(e+Nt===84&&Gr()===47););return"/*"+ou(t,Ln-1)+"*"+Ad(e===47?e:Hn())}function pY(e){for(;!Ul(Gr());)Hn();return ou(e,Ln)}function fY(e){return Oy(Nc("",null,null,null,[""],e=Ny(e),0,[0],e))}function Nc(e,t,n,r,a,s,i,o,l){for(var u=0,c=0,E=i,f=0,A=0,_=0,g=1,I=1,d=1,p=0,m="",h=a,O=s,T=r,N=m;I;)switch(_=p,p=Hn()){case 40:if(_!=108&&Xt(N,E-1)==58){gT(N+=He(_c(p),"&","&\f"),"&\f")!=-1&&(d=-1);break}case 34:case 39:case 91:N+=_c(p);break;case 9:case 10:case 13:case 32:N+=cY(_);break;case 92:N+=EY(mc()-1,7);continue;case 47:switch(Gr()){case 42:case 47:Zu(TY(dY(Hn(),mc()),t,n),l);break;default:N+="/"}break;case 123*g:o[u++]=vr(N)*d;case 125*g:case 59:case 0:switch(p){case 0:case 125:I=0;case 59+c:d==-1&&(N=He(N,/\f/g,"")),A>0&&vr(N)-E&&Zu(A>32?lN(N+";",r,n,E-1):lN(He(N," ","")+";",r,n,E-2),l);break;case 59:N+=";";default:if(Zu(T=oN(N,t,n,u,c,a,o,m,h=[],O=[],E),s),p===123)if(c===0)Nc(N,t,T,T,h,s,E,o,O);else switch(f===99&&Xt(N,3)===110?100:f){case 100:case 108:case 109:case 115:Nc(e,T,T,r&&Zu(oN(e,T,T,0,0,a,o,m,a,h=[],E),O),a,O,E,o,r?h:O);break;default:Nc(N,T,T,T,[""],O,0,o,O)}}u=c=A=0,g=d=1,m=N="",E=i;break;case 58:E=1+vr(N),A=_;default:if(g<1){if(p==123)--g;else if(p==125&&g++==0&&uY()==125)continue}switch(N+=Ad(p),p*g){case 38:d=c>0?1:(N+="\f",-1);break;case 44:o[u++]=(vr(N)-1)*d,d=1;break;case 64:Gr()===45&&(N+=_c(Hn())),f=Gr(),c=E=vr(m=N+=pY(mc())),p++;break;case 45:_===45&&vr(N)==2&&(g=0)}}return s}function oN(e,t,n,r,a,s,i,o,l,u,c){for(var E=a-1,f=a===0?s:[""],A=MA(f),_=0,g=0,I=0;_<r;++_)for(var d=0,p=wl(e,E+1,E=rY(g=i[_])),m=e;d<A;++d)(m=my(g>0?f[d]+" "+p:He(p,/&\f/g,f[d])))&&(l[I++]=m);return Sd(e,t,n,a===0?LA:o,l,u,c)}function TY(e,t,n){return Sd(e,t,n,Ry,Ad(lY()),wl(e,2,-2),0)}function lN(e,t,n,r){return Sd(e,t,n,vA,wl(e,0,r),wl(e,r+1,-1),r)}function ki(e,t){for(var n="",r=MA(e),a=0;a<r;a++)n+=t(e[a],a,e,t)||"";return n}function hY(e,t,n,r){switch(e.type){case nY:if(e.children.length)break;case tY:case vA:return e.return=e.return||e.value;case Ry:return"";case Sy:return e.return=e.value+"{"+ki(e.children,r)+"}";case LA:e.value=e.props.join(",")}return vr(n=ki(e.children,r))?e.return=e.value+"{"+n+"}":""}function AY(e){var t=MA(e);return function(n,r,a,s){for(var i="",o=0;o<t;o++)i+=e[o](n,r,a,s)||"";return i}}function RY(e){return function(t){t.root||(t=t.return)&&e(t)}}function SY(e){var t=Object.create(null);return function(n){return t[n]===void 0&&(t[n]=e(n)),t[n]}}var mY=function(e,t,n){for(var r=0,a=0;r=a,a=Gr(),r===38&&a===12&&(t[n]=1),!Ul(a);)Hn();return ou(e,Ln)},_Y=function(e,t){var n=-1,r=44;do switch(Ul(r)){case 0:r===38&&Gr()===12&&(t[n]=1),e[n]+=mY(Ln-1,t,n);break;case 2:e[n]+=_c(r);break;case 4:if(r===44){e[++n]=Gr()===58?"&\f":"",t[n]=e[n].length;break}default:e[n]+=Ad(r)}while(r=Hn());return e},NY=function(e,t){return Oy(_Y(Ny(e),t))},uN=new WeakMap,OY=function(e){if(!(e.type!=="rule"||!e.parent||e.length<1)){for(var t=e.value,n=e.parent,r=e.column===n.column&&e.line===n.line;n.type!=="rule";)if(n=n.parent,!n)return;if(!(e.props.length===1&&t.charCodeAt(0)!==58&&!uN.get(n))&&!r){uN.set(e,!0);for(var a=[],s=NY(t,a),i=n.props,o=0,l=0;o<s.length;o++)for(var u=0;u<i.length;u++,l++)e.props[l]=a[o]?s[o].replace(/&\f/g,i[u]):i[u]+" "+s[o]}}},IY=function(e){if(e.type==="decl"){var t=e.value;t.charCodeAt(0)===108&&t.charCodeAt(2)===98&&(e.return="",e.value="")}};function Iy(e,t){switch(sY(e,t)){case 5103:return Fe+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return Fe+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return Fe+e+mE+e+rn+e+e;case 6828:case 4268:return Fe+e+rn+e+e;case 6165:return Fe+e+rn+"flex-"+e+e;case 5187:return Fe+e+He(e,/(\w+).+(:[^]+)/,Fe+"box-$1$2"+rn+"flex-$1$2")+e;case 5443:return Fe+e+rn+"flex-item-"+He(e,/flex-|-self/,"")+e;case 4675:return Fe+e+rn+"flex-line-pack"+He(e,/align-content|flex-|-self/,"")+e;case 5548:return Fe+e+rn+He(e,"shrink","negative")+e;case 5292:return Fe+e+rn+He(e,"basis","preferred-size")+e;case 6060:return Fe+"box-"+He(e,"-grow","")+Fe+e+rn+He(e,"grow","positive")+e;case 4554:return Fe+He(e,/([^-])(transform)/g,"$1"+Fe+"$2")+e;case 6187:return He(He(He(e,/(zoom-|grab)/,Fe+"$1"),/(image-set)/,Fe+"$1"),e,"")+e;case 5495:case 3959:return He(e,/(image-set\([^]*)/,Fe+"$1$`$1");case 4968:return He(He(e,/(.+:)(flex-)?(.*)/,Fe+"box-pack:$3"+rn+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+Fe+e+e;case 4095:case 3583:case 4068:case 2532:return He(e,/(.+)-inline(.+)/,Fe+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(vr(e)-1-t>6)switch(Xt(e,t+1)){case 109:if(Xt(e,t+4)!==45)break;case 102:return He(e,/(.+:)(.+)-([^]+)/,"$1"+Fe+"$2-$3$1"+mE+(Xt(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~gT(e,"stretch")?Iy(He(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(Xt(e,t+1)!==115)break;case 6444:switch(Xt(e,vr(e)-3-(~gT(e,"!important")&&10))){case 107:return He(e,":",":"+Fe)+e;case 101:return He(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+Fe+(Xt(e,14)===45?"inline-":"")+"box$3$1"+Fe+"$2$3$1"+rn+"$2box$3")+e}break;case 5936:switch(Xt(e,t+11)){case 114:return Fe+e+rn+He(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return Fe+e+rn+He(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return Fe+e+rn+He(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return Fe+e+rn+e+e}return e}var gY=function(e,t,n,r){if(e.length>-1&&!e.return)switch(e.type){case vA:e.return=Iy(e.value,e.length);break;case Sy:return ki([Fo(e,{value:He(e.value,"@","@"+Fe)})],r);case LA:if(e.length)return oY(e.props,function(a){switch(iY(a,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return ki([Fo(e,{props:[He(a,/:(read-\w+)/,":"+mE+"$1")]})],r);case"::placeholder":return ki([Fo(e,{props:[He(a,/:(plac\w+)/,":"+Fe+"input-$1")]}),Fo(e,{props:[He(a,/:(plac\w+)/,":"+mE+"$1")]}),Fo(e,{props:[He(a,/:(plac\w+)/,rn+"input-$1")]})],r)}return""})}},CY=[gY],yY=function(e){var t=e.key;if(t==="css"){var n=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(n,function(_){var g=_.getAttribute("data-emotion");g.indexOf(" ")!==-1&&(document.head.appendChild(_),_.setAttribute("data-s",""))})}var r=e.stylisPlugins||CY,a={},s,i=[];s=e.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+t+' "]'),function(_){for(var g=_.getAttribute("data-emotion").split(" "),I=1;I<g.length;I++)a[g[I]]=!0;i.push(_)});var o,l=[OY,IY];{var u,c=[hY,RY(function(_){u.insert(_)})],E=AY(l.concat(r,c)),f=function(_){return ki(fY(_),E)};o=function(_,g,I,d){u=I,f(_?_+"{"+g.styles+"}":g.styles),d&&(A.inserted[g.name]=!0)}}var A={key:t,sheet:new eY({key:t,container:s,nonce:e.nonce,speedy:e.speedy,prepend:e.prepend,insertionPoint:e.insertionPoint}),nonce:e.nonce,inserted:a,registered:{},insert:o};return A.sheet.hydrate(i),A};function bY(e){for(var t=0,n,r=0,a=e.length;a>=4;++r,a-=4)n=e.charCodeAt(r)&255|(e.charCodeAt(++r)&255)<<8|(e.charCodeAt(++r)&255)<<16|(e.charCodeAt(++r)&255)<<24,n=(n&65535)*1540483477+((n>>>16)*59797<<16),n^=n>>>24,t=(n&65535)*1540483477+((n>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(a){case 3:t^=(e.charCodeAt(r+2)&255)<<16;case 2:t^=(e.charCodeAt(r+1)&255)<<8;case 1:t^=e.charCodeAt(r)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var LY={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},vY=!1,MY=/[A-Z]|^ms/g,PY=/_EMO_([^_]+?)_([^]*?)_EMO_/g,gy=function(e){return e.charCodeAt(1)===45},cN=function(e){return e!=null&&typeof e!="boolean"},Yp=SY(function(e){return gy(e)?e:e.replace(MY,"-$&").toLowerCase()}),EN=function(e,t){switch(e){case"animation":case"animationName":if(typeof t=="string")return t.replace(PY,function(n,r,a){return wa={name:r,styles:a,next:wa},r})}return LY[e]!==1&&!gy(e)&&typeof t=="number"&&t!==0?t+"px":t},DY="Component selectors can only be used in conjunction with @emotion/babel-plugin, the swc Emotion plugin, or another Emotion-aware compiler transform.";function _E(e,t,n){if(n==null)return"";var r=n;if(r.__emotion_styles!==void 0)return r;switch(typeof n){case"boolean":return"";case"object":{var a=n;if(a.anim===1)return wa={name:a.name,styles:a.styles,next:wa},a.name;var s=n;if(s.styles!==void 0){var i=s.next;if(i!==void 0)for(;i!==void 0;)wa={name:i.name,styles:i.styles,next:wa},i=i.next;var o=s.styles+";";return o}return xY(e,t,n)}}var l=n;if(t==null)return l;var u=t[l];return u!==void 0?u:l}function xY(e,t,n){var r="";if(Array.isArray(n))for(var a=0;a<n.length;a++)r+=_E(e,t,n[a])+";";else for(var s in n){var i=n[s];if(typeof i!="object"){var o=i;t!=null&&t[o]!==void 0?r+=s+"{"+t[o]+"}":cN(o)&&(r+=Yp(s)+":"+EN(s,o)+";")}else{if(s==="NO_COMPONENT_SELECTOR"&&vY)throw new Error(DY);if(Array.isArray(i)&&typeof i[0]=="string"&&(t==null||t[i[0]]===void 0))for(var l=0;l<i.length;l++)cN(i[l])&&(r+=Yp(s)+":"+EN(s,i[l])+";");else{var u=_E(e,t,i);switch(s){case"animation":case"animationName":{r+=Yp(s)+":"+u+";";break}default:r+=s+"{"+u+"}"}}}}return r}var dN=/label:\s*([^\s;{]+)\s*(;|$)/g,wa;function Vp(e,t,n){if(e.length===1&&typeof e[0]=="object"&&e[0]!==null&&e[0].styles!==void 0)return e[0];var r=!0,a="";wa=void 0;var s=e[0];if(s==null||s.raw===void 0)r=!1,a+=_E(n,t,s);else{var i=s;a+=i[0]}for(var o=1;o<e.length;o++)if(a+=_E(n,t,e[o]),r){var l=s;a+=l[o]}dN.lastIndex=0;for(var u="",c;(c=dN.exec(a))!==null;)u+="-"+c[1];var E=bY(a)+u;return{name:E,styles:a,next:wa}}function Cy(e,t,n){var r="";return n.split(" ").forEach(function(a){e[a]!==void 0?t.push(e[a]+";"):a&&(r+=a+" ")}),r}var wY=function(e,t,n){var r=e.key+"-"+t.name;e.registered[r]===void 0&&(e.registered[r]=t.styles)},UY=function(e,t,n){wY(e,t);var r=e.key+"-"+t.name;if(e.inserted[t.name]===void 0){var a=t;do e.insert(t===a?"."+r:"",a,e.sheet,!0),a=a.next;while(a!==void 0)}};function pN(e,t){if(e.inserted[t.name]===void 0)return e.insert("",t,e.sheet,!0)}function fN(e,t,n){var r=[],a=Cy(e,r,n);return r.length<2?n:a+t(r)}var kY=function(e){var t=yY(e);t.sheet.speedy=function(i){this.isSpeedy=i},t.compat=!0;var n=function(){for(var i=arguments.length,o=new Array(i),l=0;l<i;l++)o[l]=arguments[l];var u=Vp(o,t.registered,void 0);return UY(t,u),t.key+"-"+u.name},r=function(){for(var i=arguments.length,o=new Array(i),l=0;l<i;l++)o[l]=arguments[l];var u=Vp(o,t.registered),c="animation-"+u.name;return pN(t,{name:u.name,styles:"@keyframes "+c+"{"+u.styles+"}"}),c},a=function(){for(var i=arguments.length,o=new Array(i),l=0;l<i;l++)o[l]=arguments[l];var u=Vp(o,t.registered);pN(t,u)},s=function(){for(var i=arguments.length,o=new Array(i),l=0;l<i;l++)o[l]=arguments[l];return fN(t.registered,n,GY(o))};return{css:n,cx:s,injectGlobal:a,keyframes:r,hydrate:function(i){i.forEach(function(o){t.inserted[o]=!0})},flush:function(){t.registered={},t.inserted={},t.sheet.flush()},sheet:t.sheet,cache:t,getRegisteredStyles:Cy.bind(null,t.registered),merge:fN.bind(null,t.registered,n)}},GY=function e(t){for(var n="",r=0;r<t.length;r++){var a=t[r];if(a!=null){var s=void 0;switch(typeof a){case"boolean":break;case"object":{if(Array.isArray(a))s=e(a);else{s="";for(var i in a)a[i]&&i&&(s&&(s+=" "),s+=i)}break}default:s=a}s&&(n&&(n+=" "),n+=s)}}return n};const BY=Object.freeze(Object.defineProperty({__proto__:null,default:kY},Symbol.toStringTag,{value:"Module"})),FY=RN(BY);var HY=st&&st.__rest||function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)t.indexOf(r[a])<0&&Object.prototype.propertyIsEnumerable.call(e,r[a])&&(n[r[a]]=e[r[a]]);return n},YY=st&&st.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(bA,"__esModule",{value:!0});const VY=YY(FY);bA.default=(e,t=!1,n="")=>{const{variables:r={}}=e,a=HY(e,["variables"]),s={light:Object.assign({diffViewerBackground:"#fff",diffViewerColor:"#212529",addedBackground:"#e6ffed",addedColor:"#24292e",removedBackground:"#ffeef0",removedColor:"#24292e",changedBackground:"#fffbdd",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"},r.light||{}),dark:Object.assign({diffViewerBackground:"#2e303c",diffViewerColor:"#FFF",addedBackground:"#044B53",addedColor:"white",removedBackground:"#632F34",removedColor:"white",changedBackground:"#3e302c",wordAddedBackground:"#055d67",wordRemovedBackground:"#7d383f",addedGutterBackground:"#034148",removedGutterBackground:"#632b30",gutterBackground:"#2c2f3a",gutterBackgroundDark:"#262933",highlightBackground:"#2a3967",highlightGutterBackground:"#2d4077",codeFoldGutterBackground:"#21232b",codeFoldBackground:"#262831",emptyLineBackground:"#363946",gutterColor:"#666c87",addedGutterColor:"#8c8c8c",removedGutterColor:"#8c8c8c",codeFoldContentColor:"#656a8b",diffViewerTitleBackground:"#2f323e",diffViewerTitleColor:"#555a7b",diffViewerTitleBorderColor:"#353846"},r.dark||{})},i=t?s.dark:s.light,{css:o,cx:l}=(0,VY.default)({key:"react-diff",nonce:n}),u=o({width:"100%",label:"content"}),c=o({[`.${u}`]:{width:"50%"},label:"split-view"}),E=o({width:"100%",background:i.diffViewerBackground,pre:{margin:0,whiteSpace:"pre-wrap",lineHeight:"25px"},label:"diff-container",borderCollapse:"collapse"}),f=o({color:i.codeFoldContentColor,label:"code-fold-content"}),A=o({color:i.diffViewerColor,label:"content-text"}),_=o({background:i.diffViewerTitleBackground,padding:10,borderBottom:`1px solid ${i.diffViewerTitleBorderColor}`,label:"title-block",":last-child":{borderLeft:`1px solid ${i.diffViewerTitleBorderColor}`},[`.${A}`]:{color:i.diffViewerTitleColor}}),g=o({color:i.gutterColor,label:"line-number"}),I=o({background:i.removedBackground,color:i.removedColor,pre:{color:i.removedColor},[`.${g}`]:{color:i.removedGutterColor},label:"diff-removed"}),d=o({background:i.addedBackground,color:i.addedColor,pre:{color:i.addedColor},[`.${g}`]:{color:i.addedGutterColor},label:"diff-added"}),p=o({background:i.changedBackground,[`.${g}`]:{color:i.gutterColor},label:"diff-changed"}),m=o({padding:2,display:"inline-flex",borderRadius:4,wordBreak:"break-all",label:"word-diff"}),h=o({background:i.wordAddedBackground,label:"word-added"}),O=o({background:i.wordRemovedBackground,label:"word-removed"}),T=o({backgroundColor:i.codeFoldGutterBackground,label:"code-fold-gutter"}),N=o({backgroundColor:i.codeFoldBackground,height:40,fontSize:14,fontWeight:700,label:"code-fold",a:{textDecoration:"underline !important",cursor:"pointer",pre:{display:"inline"}}}),C=o({backgroundColor:i.emptyLineBackground,label:"empty-line"}),P=o({width:25,paddingLeft:10,paddingRight:10,userSelect:"none",label:"marker",[`&.${d}`]:{pre:{color:i.addedColor}},[`&.${I}`]:{pre:{color:i.removedColor}}}),S=o({background:i.highlightBackground,label:"highlighted-line",[`.${h}, .${O}`]:{backgroundColor:"initial"}}),L=o({label:"highlighted-gutter"}),D=o({userSelect:"none",minWidth:50,padding:"0 10px",whiteSpace:"nowrap",label:"gutter",textAlign:"right",background:i.gutterBackground,"&:hover":{cursor:"pointer",background:i.gutterBackgroundDark,pre:{opacity:1}},pre:{opacity:.5},[`&.${d}`]:{background:i.addedGutterBackground},[`&.${I}`]:{background:i.removedGutterBackground},[`&.${L}`]:{background:i.highlightGutterBackground,"&:hover":{background:i.highlightGutterBackground}}}),B=o({"&:hover":{background:i.gutterBackground,cursor:"initial"},label:"empty-gutter"}),F=o({verticalAlign:"baseline",label:"line"}),W={diffContainer:E,diffRemoved:I,diffAdded:d,diffChanged:p,splitView:c,marker:P,highlightedGutter:L,highlightedLine:S,gutter:D,line:F,wordDiff:m,wordAdded:h,wordRemoved:O,codeFoldGutter:T,codeFold:N,emptyGutter:B,emptyLine:C,lineNumber:g,contentText:A,content:u,codeFoldContent:f,titleBlock:_},H=Object.keys(a).reduce((k,U)=>Object.assign(Object.assign({},k),{[U]:o(a[U])}),{});return Object.keys(W).reduce((k,U)=>Object.assign(Object.assign({},k),{[U]:H[U]?l(W[U],H[U]):W[U]}),{})};var md={};Object.defineProperty(md,"__esModule",{value:!0});md.computeHiddenBlocks=void 0;function WY(e,t,n){let r=0,a,s={},i=[];return e.forEach((o,l)=>{const u=t.some(c=>c>=l-n&&c<=l+n);!u&&a==null?(a={index:r,startLine:l,endLine:l,lines:1},i.push(a),s[l]=a.index,r++):u?a=void 0:(a.endLine=l,a.lines++,s[l]=a.index)}),{lineBlocks:s,blocks:i}}md.computeHiddenBlocks=WY;var TN=Number.isNaN||function(e){return typeof e=="number"&&e!==e};function jY(e,t){return!!(e===t||TN(e)&&TN(t))}function XY(e,t){if(e.length!==t.length)return!1;for(var n=0;n<e.length;n++)if(!jY(e[n],t[n]))return!1;return!0}function KY(e,t){t===void 0&&(t=XY);var n=null;function r(){for(var a=[],s=0;s<arguments.length;s++)a[s]=arguments[s];if(n&&n.lastThis===this&&t(a,n.lastArgs))return n.lastResult;var i=e.apply(this,a);return n={lastResult:i,lastArgs:a,lastThis:this},i}return r.clear=function(){n=null},r}const zY=Object.freeze(Object.defineProperty({__proto__:null,default:KY},Symbol.toStringTag,{value:"Module"})),qY=RN(zY);(function(e){var t=st&&st.__createBinding||(Object.create?function(g,I,d,p){p===void 0&&(p=d);var m=Object.getOwnPropertyDescriptor(I,d);(!m||("get"in m?!I.__esModule:m.writable||m.configurable))&&(m={enumerable:!0,get:function(){return I[d]}}),Object.defineProperty(g,p,m)}:function(g,I,d,p){p===void 0&&(p=d),g[p]=I[d]}),n=st&&st.__setModuleDefault||(Object.create?function(g,I){Object.defineProperty(g,"default",{enumerable:!0,value:I})}:function(g,I){g.default=I}),r=st&&st.__importStar||function(g){if(g&&g.__esModule)return g;var I={};if(g!=null)for(var d in g)d!=="default"&&Object.prototype.hasOwnProperty.call(g,d)&&t(I,g,d);return n(I,g),I},a=st&&st.__importDefault||function(g){return g&&g.__esModule?g:{default:g}};Object.defineProperty(e,"__esModule",{value:!0}),e.DiffMethod=e.LineNumberPrefix=void 0;const s=R,i=r(x),o=a(X6),l=Ja;Object.defineProperty(e,"DiffMethod",{enumerable:!0,get:function(){return l.DiffMethod}});const u=a(bA),c=md,E=qY,f=E.default||E;var A;(function(g){g.LEFT="L",g.RIGHT="R"})(A||(e.LineNumberPrefix=A={}));class _ extends i.Component{constructor(I){super(I),this.resetCodeBlocks=()=>this.state.expandedBlocks.length>0?(this.setState({expandedBlocks:[]}),!0):!1,this.onBlockExpand=d=>{const p=this.state.expandedBlocks.slice();p.push(d),this.setState({expandedBlocks:p})},this.computeStyles=f(u.default),this.onLineNumberClickProxy=d=>this.props.onLineNumberClick?p=>this.props.onLineNumberClick(d,p):()=>{},this.renderWordDiff=(d,p)=>d.map((m,h)=>(0,s.jsx)("span",{className:(0,o.default)(this.styles.wordDiff,{[this.styles.wordAdded]:m.type===l.DiffType.ADDED,[this.styles.wordRemoved]:m.type===l.DiffType.REMOVED}),children:p?p(m.value):m.value},h)),this.renderLine=(d,p,m,h,O,T)=>{const N=`${m}-${d}`,C=`${T}-${O}`,P=this.props.highlightLines.includes(N)||this.props.highlightLines.includes(C),S=p===l.DiffType.ADDED,L=p===l.DiffType.REMOVED,D=p===l.DiffType.CHANGED;let B;return Array.isArray(h)?B=this.renderWordDiff(h,this.props.renderContent):this.props.renderContent?B=this.props.renderContent(h):B=h,(0,s.jsxs)(i.Fragment,{children:[!this.props.hideLineNumbers&&(0,s.jsx)("td",{onClick:d&&this.onLineNumberClickProxy(N),className:(0,o.default)(this.styles.gutter,{[this.styles.emptyGutter]:!d,[this.styles.diffAdded]:S,[this.styles.diffRemoved]:L,[this.styles.diffChanged]:D,[this.styles.highlightedGutter]:P}),children:(0,s.jsx)("pre",{className:this.styles.lineNumber,children:d})}),!this.props.splitView&&!this.props.hideLineNumbers&&(0,s.jsx)("td",{onClick:O&&this.onLineNumberClickProxy(C),className:(0,o.default)(this.styles.gutter,{[this.styles.emptyGutter]:!O,[this.styles.diffAdded]:S,[this.styles.diffRemoved]:L,[this.styles.diffChanged]:D,[this.styles.highlightedGutter]:P}),children:(0,s.jsx)("pre",{className:this.styles.lineNumber,children:O})}),this.props.renderGutter?this.props.renderGutter({lineNumber:d,type:p,prefix:m,value:h,additionalLineNumber:O,additionalPrefix:T,styles:this.styles}):null,!this.props.hideMarkers&&(0,s.jsx)("td",{className:(0,o.default)(this.styles.marker,{[this.styles.emptyLine]:!B,[this.styles.diffAdded]:S,[this.styles.diffRemoved]:L,[this.styles.diffChanged]:D,[this.styles.highlightedLine]:P}),children:(0,s.jsxs)("pre",{children:[S&&"+",L&&"-"]})}),(0,s.jsx)("td",{className:(0,o.default)(this.styles.content,{[this.styles.emptyLine]:!B,[this.styles.diffAdded]:S,[this.styles.diffRemoved]:L,[this.styles.diffChanged]:D,[this.styles.highlightedLine]:P}),children:(0,s.jsx)("pre",{className:this.styles.contentText,children:B})})]})},this.renderSplitView=({left:d,right:p},m)=>(0,s.jsxs)("tr",{className:this.styles.line,children:[this.renderLine(d.lineNumber,d.type,A.LEFT,d.value),this.renderLine(p.lineNumber,p.type,A.RIGHT,p.value)]},m),this.renderInlineView=({left:d,right:p},m)=>{let h;return d.type===l.DiffType.REMOVED&&p.type===l.DiffType.ADDED?(0,s.jsxs)(i.Fragment,{children:[(0,s.jsx)("tr",{className:this.styles.line,children:this.renderLine(d.lineNumber,d.type,A.LEFT,d.value,null)}),(0,s.jsx)("tr",{className:this.styles.line,children:this.renderLine(null,p.type,A.RIGHT,p.value,p.lineNumber)})]},m):(d.type===l.DiffType.REMOVED&&(h=this.renderLine(d.lineNumber,d.type,A.LEFT,d.value,null)),d.type===l.DiffType.DEFAULT&&(h=this.renderLine(d.lineNumber,d.type,A.LEFT,d.value,p.lineNumber,A.RIGHT)),p.type===l.DiffType.ADDED&&(h=this.renderLine(null,p.type,A.RIGHT,p.value,p.lineNumber)),(0,s.jsx)("tr",{className:this.styles.line,children:h},m))},this.onBlockClickProxy=d=>()=>this.onBlockExpand(d),this.renderSkippedLineIndicator=(d,p,m,h)=>{const{hideLineNumbers:O,splitView:T}=this.props,N=this.props.codeFoldMessageRenderer?this.props.codeFoldMessageRenderer(d,m,h):(0,s.jsxs)("pre",{className:this.styles.codeFoldContent,children:["Expand ",d," lines ..."]}),C=(0,s.jsx)("td",{children:(0,s.jsx)("a",{onClick:this.onBlockClickProxy(p),tabIndex:0,children:N})}),P=!T&&!O;return(0,s.jsxs)("tr",{className:this.styles.codeFold,children:[!O&&(0,s.jsx)("td",{className:this.styles.codeFoldGutter}),this.props.renderGutter?(0,s.jsx)("td",{className:this.styles.codeFoldGutter}):null,(0,s.jsx)("td",{className:(0,o.default)({[this.styles.codeFoldGutter]:P})}),P?(0,s.jsxs)(i.Fragment,{children:[(0,s.jsx)("td",{}),C]}):(0,s.jsxs)(i.Fragment,{children:[C,this.props.renderGutter?(0,s.jsx)("td",{}):null,(0,s.jsx)("td",{})]}),(0,s.jsx)("td",{}),(0,s.jsx)("td",{})]},`${m}-${h}`)},this.renderDiff=()=>{const{oldValue:d,newValue:p,splitView:m,disableWordDiff:h,compareMethod:O,linesOffset:T}=this.props,{lineInformation:N,diffLines:C}=(0,l.computeLineInformation)(d,p,h,O,T,this.props.alwaysShowLines),P=this.props.extraLinesSurroundingDiff<0?0:Math.round(this.props.extraLinesSurroundingDiff),{lineBlocks:S,blocks:L}=(0,c.computeHiddenBlocks)(N,C,P);return N.map((D,B)=>{if(this.props.showDiffOnly){const F=S[B];if(F!==void 0){const W=L[F].endLine===B;if(!this.state.expandedBlocks.includes(F)&&W)return(0,s.jsx)(i.Fragment,{children:this.renderSkippedLineIndicator(L[F].lines,F,D.left.lineNumber,D.right.lineNumber)},B);if(!this.state.expandedBlocks.includes(F))return null}}return m?this.renderSplitView(D,B):this.renderInlineView(D,B)})},this.render=()=>{const{oldValue:d,newValue:p,useDarkTheme:m,leftTitle:h,rightTitle:O,splitView:T,hideLineNumbers:N,hideMarkers:C,nonce:P}=this.props;if(this.props.compareMethod!==l.DiffMethod.JSON&&(typeof d!="string"||typeof p!="string"))throw Error('"oldValue" and "newValue" should be strings');this.styles=this.computeStyles(this.props.styles,m,P);const S=this.renderDiff();let L=N?2:3,D=N?2:4;C&&(L-=1,D-=1);const B=this.props.renderGutter?1:0,F=(h||O)&&(0,s.jsxs)("tr",{children:[(0,s.jsx)("td",{colSpan:(T?L:D)+B,className:this.styles.titleBlock,children:(0,s.jsx)("pre",{className:this.styles.contentText,children:h})}),T&&(0,s.jsx)("td",{colSpan:L+B,className:this.styles.titleBlock,children:(0,s.jsx)("pre",{className:this.styles.contentText,children:O})})]});return(0,s.jsx)("table",{className:(0,o.default)(this.styles.diffContainer,{[this.styles.splitView]:T}),children:(0,s.jsxs)("tbody",{children:[F,S]})})},this.state={expandedBlocks:[]}}}_.defaultProps={oldValue:"",newValue:"",splitView:!0,highlightLines:[],disableWordDiff:!1,compareMethod:l.DiffMethod.CHARS,styles:{},hideLineNumbers:!1,hideMarkers:!1,extraLinesSurroundingDiff:3,showDiffOnly:!0,useDarkTheme:!1,linesOffset:0,nonce:""},e.default=_})(j6);function hN(e){const t=new CSSStyleSheet;return t.replaceSync(e),t}async function JY(e){gh("open",{path:e})}async function ZY(){gh("close")}function AN(){return!!(window.__spotlight&&window.document.getElementById("sentry-spotlight-root"))}async function QY(e={}){var t;if(typeof document>"u"||AN())return;const n=(t=window.__spotlight)==null?void 0:t.initOptions;n&&(e={...n,...e});const{openOnInit:r=!1,sidecarUrl:a=Lv,anchor:s=KO,integrations:i,experiments:o=kf,showClearEventsButton:l=!0,initialEvents:u=void 0,startFrom:c=void 0}=e,E=new URL(a).origin===document.location.origin,f=QO(a,"/stream"),A=e.fullPage??E,_=e.showTriggerButton??!A,g=e.injectImmediately??(E||A),I=e.debug??document.location.hash.endsWith("debug");I&&Hv();const d={...kf,...o},p=()=>[zw({injectIntoSDK:!E})],m={open:JY,close:ZY,experiments:d,sidecarUrl:f},[h]=await ZO(i??p(),m),O=document.createElement("div");O.id="sentry-spotlight-root";const T=O.attachShadow({mode:"open"}),N=document.createElement("div");A?(O.style.height="100%",O.style.backgroundColor=_v.indigo[950],N.style.height="inherit"):(N.style.position="absolute",N.style.top="0",N.style.left="0",N.style.right="0"),T.appendChild(N);const C=hN(Wv);T.adoptedStyleSheets=[hN(Eb),C];const P=h.flatMap(D=>{var B;return((B=D.tabs)==null?void 0:B.call(D,{processedEvents:[]}).map(F=>({...F,processedEvents:[]})))||[]}),S=c||(P.length?`/${P[0].id}`:"/no-tabs");Ke("Starting from",S),E&&D6(S,{debug:I}),Yf.createRoot(N).render(R.jsx(sv,{initialEntries:[S],children:R.jsx(PM,{context:m,children:R.jsx(Vv,{integrations:h,openOnInit:r,showTriggerButton:_,sidecarUrl:a,anchor:s,fullPage:A,showClearEventsButton:l,initialEvents:u})})}));function L(){if(AN()){Ke("Spotlight already injected, bailing.");return}Ke("Injecting into application");const D=new CSSStyleSheet;D.replaceSync(`body.${Gf} { overflow: hidden!important; }`),document.adoptedStyleSheets=[...document.adoptedStyleSheets,D],document.body.append(O)}document.readyState==="complete"||g?L():window.addEventListener("load",L),window.addEventListener("error",L)}(function(e){e&&e.init({integrations:[e.sentry(),e.console()]})})(window.Spotlight);window.__spotlight||(window.__spotlight={});window.__spotlight.initOptions||(window.__spotlight.initOptions={});if(!window.__spotlight.initOptions.sidecarUrl){const e=performance.getEntriesByType("navigation");if(e.length>0){const t=e[0].serverTiming;if(t&&t.length>0){for(const{name:n,description:r}of t)if(n==="sentrySpotlightPort"){window.__spotlight.initOptions.sidecarUrl=`http://localhost:${r}`;break}}}}QY();
|
package/dist/spotlight.cjs
CHANGED
|
@@ -41,5 +41,5 @@ Url: ${sl(t)}`),!0)}function mY(t,e){return t.type||!e||!e.length?!1:gY(t).some(
|
|
|
41
41
|
`);for(let l of u.split(`
|
|
42
42
|
`))n.write(`data:${l}
|
|
43
43
|
`);n.write(`
|
|
44
|
-
`)});r.on("close",()=>{t.unsubscribe(s),n.end()})}else if(r.method==="POST"){jt.debug("\u{1F4E9} Received event");let s="",a=r,u=r.headers["content-encoding"];u==="gzip"?a=r.pipe((0,Df.createGunzip)()):u==="deflate"&&(a=r.pipe((0,Df.createInflate)())),a.on("readable",()=>{let l;for(;(l=a.read())!==null;)s+=l}),a.on("end",()=>{var l,p;let _=(l=r.headers["content-type"])==null?void 0:l.split(";")[0].toLocaleLowerCase();if((p=i?.get("sentry_client"))!=null&&p.startsWith("sentry.javascript.browser")&&r.headers.origin&&(_="application/x-sentry-envelope"),_?t.put([_,s]):jt.warn("No content type, skipping payload..."),process.env.SPOTLIGHT_CAPTURE||e){let f=new Date().getTime(),E=`${_?.replace(/[^a-z0-9]/gi,"_")||"no_content_type"}-${f}.txt`;e?e(s):((0,Sa.createWriteStream)(E).write(s),jt.info(`\u{1F5C3}\uFE0F Saved data to ${E}`))}n.writeHead(200,{"Cache-Control":"no-cache",Connection:"keep-alive"}),n.end()})}else{Gq(r,n);return}},Ede=t=>function(e,r,n){let o=`${n||e.url}`;o==="/"&&(o="/src/index.html"),o=o.slice(1);let i=(0,_i.extname)(o),s="text/html";switch(i){case".js":s="text/javascript";break;case".css":s="text/css";break;case".json":s="application/json";break}Object.hasOwn(t,o)?(r.writeHead(200,{"Content-Type":s}),r.end(t[o])):Lf(e,r)};function mde(t,e){e.writeHead(200,{"Content-Type":"text/plain",...Dq,...Uq}),e.end("OK")}function Sde(t,e){t.method==="DELETE"?(e.writeHead(200,{"Content-Type":"text/plain"}),Rde(),e.end("Cleared")):Gq(t,e)}function hde(t=process.cwd()){return(e,r)=>{if(e.method!=="POST"){r.writeHead(405),r.end();return}let n="";e.on("data",o=>{n+=o}),e.on("end",()=>{let o=(0,_i.resolve)(t,n);jt.debug(`Launching editor for ${o}`),(0,Mq.default)(o,(i,s)=>{jt.error(`Failed to launch editor for ${i}: ${s}`)}),r.writeHead(204),r.end()})}}function wq(t){return Uf((e,r)=>{r.writeHead(t),r.end()},{name:`HTTP ${t}`,op:`sidecar.http.error.${t}`,attributes:{"http.response.status_code":t}})}var Lf=wq(404),Gq=wq(405);function Tde(t,e,r,n,o){r&&!n&&(n={"/src/index.html":(0,Sa.readFileSync)((0,_i.join)(r,"src/index.html")),"/assets/main.js":(0,Sa.readFileSync)((0,_i.join)(r,"assets/main.js"))});let i=[[/^\/health$/,mde],[/^\/clear$/,mu(Sde)],[/^\/stream$|^\/api\/\d+\/envelope\/?$/,mu(fde(t,o))],[/^\/open$/,mu(hde(r))],[RegExp(`^${iq}$`),mu(lde)],[/^.+$/,n!=null?mu(Ede(n)):Lf]],s=(0,xf.createServer)((l,p)=>{var _;let f=l.url;if(!f)return Lf(l,p);let E=l.headers.host||"localhost",{pathname:S,searchParams:T}=new URL(f,`http://${E}`),h=i.find(O=>O[0].test(S));return h?We({name:`HTTP ${l.method} ${S}`,op:`sidecar.http.${(_=l.method)==null?void 0:_.toLowerCase()}`,forceTransaction:!0,attributes:{"http.request.method":l.method,"http.request.url":f,"http.request.query":T.toString(),"server.address":E,"server.port":l.socket.localPort}},O=>{let P=yi();p.appendHeader("server-timing"
|
|
44
|
+
`)});r.on("close",()=>{t.unsubscribe(s),n.end()})}else if(r.method==="POST"){jt.debug("\u{1F4E9} Received event");let s="",a=r,u=r.headers["content-encoding"];u==="gzip"?a=r.pipe((0,Df.createGunzip)()):u==="deflate"&&(a=r.pipe((0,Df.createInflate)())),a.on("readable",()=>{let l;for(;(l=a.read())!==null;)s+=l}),a.on("end",()=>{var l,p;let _=(l=r.headers["content-type"])==null?void 0:l.split(";")[0].toLocaleLowerCase();if((p=i?.get("sentry_client"))!=null&&p.startsWith("sentry.javascript.browser")&&r.headers.origin&&(_="application/x-sentry-envelope"),_?t.put([_,s]):jt.warn("No content type, skipping payload..."),process.env.SPOTLIGHT_CAPTURE||e){let f=new Date().getTime(),E=`${_?.replace(/[^a-z0-9]/gi,"_")||"no_content_type"}-${f}.txt`;e?e(s):((0,Sa.createWriteStream)(E).write(s),jt.info(`\u{1F5C3}\uFE0F Saved data to ${E}`))}n.writeHead(200,{"Cache-Control":"no-cache",Connection:"keep-alive"}),n.end()})}else{Gq(r,n);return}},Ede=t=>function(e,r,n){let o=`${n||e.url}`;o==="/"&&(o="/src/index.html"),o=o.slice(1);let i=(0,_i.extname)(o),s="text/html";switch(i){case".js":s="text/javascript";break;case".css":s="text/css";break;case".json":s="application/json";break}Object.hasOwn(t,o)?(r.writeHead(200,{"Content-Type":s}),r.end(t[o])):Lf(e,r)};function mde(t,e){e.writeHead(200,{"Content-Type":"text/plain",...Dq,...Uq}),e.end("OK")}function Sde(t,e){t.method==="DELETE"?(e.writeHead(200,{"Content-Type":"text/plain"}),Rde(),e.end("Cleared")):Gq(t,e)}function hde(t=process.cwd()){return(e,r)=>{if(e.method!=="POST"){r.writeHead(405),r.end();return}let n="";e.on("data",o=>{n+=o}),e.on("end",()=>{let o=(0,_i.resolve)(t,n);jt.debug(`Launching editor for ${o}`),(0,Mq.default)(o,(i,s)=>{jt.error(`Failed to launch editor for ${i}: ${s}`)}),r.writeHead(204),r.end()})}}function wq(t){return Uf((e,r)=>{r.writeHead(t),r.end()},{name:`HTTP ${t}`,op:`sidecar.http.error.${t}`,attributes:{"http.response.status_code":t}})}var Lf=wq(404),Gq=wq(405);function Tde(t,e,r,n,o){r&&!n&&(n={"/src/index.html":(0,Sa.readFileSync)((0,_i.join)(r,"src/index.html")),"/assets/main.js":(0,Sa.readFileSync)((0,_i.join)(r,"assets/main.js"))});let i=[[/^\/health$/,mde],[/^\/clear$/,mu(Sde)],[/^\/stream$|^\/api\/\d+\/envelope\/?$/,mu(fde(t,o))],[/^\/open$/,mu(hde(r))],[RegExp(`^${iq}$`),mu(lde)],[/^.+$/,n!=null?mu(Ede(n)):Lf]],s=(0,xf.createServer)((l,p)=>{var _;let f=l.url;if(!f)return Lf(l,p);let E=l.headers.host||"localhost",{pathname:S,searchParams:T}=new URL(f,`http://${E}`),h=i.find(O=>O[0].test(S));return h?We({name:`HTTP ${l.method} ${S}`,op:`sidecar.http.${(_=l.method)==null?void 0:_.toLowerCase()}`,forceTransaction:!0,attributes:{"http.request.method":l.method,"http.request.url":f,"http.request.query":T.toString(),"server.address":E,"server.port":l.socket.localPort}},O=>{let P=yi();p.appendHeader("server-timing",[`sentryTrace;desc="${P["sentry-trace"]}"`,`baggage;desc="${P.baggage}"`,`sentrySpotlightPort;desc=${e}`].join(", "));let C=h[1](l,p,S,T);return O.setAttribute("http.response.status_code",p.statusCode),C}):Lf(l,p)});return s.on("error",a),s.listen(e,()=>{u(e,r)}),s;function a(l){"code"in l&&l.code==="EADDRINUSE"?(jt.info(`Port ${e} in use, retrying...`),setTimeout(()=>{s.close(),s.listen(e),jt.info(`Port ${e} in use, retrying...`)},5e3)):Wt(l)}function u(l,p){jt.info(`Sidecar listening on ${l}`),p&&jt.info(`You can open: http://localhost:${l} to see the Spotlight overlay directly`)}}var ma,Bq=new CA,gde=Uf(t=>{if(typeof t=="string"){let e=Number(t);return/^\d+$/.test(t)&&e>0&&e<=65535}return t>0&&t<=65535},{name:"isValidPort",op:"sidecar.server.portCheck"}),Ade=Uf(t=>new Promise(e=>{let r=(0,xf.get)({hostname:"localhost",port:t,path:"/health",method:"GET",timeout:2e3,headers:{Connection:"close"}},n=>{let o=n.headers["x-powered-by"];e(o==="spotlight-by-sentry")});r.on("error",()=>{e(!1)}),r.end()}),{name:"isSidecarRunning",op:"sidecar.server.collideCheck"});function Vq({port:t,logger:e,basePath:r,filesToServe:n,debug:o,incomingPayload:i}={}){let s=8969;e&&pde(e),(o||process.env.SPOTLIGHT_DEBUG)&&dde(!0),t&&!gde(t)?(jt.info("Please provide a valid port."),process.exit(1)):t&&(s=typeof t=="string"?Number(t):t),Ade(s).then(a=>{a?jt.info(`Sidecar is already running on port ${s}`):ma||(ma=Tde(Bq,s,r,n,i))})}function Rde(){Bq.clear()}var yq=!1,Hq=()=>{(yq||!ma)&&(jt.info("Bye."),process.exit(0)),ma&&(yq=!0,jt.info("Shutting down server gracefully..."),ma.close(),ma.closeAllConnections())};process.on("SIGINT",Hq);process.on("SIGTERM",Hq);var Fq=require("node:fs"),jq=B(require("node:module"),1),yA=require("node:path"),qq=require("node:url"),kq=require("node:zlib");c();cA({dsn:"https://51bcd92dba1128934afd1c5726c84442@o1.ingest.us.sentry.io/4508404727283713",environment:"development",release:"2.8.1",debug:!!process.env.SENTRY_DEBUG,tracesSampleRate:1,beforeSendTransaction:t=>(t.server_name=void 0,t),beforeSend:t=>{let e=t.exception?.values;if(!e)return t;for(let r of e)if(r.stacktrace)for(let n of r.stacktrace.frames)n.filename&&(n.filename=n.filename?.replace(process.env.HOME,"~"));return t.server_name=void 0,t}});var Ode=jq.default.createRequire(d),hu=null;try{hu=Ode("node:sea")}catch{hu={isSea:()=>!1}}tl("CLI",{sea:hu.isSea(),argv:process.argv.map(t=>t.replace(process.env.HOME,"~"))});var vde=(t,e={})=>(...r)=>We({name:t.name,attributes:{args:r},...e},()=>t(...r)),NA=vde(hu.isSea()?t=>Buffer.from(hu.getRawAsset(t)):(()=>{let t=(0,yA.join)((0,qq.fileURLToPath)(d),"../../dist/overlay/");return e=>(0,Fq.readFileSync)((0,yA.join)(t,e))})(),{name:"readAsset",op:"cli.asset.read"});We({name:"Spotlight CLI",op:"cli"},()=>{We({name:"ASCII Art",op:"cli.art.ascii"},()=>{let t=process.stdout.columns;if(!process.stdout.isTTY||t<35)return;let e="",r=We({name:"Inflate ASCII Art Data",op:"cli.art.ascii.inflate"},()=>Uint8Array.from((0,kq.inflateRawSync)(Buffer.from("bY7LCgMxFEK9L5MwDDSL9P//1DJMKGXowoUcUaFZOk8dU2Op9+qZVkYQoFsaEqA6PZxxma1AoMG+TiONTgcfAd741YxxVf8gCzCgWcYB7OSj9sjW7t2/eKxKAxkIYv8NqL3FpVY25CmjrBSuDw==","base64")))),n="\x1B[",o=`${n}38;5;`,i=`${o}96m`,s=`${o}61m`,a=`${n}1m`,u=`${n}0m`,l=`${u}
|
|
45
45
|
`,p=.22,_=0,f=0,E=0,S=26,T=0;for(let h of r)if(h===255)e+=l,_=f=0,E++===5&&(p=p/-3),S=Math.round(S*(1+p)),T=Math.round(Math.random()*18);else{for(;h-->=0&&f<t;)f<S-1?e+=i:f===S-1?e+=s:f===S+T&&(e+=`${u}${a}`),e+=_?f>=35?"#":"s":" ",f++;_=!_}e+=l,process.stdout.write(e)}),We({name:"Setup Sidecar",op:"cli.setup.sidecar"},()=>{let t=process.argv.length>=3?Number(process.argv[2]):void 0,e="manifest.json",r="src/index.html",n=process.cwd(),o=Object.create(null);We({name:"Setup Server Assets",op:"cli.setup.sidecar.assets"},()=>{let i=JSON.parse(NA(e));o[r]=NA(r);let s=Object.values(i);for(let a of s)o[a.file]=NA(a.file)}),Vq({port:t,basePath:n,filesToServe:o})})});
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@spotlightjs/spotlight",
|
|
3
3
|
"description": "Spotlight - Sentry for development. Containing the overlay and the sidecar.",
|
|
4
|
-
"version": "2.8.
|
|
4
|
+
"version": "2.8.1",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"files": [
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"portable-executable-signature": "^2.0.6",
|
|
39
39
|
"postject": "1.0.0-alpha.6",
|
|
40
40
|
"@spotlightjs/overlay": "2.8.1",
|
|
41
|
-
"@spotlightjs/sidecar": "1.9.
|
|
41
|
+
"@spotlightjs/sidecar": "1.9.4"
|
|
42
42
|
},
|
|
43
43
|
"devDependencies": {
|
|
44
44
|
"@types/node": "^18.19.55",
|